POST
/
customers
/
{customer_id}
/
whatsapp_configs
Create a new WhatsApp config
curl --request POST \
  --url https://app.kapso.ai/api/v1/customers/{customer_id}/whatsapp_configs \
  --header 'Content-Type: application/json' \
  --header 'X-API-Key: <api-key>' \
  --data '{
  "whatsapp_config": {
    "name": "WhatsApp Business Account",
    "kind": "production",
    "phone_number_id": "1234567890",
    "business_account_id": "98765432109",
    "access_token": "<string>",
    "webhook_verify_token": "<string>",
    "webhook_destination_url": "<string>",
    "inbound_processing_enabled": true
  }
}'
{
  "data": {
    "id": "4a5b6c7d-8e9f-0a1b-2c3d-4e5f6a7b8c9d",
    "name": "Client WhatsApp",
    "display_name": "Client WhatsApp (+1234567890)",
    "phone_number_id": "1234567890",
    "business_account_id": "98765432109",
    "display_phone_number": "+56 9 61461262",
    "display_phone_number_normalized": "56961461262",
    "webhook_verify_token": "<string>",
    "webhook_destination_url": "<string>",
    "customer_id": "3f2e1d0c-9b8a-7f6e-5d4c-3b2a1f0e9d8c",
    "inbound_processing_enabled": true,
    "created_at": "2023-11-07T05:31:56Z",
    "updated_at": "2023-11-07T05:31:56Z"
  }
}

Authorizations

X-API-Key
string
header
required

Your project API key

Path Parameters

customer_id
string
required

Body

application/json
whatsapp_config
object
required

Response

WhatsApp configuration created successfully

data
object

WhatsApp configuration for a customer. Note: webhook_verify_token and webhook_destination_url are write-only fields and will not be returned in API responses for security reasons.