# List SIP trunks

`GET /v1/voice/trunks`

Returns the workspace's SIP trunks as a paginated list, each with its assigned `domain` and access control lists. Create a trunk to provision a new one, or use `voice.trunks.get` to fetch an existing trunk by ID.

## Code samples

**TypeScript**

```ts
for await (const trunk of bird.voice.trunks.list()) {
  // A trunk with no allow list and no session credentials admits nothing.
  console.log(trunk.id, trunk.domain, trunk.inbound_enabled);
}
```

Examples: [TypeScript](/docs/api/reference/list-voice-trunks.ts.md) · [Python](/docs/api/reference/list-voice-trunks.py.md) · [Go](/docs/api/reference/list-voice-trunks.go.md) · [PHP](/docs/api/reference/list-voice-trunks.php.md) · [CLI](/docs/api/reference/list-voice-trunks.cli.md) · [MCP](/docs/api/reference/list-voice-trunks.mcp.md) · [cURL](/docs/api/reference/list-voice-trunks.curl.md)

## Example response `200`

```json
{
  "data": [
    {
      "id": "spt_01krdgeqcxet5s7t44vh8rt9mg",
      "workspace_id": "ws_01krdgeqcxet5s7t44vh8rt9mg",
      "name": "Production PBX trunk",
      "domain": "01kxp5bb9qf878642atrf0xy5r.trunk.eu1.sip.bird.com",
      "ip_acls": [
        {
          "id": "sta_01krdgeqcxet5s7t44vh8rt9mg",
          "trunk_id": "spt_01krdgeqcxet5s7t44vh8rt9mg",
          "cidr": "203.0.113.0/24",
          "description": "Office network"
        }
      ],
      "allowed_api_key_ids": [
        "key_01krdgeqcxet5s7t44vh8rt9mg"
      ],
      "ineligible_api_key_ids": [
        "key_01krdgeqcxet5s7t44vh8rt9mg"
      ],
      "digest_algorithms": [
        "SHA-256",
        "MD5"
      ],
      "created_at": "2026-05-20T09:14:52Z",
      "updated_at": "2026-05-25T16:42:01Z"
    }
  ],
  "next_cursor": "eyJ2IjoxLCJzIjoiXCIyMDI2LTA1LTI1VDE0OjAzOjEwWlwiIiwiaSI6IjAxOTJmM2IxLTRjN2UtN2EyYi05ZDYxLThmM2E1YzJlN2I0MCJ9",
  "prev_cursor": null,
  "refresh_cursor": "eyJ2IjoxLCJzIjoiXCIyMDI2LTA1LTI1VDE2OjQyOjAxWlwiIiwiaSI6IjAxOTJmM2IxLTllMDQtN2NkMy1iODE3LTJhNmY0ZDFjOGUwOSJ9"
}
```

## Query parameters

- `sort` (string)

  Field to sort by.

  Possible values: `created_at`
- `order` (string)

  Sort direction. Defaults to `desc`, which sorts from newest to oldest or largest to smallest, depending on the selected sort field.

  Possible values: `asc`, `desc`
- `limit` (integer): Maximum number of items to return per page.
- `starting_after` (string): Cursor from the `next_cursor` field of a previous list response. Returns items immediately after the cursor position in the current sort order.
- `ending_before` (string): Cursor from the `prev_cursor` or `refresh_cursor` field of a previous list response. Returns items immediately before the cursor position in the current sort order. `prev_cursor` returns the preceding page. `refresh_cursor` anchors at the first row of that response, which on a newest-first sort is how to fetch the items that have appeared since.

## Response body

- `data` (array of object, required)
- `data.id` (string, required): Unique identifier for this SIP trunk.
- `data.workspace_id` (string, required)
- `data.name` (string, required): A human-readable label for this SIP trunk. Mutable, and distinct from the generated wire domain.
- `data.domain` (string, required): Full SIP address for this trunk, generated as `{trunk-id}.trunk.{region}.sip.bird.com`. This is the trunk's identity, so configure your PBX or SIP client to send calls to this address. It is derived from the trunk id and cannot be chosen or changed.
- `data.outbound_enabled` (boolean, required): Whether this trunk may place calls: your PBX connects to us to dial out. Off on a new trunk. While it is off the trunk refuses every call attempt no matter what its allow lists say, and the connection and authentication settings below have no effect. Set `outbound_enabled` through the trunk update operation.
- `data.inbound_enabled` (boolean, required): Whether this trunk may receive calls: we dial the addresses you declared, for the numbers this trunk answers. Off on a new trunk. Turning it off resets number routes that use this trunk to reject incoming calls. Turning it back on does not restore those routes. Set `inbound_enabled` through the trunk update operation.
- `data.media_bypass` (boolean, required): Whether we take ourselves out of the audio path for calls we forward to this trunk: your equipment and the originating carrier exchange audio directly, and only the call signalling passes through us. Off by default. It applies to inbound calls alone (calls this trunk places are always carried through us, whatever this says). While it is on we cannot record those calls, report their audio quality, or end one because its audio stopped. Your equipment must be reachable for audio from the public internet. Set `media_bypass` through the trunk update operation.
- `data.ip_acls` (array of object, required): The trunk's IP allow list. IP filtering is active whenever this has at least one entry: calls admitted through the allow lists must come from those CIDR ranges. This restriction does not apply to session credentials when `session_credentials_enabled` is true. An empty list means no IP restriction. Replace the whole `ip_acls` list through the trunk update operation.
- `data.ip_acls.id` (string, required): Unique identifier for this IP ACL entry.
- `data.ip_acls.trunk_id` (string, required)
- `data.ip_acls.cidr` (string, required): IPv4 or IPv6 CIDR block that is allowed to send SIP traffic to this trunk.
- `data.ip_acls.description` (nullable string): Optional human-readable label for this ACL entry.
- `data.ip_acls.created_at` (string, required)
- `data.allowed_api_key_ids` (array of string, required): The API keys allowed to authenticate this trunk over SIP Digest. A key must hold `voice` at write level and be neither revoked nor expired to authenticate. `ineligible_api_key_ids` names the entries that currently cannot. A nonempty list enables API-key authentication, limited to its eligible keys. An empty list means no API-key authentication. A trunk with empty `ip_acls` and `allowed_api_key_ids` lists accepts nothing when `session_credentials_enabled` is false. Replace the whole `allowed_api_key_ids` list through the trunk update operation.
- `data.ineligible_api_key_ids` (array of string, required): The entries in `allowed_api_key_ids` that cannot authenticate this trunk right now because the key lacks `voice` at write level, has expired, or was revoked. The bindings remain until you remove them from the trunk. Restoring `voice` at write level makes a key eligible again if it is still unexpired and unrevoked, without changing its secret or trunk binding. Empty when every allowed key can authenticate.
- `data.digest_algorithms` (array of string, required): The Digest hash algorithms this trunk offers, in the order they are offered. We send one challenge line per algorithm and your PBX answers with the first it supports, so the order decides what most equipment picks. Always populated: a trunk with no explicit setting reports the default, `["SHA-256", "MD5"]`. A trunk answering with an algorithm that is not on this list is rejected, so narrowing the list also narrows what the trunk accepts. Replace `digest_algorithms` through the trunk update operation.
- `data.session_credentials_enabled` (boolean, required): Whether a session credential may be used to connect to this trunk from a web browser, the CLI or MCP, alongside whatever the allow lists admit. Off by default. It grants nothing on its own: a call still has to present a credential issued to this workspace, and each one expires within minutes. Set `session_credentials_enabled` through the trunk update operation.
- `data.created_at` (string, required)
- `data.updated_at` (string, required)
- `next_cursor` (nullable string, required): Cursor for the next page. Pass back as `starting_after` to advance forward. `null` when no next page exists.
- `prev_cursor` (nullable string, required): Cursor for the previous page. Pass back as `ending_before` to step backward. `null` when no previous page exists.
- `refresh_cursor` (nullable string, required): Refresh anchor, the first row of this response. Pass back as `ending_before` to fetch what precedes it in the current sort order. On a newest-first sort those are the items that have appeared since; on any other sort they are the items that sort earlier, so refreshing such a list means re-fetching it instead. Non-`null` whenever `data` is non-empty; `null` only on an empty page. Distinct from `prev_cursor`.

## Related resources

- [Should I use a Bird SDK or call the API directly?](/explained/platform/should-i-use-an-sdk-or-call-the-api-directly) (answer)
- [Build your first integration](/learn/paths/integration) (course)
- [Send your first email](/docs/get-started/send-your-first-email) (docs)

[Get an implementation brief](/learn/workspace?topic=api-basics)
