# Place an outbound phone call

Places an outbound phone call.

```http
POST https://api.pozy.ai/v1/voice/calls
```

- Area: Phone & voice / Voice
- Auth: Authorization: Bearer pz_live_...

## Header parameters

- `Idempotency-Key` (string)

## Request body

Content type: `application/json`

- `to`, string, required: Matches `^\+\d{6,15}$`
- `fromNumber`, string: Matches `^\+\d{6,15}$`
- `forwardTo`, string
- `greeting`, string: Up to 1000 characters
- `recordOverride`, boolean
- `transcribeOverride`, boolean
- `transcriptionLanguage`, string: One of `auto`, `en`, `es`
- `amd`, boolean
- `voicemailDropMessage`, string: Up to 1000 characters
- `ringTimeoutSeconds`, integer: Default `30`. 5 to 120

## Example request

```bash
curl -X POST "https://api.pozy.ai/v1/voice/calls" \
  -H "Authorization: Bearer $POZY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
  "to": "+14155550123"
}'
```

```ts
import { randomUUID } from "node:crypto";

const res = await fetch("https://api.pozy.ai/v1/voice/calls", {
  method: "POST",
  headers: {
    Authorization: `Bearer ${process.env.POZY_API_KEY}`,
    "Idempotency-Key": randomUUID(),
    "Content-Type": "application/json",
  },
  body: JSON.stringify({
    to: "+14155550123"
  }),
});
const data = await res.json();
if (!res.ok) throw new Error(data?.error ?? `Request failed with status ${res.status}`);
console.log(data);
```

```python
import os
import requests

resp = requests.post(
    "https://api.pozy.ai/v1/voice/calls",
    headers={"Authorization": f"Bearer {os.environ['POZY_API_KEY']}"},
    json={
        "to": "+14155550123",
    },
    timeout=30,
)
resp.raise_for_status()
print(resp.json())
```

## Response 200

- `success`, boolean
- `callId`, string
- `carrierCallControlId`, string
- `status`, string: One of `dialing`
- `direction`, string: One of `outbound`
- `from`, string
- `to`, string
- `forwardTo`, string
- `greeting`, string: Can be null
- `recordingEnabled`, boolean
- `transcriptionEnabled`, boolean
- `transcriptionLanguage`, string: One of `auto`, `en`, `es`

```json
{
  "success": true,
  "callId": "6f502e3f20741dfe2abae39e",
  "carrierCallControlId": "6c367f42f99a6851724a1342",
  "status": "dialing",
  "direction": "outbound",
  "from": "+14155550123",
  "to": "+14155550123",
  "forwardTo": "string",
  "greeting": "string",
  "recordingEnabled": true,
  "transcriptionEnabled": true,
  "transcriptionLanguage": "auto"
}
```
