> ## 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.

# Transcribe a file

> Native or OpenAI-compatible by `model`. With `webhook_url` the job runs asynchronously and answers `202`. For OpenAI model names see [OpenAI-compatible API](/stt/openai).



## OpenAPI

````yaml /stt/openapi.json post /v1/audio/transcriptions
openapi: 3.0.3
info:
  title: Umay STT API
  version: 1.0.25
  description: >-
    Speech recognition: files, voiceprints and audio isolation. Live audio uses
    the WebSocket endpoints in the guide pages.
servers:
  - url: https://stt.eu.mihu.ai
    description: Europe (EU)
  - url: https://stt.tr.mihu.ai
    description: Türkiye (TR)
security:
  - bearerAuth: []
tags:
  - name: Service
  - name: Transcription
  - name: Voiceprints
  - name: Audio isolation
paths:
  /v1/audio/transcriptions:
    post:
      tags:
        - Transcription
      summary: Transcribe a file
      description: >-
        Native or OpenAI-compatible by `model`. With `webhook_url` the job runs
        asynchronously and answers `202`. For OpenAI model names see
        [OpenAI-compatible API](/stt/openai).
      operationId: createTranscription
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              properties:
                file:
                  type: string
                  description: The audio. Any common format (WAV, MP3, ...).
                  format: binary
                model:
                  type: string
                  description: >-
                    `umay` (most accurate; files), or an OpenAI name such as
                    `whisper-1`, `gpt-4o-transcribe`,
                    `gpt-4o-transcribe-diarize`.
                  example: umay
                language:
                  type: string
                  description: Language of the speech.
                  enum:
                    - tr
                    - en
                    - de
                    - fr
                    - it
                    - ru
                    - es
                  example: tr
                normalize:
                  type: boolean
                  description: >-
                    Inverse text normalisation on the final text: "bin iki yüz
                    elli lira" becomes "1.250 TL". `false` returns the spoken
                    words.
                  default: true
                dialect_correction:
                  type: boolean
                  description: >-
                    Turkish, with `normalize=true`: regional and colloquial
                    forms in standard Turkish.
                  default: true
                place_correction:
                  type: boolean
                  description: >-
                    Turkish, with `normalize=true`: misheard or split place
                    names corrected.
                  default: true
                abbreviations:
                  type: boolean
                  description: >-
                    Turkish, with `normalize=true`: `false` writes units out
                    ("43 dakika"), `true` abbreviates ("43 dk").
                  default: false
                mode:
                  type: string
                  description: >-
                    `normal`: files with `model=umay` use the language model
                    where the model has one. `fast`: never.
                  enum:
                    - fast
                    - normal
                  default: fast
                hint_context:
                  type: string
                  description: >-
                    Built-in hint lists (Turkish): `mugla`, `izmir`, `manisa`,
                    `aydin`, `denizli`; comma-separated for several.
                hints:
                  type: string
                  description: >-
                    Own phrases (names, places) to favour, comma or newline
                    separated; `phrase :3` gives one phrase its own boost.
                hints_score:
                  type: number
                  description: Boost for phrases without their own.
                  default: 2
                gender_detection:
                  type: boolean
                  description: >-
                    Gender of the speaker(s) with a confidence `percent`
                    (50-100).
                  default: false
                diarize:
                  type: boolean
                  description: Speaker label per segment (`S1`, `S2`, ...).
                  default: false
                max_speakers:
                  type: integer
                  description: Upper bound for diarization.
                  default: 8
                speaker_lock:
                  type: boolean
                  description: >-
                    Only the first speaker's speech becomes text; other voices
                    come as `ignored`.
                  default: false
                lock_threshold:
                  type: number
                  description: >-
                    With `speaker_lock`: the similarity a segment needs to count
                    as `S1` (0-1). Default 0.5, or 0.55 with
                    `reference_voiceprint`.
                voice_isolation:
                  type: boolean
                  description: >-
                    Removes other voices before recognition (tr, de, fr, it, es,
                    ru); switches on only after another voice is heard.
                  default: false
                reference_voiceprint:
                  type: string
                  description: >-
                    Id or token of a stored voiceprint: with `voice_isolation`,
                    `speaker_lock` or `diarize`, speaker `S1` is that person
                    from the first second.
                response_format:
                  type: string
                  description: With OpenAI model names.
                  enum:
                    - json
                    - text
                    - srt
                    - vtt
                    - verbose_json
                    - diarized_json
                  default: json
                webhook_url:
                  type: string
                  description: >-
                    `https://` URL that receives the result (`POST`, JSON). With
                    it the request answers `202` at once. Must resolve to a
                    public address.
                webhook_secret:
                  type: string
                  description: >-
                    Optional, 1-256 characters: the webhook is signed with it
                    (`X-Mihu-Signature`).
                webhook_metadata:
                  type: string
                  description: 'Optional, up to 4 KB: echoed back as `metadata`.'
                file_url:
                  type: string
                  description: >-
                    Instead of `file`: `https://` URL the server downloads the
                    audio from (up to 1 GB, 10 minutes, public addresses only).
      responses:
        '200':
          description: Transcription
          content:
            application/json:
              example:
                text: 'Adresiniz Şirinyer Mahallesi, Cumhuriyet Caddesi No: 17.'
                model: umay
                language: tr
                duration: 7.2
                processing_time: 0.16
                speakers:
                  - speaker: S1
                    gender: female
                    percent: 97
                    speech_seconds: 6.8
        '202':
          description: Accepted (with `webhook_url`); the result follows on the webhook
          content:
            application/json:
              example:
                id: 6f1d2c3b-9a4e-4b7c-8d2f-1e0a5b9c7d36
                object: transcription.job
                status: queued
                duration: 3600
                created_at: 1793145600
                source:
                  type: upload
                  filename: call-1042.wav
                  size_bytes: 115200044
                request:
                  model: umay
                  language: tr
                  response_format: json
                  language_model: false
                  normalize: true
                  diarize: true
                  gender_detection: false
                  speaker_lock: false
                  voice_isolation: false
                  hints: false
                  max_speakers: 8
        '400':
          description: Invalid field
        '401':
          description: Missing or wrong API key
        '413':
          description: File larger than 1 GB or audio longer than 4 hours
        '422':
          description: Invalid value or unusable audio
        '429':
          description: More than 20 jobs of this API key waiting or running
        '503':
          description: Server busy; retry later
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.