> ## Documentation Index
> Fetch the complete documentation index at: https://breezeblue-pre.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Save voice preview

> Save a generated preview as a private voice. Voice Metadata values are stable lowercase codes; tone accepts up to three distinct codes. language_code is required. accent is available only for en and zh and must match language_code.



## OpenAPI

````yaml /openapi.json post /v1/voice-previews/{generated_voice_id}/save
openapi: 3.1.0
info:
  title: Breeze Developer API
  description: >-
    Breeze Developer API for models, voices, text-to-speech, history, balance,
    usage, and browser-managed API keys.
  version: 1.0.0
servers:
  - url: https://api.breeze.blue
security: []
tags:
  - name: Models
    description: Supported TTS models.
  - name: Text to Speech
    description: Text-to-speech synthesis and instruction enhancement.
  - name: Voices
    description: Saved voices and voice settings.
  - name: Voice Previews
    description: Create, audition, and save temporary voice previews.
  - name: Account
    description: Balance, usage, and API keys.
  - name: History
    description: Generated audio history.
paths:
  /v1/voice-previews/{generated_voice_id}/save:
    post:
      tags:
        - Voice Previews
      summary: Save voice preview
      description: >-
        Save a generated preview as a private voice. Voice Metadata values are
        stable lowercase codes; tone accepts up to three distinct codes.
        language_code is required. accent is available only for en and zh and
        must match language_code.
      operationId: voice_previews_save
      parameters:
        - name: generated_voice_id
          in: path
          required: true
          schema:
            title: Generated Voice Id
            type: string
          description: Preview ID returned by a voice preview creation endpoint.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/SaveVoicePreviewRequest'
      responses:
        '200':
          description: Saved voice.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SavedVoiceResponse'
          headers:
            x-breeze-api-key-id:
              description: >-
                Public API key identifier used to authenticate the request, when
                an API key was used.
              schema:
                type: string
        '401':
          description: HTTP 401 error response.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '403':
          description: HTTP 403 error response.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '404':
          description: HTTP 404 error response.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '422':
          description: HTTP 422 error response.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ValidationErrorResponse'
      security:
        - ApiKeyAuth: []
      x-codeSamples:
        - lang: cURL
          label: cURL
          source: |-
            curl \
              --request POST \
              --url "https://api.breeze.blue/v1/voice-previews/gvi_01hpreview/save" \
              --header "xi-api-key: $BREEZE_API_KEY" \
              --header "Content-Type: application/json" \
              --data '{
              "voice_name": "Brand Narrator"
            }'
        - lang: Python
          label: Python SDK
          source: |-
            import os

            from breeze_blue import BreezeBlue

            client = BreezeBlue(api_key=os.environ["BREEZE_API_KEY"])

            voice = client.voices.save_preview(
                generated_voice_id="gvi_01hpreview",
                voice_name="Brand Narrator",
                language_code="en",
            )

            print(voice["voice_id"])
        - lang: TypeScript
          label: TypeScript SDK
          source: |-
            import { BreezeBlueClient } from "@breeze.blue/sdk";

            const client = new BreezeBlueClient({
              apiKey: process.env.BREEZE_API_KEY!,
            });

            const voice = await client.voices.savePreview({
              generatedVoiceId: "gvi_01hpreview",
              voiceName: "Brand Narrator",
              languageCode: "en",
            });

            console.log(voice.voiceId);
components:
  schemas:
    SaveVoicePreviewRequest:
      properties:
        gender:
          anyOf:
            - type: string
              enum:
                - male
                - female
                - neutral
            - type: 'null'
          title: Gender
          description: Stable gender code, or null when not classified.
        age:
          anyOf:
            - type: string
              enum:
                - child
                - young
                - middle_aged
                - old
            - type: 'null'
          title: Age
          description: Stable age code, or null when not classified.
        tone:
          items:
            type: string
            enum:
              - warm
              - calm
              - bright
              - gentle
              - energetic
              - authoritative
              - sincere
              - weary
              - precise
              - refined
              - urgent
              - friendly
              - articulate
              - steady
              - playful
              - compassionate
              - reflective
              - measured
              - rhythmic
              - passionate
          type: array
          maxItems: 3
          title: Tone
          description: Zero to three distinct stable tone codes.
          uniqueItems: true
        accent:
          anyOf:
            - type: string
              enum:
                - american
                - british
                - scottish
                - irish
                - australian
                - canadian
                - us_southern
                - us_new_york
                - indian
                - south_african
                - russian
                - japanese
                - korean
                - chinese
                - mandarin_guangdong
                - mandarin_northeastern
                - mandarin_shaanxi
                - mandarin_shanghai
                - mandarin_sichuan
                - mandarin_yunnan
                - mandarin_henan
                - cantonese
            - type: 'null'
          title: Accent
          description: >-
            Stable accent code, or null. Valid only for en or zh and must match
            language_code.
        voice_name:
          type: string
          maxLength: 80
          minLength: 1
          title: Voice Name
          description: Display name for the saved voice. Maximum 80 characters.
        voice_description:
          anyOf:
            - type: string
              maxLength: 1000
            - type: 'null'
          title: Voice Description
          description: Optional description stored with the saved voice.
        language_code:
          anyOf:
            - type: string
              enum:
                - ar
                - cs
                - de
                - el
                - en
                - es
                - fi
                - fr
                - hi
                - id
                - it
                - ja
                - ko
                - nl
                - pl
                - pt
                - ro
                - ru
                - th
                - tr
                - uk
                - vi
                - zh
            - type: 'null'
          title: Language Code
          description: Required saved audio language from the 23-language code contract.
        tags:
          items:
            type: string
            maxLength: 128
          type: array
          maxItems: 20
          title: Tags
          description: Canonical lowercase tags stored with the saved voice.
      additionalProperties: false
      type: object
      required:
        - voice_name
      title: SaveVoicePreviewRequest
    SavedVoiceResponse:
      properties:
        voice_id:
          title: Voice Id
          type: string
        name:
          title: Name
          type: string
        origin:
          title: Origin
          type: string
        tags:
          items:
            type: string
            maxLength: 128
          maxItems: 20
          title: Tags
          type: array
        is_favorited:
          default: false
          title: Is Favorited
          type: boolean
        preview_url:
          anyOf:
            - type: string
            - type: 'null'
          default: null
          title: Preview Url
        description:
          anyOf:
            - type: string
            - type: 'null'
          default: null
          title: Description
        language_code:
          enum:
            - ar
            - cs
            - de
            - el
            - en
            - es
            - fi
            - fr
            - hi
            - id
            - it
            - ja
            - ko
            - nl
            - pl
            - pt
            - ro
            - ru
            - th
            - tr
            - uk
            - vi
            - zh
          title: Language Code
          type: string
        gender:
          anyOf:
            - type: string
              enum:
                - male
                - female
                - neutral
            - type: 'null'
          title: Gender
        age:
          anyOf:
            - type: string
              enum:
                - child
                - young
                - middle_aged
                - old
            - type: 'null'
          title: Age
        tone:
          items:
            type: string
            enum:
              - warm
              - calm
              - bright
              - gentle
              - energetic
              - authoritative
              - sincere
              - weary
              - precise
              - refined
              - urgent
              - friendly
              - articulate
              - steady
              - playful
              - compassionate
              - reflective
              - measured
              - rhythmic
              - passionate
          maxItems: 3
          title: Tone
          type: array
          uniqueItems: true
        accent:
          anyOf:
            - type: string
              enum:
                - american
                - british
                - scottish
                - irish
                - australian
                - canadian
                - us_southern
                - us_new_york
                - indian
                - south_african
                - russian
                - japanese
                - korean
                - chinese
                - mandarin_guangdong
                - mandarin_northeastern
                - mandarin_shaanxi
                - mandarin_shanghai
                - mandarin_sichuan
                - mandarin_yunnan
                - mandarin_henan
                - cantonese
            - type: 'null'
          title: Accent
        created_at_unix:
          anyOf:
            - type: integer
            - type: 'null'
          default: null
          title: Created At Unix
      required:
        - voice_id
        - name
        - origin
        - language_code
        - gender
        - age
        - tone
        - accent
      title: SavedVoiceResponse
      type: object
    ErrorResponse:
      properties:
        ok:
          default: false
          title: Ok
          type: boolean
        code:
          title: Code
          type: string
        detail:
          title: Detail
          type: string
        error:
          title: Error
          type: string
        meta:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          default: null
          title: Meta
      required:
        - code
        - detail
        - error
      title: ErrorResponse
      type: object
    ValidationErrorResponse:
      properties:
        ok:
          default: false
          title: Ok
          type: boolean
        code:
          title: Code
          type: string
        detail:
          title: Detail
          type: string
        error:
          title: Error
          type: string
        meta:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Meta
      required:
        - code
        - detail
        - error
      title: ValidationErrorResponse
      type: object
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: xi-api-key
      description: Breeze Developer API key.

````