Get CSV/Excel column headers for mapping

POST /api/v1/transactions/bulk-upload/headers

Return the column headers, sample rows, and a suggested mapping for a previously uploaded CSV/Excel file. Use this before preview to let the user map their file's columns to DayZero fields (date, amount, description).

Operation ID: get_bulk_upload_headers_api_v1_transactions_bulk_upload_headers_post · View as markdown · OpenAPI slice

Authentication

Bearer token authentication. Pass your DayZero API token in the Authorization header and the target business UUID in x-business-id.

Request body

s3_key string required

S3 key of the CSV/Excel file to read headers from

Responses

201 Successful Response

headers array · string required

Column headers found in the file

sample_rows array · object

First few rows of raw data (up to 5) for the user to see values

suggested_mapping object

Auto-detected mapping suggestion: {dayzero_field: csv_column_or_null}

400 Bad Request - Invalid input

401 Unauthorized - Authentication required

403 Forbidden - Insufficient permissions

422 Validation Error

detail array · ValidationError ValidationError
5 fields
loc array · string | integer required
msg string required
type string required
input object
ctx object