Endpoint
GEThttps://{yourserver}/webhooks/call
This webhook is sent when a new call is created on the platform. It is configured at the application level. Parameters are passed as query string.
Reference: Call Hook (GET)
Documentation Index
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
Webhook sent when a new call is created on the platform (GET). Configured at the application level.
https://{yourserver}/webhooks/call
This webhook is sent when a new call is created on the platform. It is configured at the application level. Parameters are passed as query string.
Reference: Call Hook (GET)
| Parameter | Type | Required | Description |
|---|---|---|---|
| call_sid | string | Yes | Unique identifier for the call |
| application_sid | string | Yes | Unique identifier for the Graine application controlling this call |
| account_sid | string | Yes | Unique identifier for the Graine account |
| direction | string | Yes | inbound or outbound |
| from | string | Yes | Calling party number |
| to | string | Yes | Called party number |
| caller_name | string | Yes | Caller name, if known |
| call_status | string | Yes | One of: trying, ringing, early-media, in-progress, completed, failed, busy, no-answer |
| sip_status | number | Yes | Most recent SIP status code for the call |
import requests
url = "https://{yourserver}/webhooks/call"
querystring = {
"call_sid": "d2515c3b-b79a-41a2-971a-445e769c823c",
"application_sid": "72c5c38f-9bba-40ce-aa83-aaa6be55e1b5",
"account_sid": "bad98250-b34d-459d-9e90-f97dfb9bc519",
"direction": "inbound",
"from": "+12125551212",
"to": "+14155551234",
"caller_name": "John Doe",
"call_status": "trying",
"sip_status": "100"
}
headers = {"Authorization": "Basic <username>:<password>"}
response = requests.get(url, headers=headers, params=querystring)
print(response.json())
const params = new URLSearchParams({
call_sid: 'd2515c3b-b79a-41a2-971a-445e769c823c',
application_sid: '72c5c38f-9bba-40ce-aa83-aaa6be55e1b5',
account_sid: 'bad98250-b34d-459d-9e90-f97dfb9bc519',
direction: 'inbound',
from: '+12125551212',
to: '+14155551234',
caller_name: 'John Doe',
call_status: 'trying',
sip_status: '100'
});
const url = `https://{yourserver}/webhooks/call?${params}`;
const options = { method: 'GET', headers: { Authorization: 'Basic <username>:<password>' } };
const response = await fetch(url, options);
const data = await response.json();
console.log(data);