> ## Documentation Index
> Fetch the complete documentation index at: https://graine.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# New Call (GET)

> Webhook sent when a new call is created on the platform (GET). Configured at the application level.

## Endpoint

**GET** `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)

## Query parameters

| 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                                              |

## Response

Return a **200** with a JSON payload consisting of an array of verbs to control the call.

## Authentication

**Authorization:** Basic authentication (required)

## Example request

```python theme={null}
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())
```

```javascript theme={null}
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);
```
