authenticate
If the given credentials are valid, return a User object.
def authenticate(
request: HttpRequest = None,
**credentials: dict
) - > User
If the given credentials are valid, return a User object.
Parameters
| Name | Type | Description |
|---|---|---|
| request | HttpRequest = None | The current HTTP request object, used by backends for metadata or session handling. |
| **credentials | dict | Keyword arguments containing authentication credentials such as username, password, or tokens. |
Returns
| Type | Description |
|---|---|
User | The authenticated User object annotated with the backend path, or None if authentication failed for all backends. |