Skip to main content
GET https://app.vern.so/api/v1/migrations/{migration_id}/preview
Returns the current preview — the output of the latest generate or update run, mapped to your templates sheet-by-sheet. This is exactly what the agent proposes to import; show it to your customer, then refine or execute. A migration has a preview once a generate/update run reaches awaiting_approval. Before that, this returns 404.

Authentication

Requires an x-api-key header. See Authentication.

Response

200 OK
{
  "status": "awaiting_approval",
  "templates": [
    { "slug": "contacts", "name": "Contacts" }
  ],
  "sheets": [
    {
      "template": { "slug": "contacts", "name": "Contacts" },
      "rows": [
        ["Email", "First Name", "Last Name", "Account"],
        ["jane@acme.com", "Jane", "Doe", "Acme Corp"],
        ["john@acme.com", "John", "Smith", "Acme Corp"]
      ],
      "invalid_cells": []
    }
  ]
}
status
string
Always awaiting_approval when a preview exists.
templates
object[]
The templates this migration targets, each { slug, name }.
sheets
object[]
One entry per output sheet:

Errors

StatusMeaning
401API key missing or invalid.
404No preview generated yet, or the migration isn’t in your account.
429Rate limit hit — back off and retry.
500Server error.

Example

curl https://app.vern.so/api/v1/migrations/c0a8012e-.../preview \
  -H "x-api-key: $VERN_API_KEY"

Next

  • Start a runupdate to refine, or execute to import.
  • Export CSV — get the validated rows after execute.