Create Import Session
Create Import Session
Upload a source file and create a new import session
POST
Create Import Session
Create Import Session
Upload a CSV or XLSX file and create an import session. The backend parses the file, detects column headers, and returns metadata needed to begin the mapping and validation workflow.This is the entry point for every import. After creating a session, proceed to Suggest Mapping to auto-map source columns, then validate and submit.
Request
Headers
Your API key for authenticationExample:
sk_live_1234567890abcdefYour organization UUIDExample:
a8315ef3-dd50-43f8-b7ce-d839e68d51faBody (multipart/form-data)
Backend template identifier. Determines which columns are expected and how values are validated.Examples:
logistics_requests, purchases, wastes, invoices_electricityThe source CSV or XLSX file to import
Locale for decimal number parsing. Use this when your file uses commas as decimal separators.Example:
es_ES (parses 1.234,56 as 1234.56)Preferred date format for ambiguous slash-separated dates.Values:
dmy (European: 05/04/2026 = April 5th), mdy (US: 05/04/2026 = May 4th)When omitted, the parser auto-detects from unambiguous values in the column.Language hint for header detection and value matchingExample:
es, en, frSheet to read for multi-sheet XLSX uploads. When omitted on a multi-sheet file, the first sheet is used.
UUID of the project to scope this import to
UUID of the folder within the project
UUID of the facility. Required for templates that declare
facility_id as a context field (e.g. wastes, invoices_electricity).Transport direction. Required for
transport_routes template.Values: upstream, downstreamResponse
UUID of the created import session. Use this in all subsequent workflow calls.
Original filename of the uploaded file
Number of data rows parsed (excluding header)
The numeric locale applied during parsing
The date locale applied (
dmy or mdy), or null if auto-detectedList of sheet names in the workbook (empty for CSV)
The sheet that was parsed
Zero-based index of the detected header row
Column headers detected in the source file
First few rows of parsed data for preview
Example
Successful Response
Common Errors
401 Unauthorized
Cause: Missing or invalid API key403 Forbidden
Cause: The authenticated user is not a member of the organization400 Bad Request
Cause: File could not be parsed (unsupported format, empty, or corrupt)422 Unprocessable Entity
Cause: Missing required context field for the templateRelated Endpoints
Import Overview
Full import workflow guide
Get Import Status
Check session status and validation summary
Submit Import
Submit the validated session for processing
Delete Session
Abandon and clean up a session

