Set the webhook
curl --request PUT \
--url https://api.telleo.ai/v1/webhook \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"url": "https://crm.example.com/telleo/webhook"
}
'import requests
url = "https://api.telleo.ai/v1/webhook"
payload = { "url": "https://crm.example.com/telleo/webhook" }
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({url: 'https://crm.example.com/telleo/webhook'})
};
fetch('https://api.telleo.ai/v1/webhook', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"object": "webhook",
"url": "<string>",
"enabled": true,
"events": [
"call.completed",
"call.not_connected",
"human_call.completed",
"human_call.not_connected",
"human_call.analysis_ready"
],
"secret": "whsec_3f9a…",
"secret_hint": "whsec_…9c1d",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}
Webhook
Set the webhook
Sets the one HTTPS endpoint that receives call.completed and call.not_connected. The first time, the response includes the signing secret; changing the URL later keeps the secret.
Scope: webhooks:manage.
PUT
/
webhook
Set the webhook
curl --request PUT \
--url https://api.telleo.ai/v1/webhook \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"url": "https://crm.example.com/telleo/webhook"
}
'import requests
url = "https://api.telleo.ai/v1/webhook"
payload = { "url": "https://crm.example.com/telleo/webhook" }
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({url: 'https://crm.example.com/telleo/webhook'})
};
fetch('https://api.telleo.ai/v1/webhook', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"object": "webhook",
"url": "<string>",
"enabled": true,
"events": [
"call.completed",
"call.not_connected",
"human_call.completed",
"human_call.not_connected",
"human_call.analysis_ready"
],
"secret": "whsec_3f9a…",
"secret_hint": "whsec_…9c1d",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}
Authorizations
Response
The webhook (with secret when it was just created).