Skip to main content
POST
Upload Workflow Leads
Changes state - verify before retry
Recommended. This endpoint is part of the public /v1 API reference and is the supported path for new integrations. See the migration guide for versioning guidance.
Uploads leads into a workflow from a CSV or Excel file. Each row in the file becomes one enrolled lead. The file must include a phone_number column; all other columns become dynamic variables available in the agent’s prompt at each voice call step.

When to use this

  • Enrolling a cohort: add a new set of leads to a workflow that is already built, whether it is active now or will be activated later.
  • Incremental enrollment: keep feeding new leads into a long-running workflow as they arrive, unlike a batch call where the list is fixed at creation.
  • Re-enrollment after correction: remove a lead that was uploaded with bad data via Delete Workflow Lead, then upload the corrected record here.
For a one-shot list where every contact just gets a single call, Create Batch Call is the simpler tool.

File format

The response groups created lead IDs by phone number and includes a count of created leads. Leads begin processing once the workflow is active. Their progress through the nodes depends on the outcomes of each step.

Destination validation

If the workflow contains Voice Call nodes, uploaded leads are validated before enrollment. A lead’s phone_number must be valid and must be allowed by at least one active Voice Call phone number in the workflow. For non-SIP routes, the destination country and prefix must be enabled in Workspace Settings > Telephony Config. Validation failures return 400 Bad Request with grouped row-level errors so you can fix the file and retry.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

workflowId
string
required

Workflow ID

Example:

"workflow_abc123"

Body

multipart/form-data
file
file

CSV or Excel file with leads data

Response

File processed successfully.