Skip to content

Get job

Retrieve the status and, once complete, the result of a generation job. Poll this endpoint until status is done or failed.

GET /jobs/{job_id}
Authorization string required

Bearer <YOUR_API_KEY>. See Authentication.

UUID of the job, as returned by a generation request.
job_id string

UUID of the job.

status string

One of queued, processing, done, failed. See Jobs & polling.

created_at datetime

When the job was accepted.

started_at datetime | null

When processing began. null while still queued.

finished_at datetime | null

When the job reached a terminal state. null until then.

result object | null

Present only when status is done.

Presigned download URL for the generated image. Valid for 24 hours, and regenerated on every poll — always use the freshest value. null when the model returned text only.

Text part of the response, when the model returned text (image models can answer with text, or with text and an image at the same time). null for image-only results.
error string | null

Failure reason. Present only when status is failed.

Terminal window
curl -s https://api.moonez.ai/api/v1/jobs/$JOB_ID \
-H "Authorization: Bearer $API_KEY"
import requests
job = requests.get(
f"https://api.moonez.ai/api/v1/jobs/{job_id}",
headers={"Authorization": f"Bearer {API_KEY}"},
).json()
print(job["status"])
{
"job_id": "0193a7f2-1c4a-7e0b-9b3a-2f1d8c6e4a55",
"status": "done",
"created_at": "2026-06-11T12:00:00Z",
"started_at": "2026-06-11T12:00:01Z",
"finished_at": "2026-06-11T12:00:09Z",
"result": {
"image_url": "https://cdn.moonez.ai/results/...?X-Amz-Signature=...",
"text": null
},
"error": null
}
{
"job_id": "0193a7f2-1c4a-7e0b-9b3a-2f1d8c6e4a55",
"status": "failed",
"created_at": "2026-06-11T12:00:00Z",
"started_at": "2026-06-11T12:00:01Z",
"finished_at": "2026-06-11T12:00:05Z",
"result": null,
"error": "Provider returned no image"
}