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

# List voice records

> Returns a paginated list of voice calls you've previously sent.



## OpenAPI

````yaml /openapi/endpoints/ycloud-api-v2.yaml get /voices
openapi: 3.0.0
info:
  description: >-
    The [YCloud](https://ycloud.com) API is organized around
    [REST](https://en.wikipedia.org/wiki/Representational_state_transfer). Our
    API is designed to have predictable, resource-oriented URLs, return
    [JSON](https://www.json.org) responses, and use standard HTTP response codes
    and verbs.
  version: v2
  title: YCloud API
  termsOfService: https://ycloud.com/terms-service
  contact:
    email: service@ycloud.com
servers:
  - url: https://api.ycloud.com/v2
    description: Base URL
security:
  - api_key: []
tags:
  - name: Balance
  - name: Contacts
  - name: Custom Events
  - name: Emails
  - name: SMS
  - name: Unsubscribers
  - name: Verify
  - name: Voices
  - name: Webhook Endpoints
  - name: WhatsApp Business Accounts
  - name: WhatsApp Inbound Messages
  - name: WhatsApp Media
  - name: WhatsApp Messages
  - name: WhatsApp Blocked Users
  - name: WhatsApp Groups
  - name: WhatsApp Calling
  - name: WhatsApp Phone Numbers
  - name: WhatsApp Templates
  - name: WhatsApp Flows
  - name: Meta Business Agent
  - name: WhatsApp Group Messages
externalDocs:
  description: Homepage
  url: https://ycloud.com
paths:
  /voices:
    get:
      tags:
        - Voices
      summary: List voice records
      description: Returns a paginated list of voice calls you've previously sent.
      operationId: voice-list
      parameters:
        - $ref: '#/components/parameters/page'
        - $ref: '#/components/parameters/limit'
        - $ref: '#/components/parameters/includeTotal'
        - $ref: '#/components/parameters/filter_createTime_gte-default_1d'
        - $ref: '#/components/parameters/filter_createTime_lte'
        - $ref: '#/components/parameters/filter_id'
      responses:
        '200':
          description: Successfully retrieved a paginated list of objects.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/VoicePage'
components:
  parameters:
    page:
      name: page
      in: query
      description: Page number of the results to be returned, 1-based.
      required: false
      schema:
        type: integer
        format: int32
        minimum: 1
        maximum: 100
        default: 1
    limit:
      name: limit
      in: query
      description: >-
        A limit on the number of results to be returned, or number of results
        per page, between 1 and 100, defaults to 10.
      required: false
      schema:
        type: integer
        format: int32
        minimum: 1
        maximum: 100
        default: 10
    includeTotal:
      name: includeTotal
      in: query
      description: >-
        Return results inside an object that contains the total result count or
        not.
      required: false
      schema:
        type: boolean
        default: false
    filter_createTime_gte-default_1d:
      name: filter.createTime.gte
      in: query
      description: >-
        Return results where the `createTime` field is greater than or equal to
        this value. Default: One day ago from now.
      required: false
      schema:
        type: string
        format: date-time
        example: '2022-03-01T12:00:00.000Z'
    filter_createTime_lte:
      name: filter.createTime.lte
      in: query
      description: >-
        Return results where the `createTime` field is less than or equal to
        this value.
      required: false
      schema:
        type: string
        format: date-time
        example: '2022-03-31T12:00:00.000Z'
    filter_id:
      name: filter.id
      in: query
      description: >-
        Unique object ID on our side. Other filter parameters will be ignored if
        this parameter is present.
      required: false
      schema:
        type: string
  schemas:
    VoicePage:
      type: object
      description: Represents a given page of Voice Calls.
      allOf:
        - $ref: '#/components/schemas/Page'
      properties:
        items:
          description: An array containing Voice objects.
          type: array
          items:
            $ref: '#/components/schemas/Voice'
    Page:
      type: object
      description: Represents a given page of items.
      required:
        - offset
        - limit
        - length
      properties:
        offset:
          description: >-
            The position of the item this page starts from, zero-based. e.g.,
            the 11th item is at offset 10.
          type: integer
          format: int32
          minimum: 0
        limit:
          description: >-
            A limit on the number of items to be returned, between 1 and 100,
            defaults to 10.
          type: integer
          format: int32
          minimum: 1
        length:
          description: The actual number of items in the page.
          type: integer
          format: int32
          minimum: 0
        total:
          description: >-
            The total number of items. This field is returned only when the
            request parameter `includeTotal` is set to `true`.
          type: integer
          format: int32
          minimum: 0
        items:
          type: array
          items:
            type: object
    Voice:
      type: object
      required:
        - id
        - to
      properties:
        id:
          type: string
          description: Unique ID for the object.
          minLength: 6
          maxLength: 128
        to:
          type: string
          description: >-
            The recipient's phone number in
            [E.164](https://en.wikipedia.org/wiki/E.164) format.
          example: '+16315551111'
        verificationCode:
          type: string
          description: The verification code to be sent, 4 to 6 digits.
          example: '123456'
        language:
          type: string
          description: >-
            [ISO 639 Language
            Code](https://www.iso.org/iso-639-language-codes.html).
          example: en
        regionCode:
          type: string
          description: >-
            [ISO 3166-1 alpha-2 country
            code](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2).
          example: US
        totalSegments:
          type: integer
          format: int32
          minimum: 1
          description: Number of message segments. It's always 1 for voice calls.
          example: 1
        totalPrice:
          type: number
          format: double
          description: Total price of this message.
          example: 0.05
        currency:
          type: string
          description: >-
            Price currency. [ISO 4217 currency
            code](https://en.wikipedia.org/wiki/ISO_4217).
          example: USD
        status:
          type: string
          description: >-
            Delivery status. One of `accepted`, `sent`, `delivered`,
            `undelivered`, or `failed`.

            - `accepted`: The messaging request is accepted by our system.

            - `failed`: The message failed to be sent from our system.

            - `sent`: The message has been sent from our system.

            - `delivered`: Our system has received a delivery receipt indicating
            that message is delivered.

            - `undelivered`: Our system has received a delivery receipt
            indicating that message is not delivered.
          example: sent
          enum:
            - accepted
            - failed
            - sent
            - delivered
            - undelivered
        errorCode:
          type: string
          description: Error code when the message is undeliverable.
        createTime:
          type: string
          format: date-time
          description: >-
            The time at which this message was created, formatted in [RFC
            3339](https://datatracker.ietf.org/doc/html/rfc3339). e.g.,
            `2022-03-01T12:00:00.000Z`.
          example: '2022-03-01T12:00:00.000Z'
        updateTime:
          type: string
          format: date-time
          description: >-
            The time at which the delivery report for this message was updated,
            formatted in [RFC
            3339](https://datatracker.ietf.org/doc/html/rfc3339). e.g.,
            `2022-03-01T12:00:00.000Z`.
          example: '2022-03-01T12:00:00.000Z'
        externalId:
          type: string
          description: >-
            A unique (recommended) string to reference the object. This can be
            an order number or similar, and can be used to reconcile the object
            with your internal systems.
        callbackUrl:
          type: string
          description: >-
            Delivery report URL. You can provide a URL, and we will push the
            updated status report to your server in time. e.g.,
            https://httpbin.org/anything?tag=api.

            Note: We recommend configuring Webhook Endpoints instead.
          example: https://httpbin.org/anything?tag=api-voice
        bizType:
          type: string
          description: >-
            This can be either empty or one of `voice`, or `verify`. Defaults to
            `voice`.

            - `voice`: Indicates that the message is sent via the **Voice**
            product.

            - `verify`: Indicates that the message is sent via **Verify**
            product.
          example: voice
        verificationId:
          type: string
          description: The verification ID. Included only when `bizType` is `verify`.
          example: VERIFICATION-ID
  securitySchemes:
    api_key:
      type: apiKey
      name: X-API-Key
      in: header

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.