---
title: "Start an export"
method: POST
path: "/migrations/{migration_id}/exports"
tags: ["Exports"]
---

# Start an export

`POST /migrations/{migration_id}/exports`

## Request

- Base URL: `https://app.vern.so/api/v1`
- URL: `https://app.vern.so/api/v1/migrations/{migration_id}/exports`
- Auth: API key in header `x-api-key`
- TypeScript: <https://skmtc.dev/vern-so/apis/vern-api/docs/migrations/:migration_id/exports/post.ts> (a function with typed inputs; its response is checked against the schema)

Queues an export of one or more destination sheets. One slug produces a CSV, several produce a ZIP. Poll the returned `status_url` for the download link.

## Request body

- object: Provide `slug` or `slugs`; `slugs` wins if both are sent.
  - `slug` string
  - `slugs` string[]
  - `fields` string[]: Column names to export, in the order given. Omit to export every column. Matched exactly and case-sensitively; an unrecognised name returns `400` rather than being ignored.
  - `omit_empty` boolean: Drop columns with no data in any row, using the completed import's stored per-column coverage. Returns `409` (`coverage_unavailable`) when that coverage does not exist, rather than quietly exporting every column.

## Response `202`

Export queued.

- object
  - `job_id` string
  - `status` 'pending'
  - `format` 'csv' | 'zip'
  - `total_rows` integer
  - `status_url` string: Relative path of this job's status endpoint.

## Other responses

- `400`: Malformed request.
- `401`: API key missing, malformed, or revoked.
- `404`: Migration not found, or an unknown template slug.
- `409`: A sheet has no exportable data.
- `429`: Rate limit hit. Counted per account, not per API key. Creating a migration and starting a `generate` run are limited to 30/hour each; answering a run is limited to 30/hour; reads allow 30/minute and writes 30/minute. `Retry-After` gives the seconds until the window resets, alongside `X-RateLimit-Limit`, `X-RateLimit-Remaining` and `X-RateLimit-Reset`.
- `500`: Unexpected server error.
- `502`: The export worker could not be started. Retryable.

## Changes

- **2026-09-27** `1990c15edaad`: 2 info
  - added the new optional request property `fields`
  - added the new optional request property `omit_empty`
- **2026-08-21** `f23b9ff77f72`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/vern-so/apis/vern-api/changes/migrations/:migration_id/exports/post.md)

---

[API](https://skmtc.dev/vern-so/apis/vern-api.md) - [All operations](https://skmtc.dev/vern-so/apis/vern-api/llms.txt) - [OpenAPI document](https://skmtc.dev/vern-so/apis/vern-api/revisions/6ae61af2db81?raw)
