Skip to main content
POST
/
v1
/
phoneCalls
/
batch
cURL
curl --request POST \
  --url https://api.aicaller.io/v1/phoneCalls/batch \
  --header 'Content-Type: application/json' \
  --header 'aicaller-api-key: <api-key>' \
  --data '
{
  "phoneCalls": [
    {
      "teamId": "363573667364666473667332",
      "callTemplateId": "363573667364666473667332",
      "nameOfHuman": "John",
      "toPhoneNumber": "+1234567890",
      "promptVariableValues": [
        {
          "key": "customer_name",
          "value": "John"
        }
      ],
      "phoneNumberId": "363573667364666473667332",
      "fromPhoneNumber": "+1234567890",
      "toEmailAddress": "[email protected]",
      "status": "queued",
      "telephonyProvider": "twilio",
      "record": false,
      "callDelayedUntil": "2023-10-12T09:08:00.387Z",
      "phoneCallWebhooks": [
        {
          "url": "https://hooks.abc.com/",
          "subscribedEvent": "phoneCall.completed",
          "secret": "NjUyOTgwMjkpJU0NmY25yzWkJFWDBE12"
        }
      ]
    }
  ]
}
'
{
  "data": [
    {
      "teamId": "363573667364666473667332",
      "callTemplateId": "363573667364666473667332",
      "nameOfHuman": "John",
      "toPhoneNumber": "+1234567890",
      "promptVariableValues": [
        {
          "key": "customer_name",
          "value": "John"
        }
      ],
      "_id": "12345678901234567890",
      "createdAt": "<string>",
      "updatedAt": "<string>",
      "phoneNumberId": "363573667364666473667332",
      "fromPhoneNumber": "+1234567890",
      "toEmailAddress": "[email protected]",
      "status": "queued",
      "telephonyProvider": "twilio",
      "record": false,
      "callDelayedUntil": "2023-10-12T09:08:00.387Z",
      "phoneCallWebhooks": [
        {
          "url": "https://hooks.abc.com/",
          "subscribedEvent": "phoneCall.completed",
          "secret": "NjUyOTgwMjkpJU0NmY25yzWkJFWDBE12"
        }
      ]
    }
  ]
}

Authorizations

aicaller-api-key
string
header
required

Body

application/json
phoneCalls
object[]
required

Array of phone calls used in the call (maximum 20 items).

Maximum array length: 20

Response

Phone calls successfully created.

data
object[]
required