Skip to main content
The indexing queue sits between the file watcher and the processing pipeline. File changes are debounced through a cooldown period before being processed. The queue supports manual and scheduler-driven pause/resume.

Get Queue Status

GET /api/queue/status
cURL
curl http://localhost:60534/api/queue/status

Response

paused
boolean
Whether the queue is paused (manual OR scheduler)
manually_paused
boolean
Whether the queue was manually paused via API
scheduler_paused
boolean
Whether the queue was paused by the scheduler
total_items
number
Total items in the queue
cooling_down
number
Items waiting for cooldown to expire
ready
number
Items ready to be processed
processing
number
Items currently being processed
200 Success
{
  "paused": false,
  "manually_paused": false,
  "scheduler_paused": false,
  "total_items": 5,
  "cooling_down": 3,
  "ready": 1,
  "processing": 1
}

Pause Queue

POST /api/queue/pause Manually pause the queue. Items will continue to be enqueued but won’t be processed until resumed.
cURL
curl -X POST http://localhost:60534/api/queue/pause
200 Success
{
  "success": true,
  "message": "Queue paused"
}

Resume Queue

POST /api/queue/resume Resume a manually paused queue.
cURL
curl -X POST http://localhost:60534/api/queue/resume
200 Success
{
  "success": true,
  "message": "Queue resumed"
}
If the scheduler has also paused the queue, resuming manually won’t start processing until the scheduler conditions are also met.

List Queue Items

GET /api/queue/items Get all items currently in the queue.
cURL
curl http://localhost:60534/api/queue/items

Response

200 Success
{
  "items": [
    {
      "id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
      "file_path": "/Users/username/Documents/report.pdf",
      "action": "index",
      "status": "cooling_down",
      "enqueued_at": 1705312200.0,
      "cooldown_expires_at": 1705312260.0,
      "dest_path": null,
      "retry_count": 0
    }
  ]
}

Queue Item Fields

FieldTypeDescription
idstringUUID of the queue item
file_pathstringAbsolute path to the file
actionstring"index", "delete", or "move"
statusstring"cooling_down", "ready", or "processing"
enqueued_atnumberUnix timestamp when item was enqueued
cooldown_expires_atnumberUnix timestamp when cooldown expires
dest_pathstring | nullDestination path for move actions
retry_countnumberNumber of failed processing attempts

Remove Queue Item

DELETE /api/queue/items/{item_id} Remove an item from the queue by its UUID.
cURL
curl -X DELETE http://localhost:60534/api/queue/items/a1b2c3d4-e5f6-7890-abcd-ef1234567890
200 Success
{
  "success": true,
  "message": "Item removed"
}
404 Not Found
{
  "success": false,
  "message": "Item not found"
}