minos.networks.http.requests
Classes
Http Request class. |
|
Http Response class. |
Exceptions
Http Response Exception class. |
- class HttpRequest[source]
-
Http Request class.
- user
Returns the UUID of the user making the Request.
- abstract property headers: dict[str, str]
Get the headers of the request.
- Returns
A dictionary in which keys are
str
instances and values arestr
instances.
- abstract property has_url_params: bool
Check if the request has url params.
- Returns
True
if it has url params orFalse
otherwise.
- abstract property has_query_params: bool
Check if the request has query params.
- Returns
True
if it has query params orFalse
otherwise.
- async content(**kwargs)
Get the request content.
- Parameters
kwargs – Additional named arguments.
- Returns
The request content.
- Return type
- abstract property has_content: bool
Check if the request has content.
- Returns
True
if it has content orFalse
otherwise.
- class HttpResponse[source]
-
Http Response class.
- classmethod from_response(response)[source]
Build a new
RestRequest
from another response.- Parameters
- Returns
A
RestResponse
instance.- Return type
- async content(**kwargs)
Response content.
- Parameters
kwargs – Additional named arguments.
- Returns
A list of items.
- Return type