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

# Stream Voice Preview

> Stream a short audio preview of a specific TTS voice from a given provider.

Stream a short audio sample of a specific voice directly from the TTS provider.

When users are building Voice Agents, reading that a voice is "warm and energetic" often isn't enough—they need to hear it. This endpoint proxies the audio preview from providers like ElevenLabs or Cartesia so you can play it directly in your application's UI.

<Info>
  **Authentication Required:** You must include your API key in the `x-api-key` header to authenticate this request.
</Info>

### Required Parameters

You must provide two query parameters to successfully fetch the audio:

1. **`providerId`**: The ID of the provider hosting the voice (e.g., `elevenlabs`, `cartesia`).
2. **`url`**: The exact URL of the preview audio file. You can find this URL inside the `previewUrl` field when querying the [List Provider Voices](/api-reference/config/list-provider-voices) endpoint.


## OpenAPI

````yaml get /config/tts-voice-preview
openapi: 3.0.3
info:
  title: Lyzr Voice LiveKit API
  version: 1.0.0
servers:
  - url: https://voice-livekit.studio.lyzr.ai/v1
security: []
paths:
  /config/tts-voice-preview:
    get:
      summary: Stream Voice Preview
      description: >-
        Stream a short audio preview of a specific TTS voice from a given
        provider.
      parameters:
        - name: providerId
          in: query
          required: true
          description: The internal ID of the TTS provider hosting the voice.
          schema:
            type: string
            enum:
              - cartesia
              - elevenlabs
              - deepgram
              - inworld
              - rime
              - sarvam
            example: elevenlabs
        - name: url
          in: query
          required: true
          description: >-
            The specific preview URL for the voice (typically obtained from the
            `tts-voices` or `realtime-options` endpoints).
          schema:
            type: string
            format: uri
            example: https://example.com/audio/voice_sample.wav
      responses:
        '200':
          description: Audio bytes streamed successfully with the provider's content-type.
          content:
            audio/*:
              schema:
                type: string
                format: binary
                description: The raw binary audio stream of the voice preview.
        '400':
          description: Invalid query parameters.
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    example: Invalid query params
                  issues:
                    type: array
                    items:
                      type: object
                      additionalProperties: true
                  example:
                    type: object
                    additionalProperties: true
      security:
        - ApiKeyAuth: []
components:
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key

````