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

# List TTS voices

> Retrieve available TTS voices with optional filtering, pagination, and source flags.



## OpenAPI

````yaml /api-reference/openapi.json get /v2/tts/voices
openapi: 3.0.1
info:
  title: Hamsa API
  description: Trying out our transcription and media-to-text APIs
  license:
    name: MIT
  version: 1.0.0
servers:
  - url: https://api.tryhamsa.com
security: []
paths:
  /v2/tts/voices:
    get:
      summary: List TTS voices
      description: >-
        Retrieve available TTS voices with optional filtering, pagination, and
        source flags.
      parameters:
        - in: query
          name: q
          required: false
          description: Search query string.
          schema:
            type: string
            example: test
        - in: query
          name: page
          required: true
          description: Current page number.
          schema:
            type: integer
            example: 1
        - in: query
          name: perPage
          required: true
          description: Number of voices per page.
          schema:
            type: integer
            example: 10
        - in: query
          name: source
          required: true
          description: >-
            Filter voices by source. jobs for media voices, voice_agents for
            agents voices.
          schema:
            type: string
            enum:
              - jobs
              - voice_agents
            example: voice_agents
        - in: query
          name: recentlyUsed
          required: false
          description: Filter by recently used flag.
          schema:
            type: boolean
            example: true
        - in: query
          name: all
          required: false
          description: Return all voices when true.
          schema:
            type: boolean
            example: false
        - in: query
          name: myVoices
          required: false
          description: Filter by voices owned by the user.
          schema:
            type: boolean
            example: true
        - in: query
          name: favourite
          required: false
          description: Filter favourite voices.
          schema:
            type: boolean
            example: true
        - in: query
          name: gender
          required: false
          description: Filter by one or more genders.
          style: form
          explode: true
          schema:
            type: array
            items:
              type: string
              enum:
                - male
                - female
            example:
              - male
              - female
        - in: query
          name: language
          required: false
          description: Filter by one or more languages.
          style: form
          explode: true
          schema:
            type: array
            items:
              type: string
              enum:
                - ar
                - en
            example:
              - ar
              - en
        - in: query
          name: style
          required: false
          description: Filter by one or more styles.
          style: form
          explode: true
          schema:
            type: array
            items:
              type: string
              enum:
                - narrator
                - conversational
            example:
              - narrator
              - conversational
        - in: query
          name: dialectId
          required: false
          description: Filter by one or more dialect IDs (UUID).
          style: form
          explode: true
          schema:
            type: array
            items:
              type: string
              format: uuid
            example:
              - ae6d58c6-c6bd-4ae0-ad74-b8b39c29928b
              - 2b9d0f7e-6c1b-4a41-9e41-3a7e6f5d9a11
        - in: query
          name: projectId
          required: true
          description: Project identifier.
          schema:
            type: string
            example: ae6d58c6-c6bd-4ae0-ad74-b8b39c29928b
      responses:
        '200':
          description: Voices retrieved successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ListTtsVoicesResponse'
        '400':
          description: Validation error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ValidationErrorResponse'
        '500':
          description: Internal server error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/InternalServerErrorResponse'
      security:
        - ApiKeyAuth: []
components:
  schemas:
    ListTtsVoicesResponse:
      type: object
      allOf:
        - $ref: '#/components/schemas/SuccessResponse'
        - type: object
          properties:
            data:
              type: object
              properties:
                voices:
                  type: array
                  items:
                    $ref: '#/components/schemas/TtsVoice'
                totalPages:
                  type: integer
                  example: 5
                page:
                  type: integer
                  example: 1
                totalCount:
                  type: integer
                  example: 50
    ValidationErrorResponse:
      type: object
      properties:
        code:
          type: integer
          example: 9400
        message:
          type: string
          example: Field must be a string!
        messageKey:
          type: string
          example: FieldMustBeString
    InternalServerErrorResponse:
      type: object
      properties:
        success:
          type: boolean
          example: false
        code:
          type: integer
          example: 500
        message:
          type: string
          example: Internal server error
    SuccessResponse:
      type: object
      properties:
        success:
          type: boolean
          example: true
        message:
          type: string
          example: Operation completed successfully
        messageKey:
          type: string
          example: OPERATION_SUCCESSFUL
    TtsVoice:
      type: object
      required:
        - id
        - language
        - name
        - tags
        - voiceRecord
        - createdAt
        - isFavourite
        - usedInJobs
        - usedInVoiceAgents
      properties:
        id:
          type: string
          format: uuid
          example: 633f19a6-089b-4950-bfab-55f5c750732e
        language:
          type: string
          enum:
            - en
            - ar
          example: ar
        name:
          type: string
          example: Aisha
        tags:
          type: array
          minItems: 2
          maxItems: 2
          items:
            type: string
            enum:
              - male
              - female
              - conversational
              - narrator
          example:
            - female
            - conversational
        voiceRecord:
          type: string
          format: uri
          description: Signed URL for the voice audio sample
          example: https://cdn.tryhamsa.com/tts-voices/Aisha.wav
        dialectId:
          type: string
          format: uuid
          nullable: true
          example: 6ac0324d-bcb9-40f3-a57a-de6da7b721c8
        dialect:
          type: object
          nullable: true
          properties:
            name:
              type: string
              example: Oman
            languageCode:
              type: string
              example: oma
        image:
          type: string
          format: uri
          nullable: true
          description: Avatar image for the voice
          example: https://cdn.tryhamsa.com/tts-voices-images/aisha.jpg
        createdAt:
          type: string
          format: date-time
          example: '2025-12-18T11:21:36.182Z'
        isFavourite:
          type: boolean
          example: false
        usedInJobs:
          type: boolean
          description: Indicates whether this voice has been used in TTS jobs
          example: true
        usedInVoiceAgents:
          type: boolean
          description: Indicates whether this voice is assigned to any voice agents
          example: true
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: Authorization
      description: >-
        Pass the API key in the Authorization header, You need to put Token
        keyword before the API key. e.g. 'Authorization: Token <api-key>'

````