# Initiate a Call

> POST /masking/calls — dial Party A, then bridge Party B on a masked caller ID. Returns a call_sid for tracking.

Source: https://edesy.in/docs/number-masking/api-reference/initiate-call

```
POST /masking/calls
```

Dials Party A first; on answer, bridges Party B. Both parties see the masked number as the caller ID. Returns immediately with a `call_sid` — poll the [status endpoint](https://edesy.in/docs/number-masking/api-reference/get-call-status) for progress, or use [webhooks](https://edesy.in/docs/number-masking/api-reference/webhooks).

## Body parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `party_a` | string | Yes | 10-digit Indian mobile number to dial first. |
| `party_b` | string | Yes | 10-digit Indian mobile number to bridge after Party A answers. |
| `max_duration_sec` | integer | No | Maximum bridged-call duration in seconds (10–7200). The call is automatically ended once Party B has been connected for this long. Leave unset for no limit. |

## Request

```bash
curl -X POST https://voice-api.edesy.in/v1/masking/calls \
  -H "Authorization: Bearer vp_YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "party_a": "9876543210",
    "party_b": "9123456789"
  }'
```

```javascript
const response = await fetch("https://voice-api.edesy.in/v1/masking/calls", {
  method: "POST",
  headers: {
    "Authorization": "Bearer vp_YOUR_API_KEY",
    "Content-Type": "application/json",
  },
  body: JSON.stringify({
    party_a: "9876543210",
    party_b: "9123456789",
  }),
});
const data = await response.json();
console.log(data);
```

```python
import requests

response = requests.post(
    "https://voice-api.edesy.in/v1/masking/calls",
    headers={
        "Authorization": "Bearer vp_YOUR_API_KEY",
        "Content-Type": "application/json",
    },
    json={"party_a": "9876543210", "party_b": "9123456789"},
)
print(response.json())
```

## Responses

**`201` — Call initiated successfully**

```json
{
  "data": {
    "call_sid": "d28be7cd-9840-4b23-9627-199f1ef81fc6",
    "status": "initiated",
    "party_a": "9876543210",
    "party_b": "9123456789",
    "masked_number": "917969002802"
  }
}
```

**`402` — Wallet balance is too low to start the call**

```json
{
  "error": {
    "code": "insufficient_balance",
    "message": "Insufficient balance. Please add funds to continue making calls."
  }
}
```

**`400` — Party A and Party B are the same number**

```json
{
  "error": {
    "code": "invalid_numbers",
    "message": "Party A and Party B cannot be the same number."
  }
}
```

See all [error codes](https://edesy.in/docs/number-masking/api-reference/errors).
