---
title: "Search phone call legs"
method: POST
path: "/public-api/v1/phone_call_legs/list"
tags: ["phone_call_legs"]
---

# Search phone call legs

`POST /public-api/v1/phone_call_legs/list`

## Request

- Base URL: `/` (relative, and the document’s source URL is not known)
- URL: `/public-api/v1/phone_call_legs/list`
- Auth: HTTP bearer and API key in header `x-tenant-code`

Searchable list of call-detail records, one row per call leg.

Use ``POST /phone_calls/list`` for the grouped parent-call view. Filter and
paginate with ``first``, ``offset``, and ``after``; continue with the
previous ``page_info.end_cursor``. ``count`` is a top-level response field
and is populated only when ``include_count=true``.

## Request body

- PhoneCallLegListRequest: Filters and pagination for ``POST /phone_call_legs/list``.
  - `first` integer, required: Maximum call legs to return.
  - `offset` integer, required: Number of matching call legs to skip before this page.
  - `include_archived` boolean: When true, include archived call legs. Default false.
  - `include_count` boolean: When true, populate the top-level ``count`` field. Default false.
  - `starts_at` string, date-time, nullable: Filter call legs by start time.
  - `ends_at` string, date-time, nullable: Filter call legs by end time.
  - `after` string, nullable: Cursor from the previous response's ``page_info.end_cursor``.
  - `q` string, nullable: Free-text filter for call legs.
  - `user_ids` string[]: Restrict results to these numeric platform user IDs.
  - `call_types` AppSchemasCallDetailsCallType[]: Restrict results to these call types.
  - `numbers` string[]: Restrict results to call legs involving any of these phone numbers.
  - `keyword_values__include_and` string[]: Require call legs to contain every supplied keyword value.
  - `tag_values__include_and` string[]: Require call legs to have every supplied tag value.
  - `tag_values__exclude` string[]: Exclude call legs with any supplied tag value.

## Response `200`

A page of matching phone call legs, an optional matched count, and pagination cursors.

- CallDetailListResponse: Response body for the call-detail list.
  - `call_details` AppSchemasCallDetailsCallDetail[], required: Matching individual phone call legs.
    - `id` string, uuid, required
    - `event_type` string, nullable
    - `answered` boolean
    - `circuit_number` string, nullable
    - `circuit_name` string, nullable
    - `from_number` string, nullable
    - `to_number` string, nullable
    - `dial_starts_at` string, date-time, nullable
    - `dial_answered_at` string, date-time, nullable
    - `queueing_starts_at` string, date-time, nullable
    - `queueing_answered_at` string, date-time, nullable
    - `queueing_ends_at` string, date-time, nullable
    - `dial_ends_at` string, date-time, nullable
    - `acw_ends_at` string, date-time, nullable
    - `monitoring_type` string, nullable
    - `group_name` string, nullable
    - `dtmf` string, nullable
    - `keywords` AppSchemasCallDetailsKeyword[]
      - `participant_id` string, uuid, required
      - `starts_at` number, required
      - `value` string, required
    - `participants` AppSchemasCallDetailsParticipant[]
      - `id` string, uuid, required
      - `from_to` string, nullable
      - `type` string, nullable
      - `name` string, nullable
      - `company_name` string, nullable
    - `tags` AppSchemasCallDetailsTag[]
      - `value` string, nullable
      - `creator_type` string, nullable
    - `duration_wait` number, nullable
    - `duration_talk` number, nullable
    - `call_type` 'EXTENSION_ANSWERED' | 'EXTENSION_UNANSWERED' | 'OUTGOING_ANSWERED' | 'OUTGOING_UNANSWERED' | 'INCOMING_ANSWERED' | 'INCOMING_UNANSWERED' | 'AUTOMATIC_RECORD' | 'TRANSFER_ANSWERED' | 'TRANSFER_UNANSWERED': ``call_type`` enum (response field and filter).
    - `customers` ParticipantForItem[]
      - `id` string, uuid, required
      - `from_to` string, nullable
      - `type` string, nullable
      - `name` string, nullable
      - `company_name` string, nullable
      - `analysis` AppSchemasCallDetailsParticipantAnalysis: Per-participant audio analysis (only present on customers/operators).
        - `f0` number, nullable
        - `speechrate` number, nullable
        - `variance` number, nullable
        - `filler_count` integer, nullable
    - `operators` ParticipantForItem[]
      - `id` string, uuid, required
      - `from_to` string, nullable
      - `type` string, nullable
      - `name` string, nullable
      - `company_name` string, nullable
      - `analysis` AppSchemasCallDetailsParticipantAnalysis: Per-participant audio analysis (only present on customers/operators).
        - `f0` number, nullable
        - `speechrate` number, nullable
        - `variance` number, nullable
        - `filler_count` integer, nullable
  - `count` integer, nullable, required: Total matching call legs when ``include_count=true``; otherwise null.
  - `page_info` AppSchemasCallDetailsPageInfo, required: Pagination info for the list response.
    - `start_cursor` string, nullable: ID of the first record on this page, or null when the returned ``call_details`` collection is empty. Treat this value as opaque.
    - `end_cursor` string, nullable: ID of the last record on this page. Pass it unchanged as ``after`` to fetch the next page. Continue until the returned ``call_details`` collection is empty; do not use ``end_cursor`` as the completion signal.

## Other responses

- `400`: The tenant could not be resolved from the request.
- `401`: Error envelope (`public_api.unauthorized`).
- `403`: The request is not allowed for the current tenant or access configuration.
- `404`: Error envelope (`public_api.not_found`).
- `409`: Error envelope (`public_api.conflict`).
- `413`: The request body exceeds the maximum allowed size.
- `422`: Validation Error
- `429`: Rate limit exceeded. Wait for ``Retry-After`` seconds before retrying.
- `502`: Error envelope (`public_api.internal_error`).
- `503`: The request could not be served right now. Please retry.
- `504`: Error envelope (`public_api.request_timeout`).

---

[API](https://skmtc.dev/miitel/apis/miitel-public-api.md) - [All operations](https://skmtc.dev/miitel/apis/miitel-public-api/llms.txt) - [OpenAPI document](https://skmtc.dev/miitel/apis/miitel-public-api/revisions/961732756fa3?raw)
