jobs#

System maintenance, scheduler canary, and report export queue tasks.

System domain background and scheduled tasks.

class app.domain.system.jobs.QueueTaskEventPayload(task_id: str, task_name: str, queue: str, status: str, timestamp: datetime, progress: int | None = None, total: int | None = None, message: str | None = None)[source]#

Bases: CamelizedBaseStruct

Typed AsyncAPI payload emitted on the queue_events channel.

async app.domain.system.jobs.run_cleanup_auth_tokens(alchemy_config: SQLAlchemyAsyncConfig) → dict[str, int][source]#

Delete expired security tokens, challenges, sessions, and AppStore entries.

Returns:

Mapping of cleaned table or namespace labels to deleted row counts.

async app.domain.system.jobs.run_export_team_summary(alchemy_config: SQLAlchemyAsyncConfig, *, team_id: str, requested_by_id: str) → dict[str, Any][source]#

Compute member and tag counts for a team.

Returns:

Structured summary payload for the requested team.

Raises:

NonRetryableError – If team_id is malformed or no such team exists.