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

# List Trunks

> List all trunks.



## OpenAPI

````yaml /openapi.json get /core/trunks
openapi: 3.1.0
info:
  title: Anyreach API
  version: 1.0.0
  description: >-
    REST API for the Anyreach platform.


    Every endpoint is scoped to one organization. Authenticate with a bearer
    token and, if your token can reach more than one organization, name the one
    you mean with the `X-Anyreach-Org` header. See
    [Authentication](https://docs.anyreach.ai/api-reference/authentication).


    This reference is generated from the running service, so the request and
    response shapes here are the ones the API actually enforces.
servers:
  - url: https://api.anyreach.ai
    description: Production
security:
  - bearerAuth: []
tags:
  - name: Agents
    description: >-
      Create and configure the agent that handles a conversation, and manage its
      versions. An agent's behaviour lives in a version; publishing a version is
      what puts it on the air.
  - name: Conversations
    description: >-
      Create, list, retrieve, and message conversations between your users and
      Anyreach agents.
  - name: Conversation attachments
    description: >-
      Upload files into a conversation and read them back. Uploads are two-step:
      presign, PUT to the returned URL, then mark the attachment complete.
  - name: Conversation events
    description: >-
      The ordered event stream behind a conversation — turns, tool calls,
      transfers, and status changes.
  - name: Knowledge bases
    description: >-
      A knowledge base (a `dataset` in the API) is a collection of embedded
      content an agent can retrieve from.
  - name: Knowledge base sources
    description: Attach and detach sources to a knowledge base.
  - name: Sources
    description: >-
      A source is a file or URL whose content is ingested, chunked, and
      embedded.
  - name: Phone numbers
    description: >-
      Buy, list, and release phone numbers, and point each one at the agent that
      should answer it.
  - name: Trunks
    description: >-
      SIP trunks for bringing your own carrier. A trunk carries calls between
      your carrier and Anyreach.
  - name: Inbound routing
    description: >-
      Rules that decide which agent answers an inbound call, evaluated before
      the call connects.
  - name: Agent assist
    description: >-
      Look up the live-assist context for a number so a human agent can see what
      the AI agent knows.
  - name: Human handoff
    description: >-
      Connections to the help desk a conversation escalates into, and the test
      endpoint that proves one works.
  - name: Email domains
    description: >-
      Register a sending domain and verify its DNS before an agent can send from
      it.
  - name: Email addresses
    description: >-
      The addresses on a verified domain, and the agent that handles mail
      arriving at each one.
  - name: Unsubscribes
    description: >-
      The suppression list. An address on this list is never emailed again until
      it is removed.
  - name: Web widgets
    description: >-
      The embeddable chat and voice widget: its appearance, its allowed domains,
      and the agent behind it.
  - name: Campaigns
    description: >-
      An outbound campaign dials a contact list with a given agent on a given
      schedule. Start, pause, and close control its lifecycle.
  - name: Campaign contacts
    description: >-
      The people a campaign dials. Contacts can be added while the campaign is
      running.
  - name: Campaign configurations
    description: >-
      Reusable dialing settings — calling windows, retry policy, timezone
      handling — that campaigns reference.
  - name: Campaign stats
    description: >-
      Per-campaign outcome counters, and the organization-wide cap on how many
      calls run at once.
  - name: Custom data
    description: >-
      Your own tables, queryable by an agent mid-conversation. Define a table,
      load rows, and expose read-only stored queries as agent tools.
  - name: Metrics
    description: >-
      The definitions an LLM judge scores a conversation against. Lint and
      preview a metric before you run it at scale.
  - name: Evaluations
    description: A scorecard binding a set of metrics to a population of conversations.
  - name: Evaluation runs
    description: >-
      One execution of an evaluation over a conversation set, and the results it
      produced.
  - name: Workflows
    description: >-
      Automations built from steps. A workflow is edited as a version and goes
      live when a version is published and set live.
  - name: Workflow triggers
    description: >-
      What starts a workflow — a schedule, a webhook, or a point in an agent
      conversation. Triggers are versioned alongside the workflow.
  - name: Workflow executions
    description: >-
      Run a workflow and read back what happened. Executions are synchronous by
      default; use the async endpoint for long-running work.
  - name: Workflow credentials
    description: >-
      Secrets a workflow step authenticates with. Values are write-only — they
      can be set and rotated, never read back.
paths:
  /core/trunks:
    get:
      tags:
        - Trunks
      summary: List Trunks
      description: List all trunks.
      operationId: listTrunks
      parameters:
        - name: name
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Name
        - name: created_after
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            title: Created After
        - name: created_before
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            title: Created Before
        - name: updated_after
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            title: Updated After
        - name: updated_before
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            title: Updated Before
        - name: limit
          in: query
          required: false
          schema:
            anyOf:
              - type: integer
              - type: 'null'
            title: Limit
        - name: cursor
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Cursor
        - name: x-anyreach-org
          in: header
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            description: Organization ID for user PATs (pat_ prefix tokens)
            title: X-Anyreach-Org
          description: Organization ID for user PATs (pat_ prefix tokens)
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/Trunk'
                title: Response List Trunks Core Trunks Get
              example:
                - id: 3fa85f64-5717-4562-b3fc-2c963f66afa6
                  organization_id: 3fa85f64-5717-4562-b3fc-2c963f66afa6
                  name: Example
                  created_at: '2026-01-15T09:30:00Z'
                  updated_at: '2026-01-15T09:30:00Z'
                  created_by: user:3fa85f64-5717-4562-b3fc-2c963f66afa6
                  modified_by: user:3fa85f64-5717-4562-b3fc-2c963f66afa6
                  inbound_config:
                    id: null
                    enable_noise_cancellation: false
                    media_encryption: null
                    allowed_addresses: null
                    caller_id_header: null
                    header_metadata_mappings: null
                  outbound_config:
                    id: 3fa85f64-5717-4562-b3fc-2c963f66afa6
                    address: string
                    auth_username: string
                    auth_password: string
                    transport: null
                    media_encryption: null
                  managed_account_id: 3fa85f64-5717-4562-b3fc-2c963f66afa6
                  external_id: 3fa85f64-5717-4562-b3fc-2c963f66afa6
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - HTTPBearer: []
components:
  schemas:
    Trunk:
      properties:
        id:
          type: string
          title: Id
        organization_id:
          type: string
          title: Organization Id
        name:
          type: string
          title: Name
        created_at:
          type: string
          format: date-time
          title: Created At
        updated_at:
          type: string
          format: date-time
          title: Updated At
        created_by:
          anyOf:
            - type: string
            - type: 'null'
          title: Created By
        modified_by:
          anyOf:
            - type: string
            - type: 'null'
          title: Modified By
        inbound_config:
          anyOf:
            - $ref: '#/components/schemas/InboundTrunkConfig'
            - type: 'null'
        outbound_config:
          anyOf:
            - $ref: '#/components/schemas/OutboundTrunkConfig'
            - type: 'null'
        managed_account_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Managed Account Id
        external_id:
          type: string
          title: External Id
      type: object
      required:
        - id
        - organization_id
        - name
        - created_at
        - updated_at
        - external_id
      title: Trunk
      description: Trunk entity representing a SIP trunk configuration.
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    InboundTrunkConfig:
      properties:
        id:
          anyOf:
            - type: string
            - type: 'null'
          title: Id
        enable_noise_cancellation:
          type: boolean
          title: Enable Noise Cancellation
          default: false
        media_encryption:
          $ref: '#/components/schemas/MediaEncryption'
          default: SIP_MEDIA_ENCRYPT_DISABLE
        allowed_addresses:
          anyOf:
            - items:
                type: string
              type: array
            - type: 'null'
          title: Allowed Addresses
        caller_id_header:
          anyOf:
            - type: string
            - type: 'null'
          title: Caller Id Header
        header_metadata_mappings:
          anyOf:
            - additionalProperties:
                type: string
              type: object
            - type: 'null'
          title: Header Metadata Mappings
      type: object
      title: InboundTrunkConfig
      description: Inbound trunk configuration for SIP trunks.
    OutboundTrunkConfig:
      properties:
        id:
          type: string
          title: Id
        address:
          type: string
          title: Address
        auth_username:
          type: string
          title: Auth Username
        auth_password:
          type: string
          title: Auth Password
        transport:
          $ref: '#/components/schemas/Transport'
          default: SIP_TRANSPORT_UDP
        media_encryption:
          $ref: '#/components/schemas/MediaEncryption'
          default: SIP_MEDIA_ENCRYPT_DISABLE
      type: object
      required:
        - id
        - address
        - auth_username
        - auth_password
      title: OutboundTrunkConfig
      description: Outbound trunk configuration for SIP trunks.
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
    MediaEncryption:
      type: string
      enum:
        - SIP_MEDIA_ENCRYPT_DISABLE
        - SIP_MEDIA_ENCRYPT_ALLOW
        - SIP_MEDIA_ENCRYPT_REQUIRE
      title: MediaEncryption
    Transport:
      type: string
      enum:
        - SIP_TRANSPORT_UDP
        - SIP_TRANSPORT_TCP
        - SIP_TRANSPORT_TLS
      title: Transport
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: Personal access token or organization API key. See Authentication.

````