Get the status and result of a config export/import job
Get the status and result of a config export/import job
Authentication
Bearer authentication of the form Bearer <token>, where token is your auth token.
Path parameters
The job id returned by the export/import submit endpoint
Response
Current lifecycle status of the job. waiting_for_upload is
import-only: the job exists and the archive has not arrived yet, so no
work has begun and started_at stays null throughout.
When the job started running; null while the job is still queued or
waiting for its upload. The gap from created_at is time spent waiting
— for the archive, then to start — not working.
When the job reached a terminal status; null while it runs
How far through the knowledge the job has got, as a percentage.
null until the size of the work is known, which for both directions is
once the job has started and read the manifest — so a queued or
waiting_for_upload job always reports null.
Knowledge is the only phase whose duration scales with the Agent: an export counts the articles written to the archive, an import the archive’s article files applied.
It answers “how far”, never “is it done” — read status for that.
100 does not mean finished, and appears on three different statuses:
completed— reported outright, since an Agent with no articles finishes with nothing counted.in_progress— the phases either side of the knowledge are not counted, so an export sits at100while it packs and uploads the archive, and an import while it applies the configuration document.failed— an export whose scan completed but whose archive expired before you polled (failure_reason: archive_expired).
A job that fails partway keeps serving the ratio it reached, so an
import that died at 4,000 of 10,000 files reports 40 from then on. One
that fails before the manifest reports null.
Floored while the job runs, so a job one article short of done reports
99. It can go down: an interrupted job is restarted from the
start of the knowledge, and an import resumes where it stopped rather than from what the dead attempt had merely reported.
Null while the job is queued or in progress. Which shape it takes is
settled by type, the submitted mode, and status:
What the import did not do, without failing — see
ConfigImportWarning for the five kinds. An empty array once an
import completes cleanly; null for an export, and null while a job
runs or after it fails.
The kind of failure, as a stable slug — null unless status is
failed. Branch on this rather than on failure_detail, whose
wording is not part of the contract.
One sentence naming what actually went wrong, to show a person. Null
when the job has not failed, and null on the failures whose slug says
everything there is to say — preflight_failed (whose findings are in
result), timeout, stalled, agent_not_found, and
internal_error, whose underlying message is never returned because
driver and storage errors carry internal hostnames.