RomM uses a Redis-backed RQ (Redis Queue) task queue to run background operations without blocking the API. The Tasks API lets you list available tasks, trigger them on demand, and inspect the status of running or completed jobs.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/rommapp/romm/llms.txt
Use this file to discover all available pages before exploring further.
All Tasks API endpoints require the
tasks.run scope, which is only available to admin users by default.GET /api/tasks
List all available tasks grouped by type (scheduled, manual, and watcher). Returns task metadata — name, title, description, enabled status, and cron schedule — but not execution history. Required scope:tasks.run
Machine-readable task identifier used when triggering via
POST /api/tasks/run/{task_name}.Task category:
scan, update, cleanup, conversion, sync, watcher, or generic.Human-readable display name.
What the task does.
Whether the task is active. Disabled tasks cannot be triggered.
Whether the task can be triggered via the API. Watcher tasks cannot be triggered manually.
Cron expression for scheduled tasks, or an empty string for manual-only tasks.
Available Tasks
Scheduled Tasks
These run automatically on their cron schedule and can also be triggered manually:| Name | Type | Description |
|---|---|---|
scan_library | scan | Scans the library filesystem and updates ROM metadata |
update_launchbox_metadata | update | Downloads the latest LaunchBox metadata database |
update_switch_titledb | update | Downloads the latest Nintendo Switch TitleDB |
convert_images_to_webp | conversion | Converts stored cover images to WebP format |
Manual Tasks
These must be triggered explicitly and do not run on a schedule:| Name | Type | Description |
|---|---|---|
cleanup_orphaned_resources | cleanup | Removes cover images and resources for ROMs/platforms no longer in the database |
cleanup_missing_roms | cleanup | Removes database entries for ROM files missing from the filesystem |
sync_folder_scan | sync | Synchronises the folder structure with the database |
recompute_save_content_hashes | cleanup | Recomputes content hashes for all save files |
Watcher Task
| Name | Type | Description |
|---|---|---|
filesystem_watcher | watcher | Automatically triggers a scan when a change is detected in the library path (enable with ENABLE_RESCAN_ON_FILESYSTEM_CHANGE=true, delay set by RESCAN_ON_FILESYSTEM_CHANGE_DELAY) |
GET /api/tasks/status
Get all active, queued, completed, and failed task jobs from all three priority queues. Required scope:tasks.run
TaskStatusResponse objects, sorted by start time descending.
Human-readable task name (from the job metadata or function name).
Unique RQ job ID. Use this to query a specific job via
GET /api/tasks/{task_id}.Task type:
scan, update, cleanup, conversion, sync, watcher, or generic.RQ job status:
queued, started, finished, failed, stopped, or canceled.Type-specific metadata. Shape depends on
task_type:scan→{ "scan_stats": {...} }update→{ "update_stats": {...} }cleanup→{ "cleanup_stats": {...} }conversion→{ "conversion_stats": {...} }- All others →
{}
ISO 8601 job creation time.
ISO 8601 time the job entered the queue.
ISO 8601 time the job started executing.
ISO 8601 time the job finished (success or failure).
GET /api/tasks/
Retrieve the status of a specific task by its RQ job ID. Required scope:tasks.run
The RQ job ID returned when the task was enqueued (from
POST /api/tasks/run/{task_name}).TaskStatusResponse object. Returns 404 if the job ID is not found.
Completed job results are retained in Redis for a duration controlled by the
TASK_RESULT_TTL environment variable (default: 300 seconds). After this TTL, the job record is removed and this endpoint will return 404.POST /api/tasks/run/
Enqueue a task for immediate execution. Only tasks withenabled: true and manual_run: true can be triggered.
Required scope: tasks.run
The machine-readable task name (e.g.
scan_library, cleanup_orphaned_resources). See the task table above for all valid names.Optional keyword arguments forwarded to the task’s
run() method. Shape varies by task.task_id to poll GET /api/tasks/{task_id} for progress, or stream real-time progress via the /ws WebSocket endpoint.