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

# Choose Your Telephony Integration

> Pick between Kallglot-managed numbers, your own provider connection, or SIP / PBX.

# Choose Your Telephony Integration

Kallglot supports three telephony integration paths:

1. **Kallglot-managed numbers**
2. **External provider connections**
3. **SIP / PBX**

This is the same routing model you configure in the Developer Portal and send through the public API.

<Note>
  Use the **`routing`** object in JSON for every path below. **Response** fields like **`provider`** (string) tell you which carrier was used after the fact—they are not a substitute for `routing` in your request. See [Telephony providers](/concepts/providers).
</Note>

## Kallglot-managed numbers

Use numbers provisioned by Kallglot. No external provider setup is required.

Use this mode when:

* You want the fastest setup path.
* Kallglot owns the underlying telephony provider relationship.
* You want to reference a number directly in `routing.phone_number`.

Example session request:

```json theme={null}
{
  "mode": "bidirectional_translation",
  "source_language": "de",
  "target_language": "en",
  "routing": {
    "phone_number": "+19788006140"
  }
}
```

<Note>
  Kallglot automatically resolves the provider (Twilio or Telnyx) from the phone number configuration.
</Note>

## External provider connections

Connect your own Twilio or Telnyx account in the Developer Portal, then reference that connection from the API.

Use this mode when:

* You want Kallglot to run on top of your own telephony account.
* You already own numbers and routing in Twilio or Telnyx.
* You want explicit control over which provider connection is used.

Example session request:

```json theme={null}
{
  "mode": "bidirectional_translation",
  "source_language": "de",
  "target_language": "en",
  "routing": {
    "connection_id": "pcon_01HXYZ",
    "direction": "inbound"
  }
}
```

<Note>
  Use `routing.connection_id` for bring-your-own-provider flows. If your organization has multiple external provider connections, pass it explicitly.
</Note>

## SIP / PBX

Use SIP to connect your existing SIP-capable PBX or session border controller.

Use this mode when:

* You already run a PBX or contact center platform.
* You want to create the session first and bridge the call afterward.
* You do not want or need a provider connection record.

Create the session, then route your PBX call to:

```text theme={null}
sip:<session_id>@sip.kallglot.com
```

Example session request:

```json theme={null}
{
  "mode": "bidirectional_translation",
  "source_language": "de",
  "target_language": "en",
  "routing": {
    "type": "sip"
  }
}
```

## Telephony Resolution Order

When you create a session, Kallglot resolves telephony in this order:

1. `routing.connection_id`, if provided
2. SIP mode when `routing.type` is `sip`
3. active Kallglot-managed number when `routing.phone_number` matches an organization-owned number
4. default external provider connection, if configured
5. a setup error if no valid route exists

## Which One Should You Use?

| Mode                          | Best for                                  | Requires provider connection |
| ----------------------------- | ----------------------------------------- | ---------------------------- |
| Kallglot-managed numbers      | Fastest setup, Kallglot-managed telephony | No                           |
| External provider connections | Bring your own Twilio/Telnyx              | Yes                          |
| SIP / PBX                     | Dedicated PBX / SBC integrations          | No                           |

## Developer Portal Setup

Configure telephony options in **Developer Portal > Telephony**:

### Kallglot-managed Numbers

1. Click **Buy Number** to purchase a phone number
2. Numbers are automatically linked to your organization
3. Use `routing.phone_number` in API requests

### External Provider Connections

1. Click **Add Provider Connection**
2. Select Twilio or Telnyx
3. Enter your API credentials (Account SID + Auth Token for Twilio, API Key for Telnyx)
4. Optionally set as default connection
5. Use `routing.connection_id` in API requests, or omit to use the default

### SIP / PBX

1. Click **Configure SIP**
2. Enable SIP access
3. Add allowed IP addresses for security
4. Use the provided username and domain to configure your PBX

## Routing Errors

| Error                    | Cause                                 | Solution                                                    |
| ------------------------ | ------------------------------------- | ----------------------------------------------------------- |
| `no_default_provider`    | No route could be resolved            | Add a provider connection, buy a managed number, or use SIP |
| `sip_not_enabled`        | SIP mode requested but not enabled    | Enable SIP in Developer Portal                              |
| `phone_number_not_found` | Number not owned by your organization | Buy the number or use a different route                     |
| `connection_not_found`   | Invalid connection ID                 | Verify connection exists and is active                      |

## Next Steps

* Managed numbers: see the [Quick Start](/quickstart)
* External providers: see [Twilio](/guides/twilio) or [Telnyx](/guides/telnyx)
* SIP / PBX: see [SIP Integration](/guides/sip)
