Requests

from aioauth import requests

Request objects used throughout the project.


class Query(client_id: str | None = None, redirect_uri: str = '', response_type: str | None = None, state: str = '', scope: str = '', nonce: str | None = None, code_challenge_method: Literal['plain', 'S256'] | None = None, code_challenge: str | None = None, response_mode: Literal['query', 'form_post', 'fragment'] | None = None)[source]

Object that contains a client’s query string portion of a request. Read more on query strings here.

client_id: str | None = None
redirect_uri: str = ''
response_type: str | None = None
state: str = ''
scope: str = ''
nonce: str | None = None
code_challenge_method: Literal['plain', 'S256'] | None = None
code_challenge: str | None = None
response_mode: Literal['query', 'form_post', 'fragment'] | None = None
class Post(grant_type: Literal['authorization_code', 'password', 'client_credentials', 'refresh_token'] | None = None, client_id: str | None = None, client_secret: str | None = None, redirect_uri: str | None = None, scope: str = '', username: str | None = None, password: str | None = None, refresh_token: str | None = None, code: str | None = None, token: str | None = None, token_type_hint: str | None = None, code_verifier: str | None = None)[source]

Object that contains a client’s post request portion of a request. Read more on post requests here.

grant_type: Literal['authorization_code', 'password', 'client_credentials', 'refresh_token'] | None = None
client_id: str | None = None
client_secret: str | None = None
redirect_uri: str | None = None
scope: str = ''
username: str | None = None
password: str | None = None
refresh_token: str | None = None
code: str | None = None
token: str | None = None
token_type_hint: str | None = None
code_verifier: str | None = None
class BaseRequest(method: Literal['GET', 'POST'], query: ~TQuery, post: ~TPost, headers: aioauth.collections.HTTPHeaderDict = <factory>, url: str = '', user: Optional[~TUser] = None, settings: aioauth.config.Settings = <factory>)[source]
method: Literal['GET', 'POST']
query: TQuery
post: TPost
headers: HTTPHeaderDict
url: str = ''
user: TUser | None = None
settings: Settings
class Request(method: ~typing.Literal['GET', 'POST'], query: ~aioauth.requests.Query = <factory>, post: ~aioauth.requests.Post = <factory>, headers: ~aioauth.collections.HTTPHeaderDict = <factory>, url: str = '', user: ~typing.Any | None = None, settings: ~aioauth.config.Settings = <factory>)[source]

Object that contains a client’s complete request.

query: Query
post: Post
user: Any | None = None