# Inbound Trunks

Use the Inbound Trunks resource to create, retrieve, update, and delete routing destinations
for incoming calls to your DID phone numbers.

An Inbound Trunk represents a SIP or PSTN destination to which DIDWW can route incoming
calls. Each trunk defines its destination configuration and can also specify routing
priority, weight, simultaneous-call limit, ringing timeout, calling-line-identification
format, and other call-delivery settings.

Inbound Trunks can be assigned directly to DIDs or organized into Inbound Trunk Groups for
routing and failover. Trunks can also be associated with a DIDWW Point of Presence (POP).

## Endpoints

| Action | Method | Endpoint |
| --- | --- | --- |
| Retrieve all Inbound Trunks | `GET` | `/v3/voice_in_trunks` |
| Retrieve Inbound Trunk | `GET` | `/v3/voice_in_trunks/{id}` |
| Create Inbound Trunk | `POST` | `/v3/voice_in_trunks` |
| Update Inbound Trunk | `PATCH` | `/v3/voice_in_trunks/{id}` |
| Delete Inbound Trunk | `DELETE` | `/v3/voice_in_trunks/{id}` |
| Retrieve all POPs | `GET` | `/v3/pops` |

## Retrieve all Inbound Trunks

Retrieves all Inbound Trunks configured for the account.

Use this endpoint to filter trunks by ID, name, external reference ID, or configuration
type. Results can be sorted by routing, capacity, CLI, timeout, description, and creation
attributes.

See [Retrieve All Inbound Trunks](get-voice-in-trunks.html).

```
GET /v3/voice_in_trunks
```

## Retrieve Inbound Trunk

Retrieves a specific Inbound Trunk by its unique ID.

Use this endpoint to inspect the trunk's SIP or PSTN configuration, delivery settings, and
related Inbound Trunk Group or POP.

See [Retrieve Inbound Trunk](get-voice-in-trunk.html).

```
GET /v3/voice_in_trunks/{id}
```

## Create Inbound Trunk

Creates a SIP or PSTN Inbound Trunk.

Use a SIP configuration to route calls to a SIP destination, or use a PSTN configuration
to route calls to a phone number. The request can define routing priority and weight,
simultaneous-call limits, ringing timeout, CLI handling, SIP behavior, and related Inbound
Trunk Group or POP data.

See [Create Inbound Trunk](create-voice-in-trunk.html).

```
POST /v3/voice_in_trunks
```

## Update Inbound Trunk

Updates the settings or configuration of a specific Inbound Trunk.

Use this endpoint to change its destination, routing behavior, simultaneous-call limit,
ringing timeout, CLI handling, description, external reference ID, Inbound Trunk Group, or
POP association.

See [Update Inbound Trunk](update-voice-in-trunk.html).

```
PATCH /v3/voice_in_trunks/{id}
```

## Delete Inbound Trunk

Deletes a specific Inbound Trunk from the account.

See [Delete Inbound Trunk](delete-voice-in-trunk.html).

```
DELETE /v3/voice_in_trunks/{id}
```

## Retrieve all POPs

Retrieves the DIDWW Points of Presence available for Inbound Trunk configuration.
Pagination is disabled for this endpoint.

See [Retrieve All POPs](get-pops.html).

```
GET /v3/pops
```

## Configuration reference

Use these pages when configuring or interpreting Inbound Trunk data.

| Reference | Description |
| --- | --- |
| [Inbound Trunk Object](voice-in-trunk-object.html) | Inbound Trunk attributes, relationships, and SIP or PSTN configuration fields. |
| [POP Object](pop-object.html) | Attributes returned for a DIDWW Point of Presence. |
| [Codecs](codecs.html) | Codec IDs and names accepted by the SIP `codec_ids` setting. |

## Rerouting Disconnect Codes

Rerouting Disconnect Codes list the supported disconnect-code IDs and SIP response codes
that can be configured on an inbound SIP trunk.

Use the listed IDs in `rerouting_disconnect_code_ids` when creating or updating a SIP
configuration.

See [Rerouting Disconnect Codes](rerouting-disconnect-codes.html).

## Common Inbound Trunk use cases

| Use case | Description |
| --- | --- |
| Route calls to a SIP destination | Create a SIP trunk with the required Request-URI username and host configuration. |
| Route calls to a PSTN destination | Create a PSTN trunk that forwards incoming calls to a phone number. |
| Configure routing preference | Use priority and weight to control trunk selection and distribute calls. |
| Limit simultaneous calls | Set `capacity_limit` to control the maximum number of concurrent calls delivered to the trunk. |
| Control call setup timeout | Set `ringing_timeout` to stop a delivery attempt when the call is not connected within the configured interval. |
| Configure SIP delivery | Select codecs, DTMF handling, transport, authentication, media behavior, SIP session timers, and other SIP options. |
| Control CLI presentation | Configure the CLI format and optional prefix applied to inbound calls. |
| Configure rerouting behavior | Select the disconnect codes that allow another routing destination to be attempted. |
| Organize routing destinations | Associate trunks with an Inbound Trunk Group and a DIDWW POP. |

## Related resources

Use Inbound Trunks together with DIDs, trunk groups, and capacity resources to configure
incoming call delivery.

| Resource | Description |
| --- | --- |
| [DIDs](../did/index.html) | DID phone numbers that can use an Inbound Trunk as their routing destination. |
| [Inbound Trunk Groups](../voice-in-trunk-groups/index.html) | Groups of Inbound Trunks used for routing and failover. |
| [Capacity Pools](../capacity-pool/index.html) | Channel capacity available for inbound voice services. |
| [Shared Capacity Groups](../shared-capacity-group/index.html) | Shared channel allocation for DIDs using inbound voice services. |

On this page
