API reference/19 of 24

Download one file

Download one file from a batch by index.

GET/jobs/{id}/files/{index}

Returns one file from a job, by its index in "files". Same authentication as downloading the whole job.

Path parameters

  • idstringRequired

    The job ID.

  • indexintegerRequired

    The file's index, starting at 0.

curl https://api.comprestack.com/api/v1/jobs/job_4f1c9a2e7b3d5c8f0a6e1b9d/files/0 \
  -H "Authorization: Bearer $COMPRESTACK_API_KEY" \
  -o hero-banner.png
Response
HTTP/1.1 200 OK
Content-Type: image/png
Content-Length: 1032410
Content-Disposition: attachment; filename="hero-banner.png"