http
Async HTTP request client implementation built on httpx.
Client ¶
Base class for HTTP clients.
client = Client()
response = await client.request("GET", "/some/resource")
assert response.status_code == 200
json ¶
request
async
¶
Passes *args, **kwargs straight through to
httpx.AsyncClient.request, we call raise_for_status() on the
response and wrap any HTTPX error in a ClientException.
Parameters¶
args : Any
Unpacked into httpx.AsyncClient.request().
*kwargs : Any
Unpacked into httpx.AsyncClient.request().
Returns¶
httpx.Response
Return value of httpx.AsyncClient.request() after calling
httpx.Response.raise_for_status()
Raises¶
ClientException
Wraps any httpx.HTTPError arising from the request or response status check.