Get Async Job
Async Jobs
Get Async Job
Poll the status and result of a long-running async job
GET
Get Async Job
jobId immediately; poll this endpoint until the job reaches a terminal state (ready or failed). The result shape depends on which endpoint created the job.
Job lifecycle
A job moves through these states:status | Terminal | Payload | Meaning |
|---|---|---|---|
pending | No | β | Queued, not yet picked up |
processing | No | β | Actively running |
ready | Yes | result | Completed successfully β result is available |
failed | Yes | error | Failed β error describes what went wrong |
Poll on a backoff interval (e.g. every 2β5 seconds) until
status is ready
or failed. Jobs are retained temporarily and then expire via a TTL, after
which the job ID returns 404 β fetch the result promptly once itβs ready.Request
Path parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
jobId | string | Yes | The job ID returned by the creating endpoint |
Headers
| Header | Required | Description |
|---|---|---|
x-api-key | Yes | Your API key |
Example request
Response
200 β Job state
The response is a discriminated union onstatus. All variants include jobId, createdAt, updatedAt, and status.
| Field | Type | Present when | Description |
|---|---|---|---|
jobId | string | always | The job identifier |
status | string | always | pending, processing, ready, or failed |
createdAt | number | always | Epoch timestamp the job was created |
updatedAt | string | always | ISO 8601 timestamp the job was last updated |
result | object | status is ready | The job result (shape depends on the originating job) |
error | string | status is failed | Description of the failure |
Error responses
| Status | Description |
|---|---|
400 Bad Request | Malformed job ID |
401 Unauthorized | API key is invalid |
403 Forbidden | API key is missing or the job belongs to another org |
404 Not Found | No job with that ID (unknown or expired) |
500 Server Error | Unexpected server error |