Skip to main content

Preview a table CSV import

Upload a CSV to preview headers, up to five sample rows, protected/generated columns, suggested mappings, detected types, and importable existing table columns. This endpoint does not import or mutate table rows.

POST/api/tables/{table_id}/csv-preview
HTTP referenceScope tables:writeUpdated September 27, 2026

This page documents the canonical HTTP contract for this endpoint.

Developer API keys need the listed scope. A valid authenticated user session may also call this route.

Mapping analysis can fall back to basic unmapped-column suggestions when the AI mapping service is unavailable. Only the first five rows are returned as sample_rows. Consult the workspace column catalog for valid table fields; the dynamic response example is abbreviated.

Path parameters

  • table_idrequired

    string

    Research table identifier; caller must have access.

Body parameters

  • filerequired

    file<text/csv>

    CSV uploaded as multipart form data.

  • null_policy · optional

    string

    common treats configured common null tokens as empty; preserve retains input values.

Errors

StatusMeaning
401Authentication is missing or invalid.
403The credential is invalid or lacks the required scope, or the caller cannot access the resource.
400The CSV is empty or could not be parsed.
422Request validation failed, including a missing required file or invalid multipart/form value.
500An unexpected preview-processing error occurred.

Docs