From: Tom Christie Date: Wed, 1 May 2019 14:33:41 +0000 (+0100) Subject: Update README X-Git-Tag: 0.3.0~47 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=4fe2f694a17972efe71fcd9460f57b2b8f3dcfd7;p=thirdparty%2Fhttpx.git Update README --- diff --git a/README.md b/README.md index 0c8817a7..649affdb 100644 --- a/README.md +++ b/README.md @@ -61,27 +61,41 @@ Alternatively, thread-synchronous requests: --- +## Dependencies + +* `h11` - HTTP/1.1 support. +* `h2` - HTTP/2 support. +* `certifi` - SSL certificates. +* `chardet` - Fallback auto-detection for response encoding. +* `idna` - Internationalized domain name support. +* `rfc3986` - URL parsing & normalization. +* `brotlipy` - Decoding for "brotli" compressed responses. *(Optional)* + +Additionally, credit is due to for `urllib3` for plenty of design inspiration. + +--- + ## API Reference #### `Client([ssl], [timeout], [pool_limits], [max_redirects])` -* `async def .request(method, url, ...)` -* `async def .get(url, ...)` -* `async def .options(url, ...)` -* `async def .head(url, ...)` -* `async def .post(url, ...)` -* `async def .put(url, ...)` -* `async def .patch(url, ...)` -* `async def .delete(url, ...)` +* `async def .request(method, url, [content], [headers], [stream], [allow_redirects], [ssl], [timeout])` +* `async def .get(url, [headers], [stream], [allow_redirects], [ssl], [timeout])` +* `async def .options(url, [headers], [stream], [allow_redirects], [ssl], [timeout])` +* `async def .head(url, [headers], [stream], [allow_redirects], [ssl], [timeout])` +* `async def .post(url, [content], [headers], [stream], [allow_redirects], [ssl], [timeout])` +* `async def .put(url, [content], [headers], [stream], [allow_redirects], [ssl], [timeout])` +* `async def .patch(url, [content], [headers], [stream], [allow_redirects], [ssl], [timeout])` +* `async def .delete(url, [content], [headers], [stream], [allow_redirects], [ssl], [timeout])` * `def .prepare_request(request)` -* `async def .send(request, ...)` +* `async def .send(request, [stream], [allow_redirects], [ssl], [timeout])` * `async def .close()` ### Models #### `Response(...)` -*An HTTP response.** +*An HTTP response.* * `.status_code` - **int** * `.reason_phrase` - **str**