app.repository package¶
Submodules¶
app.repository.base_repository module¶
- class app.repository.base_repository.BaseRepository(session_factory: Callable[[...], AbstractContextManager[Session]], model)[source]¶
Bases:
object
Base repository providing common CRUD operations.
- session_factory¶
Factory for creating SQLAlchemy sessions.
- Type:
Callable[…, AbstractContextManager[Session]]
- model¶
SQLAlchemy model class.
- async create(schema)[source]¶
Creates a new record.
- Parameters:
schema – The schema containing the record data.
- Returns:
The created record.
- Return type:
- delete_by_id(id: int)[source]¶
Deletes a record by its ID.
- Parameters:
id (int) – The record ID.
- Returns:
None
- read_by_column(column: str, value: str, eager=False, only_one=True, not_found_raise_exception=True, not_found_message='Not found {column} : {value}')[source]¶
Reads records by a specified column and value.
- Parameters:
column (str) – The column name.
value (str) – The value to filter by.
eager (bool) – Whether to use eager loading.
only_one (bool) – Whether to return only one record.
not_found_raise_exception (bool) – Whether to raise an exception if the record is not found.
not_found_message (str) – The message for the not found exception.
- Returns:
- The record(s) if found, otherwise None or raises
an exception.
- Return type:
- read_by_id(id: int, eager=False, not_found_raise_exception=True, not_found_message='Not found id : {id}')[source]¶
Reads a record by its ID.
- Parameters:
- Returns:
The record if found, otherwise None or raises an exception.
- Return type:
app.repository.game_params_repository module¶
- class app.repository.game_params_repository.GameParamsRepository(session_factory: ~typing.Callable[[...], ~contextlib.AbstractContextManager[~sqlalchemy.orm.session.Session]], model=<class 'app.model.game_params.GamesParams'>)[source]¶
Bases:
BaseRepository
Repository class for game parameters.
- session_factory¶
Factory for creating SQLAlchemy sessions.
- Type:
Callable[…, AbstractContextManager[Session]]
- model¶
SQLAlchemy model class for game parameters.
app.repository.game_repository module¶
- class app.repository.game_repository.GameRepository(session_factory: ~typing.Callable[[...], ~contextlib.AbstractContextManager[~sqlalchemy.orm.session.Session]], model=<class 'app.model.games.Games'>, model_tasks=<class 'app.model.tasks.Tasks'>, model_game_params=<class 'app.model.game_params.GamesParams'>, model_tasks_params=<class 'app.model.task_params.TasksParams'>, model_user_points=<class 'app.model.user_points.UserPoints'>)[source]¶
Bases:
BaseRepository
Repository class for games.
- session_factory¶
Factory for creating SQLAlchemy sessions.
- Type:
Callable[…, AbstractContextManager[Session]]
- model¶
SQLAlchemy model class for games.
- model_tasks¶
SQLAlchemy model class for tasks.
- model_game_params¶
SQLAlchemy model class for game parameters.
- delete_game_by_id(game_id: str)[source]¶
- Deletes a game by its ID , it’s delete all games related with gameId in
games, game_params, tasks and tasks_params.
- Parameters:
game_id (str) – The game ID.
- Raises:
NotFoundError – If the game is not found.
- get_all_games(schema, api_key=None)[source]¶
Retrieves all games based on the provided schema.
- Parameters:
schema – The schema for filtering the games.
- Returns:
- A result set containing the games and search
options.
- Return type:
FindGameResult
- get_game_by_id(id: str)[source]¶
Retrieves a game by its ID.
- Parameters:
id (str) – The game ID.
- Returns:
The game details.
- Return type:
BaseGameResult
- patch_game_by_id(gameId: str, schema)[source]¶
Updates a game by its ID using the provided schema.
- Parameters:
gameId (str) – The game ID.
schema – The schema representing the updated data.
- Returns:
The updated game details.
- Return type:
BaseGameResult
- Raises:
NotFoundError – If the game is not found.
DuplicatedError – If a duplicated error occurs during update.
app.repository.task_params_repository module¶
- class app.repository.task_params_repository.TaskParamsRepository(session_factory: ~typing.Callable[[...], ~contextlib.AbstractContextManager[~sqlalchemy.orm.session.Session]], model=<class 'app.model.task_params.TasksParams'>)[source]¶
Bases:
BaseRepository
Repository class for task parameters.
- session_factory¶
Factory for creating SQLAlchemy sessions.
- Type:
Callable[…, AbstractContextManager[Session]]
- model¶
SQLAlchemy model class for task parameters.
app.repository.task_repository module¶
- class app.repository.task_repository.TaskRepository(session_factory: ~typing.Callable[[...], ~contextlib.AbstractContextManager[~sqlalchemy.orm.session.Session]], model=<class 'app.model.tasks.Tasks'>)[source]¶
Bases:
BaseRepository
Repository class for tasks.
- session_factory¶
Factory for creating SQLAlchemy sessions.
- Type:
Callable[…, AbstractContextManager[Session]]
- model¶
SQLAlchemy model class for tasks.
- get_points_and_users_by_taskId(taskId)[source]¶
Retrieves points and users associated with a task ID.
app.repository.user_points_repository module¶
- class app.repository.user_points_repository.UserPointsRepository(session_factory: ~typing.Callable[[...], ~contextlib.AbstractContextManager[~sqlalchemy.orm.session.Session]], model=<class 'app.model.user_points.UserPoints'>)[source]¶
Bases:
BaseRepository
Repository class for user points.
- session_factory¶
Factory for creating SQLAlchemy sessions.
- Type:
Callable[…, AbstractContextManager[Session]]
- model¶
SQLAlchemy model class for user points.
- task_repository¶
Repository instance for tasks.
- Type:
- user_repository¶
Repository instance for users.
- Type:
- count_measurements_by_external_task_id(external_task_id)[source]¶
Retrieves the total number of measurements by external task ID.
- count_personal_records_by_external_game_id(externalGameId, externalUserId)[source]¶
Retrieves the total number of personal records by external game ID.
- get_all_UserPoints_by_taskId_with_details(taskId)[source]¶
Retrieves all user points for a specific task with details.
- get_avg_time_between_tasks_by_user_and_game_task(externalGameId, externalTaskId, externalUserId)[source]¶
Retrieves the average time between tasks for a user and game task.
- get_avg_time_between_tasks_for_all_users(externalGameId, externalTaskId)[source]¶
Retrieves the average time between tasks for all users for a game task.
- get_first_user_points_in_external_task_id_by_user_id(externalTaskId, externalUserId)[source]¶
Retrieves the first user points in an external task by user ID.
- get_global_avg_by_external_game_id(externalGameId)[source]¶
- Retrieves the global average time using data[“minutes”] for a given
external game ID.
- get_global_calculation()[source]¶
Calculates and retrieves a global performance metric.
- Returns:
The calculated global performance metric.
- Return type:
- get_individual_calculation(userId)[source]¶
Calculates and retrieves an individual performance metric for a user.
- get_last_window_time_diff(externalTaskId, externalUserId)[source]¶
- Retrieves the time difference between the last two measurements by
a user for a task.
- get_new_last_window_time_diff(externalTaskId, externalUserId, externalGameId)[source]¶
- Retrieves the time difference between the last measurement and current
time for a user for a task in a game.
- get_personal_avg_by_external_game_id(externalGameId, externalUserId)[source]¶
- Retrieves the personal average time using data[“minutes”] for a given
external game ID and user ID.
- get_points_and_users_by_taskId(taskId)[source]¶
Retrieves points and users associated with a task ID.
- get_start_time_for_last_task(userId)[source]¶
Retrieves the start time of the last task completed by a user.
- Parameters:
userId (str) – The user ID.
- Returns:
The start time of the last task.
- Return type:
datetime
- get_task_and_sum_points_by_userId(userId)[source]¶
Retrieves tasks and the sum of points for a user by their user ID.
- get_task_by_externalUserId(externalUserId)[source]¶
Retrieves tasks associated with a user by their external user ID.
- get_time_taken_for_last_task(userId)[source]¶
Retrieves the time taken by a user to complete the last task.
- Parameters:
userId (str) – The user ID.
- Returns:
The time taken to complete the last task.
- Return type:
datetime
- get_user_measurement_count(userId)[source]¶
- Retrieves the total number of measurements (tasks completed) by a
specific user.
- get_user_task_measurements(externalTaskId, externalUserId)[source]¶
Retrieves measurements for a user and task.
- get_user_task_measurements_count(externalTaskId, externalUserId)[source]¶
Retrieves the total number of measurements by user and task.
- get_user_task_measurements_count_the_last_seconds(externalTaskId, externalUserId, seconds)[source]¶
- Retrieves the total number of measurements by user and task in the last
n seconds.
app.repository.user_repository module¶
- class app.repository.user_repository.UserRepository(session_factory: ~typing.Callable[[...], ~contextlib.AbstractContextManager[~sqlalchemy.orm.session.Session]], model=<class 'app.model.users.Users'>)[source]¶
Bases:
BaseRepository
Repository class for users.
- session_factory¶
Factory for creating SQLAlchemy sessions.
- Type:
Callable[…, AbstractContextManager[Session]]
- model¶
SQLAlchemy model class for users.
app.repository.wallet_repository module¶
- class app.repository.wallet_repository.WalletRepository(session_factory: ~typing.Callable[[...], ~contextlib.AbstractContextManager[~sqlalchemy.orm.session.Session]], model=<class 'app.model.wallet.Wallet'>)[source]¶
Bases:
BaseRepository
Repository class for wallets.
- session_factory¶
Factory for creating SQLAlchemy sessions.
- Type:
Callable[…, AbstractContextManager[Session]]
- model¶
SQLAlchemy model class for wallets.
app.repository.wallet_transaction_repository module¶
- class app.repository.wallet_transaction_repository.WalletTransactionRepository(session_factory: ~typing.Callable[[...], ~contextlib.AbstractContextManager[~sqlalchemy.orm.session.Session]], model=<class 'app.model.wallet_transactions.WalletTransactions'>)[source]¶
Bases:
BaseRepository
Repository class for wallet transactions.
- session_factory¶
Factory for creating SQLAlchemy sessions.
- Type:
Callable[…, AbstractContextManager[Session]]
- model¶
SQLAlchemy model class for wallet transactions.
Module contents¶
- class app.repository.ApiKeyRepository(session_factory: ~typing.Callable[[...], ~contextlib.AbstractContextManager[~sqlalchemy.orm.session.Session]], model=<class 'app.model.api_key.ApiKey'>)[source]¶
Bases:
BaseRepository
Repository class for API keys.
- session_factory¶
Factory for creating SQLAlchemy sessions.
- Type:
Callable[…, AbstractContextManager[Session]]
- model¶
SQLAlchemy model class for API keys.
- class app.repository.ApiRequestsRepository(session_factory: ~typing.Callable[[...], ~contextlib.AbstractContextManager[~sqlalchemy.orm.session.Session]], model=<class 'app.model.api_requests.ApiRequests'>)[source]¶
Bases:
BaseRepository
Repository class for API Requests.
- session_factory¶
Factory for creating SQLAlchemy sessions.
- Type:
Callable[…, AbstractContextManager[Session]]
- model¶
SQLAlchemy model class for API Requests.
- class app.repository.BaseRepository(session_factory: Callable[[...], AbstractContextManager[Session]], model)[source]¶
Bases:
object
Base repository providing common CRUD operations.
- session_factory¶
Factory for creating SQLAlchemy sessions.
- Type:
Callable[…, AbstractContextManager[Session]]
- model¶
SQLAlchemy model class.
- async create(schema)[source]¶
Creates a new record.
- Parameters:
schema – The schema containing the record data.
- Returns:
The created record.
- Return type:
- delete_by_id(id: int)[source]¶
Deletes a record by its ID.
- Parameters:
id (int) – The record ID.
- Returns:
None
- read_by_column(column: str, value: str, eager=False, only_one=True, not_found_raise_exception=True, not_found_message='Not found {column} : {value}')[source]¶
Reads records by a specified column and value.
- Parameters:
column (str) – The column name.
value (str) – The value to filter by.
eager (bool) – Whether to use eager loading.
only_one (bool) – Whether to return only one record.
not_found_raise_exception (bool) – Whether to raise an exception if the record is not found.
not_found_message (str) – The message for the not found exception.
- Returns:
- The record(s) if found, otherwise None or raises
an exception.
- Return type:
- read_by_id(id: int, eager=False, not_found_raise_exception=True, not_found_message='Not found id : {id}')[source]¶
Reads a record by its ID.
- Parameters:
- Returns:
The record if found, otherwise None or raises an exception.
- Return type:
- class app.repository.DashboardRepository(session_factory: ~typing.Callable[[...], ~contextlib.AbstractContextManager[~sqlalchemy.orm.session.Session]], model_games=<class 'app.model.games.Games'>, model_tasks=<class 'app.model.tasks.Tasks'>, model_users=<class 'app.model.users.Users'>, model_logs=<class 'app.model.logs.Logs'>, model_user_points=<class 'app.model.user_points.UserPoints'>, model_user_actions=<class 'app.model.user_actions.UserActions'>)[source]¶
Bases:
BaseRepository
Repository class for API keys and dashboard metrics.
- get_dashboard_summary(start_date, end_date, group_by)[source]¶
Retrieves the dashboard summary.
- Parameters:
start_date – The start date for the summary.
end_date – The end date for the summary.
group_by – The group by for the summary (e.g. day, week, month).
- Returns:
The dashboard summary.
- Return type:
Dict[str, Any]
- get_dashboard_summary_logs(start_date, end_date, group_by)[source]¶
Retrieves the dashboard summary logs.
- Parameters:
start_date – The start date for the summary.
end_date – The end date for the summary.
group_by – The group by for the summary (e.g. day, week, month).
- Returns:
The dashboard summary logs.
- Return type:
Dict[str, Any]
- process_query(query, start_date=None, end_date=None, group_by_column=None)[source]¶
Processes the query by filtering and grouping the results.
- Parameters:
query – The query to process.
start_date – The start date for the query.
end_date – The end date for the query.
group_by_column – The column to group by.
- Returns:
The processed query.
- Return type:
Any
- class app.repository.GameParamsRepository(session_factory: ~typing.Callable[[...], ~contextlib.AbstractContextManager[~sqlalchemy.orm.session.Session]], model=<class 'app.model.game_params.GamesParams'>)[source]¶
Bases:
BaseRepository
Repository class for game parameters.
- session_factory¶
Factory for creating SQLAlchemy sessions.
- Type:
Callable[…, AbstractContextManager[Session]]
- model¶
SQLAlchemy model class for game parameters.
- class app.repository.GameRepository(session_factory: ~typing.Callable[[...], ~contextlib.AbstractContextManager[~sqlalchemy.orm.session.Session]], model=<class 'app.model.games.Games'>, model_tasks=<class 'app.model.tasks.Tasks'>, model_game_params=<class 'app.model.game_params.GamesParams'>, model_tasks_params=<class 'app.model.task_params.TasksParams'>, model_user_points=<class 'app.model.user_points.UserPoints'>)[source]¶
Bases:
BaseRepository
Repository class for games.
- session_factory¶
Factory for creating SQLAlchemy sessions.
- Type:
Callable[…, AbstractContextManager[Session]]
- model¶
SQLAlchemy model class for games.
- model_tasks¶
SQLAlchemy model class for tasks.
- model_game_params¶
SQLAlchemy model class for game parameters.
- delete_game_by_id(game_id: str)[source]¶
- Deletes a game by its ID , it’s delete all games related with gameId in
games, game_params, tasks and tasks_params.
- Parameters:
game_id (str) – The game ID.
- Raises:
NotFoundError – If the game is not found.
- get_all_games(schema, api_key=None)[source]¶
Retrieves all games based on the provided schema.
- Parameters:
schema – The schema for filtering the games.
- Returns:
- A result set containing the games and search
options.
- Return type:
FindGameResult
- get_game_by_id(id: str)[source]¶
Retrieves a game by its ID.
- Parameters:
id (str) – The game ID.
- Returns:
The game details.
- Return type:
BaseGameResult
- patch_game_by_id(gameId: str, schema)[source]¶
Updates a game by its ID using the provided schema.
- Parameters:
gameId (str) – The game ID.
schema – The schema representing the updated data.
- Returns:
The updated game details.
- Return type:
BaseGameResult
- Raises:
NotFoundError – If the game is not found.
DuplicatedError – If a duplicated error occurs during update.
- class app.repository.KpiMetricsRepository(session_factory: ~typing.Callable[[...], ~contextlib.AbstractContextManager[~sqlalchemy.orm.session.Session]], model=<class 'app.model.kpi_metrics.KpiMetrics'>)[source]¶
Bases:
BaseRepository
Repository class for KPI metrics.
- session_factory¶
Factory for creating SQLAlchemy sessions.
- Type:
Callable[…, AbstractContextManager[Session]]
- model¶
SQLAlchemy model class for KPI metrics.
- class app.repository.LogsRepository(session_factory: ~typing.Callable[[...], ~contextlib.AbstractContextManager[~sqlalchemy.orm.session.Session]], model=<class 'app.model.logs.Logs'>)[source]¶
Bases:
BaseRepository
Repository class for Logs.
- session_factory¶
Factory for creating SQLAlchemy sessions.
- Type:
Callable[…, AbstractContextManager[Session]]
- model¶
SQLAlchemy model class for Logs.
- class app.repository.OAuthUsersRepository(session_factory: ~typing.Callable[[...], ~contextlib.AbstractContextManager[~sqlalchemy.orm.session.Session]], model=<class 'app.model.oauth_users.OAuthUsers'>)[source]¶
Bases:
BaseRepository
Repository class for OAuth users.
- session_factory¶
Factory for creating SQLAlchemy sessions.
- Type:
Callable[…, AbstractContextManager[Session]]
- model¶
SQLAlchemy model class for OAuth users.
- class app.repository.TaskParamsRepository(session_factory: ~typing.Callable[[...], ~contextlib.AbstractContextManager[~sqlalchemy.orm.session.Session]], model=<class 'app.model.task_params.TasksParams'>)[source]¶
Bases:
BaseRepository
Repository class for task parameters.
- session_factory¶
Factory for creating SQLAlchemy sessions.
- Type:
Callable[…, AbstractContextManager[Session]]
- model¶
SQLAlchemy model class for task parameters.
- class app.repository.TaskRepository(session_factory: ~typing.Callable[[...], ~contextlib.AbstractContextManager[~sqlalchemy.orm.session.Session]], model=<class 'app.model.tasks.Tasks'>)[source]¶
Bases:
BaseRepository
Repository class for tasks.
- session_factory¶
Factory for creating SQLAlchemy sessions.
- Type:
Callable[…, AbstractContextManager[Session]]
- model¶
SQLAlchemy model class for tasks.
- get_points_and_users_by_taskId(taskId)[source]¶
Retrieves points and users associated with a task ID.
- class app.repository.UptimeLogsRepository(session_factory: ~typing.Callable[[...], ~contextlib.AbstractContextManager[~sqlalchemy.orm.session.Session]], model=<class 'app.model.uptime_logs.UptimeLogs'>)[source]¶
Bases:
BaseRepository
Repository class for Uptime Logs.
- session_factory¶
Factory for creating SQLAlchemy sessions.
- Type:
Callable[…, AbstractContextManager[Session]]
- model¶
SQLAlchemy model class for Uptime Logs.
- class app.repository.UserActionsRepository(session_factory: ~typing.Callable[[...], ~contextlib.AbstractContextManager[~sqlalchemy.orm.session.Session]], model=<class 'app.model.user_actions.UserActions'>)[source]¶
Bases:
BaseRepository
Repository class for user points.
- session_factory¶
Factory for creating SQLAlchemy sessions.
- Type:
Callable[…, AbstractContextManager[Session]]
- model¶
SQLAlchemy model class for user points.
- class app.repository.UserInteractionsRepository(session_factory: ~typing.Callable[[...], ~contextlib.AbstractContextManager[~sqlalchemy.orm.session.Session]], model=<class 'app.model.user_interactions.UserInteractions'>)[source]¶
Bases:
BaseRepository
Repository class for User interactions.
- session_factory¶
Factory for creating SQLAlchemy sessions.
- Type:
Callable[…, AbstractContextManager[Session]]
- model¶
SQLAlchemy model class for User interactions.
- class app.repository.UserPointsRepository(session_factory: ~typing.Callable[[...], ~contextlib.AbstractContextManager[~sqlalchemy.orm.session.Session]], model=<class 'app.model.user_points.UserPoints'>)[source]¶
Bases:
BaseRepository
Repository class for user points.
- session_factory¶
Factory for creating SQLAlchemy sessions.
- Type:
Callable[…, AbstractContextManager[Session]]
- model¶
SQLAlchemy model class for user points.
- task_repository¶
Repository instance for tasks.
- Type:
- user_repository¶
Repository instance for users.
- Type:
- count_measurements_by_external_task_id(external_task_id)[source]¶
Retrieves the total number of measurements by external task ID.
- count_personal_records_by_external_game_id(externalGameId, externalUserId)[source]¶
Retrieves the total number of personal records by external game ID.
- get_all_UserPoints_by_taskId_with_details(taskId)[source]¶
Retrieves all user points for a specific task with details.
- get_avg_time_between_tasks_by_user_and_game_task(externalGameId, externalTaskId, externalUserId)[source]¶
Retrieves the average time between tasks for a user and game task.
- get_avg_time_between_tasks_for_all_users(externalGameId, externalTaskId)[source]¶
Retrieves the average time between tasks for all users for a game task.
- get_first_user_points_in_external_task_id_by_user_id(externalTaskId, externalUserId)[source]¶
Retrieves the first user points in an external task by user ID.
- get_global_avg_by_external_game_id(externalGameId)[source]¶
- Retrieves the global average time using data[“minutes”] for a given
external game ID.
- get_global_calculation()[source]¶
Calculates and retrieves a global performance metric.
- Returns:
The calculated global performance metric.
- Return type:
- get_individual_calculation(userId)[source]¶
Calculates and retrieves an individual performance metric for a user.
- get_last_window_time_diff(externalTaskId, externalUserId)[source]¶
- Retrieves the time difference between the last two measurements by
a user for a task.
- get_new_last_window_time_diff(externalTaskId, externalUserId, externalGameId)[source]¶
- Retrieves the time difference between the last measurement and current
time for a user for a task in a game.
- get_personal_avg_by_external_game_id(externalGameId, externalUserId)[source]¶
- Retrieves the personal average time using data[“minutes”] for a given
external game ID and user ID.
- get_points_and_users_by_taskId(taskId)[source]¶
Retrieves points and users associated with a task ID.
- get_start_time_for_last_task(userId)[source]¶
Retrieves the start time of the last task completed by a user.
- Parameters:
userId (str) – The user ID.
- Returns:
The start time of the last task.
- Return type:
datetime
- get_task_and_sum_points_by_userId(userId)[source]¶
Retrieves tasks and the sum of points for a user by their user ID.
- get_task_by_externalUserId(externalUserId)[source]¶
Retrieves tasks associated with a user by their external user ID.
- get_time_taken_for_last_task(userId)[source]¶
Retrieves the time taken by a user to complete the last task.
- Parameters:
userId (str) – The user ID.
- Returns:
The time taken to complete the last task.
- Return type:
datetime
- get_user_measurement_count(userId)[source]¶
- Retrieves the total number of measurements (tasks completed) by a
specific user.
- get_user_task_measurements(externalTaskId, externalUserId)[source]¶
Retrieves measurements for a user and task.
- get_user_task_measurements_count(externalTaskId, externalUserId)[source]¶
Retrieves the total number of measurements by user and task.
- get_user_task_measurements_count_the_last_seconds(externalTaskId, externalUserId, seconds)[source]¶
- Retrieves the total number of measurements by user and task in the last
n seconds.
- class app.repository.UserRepository(session_factory: ~typing.Callable[[...], ~contextlib.AbstractContextManager[~sqlalchemy.orm.session.Session]], model=<class 'app.model.users.Users'>)[source]¶
Bases:
BaseRepository
Repository class for users.
- session_factory¶
Factory for creating SQLAlchemy sessions.
- Type:
Callable[…, AbstractContextManager[Session]]
- model¶
SQLAlchemy model class for users.
- class app.repository.WalletRepository(session_factory: ~typing.Callable[[...], ~contextlib.AbstractContextManager[~sqlalchemy.orm.session.Session]], model=<class 'app.model.wallet.Wallet'>)[source]¶
Bases:
BaseRepository
Repository class for wallets.
- session_factory¶
Factory for creating SQLAlchemy sessions.
- Type:
Callable[…, AbstractContextManager[Session]]
- model¶
SQLAlchemy model class for wallets.
- class app.repository.WalletTransactionRepository(session_factory: ~typing.Callable[[...], ~contextlib.AbstractContextManager[~sqlalchemy.orm.session.Session]], model=<class 'app.model.wallet_transactions.WalletTransactions'>)[source]¶
Bases:
BaseRepository
Repository class for wallet transactions.
- session_factory¶
Factory for creating SQLAlchemy sessions.
- Type:
Callable[…, AbstractContextManager[Session]]
- model¶
SQLAlchemy model class for wallet transactions.