Database adapters¶
litestar_auth.db
¶
Database abstractions and implementations.
BaseOAuthAccountStore
¶
Bases: Protocol
Structural contract for linked OAuth-account persistence backends.
BaseUserStore
¶
Bases: ABC
Abstract CRUD interface for user persistence backends.
create(user_dict)
abstractmethod
async
¶
delete(user_id)
abstractmethod
async
¶
get(user_id)
abstractmethod
async
¶
get_by_email(email)
abstractmethod
async
¶
get_by_field(field_name, value)
abstractmethod
async
¶
Return the user where field_name equals value, if present.
Implementations may perform a direct column/attribute lookup. Invalid
field_name values are a programming error and may surface as
backend-specific errors at runtime.