AuthXConfig
authx.config.AuthXConfig
AuthXConfig(__pydantic_self__, _case_sensitive=None, _env_prefix=None, _env_file=ENV_FILE_SENTINEL, _env_file_encoding=None, _env_ignore_empty=None, _env_nested_delimiter=None, _env_parse_none_str=None, _env_parse_enums=None, _cli_prog_name=None, _cli_parse_args=None, _cli_settings_source=None, _cli_parse_none_str=None, _cli_hide_none_type=None, _cli_avoid_json=None, _cli_enforce_required=None, _cli_use_class_docs_for_groups=None, _cli_prefix=None, _secrets_dir=None, **values)
Bases: BaseSettings
AuthX Base Configuration Object
PARAMETER | DESCRIPTION |
---|---|
BaseSettings |
BaseSettings class from Pydantic
TYPE:
|
RAISES | DESCRIPTION |
---|---|
BadConfigurationError
|
If JWT_ALGORITHM is not supported |
BadConfigurationError
|
If JWT_ALGORITHM requires a key and it is not set |
RETURNS | DESCRIPTION |
---|---|
AuthXConfig
|
AuthX Configuration Object |
PARAMETER | DESCRIPTION |
---|---|
__pydantic_self__ |
|
_case_sensitive |
TYPE:
|
_env_prefix |
TYPE:
|
_env_file |
TYPE:
|
_env_file_encoding |
TYPE:
|
_env_ignore_empty |
TYPE:
|
_env_nested_delimiter |
TYPE:
|
_env_parse_none_str |
TYPE:
|
_env_parse_enums |
TYPE:
|
_cli_prog_name |
TYPE:
|
_cli_parse_args |
TYPE:
|
_cli_settings_source |
TYPE:
|
_cli_parse_none_str |
TYPE:
|
_cli_hide_none_type |
TYPE:
|
_cli_avoid_json |
TYPE:
|
_cli_enforce_required |
TYPE:
|
_cli_use_class_docs_for_groups |
TYPE:
|
_cli_prefix |
TYPE:
|
_secrets_dir |
TYPE:
|
**values |
TYPE:
|
Source code in pydantic_settings/main.py
model_config
class-attribute
model_config = SettingsConfigDict(extra='forbid', arbitrary_types_allowed=True, validate_default=True, case_sensitive=False, env_prefix='', env_file=None, env_file_encoding=None, env_ignore_empty=False, env_nested_delimiter=None, env_parse_none_str=None, env_parse_enums=None, cli_prog_name=None, cli_parse_args=None, cli_settings_source=None, cli_parse_none_str=None, cli_hide_none_type=False, cli_avoid_json=False, cli_enforce_required=False, cli_use_class_docs_for_groups=False, cli_prefix='', json_file=None, json_file_encoding=None, yaml_file=None, yaml_file_encoding=None, toml_file=None, secrets_dir=None, protected_namespaces=('model_', 'settings_'))
JWT_ACCESS_TOKEN_EXPIRES
class-attribute
instance-attribute
JWT_DECODE_ALGORITHMS
class-attribute
instance-attribute
JWT_REFRESH_TOKEN_EXPIRES
class-attribute
instance-attribute
JWT_ACCESS_COOKIE_NAME
class-attribute
instance-attribute
JWT_REFRESH_COOKIE_NAME
class-attribute
instance-attribute
JWT_ACCESS_CSRF_COOKIE_NAME
class-attribute
instance-attribute
JWT_ACCESS_CSRF_FIELD_NAME
class-attribute
instance-attribute
JWT_ACCESS_CSRF_HEADER_NAME
class-attribute
instance-attribute
JWT_CSRF_METHODS
class-attribute
instance-attribute
JWT_REFRESH_CSRF_COOKIE_NAME
class-attribute
instance-attribute
JWT_REFRESH_CSRF_FIELD_NAME
class-attribute
instance-attribute
JWT_REFRESH_CSRF_HEADER_NAME
class-attribute
instance-attribute
JWT_IMPLICIT_REFRESH_ROUTE_EXCLUDE
class-attribute
instance-attribute
JWT_IMPLICIT_REFRESH_ROUTE_INCLUDE
class-attribute
instance-attribute
JWT_IMPLICIT_REFRESH_METHOD_EXCLUDE
class-attribute
instance-attribute
JWT_IMPLICIT_REFRESH_METHOD_INCLUDE
class-attribute
instance-attribute
JWT_IMPLICIT_REFRESH_DELTATIME
class-attribute
instance-attribute
is_algo_symmetric
property
Check if the JWT_ALGORITHM is a symmetric encryption algorithm
is_algo_asymmetric
property
Check if the JWT_ALGORITHM is an asymmetric encryption algorithm
settings_customise_sources
classmethod
settings_customise_sources(settings_cls, init_settings, env_settings, dotenv_settings, file_secret_settings)
Define the sources and their order for loading the settings values.
PARAMETER | DESCRIPTION |
---|---|
settings_cls |
TYPE:
|
init_settings |
TYPE:
|
env_settings |
TYPE:
|
dotenv_settings |
TYPE:
|
file_secret_settings |
TYPE:
|
PARAMETER | DESCRIPTION |
---|---|
settings_cls |
The Settings class.
TYPE:
|
init_settings |
The
TYPE:
|
env_settings |
The
TYPE:
|
dotenv_settings |
The
TYPE:
|
file_secret_settings |
The
TYPE:
|
RETURNS | DESCRIPTION |
---|---|
tuple[PydanticBaseSettingsSource, ...]
|
A tuple containing the sources and their order for loading the settings values. |