curl --request POST \
--url https://api.agentline.cloud/v1/webhooks \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"url": "<string>",
"agent_id": "<string>",
"secret": "<string>",
"signature_header": "<string>"
}
'import requests
url = "https://api.agentline.cloud/v1/webhooks"
payload = {
"url": "<string>",
"agent_id": "<string>",
"secret": "<string>",
"signature_header": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
url: '<string>',
agent_id: '<string>',
secret: '<string>',
signature_header: '<string>'
})
};
fetch('https://api.agentline.cloud/v1/webhooks', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"agent_id": "<string>",
"url": "<string>",
"secret": "<string>",
"signature_header": "<string>",
"created_at": "2023-11-07T05:31:56Z"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Set Webhook
Create or replace an agent’s webhook.
The configured URL receives ALL of that agent’s event types — call lifecycle
(call.received, call.completed, call.failed), SMS (sms.received),
and future events — as signed JSON POSTs. Each agent may have at most one
webhook; POSTing again replaces it.
agent_id: the agent whose events this webhook receives (required).secret: HMAC signing secret. Omit to auto-generate.
The response returns the full secret once — store it to verify the
signature header on deliveries.
curl --request POST \
--url https://api.agentline.cloud/v1/webhooks \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"url": "<string>",
"agent_id": "<string>",
"secret": "<string>",
"signature_header": "<string>"
}
'import requests
url = "https://api.agentline.cloud/v1/webhooks"
payload = {
"url": "<string>",
"agent_id": "<string>",
"secret": "<string>",
"signature_header": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
url: '<string>',
agent_id: '<string>',
secret: '<string>',
signature_header: '<string>'
})
};
fetch('https://api.agentline.cloud/v1/webhooks', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"agent_id": "<string>",
"url": "<string>",
"secret": "<string>",
"signature_header": "<string>",
"created_at": "2023-11-07T05:31:56Z"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Authorizations
AgentLine API key. Get one via the email OTP flow (POST /v1/auth/otp then POST /v1/auth/verify). Pass as: Authorization: Bearer sk_live_...
Body
Body for POST /v1/webhooks (create or replace an agent's webhook).
HTTPS URL that will receive this agent's events as signed JSON POSTs. Setting this replaces any existing webhook for the agent.
1 - 2083ID of the agent whose events this webhook receives. Each agent may have at most one webhook.
Optional HMAC signing secret. Auto-generated if omitted. Used to verify the signature header on delivered payloads.
Header name for the HMAC-SHA256 signature of the raw body. Defaults to 'X-Webhook-Signature' (natively verified by Hermes, OpenClaw, and other agent platforms). Set to 'X-Hub-Signature-256' for GitHub-style verification, or any custom header name your platform expects. Omit to keep the existing value when updating.
Response
Successful Response
Returned on POST — exposes the full secret this one time.
Agent this webhook is scoped to
Configured webhook URL
Full signing secret. Save it now — it is masked on subsequent reads.
Header name used for HMAC-SHA256 signature delivery.
When the webhook was last (re)configured