Skip to content

Base Model Protocols

Types

fastauth.models.UP module-attribute

UP = TypeVar('UP', bound=UserProtocol)

fastauth.models.ID module-attribute

ID = TypeVar('ID')

fastauth.models.PP module-attribute

PP = TypeVar('PP', bound=PermissionProtocol)

fastauth.models.RP module-attribute

RP = TypeVar('RP', bound=RoleProtocol)

fastauth.models.URPP module-attribute

URPP = TypeVar('URPP', bound=RBACUserProtocol)

fastauth.models.OAP module-attribute

OAP = TypeVar('OAP', bound=OAuthProtocol)

fastauth.models.UOAP module-attribute

UOAP = TypeVar('UOAP', bound=OAuthUserProtocol)

User protocols

fastauth.models.UserProtocol

Bases: Protocol[ID]

id instance-attribute

id

email instance-attribute

email

username instance-attribute

username

hashed_password instance-attribute

hashed_password

is_active instance-attribute

is_active

is_verified instance-attribute

is_verified

fastauth.models.RBACUserProtocol

Bases: UserProtocol[ID], Generic[ID, RP, PP]

id instance-attribute

id

email instance-attribute

email

username instance-attribute

username

hashed_password instance-attribute

hashed_password

is_active instance-attribute

is_active

is_verified instance-attribute

is_verified

role_id instance-attribute

role_id

role instance-attribute

role

permissions instance-attribute

permissions

fastauth.models.OAuthUserProtocol

Bases: UserProtocol[ID], Generic[ID, OAP]

id instance-attribute

id

email instance-attribute

email

username instance-attribute

username

hashed_password instance-attribute

hashed_password

is_active instance-attribute

is_active

is_verified instance-attribute

is_verified

oauth_accounts instance-attribute

oauth_accounts

RBAC protocols

fastauth.models.RoleProtocol

Bases: Protocol[PP]

id instance-attribute

id

codename instance-attribute

codename

permissions instance-attribute

permissions

fastauth.models.PermissionProtocol

Bases: Protocol

id instance-attribute

id

codename instance-attribute

codename

detail instance-attribute

detail

OAuth protocol

fastauth.models.OAuthProtocol

Bases: Protocol[ID]

id instance-attribute

id

oauth_name instance-attribute

oauth_name

access_token instance-attribute

access_token

expires_at instance-attribute

expires_at

refresh_token instance-attribute

refresh_token

account_id instance-attribute

account_id

account_email instance-attribute

account_email