Skip to main content
POST
/
batches
cURL
curl --request POST \
  --url https://api.bolna.ai/batches \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: text/csv' \
  --data '
{
  "agent_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "file": "<string>",
  "from_phone_numbers": [
    "+919876543210",
    "+919876543211"
  ],
  "retry_config": "<string>"
}
'
{
  "batch_id": "3c90c3cc0d444b5088888dd25736052a",
  "state": "created"
}

Authorizations

Authorization
string
header
required

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

Body

text/csv
agent_id
string<uuid>
required

The ID of the agent

file
file
required

CSV file to upload

from_phone_numbers
string[]

List of phone numbers from which the batch calls will be made. Each number must include the country code in E.164 format. Pass multiple values to use multiple originating numbers.

Example:
["+919876543210", "+919876543211"]
retry_config
string

JSON string containing retry configuration for failed calls. See auto-retry documentation for details. Example - {"enabled":true,"max_retries":2,"retry_intervals_minutes":[15,30]}

Response

agent status response

batch_id
string<^[0-9a-fA-F]{32}$>
required

The ID of the batch

Example:

"3c90c3cc0d444b5088888dd25736052a"

state
enum<string>
required

Status of the request

Available options:
created