API reference/17 of 24

Retrieve a job

Read metadata for a completed job.

GET/jobs/{id}

Compress and convert finish before they respond, so a job you get back is always "done". Use this to look a job up again later, for example from another process. Jobs and their files are deleted 1 hour after they're created; after that this returns 404 not_found.

Path parameters

  • idstringRequired

    The job ID, for example job_4f1c9a2e7b3d5c8f0a6e1b9d.

curl https://api.comprestack.com/api/v1/jobs/job_4f1c9a2e7b3d5c8f0a6e1b9d \
  -H "Authorization: Bearer $COMPRESTACK_API_KEY"
Response
{
  "id": "job_4f1c9a2e7b3d5c8f0a6e1b9d",
  "object": "job",
  "mode": "compress",
  "status": "done",
  "format": null,
  "files": [
    {
      "index": 0,
      "name": "hero-banner.png",
      "original_size": 4820113,
      "size": 1032410,
      "saved_percent": 78.6,
      "unchanged": false,
      "width": 2400,
      "height": 1260,
      "format": "png"
    }
  ],
  "created_at": "2026-10-17T10:42:08.114Z",
  "expires_at": "2026-10-17T11:42:08.114Z"
}