resourcepack.ai
DOCS

Jobs

Check a generation

A handle looks like <pack>:<kind>:<name> and comes back from every generation endpoint.

There's no jobs table behind this: generation is two-phase, so the asset row is written up front with status generating and the runner fills it in. The asset is the job record, which is why a handle stays resolvable long after the run finished.

Polling always terminates. A run that dies without recording anything reads as error once it passes the stale cutoff.

GET/jobs/{job}

Path parameters

jobstringrequired

The job handle.

Response · 200

The job's current state. status is generating, ready or error.

jobstringrequired

The handle you asked about.

packstringrequired

The pack it belongs to.

statusstringrequired

Hoisted from the asset so a poll loop needn't reach into it.

Options: generating, ready, error

errorstring

Why it failed. Null unless status is error.

assetobjectrequired

The asset itself.

idstringrequired

Stable id, and the job handle this asset was created under.

kindstringrequired

Which store it lives in.

Options: texture, model, font, sound

namestringrequired

Its name within the pack. Prefixed for item sprites and GUI sheets.

statusstringrequired

Where the generation got to.

Options: generating, ready, error

displayNamestring

The label you gave it, if any.

promptstring

What it was generated from.

errorstring

Why it failed. Null unless status is error.

sizeBytesinteger

Size of the stored file.

updatedAtstringrequired

ISO 8601.

Error codes

Branch on error.code, never on the message.

invalid_job_handle400

A job handle that isn't <pack>:<kind>:<name>.

invalid_api_key401

The key isn't one of ours, or it has been revoked.

missing_api_key401

No Authorization: Bearer header was sent.

plan_required403

The key is valid, but its account is on Starter. The API needs a paid plan.

job_not_found404

No job by that handle.

not_found404

No such pack, asset or job.