`POST /exports` — create an export of a query's result table.
/exportsRoutes through preprocessor.submit_export, which:
- Verifies the source query exists and reached terminal
Succeeded. - Re-runs the source query's table-level grants — the caller must be able to access every table the query touched.
- Validates the export-shape fields (format / delivery
configuration) + compiles
filterExpressionfor syntax. - Dispatches to
Scheduler::submit_export, which persists an Export-kind workload (status: "pending").
The exporter ECS service picks up Queued Export workloads from the scheduler tick and drives them through Running → terminal.
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Body of POST /exports. The UI offers two delivery modes:
direct download (small result sets) and S3 push (large exports
the customer wants in their own bucket).
The source is a table (ADR-0027 §2 / M2.2): any table the caller may
tables:export — a query-result table (owned via the executing team) or a
regular ingestion/storage table. The old query-keyed source is gone.
Response Body
application/json
curl -X POST "https://example.com/exports" \ -H "Content-Type: application/json" \ -d '{ "delivery_method": "string", "format": "string", "table_id": "string" }'{ "created_at": "string", "delivery_method": "string", "destination": null, "download_url": "string", "error_message": "string", "filter_expression": "string", "format": "string", "id": "string", "org_id": "string", "progress": 0, "status": "string", "table_id": "string", "updated_at": "string"}`DELETE /exports/{id}` — cancel an in-flight (or queued) export. DELETE
Idempotent: cancelling an already-terminal export returns the row's current state. Routes through `preprocessor.cancel_export` → `scheduler::cancel_export`, which signals the exporter to halt any in-flight encode task at the next milestone, then flips the workload to terminal `Cancelled`. The FE sees the new state on the next poll.
`GET /exports/{id}` — fetch an export's status. Polled by the UI until `status ∈ {completed, failed, cancelled}`. GET
Next Page