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

# Create speech

> Text to audio, streamed while it is generated.



## OpenAPI

````yaml /tts/openapi.json post /v1/audio/speech
openapi: 3.0.3
info:
  title: Ses TTS API
  version: 1.0.12
  description: 'Text to speech: streamed audio, seven languages, custom voices.'
servers:
  - url: https://tts.eu.mihu.ai
    description: Europe (EU)
  - url: https://tts.tr.mihu.ai
    description: Türkiye (TR)
security:
  - bearerAuth: []
tags:
  - name: TTS speech
  - name: TTS voices
  - name: TTS service
paths:
  /v1/audio/speech:
    post:
      tags:
        - TTS speech
      summary: Create speech
      description: Text to audio, streamed while it is generated.
      operationId: createSpeech
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
                - input
              properties:
                input:
                  type: string
                  description: >-
                    The text. Long texts are split into chunks and streamed (up
                    to 20,000 characters).
                  example: Siparişiniz 28 Ekim günü saat 14.30da teslim edilecek.
                model:
                  type: string
                  description: 'The model: `mihu-ses-v1`.'
                  default: mihu-ses-v1
                language:
                  type: string
                  description: >-
                    `tr`, `en`, `de`, `fr`, `es`, `it`, `ru`, or `auto` (detect
                    from the text). Without it: from the voice, else Turkish.
                  example: tr
                voice:
                  type: string
                  description: >-
                    Voice id or name, or a custom voice id. See
                    [Voices](/tts/voices).
                  example: alp
                response_format:
                  type: string
                  description: >-
                    `pcm` is raw 16-bit little-endian 24 kHz mono. Default
                    `pcm`.
                  enum:
                    - pcm
                    - wav
                    - mp3
                    - opus
                    - aac
                    - flac
                  example: wav
                speed:
                  type: number
                  description: '0.25 to 4.0: tempo, pitch unchanged.'
                  default: 1
                stream_format:
                  type: string
                  description: '`audio`: the audio bytes. `sse`: Server-Sent Events.'
                  enum:
                    - audio
                    - sse
                  default: audio
                normalize:
                  type: boolean
                  description: >-
                    Numbers, amounts, dates, times and abbreviations written out
                    before synthesis.
                  default: true
                verify:
                  type: boolean
                  description: >-
                    Turkish: a recognizer checks each chunk; first audio comes
                    about 2 s later. Not for live calls.
                  default: false
                instructions:
                  type: string
                  description: Accepted and ignored (OpenAI style prompt).
      responses:
        '200':
          description: >-
            The audio, streamed. Headers: `X-Sample-Rate`, `X-Language`,
            `X-Voice`, `X-Model`.
          content:
            audio/wav:
              schema:
                type: string
                format: binary
            audio/mpeg:
              schema:
                type: string
                format: binary
            audio/pcm:
              schema:
                type: string
                format: binary
            audio/ogg:
              schema:
                type: string
                format: binary
            audio/aac:
              schema:
                type: string
                format: binary
            audio/flac:
              schema:
                type: string
                format: binary
        '400':
          description: Invalid request
        '401':
          description: Missing or wrong API key
        '404':
          description: Custom voice not found
        '409':
          description: Voice limit reached, or voice made with another model
        '500':
          description: Synthesis failed before any audio
        '503':
          description: All workers busy or still loading; retry
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: Your API key

````

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