Skip to main content

Export jobs

Generated from apiome-rest/openapi.yaml (API version 1.719.0) — do not edit by hand. How to authenticate is on the REST API reference.

Tag: export-jobs · 6 operations

GET /v1/export/{tenant_slug}/jobs​

List export jobs

Paginated tenant export jobs from the shared store (IXH-6.3), newest first. Supports state and created_after / created_before filters. Default page size is 50 (max 200). Pages by cursor: pass the previous page's next_cursor until has_more is false; the total is counted only when include_total is set.

Operation id: list_export_jobs_v1_export__tenant_slug__jobs_get

Parameters

NameInTypeRequiredDescription
tenant_slugpathstringyesURL-safe tenant slug that scopes the request.
limitqueryintegernoPage size. At most 200.
cursorquerystring or nullnoOpaque cursor from the previous page (next_cursor, or the X-Next-Cursor header). Omit for the first page.
include_totalquerybooleannoAlso count the matching rows. Off by default because counting reads every match; the count stops at 10,000.
offsetqueryintegernoRows to skip. Deprecated: page with cursor instead. At most 10,000.
statequerystring or nullnoExact job state filter (e.g. completed, failed, running).
created_afterquerystring (date-time) or nullnoInclusive lower bound on job created_at (ISO-8601).
created_beforequerystring (date-time) or nullnoInclusive upper bound on job created_at (ISO-8601).
authorizationheaderstring or nullnoJWT bearer token for authenticated access (Authorization: Bearer <token>).
X-API-Keyheaderstring or nullnoTenant-scoped API key used as an alternative to JWT bearer authentication.

Responses

StatusDescriptionBody
200Successful response for list export jobs.application/json ExportJobListResponse
422Validation Errorapplication/json HTTPValidationError

POST /v1/export/{tenant_slug}/jobs​

Start an asynchronous export job

Submit an export of one artifact/version to one target through the async job pipeline: load source → fidelity report → emit → validate → package. dry_run: true stops after the fidelity report (no artifact), the async twin of POST …/preview. Poll the returned status_path for progress; the status contract matches the spec-import job surface.

Multi-target (MFX-39.1): send a targets list (each entry {target, options?, acknowledged_snapshot?}) instead of target to emit the version to every listed target in one job. The download is one zip with a subdirectory per target plus a root manifest.json; result.targets carries each target's fidelity report, guard, validation and delivery decision, and result.fidelity_rollup the merged summary. The job is all-or-nothing: the first target that fails fails the job, naming it in error.context.target.

Batch (MFX-39.2): send versions (a list of revision ids or version labels) or all_versions: true instead of version to export several versions of the artifact to the target(s) in one job. The download is one zip (export-batch.zip) with a <version>/<target>/ folder per completed item plus a root manifest.json listing every item. Failures are per item: result.batch.items[] carries each item's state and, for a failed one, its structured error; the job only fails (EXPORT_BATCH_FAILED) when every item failed. At most 100 version × target items; acknowledged_snapshot is not accepted on a batch.

Several items (E1-3): send items (a list of {artifact, version?}; a missing version exports the item's latest) instead of artifact to export several artifacts — say catalog items picked together — to the target(s) in one batch job. Each item's files land under <item>/<target>/ (<item> is its slug, plus the version label when one was named) and manifest.json names each item's artifact. items cannot be combined with version, versions or all_versions; entries must be distinct; at most 100 item × target pairs.

Overlays (GVM-4.2): send overlays (a list of {name, document}, 1–10 Overlay 1.0 / 1.1 / 1.2 documents, each at most 1 MiB) to apply them, in order, to the source's OpenAPI document before the export runs: fidelity, the emitter, validation and the export quality policy all judge the post-overlay document. result.overlay lists every changed leaf with the overlay that changed it (500 rows, then a truncation row) and every action that could not be applied — an action whose target matches nothing is an overlay.unmatched-target finding and changes nothing. A version not imported from OpenAPI fails with OVERLAY_SOURCE_UNSUPPORTED; an unreadable overlay with OVERLAY_INVALID. Overlays apply to one source, so they cannot be combined with a batch. Send the same overlays to POST …/verify so its snapshot matches the job's.

Presets (MFX-39.3): preset names a saved export preset (by id or name): its targets and their options stand in for target / targets / options, and its delivery profile is added to delivery_profiles. 400 for an unknown preset or one whose targets no longer validate.

Delivery (MFX-38.4): delivery_profiles lists delivery profiles the export is delivered with as soon as it completes — each through its channel, recorded on the job (GET …/jobs/{job_id}/deliveries) and as an EXPORT_DELIVERED / EXPORT_DELIVERY_FAILED event. It needs versions:publish (403) and existing profiles (400).

Limits (X5): each refusal names the limit it hit. A tenant runs at most APIOME_EXPORT_MAX_CONCURRENT_JOBS_PER_TENANT (default 5) queued or running export jobs; a submit past it is refused with 429. A job running longer than APIOME_EXPORT_JOB_TIMEOUT_SECONDS (default 1800) fails with EXPORT_JOB_TIMED_OUT; an artifact over APIOME_EXPORT_ARTIFACT_MAX_BYTES (default 32 MiB) fails with EXPORT_ARTIFACT_TOO_LARGE; the download is kept for APIOME_EXPORT_ARTIFACT_RETENTION_HOURS (default 24) and is 410 after that. 0 turns a limit off.

Operation id: start_export_job_v1_export__tenant_slug__jobs_post

Parameters

NameInTypeRequiredDescription
tenant_slugpathstringyesURL-safe tenant slug that scopes the request.
authorizationheaderstring or nullnoJWT bearer token for authenticated access (Authorization: Bearer <token>).
X-API-Keyheaderstring or nullnoTenant-scoped API key used as an alternative to JWT bearer authentication.

Request body (required)

Request body for start an asynchronous export job.

Responses

StatusDescriptionBody
202Successful response for start an asynchronous export job.application/json ExportJobAccepted
422Validation Errorapplication/json HTTPValidationError

GET /v1/export/{tenant_slug}/jobs/{job_id}​

Get export job status

Poll payload for one export job: state, percent, structured events, and coarse progress. A terminal job is self-describing — a completed real export carries a result (resolved coordinates, fidelity envelope, transcode guard, emitted-file manifest, and a download_path for the artifact bytes); a dry-run carries the report only (no download_path); a failed job carries a structured error.

Operation id: get_export_job_status_v1_export__tenant_slug__jobs__job_id__get

Parameters

NameInTypeRequiredDescription
tenant_slugpathstringyesURL-safe tenant slug that scopes the request.
job_idpathstringyesAsynchronous job identifier.
authorizationheaderstring or nullnoJWT bearer token for authenticated access (Authorization: Bearer <token>).
X-API-Keyheaderstring or nullnoTenant-scoped API key used as an alternative to JWT bearer authentication.

Responses

StatusDescriptionBody
200Successful response for get export job status.application/json ExportJobStatus
422Validation Errorapplication/json HTTPValidationError

DELETE /v1/export/{tenant_slug}/jobs/{job_id}​

Cancel an export job

Request cancellation. The pipeline stops at its next stage boundary; a job already in a terminal state is left unchanged (the request is a no-op).

Operation id: cancel_export_job_v1_export__tenant_slug__jobs__job_id__delete

Parameters

NameInTypeRequiredDescription
tenant_slugpathstringyesURL-safe tenant slug that scopes the request.
job_idpathstringyesAsynchronous job identifier.
authorizationheaderstring or nullnoJWT bearer token for authenticated access (Authorization: Bearer <token>).
X-API-Keyheaderstring or nullnoTenant-scoped API key used as an alternative to JWT bearer authentication.

Responses

StatusDescriptionBody
204Successful response for cancel an export job.—
422Validation Errorapplication/json HTTPValidationError

GET /v1/export/{tenant_slug}/jobs/{job_id}/attestation​

Fetch a delivered artifact's signed delivery attestation

The delivery attestation for a completed export job (IXH-2.5): an in-toto Statement v1 in a DSSE envelope, HMAC-SHA256 signed with the shared attestation secret (APIOME_LINT_ATTESTATION_SIGNING_SECRET — the same key the CLX-4.2 lint gate attestations use, so a verifier needs no new configuration).

The statement's subject is the delivered artifact, digested with a plain sha256 over the exact bytes the download route serves, so sha256sum on the downloaded file is enough to tie the two together. Its predicate records the delivery identity, the tool versions, the source lint fingerprint, the policy version and content fingerprint that were applied, any waiver the decision honoured, and the delivery decision with its named reasons — everything needed to reproduce the verdict offline. apiome lint verify-attestation verifies it as-is.

A multi-target job (MFX-39.1) attests each target separately against the combined bundle: pass target (the resolved format key from result.targets[].target) to pick one. A batch export (MFX-39.2) attests each completed item against the archive: pass version (an item's requested version, revision id, or version label) and target.

404 when the job is unknown for this tenant; 409 when the job produced no attested delivery (still running, canceled, failed, or a dry-run), when a multi-target job is asked without a target or for a target it did not export, or when a batch export is asked for an item it did not complete.

Operation id: get_export_job_attestation_v1_export__tenant_slug__jobs__job_id__attestation_get

Parameters

NameInTypeRequiredDescription
tenant_slugpathstringyesURL-safe tenant slug that scopes the request.
job_idpathstringyesAsynchronous job identifier.
targetquerystring or nullnoMulti-target and batch jobs only: the resolved target format key whose attestation to return. Ignored for a single-target job.
versionquerystring or nullnoBatch jobs only: the item's version — as requested, its revision id, or its version label. Ignored for any other job.
authorizationheaderstring or nullnoJWT bearer token for authenticated access (Authorization: Bearer <token>).
X-API-Keyheaderstring or nullnoTenant-scoped API key used as an alternative to JWT bearer authentication.

Responses

StatusDescriptionBody
200Successful response for fetch a delivered artifact's signed delivery attestation.application/json DeliveryAttestation
422Validation Errorapplication/json HTTPValidationError

GET /v1/export/{tenant_slug}/jobs/{job_id}/download​

Download a completed export job's artifact

Serve the artifact a completed export job produced — the target the poller was handed via result.download_path. The bytes come from the job's retained emit result (no re-emit) and are streamed in fixed-size chunks with an up-front Content-Length (MFX-4.3), so a large bundle is not buffered whole. A single-file export (MFX-4.1) is served inline with the emitted file's content type and a Content-Disposition filename, byte-identical to the size the job manifest reported. A multi-file export (protobuf packages, WSDL+XSD, per-subject Avro) is served as an application/zip bundle (MFX-4.2) carrying every emitted file plus a root manifest.json. A job that is not completed or is a dry-run (no artifact) is rejected with 409; a completed job whose retained artifact has passed its retention window (MFX-4.3) is 410 Gone.

Operation id: download_export_job_artifact_v1_export__tenant_slug__jobs__job_id__download_get

Parameters

NameInTypeRequiredDescription
tenant_slugpathstringyesURL-safe tenant slug that scopes the request.
job_idpathstringyesAsynchronous job identifier.
authorizationheaderstring or nullnoJWT bearer token for authenticated access (Authorization: Bearer <token>).
X-API-Keyheaderstring or nullnoTenant-scoped API key used as an alternative to JWT bearer authentication.

Responses

StatusDescriptionBody
200Successful response for download a completed export job's artifact.—
422Validation Errorapplication/json HTTPValidationError

Schemas used​

DeliveryAttestation​

The signed evidence attached to a delivered artifact.

PropertyTypeRequiredDescription
predicate_typestringyesThe in-toto predicate type of the wrapped statement.
signedbooleanyesWhether the envelope carries a signature. False when no attestation signing secret is configured on this server — the document is still well-formed, just not verifiable.
key_idstring or nullnoThe key id a verifier uses to select the shared secret.
generated_atstringyesStatement timestamp (ISO-8601, UTC).
envelopeobjectyesThe DSSE envelope: payloadType / base64 payload / signatures. Verifiable offline with the shared secret and the standard library alone.

ExportJobAccepted​

Returned when a job is accepted (HTTP 202) — mirrors the import acceptance.

PropertyTypeRequiredDescription
job_idstringyesJob ID.
status_pathstringyesRelative URL path for GET …/jobs/{job_id} until the job reaches a terminal state.

ExportJobListResponse​

Paginated tenant-scoped export jobs (IXH-6.3).

PropertyTypeRequiredDescription
jobsarray of ExportJobListItemyesJobs.
totalinteger or nullnoTotal jobs matching the filter (not just this page), counted up to 10,000. Present only when the request set include_total.
limitintegernoPage size applied to this response.
offsetintegernoNumber of matching jobs skipped before this page (deprecated; 0 when paging by cursor).
has_morebooleannoWhether another page exists.
next_cursorstring or nullnoPass as cursor to read the next page; null on the last page.

ExportJobStartRequest​

Submit an export job: source coordinates + target(s) + options + dry-run flag.

The source half matches POST /export/preview / POST /export/document (MFX-2.5/11.5); dry_run selects the preview-only path (fidelity report, no artifact), the async twin of the synchronous /export/preview endpoint.

Name either one target (with optional options / acknowledged_snapshot) or a targets list (MFX-39.1) — one job then emits the version to every listed target into a single zip bundle with per-target subdirectories and a root manifest, and its result carries per-target fidelity reports plus a merged rollup.

PropertyTypeRequiredDescription
artifactstring or nullnoThe artifact (project) id to export. Required unless items is given.
versionstring or nullnoRevision UUID, version label (1.0.0), or null for the latest revision.
targetstring or nullnoTarget emitter key (openapi) or format key (openapi-3.1) for a single-target export. Required unless targets is given; never both.
targetsarray of ExportJobTargetSpec or nullnoThe targets of a multi-target export (MFX-39.1), each with its own options and acknowledged snapshot; 1–16 entries, each resolving to a distinct format. Mutually exclusive with target / options / acknowledged_snapshot.
optionsobject or nullnoPer-target emit options (MFX-1.4); null or empty applies the target defaults. Single-target only — a multi-target job sets options per targets entry.
dry_runbooleannoWhen true, stop after the fidelity report: no artifact is emitted.
confirmbooleannoWhen true, proceed with a severe conversion (MFX-3.3) the transcoding guard would otherwise fail the job on. Ignored for non-severe conversions and dry-runs.
acknowledged_snapshotstring or nullnoThe projection snapshot hash (fidelity.projection.manifest_hash) the caller previewed and acknowledged (EFP-2.1). When set, the job recomputes the snapshot for its actual inputs and fails with STALE_PREVIEW if the hashes differ — the source revision, options, emitter version, or registry changed since the preview, so the acknowledgement no longer describes what would be generated. Null skips the check. Single-target only — a multi-target job acknowledges per targets entry.
min_severityLossinessSeveritynoLowest loss severity that raises the advisory (MFX-2.4); does not affect the report or counts.
versionsarray of string or nullnoA batch export over these versions of the artifact (MFX-39.2): revision UUIDs or version labels, 1–50 distinct entries. Every version is exported to every target into one archive, and a version or target that fails is reported on its item without failing the batch. Mutually exclusive with version and all_versions.
itemsarray of ExportJobItemRef or nullnoA batch export over several artifacts (E1-3): each entry an artifact and an optional version (latest when omitted). Every item is exported to every target into one archive with a folder per item, and an item that fails is reported on its own without failing the batch. At most 100 item × target pairs. Replaces artifact; mutually exclusive with version, versions and all_versions.
overlaysarray of ExportOverlay or nullnoOverlay 1.0 / 1.1 / 1.2 documents applied, in this order, to the source's OpenAPI document before anything else runs (GVM-4.2): fidelity, the emitter, validation and the export quality policy all judge the post-overlay document. 1–10 entries; the result's overlay lists every changed leaf and every action that could not be applied. A source not built from OpenAPI fails with OVERLAY_SOURCE_UNSUPPORTED. Not combinable with a batch export.
apply_stored_overlaysbooleannoApply the revision's stored overlay chain (GVM-4.3, /v1/versions/{t}/{p}/{v}/overlays) before any inline overlays. Set false to export the source without its stored chain. A batch export never applies stored chains.
all_versionsbooleannoWhen true, a batch export over every version of the artifact (MFX-39.2), newest first; the job fails with EXPORT_BATCH_TOO_LARGE when versions × targets exceeds 100. Mutually exclusive with version and versions.
delivery_profilesarray of string or nullnoDelivery profiles (MFX-38.4, GET /v1/export/{tenant}/delivery-profiles) the export is delivered with as soon as it completes, in this order — each through its channel's own delivery, recorded on the job (GET …/jobs/{job_id}/deliveries) and audited. 1–5 distinct ids; needs versions:publish. Not combinable with dry_run. A delivery's outcome never changes the job's state: each adds an EXPORT_DELIVERED or EXPORT_DELIVERY_FAILED event.
presetstring or nullnoAn export preset (MFX-39.3, GET /v1/export/{tenant}/presets), by id or name. Its targets and their options stand in for target / targets / options — which must then be left out — and its delivery profile is added ahead of delivery_profiles. Everything else (the source, version, items, overlays, confirm, dry_run) is this request's own. 400 for an unknown preset or one whose targets no longer validate.

ExportJobStatus​

Poll payload for an export job (same shape as the import job status).

A terminal job is self-describing: completed carries result (with a download_path for a real export), failed carries a structured error (MFX-3.4).

PropertyTypeRequiredDescription
job_idstringyesJob ID.
stateenum "queued", "running", "completed", "failed", "canceled"yesState.
percentintegernoPercent.
eventsarray of ExportJobEventnoEvents.
progressExportJobProgress or nullnoProgress.
resultExportJobResult or nullnoResult.
errorExportJobError or nullnoStructured failure detail; set only in the failed terminal state.
correlation_idstring or nullnoCorrelation id of the request that started the job (IXH-6.6); matches the X-Request-ID of the submitting request and every log line the job emitted.

HTTPValidationError​

Validation error response emitted when request data fails schema checks.

PropertyTypeRequiredDescription
detailarray of ValidationErrornoDetail.