Skip to main content
POST
CSV Import
← Employees API Create multiple employees from a CSV or Excel (.xlsx/.xls) file and automatically send commuting survey emails to every email in the file. Emails that already belong to an employee of the organization (matched case-insensitively) are not re-created: the existing employee is reused and surveyed for the new period, and is included in the response, unless they already answered that period (a commuting response whose dates overlap it, from any channel): those are not sent the survey again, and the X-Already-Responded response header says how many. The file should contain an email column identified by an email, correo, e-mail, or mail header. Extra columns are ignored. A single-column CSV with one email per line (no header) is also accepted; in multi-column files without a recognized header, the column containing email addresses is detected automatically.

Request

Headers

string
required
Your API key for authenticationExample: sk_live_1234567890abcdef
string
required
Your organization UUIDExample: a8315ef3-dd50-43f8-b7ce-d839e68d51fa
string
required
Must be multipart/form-data

Form Parameters

file
required
CSV or Excel (.xlsx/.xls) file containing an email column (header: email, correo, e-mail, or mail); extra columns are ignored
string
required
Survey language code. Values: ar, ca, de, en, es, fr, it, pt, zh
string
required
Survey period start date (YYYY-MM-DD)
string
required
Survey period end date (YYYY-MM-DD)
string
required
Still required (1–255 characters) but ignored since 2026-10-25: the email always has Dcycle’s localized subject. The send is charged to the daily survey email budgets described in Resend Commuting Survey.
string
Survey response deadline (YYYY-MM-DD). After this date, the survey link expires.

Response

Returns an array of created employees (HTTP 201).
string
Unique identifier (UUID) for the employee
string | null
Employee’s full name
string | null
Employee’s email address
string
Organization UUID
string | null
Employment status: active, inactive, or terminated
string
Data status: uploaded, loading or error (see Get Employee)
array | null
List of commuting periods (empty for newly imported employees)
datetime
Timestamp when the employee was created
datetime | null
Timestamp when the employee was last updated

Example

Successful Response

Common Errors

401 Unauthorized

Cause: Missing or invalid API key

403 Forbidden

Cause: The authenticated user is not a member of the organization

422 Unprocessable Entity

Cause: Invalid CSV format or missing required columns

Create Employee

Create a single employee

Resend Survey

Resend survey to existing employees