Home Assistant Unofficial Reference 2024.12.1
homeassistant.components.auth.TokenView Class Reference
Inheritance diagram for homeassistant.components.auth.TokenView:
[legend]
Collaboration diagram for homeassistant.components.auth.TokenView:
[legend]

Public Member Functions

None __init__ (self, RetrieveResultType retrieve_auth)
 
web.Response post (self, web.Request request)
 

Static Public Attributes

bool cors_allowed = True
 
string name = "api:auth:token"
 
bool requires_auth = False
 
string url = "/auth/token"
 

Private Member Functions

web.Response _async_handle_auth_code (self, HomeAssistant hass, MultiDictProxy[str] data, web.Request request)
 
web.Response _async_handle_refresh_token (self, HomeAssistant hass, MultiDictProxy[str] data, web.Request request)
 

Private Attributes

 _retrieve_auth
 

Detailed Description

View to issue tokens.

Definition at line 238 of file __init__.py.

Constructor & Destructor Documentation

◆ __init__()

None homeassistant.components.auth.TokenView.__init__ (   self,
RetrieveResultType  retrieve_auth 
)
Initialize the token view.

Definition at line 246 of file __init__.py.

Member Function Documentation

◆ _async_handle_auth_code()

web.Response homeassistant.components.auth.TokenView._async_handle_auth_code (   self,
HomeAssistant  hass,
MultiDictProxy[str]  data,
web.Request  request 
)
private
Handle authorization code request.

Definition at line 277 of file __init__.py.

◆ _async_handle_refresh_token()

web.Response homeassistant.components.auth.TokenView._async_handle_refresh_token (   self,
HomeAssistant  hass,
MultiDictProxy[str]  data,
web.Request  request 
)
private
Handle refresh token request.

Definition at line 345 of file __init__.py.

◆ post()

web.Response homeassistant.components.auth.TokenView.post (   self,
web.Request  request 
)
Grant a token.

Definition at line 251 of file __init__.py.

Member Data Documentation

◆ _retrieve_auth

homeassistant.components.auth.TokenView._retrieve_auth
private

Definition at line 248 of file __init__.py.

◆ cors_allowed

bool homeassistant.components.auth.TokenView.cors_allowed = True
static

Definition at line 244 of file __init__.py.

◆ name

string homeassistant.components.auth.TokenView.name = "api:auth:token"
static

Definition at line 242 of file __init__.py.

◆ requires_auth

bool homeassistant.components.auth.TokenView.requires_auth = False
static

Definition at line 243 of file __init__.py.

◆ url

string homeassistant.components.auth.TokenView.url = "/auth/token"
static

Definition at line 241 of file __init__.py.


The documentation for this class was generated from the following file: