POST
/
v1
/
postcall
/
webhooks
/
create
curl --request POST \
  --url https://api.bland.ai/v1/postcall/webhooks/create \
  --header 'Content-Type: application/json' \
  --header 'authorization: <authorization>' \
  --data '{
  "call_ids": [
    {}
  ],
  "webhook_url": "<string>"
}'
{
  "data": [
    {
      "call_id": "<string>",
      "payload": {},
      "url": "<string>",
      "user_id": "<string>",
      "created_at": "<string>",
      "metadata": [
        {
          "sent_at": "<string>",
          "response_code": 123,
          "response_time": "<string>",
          "send_type": "<string>"
        }
      ]
    }
  ],
  "errors": [
    {
      "error": "<string>",
      "message": "<string>"
    }
  ]
}

Overview

Create and send post call webhooks for one or more call IDs. This endpoint allows you to create webhooks for calls that don’t already have webhooks configured. The webhooks will be sent immediately after creation to the specified webhook URL. If the call has already sent a post call webhook, this endpoint will return an error.


Headers

authorization
string
required

Your API key for authentication.


Body Parameters

call_ids
array
required

Array of call IDs to create and send webhooks for. Each call ID must be unique within the array.

webhook_url
string
required

The URL where the webhook payloads should be sent.


Response

data
array

Array of webhook objects for each created webhook.

errors
array

Array of error objects if any errors occurred.