---
title: "Reprocess Audio"
method: PUT
path: "/v1/audios/{audio_id}"
tags: ["Audio Emotion API"]
---

# Reprocess Audio

`PUT /v1/audios/{audio_id}`

## Request

- Base URL: `https://api.imentiv.ai` (the document declares no server; this is the origin it was published from)
- URL: `https://api.imentiv.ai/v1/audios/{audio_id}`
- Auth: one of:
  - API key in header `X-API-Key`
  - HTTP bearer

Reprocess an audio file based on audio id.

The three speech-analysis flags are optional and default to "leave whatever
is stored alone", so existing callers are unaffected. Supplying them is how
media uploaded with speech analysis skipped gets analyzed later (#840).

`language` is optional too. Without it the language is detected from the audio, as before; with it
the audio is processed in that language. It is checked before anything is charged, so an unsupported
code is refused with 422 `invalid_language` and costs nothing. It is only used by a request that
starts a run (a failed audio, or `reprocess=true`); on a request that does not, it is ignored.
For a standalone audio it applies to this run only: a later reprocess that omits it auto-detects again.
For a video's companion audio the choice is also recorded on the video, so a later reprocess of the
video re-sends it; a later audio reprocess that omits `language` re-detects the audio but leaves the
video's recorded language alone.

`multilingual` and `expected_languages` are the language hints (`expected_languages` is the set of languages
the audio may contain, up to 5; see the field descriptions). They are checked with `language`, before anything
is charged: an invalid one is refused with 422 `invalid_language` and costs nothing. Unlike `language` they are
not sticky: a request that starts a run and omits them runs without a hint, and clears the audio's stored ones.
For a video's companion audio, a request that names any of `language`, `multilingual` or `expected_languages`
also replaces the video's hints with the audio's resulting ones, so naming only `language` clears the video's
hints; a request that names none leaves the video's alone.

## Path parameters

- `audio_id` string, required: Unique identifier of the audio to reprocess

## Request body `application/x-www-form-urlencoded`

- BodyReprocessAudioV1AudiosAudioIdPut
  - `callback_url` string, nullable: The callback url to notify audio reprocessing is completed. Give a valid URL. Must be an https URL on a publicly reachable host.
  - `reprocess` boolean: Set to 'True' to reprocess an already completed audio; defaults to 'False'.
  - `transcription` boolean, nullable: Turn speech-to-text on or off for this run. Omit to keep the current setting.
  - `diarization` boolean, nullable: Turn speaker diarization on or off for this run. Omit to keep the current setting.
  - `text_emotion` boolean, nullable: Turn transcript emotion analysis on or off for this run. Requires transcription (or an already-applied transcript). Omit to keep the current setting.
  - `language` string, nullable: Language of the audio as a language code such as `hu` or `pt-BR` (a region is ignored, so `zh-yue` becomes `zh`: send `yue` for Cantonese). Use it when automatic detection got the language wrong. Omit to auto-detect. A later reprocess of this audio that omits it auto-detects the audio again. For a video's companion audio the choice is also recorded on the video, so a later reprocess of the video re-sends it, and omitting it here does not clear that. Unsupported codes are refused with 422 `invalid_language`. With `expected_languages` it must be one of them.
  - `multilingual` boolean, nullable: Opt in to mixed-language transcription: the speech may switch language, and each stretch is transcribed in the language it is spoken in. Once the audio completes, the lines that are not in its main language are also translated into the main language and billed as a translation, on top of transcription (`auto_translation` reports it). This is input only; the languages actually detected are reported separately. Omitted means no hint: the audio is analysed again without one, and any stored hint is cleared.
  - `expected_languages` string, nullable: Comma-separated codes of the languages the audio may contain, the main one included (e.g. `en,ja`), 1 to 5 after duplicates are removed. Case and whitespace are ignored, a region is dropped (`pt-BR` is `pt`) and an alias maps to the Whisper spelling (`iw` is `he`); Cantonese is `yue`. Language detection is restricted to the set, with or without `multilingual`. If `language` is also sent it must be one of them (422 `invalid_language` otherwise). If `language` is omitted, detection still runs, restricted to the set. An unknown code, or more than 5, is refused with 422 `invalid_language` before anything is charged. Omitted means no hint: the audio is analysed again without one, and any stored hint is cleared.

## Response `200`

Successful Response

- AudioReprocessResponse: Response model for audio reprocessing. Inherits: TextReprocessResponse: Reuse response format for audio reprocessing.
  - `id` string, required
  - `status` string, required
  - `message` string, required

## Other responses

- `422`: Validation Error

## Changes

- **2026-10-31** `bd825cd86e8c`: 3 info
  - added the new optional request property `expected_languages`
  - added the new optional request property `language`
  - added the new optional request property `multilingual`
- **2026-08-20** `74ceee4a5c98`: 4 info
  - added the new optional request property `diarization`
  - added the new optional request property `text_emotion`
  - added the new optional request property `transcription`
  - request property `callback_url` list-of-types was widened by adding types `null` to media type `application/x-www-form-urlencoded`

[Operation history](https://skmtc.dev/imentiv/apis/welcome-to-imentiv-ai/changes/v1/audios/:audio_id/put.md)

---

[API](https://skmtc.dev/imentiv/apis/welcome-to-imentiv-ai.md) - [All operations](https://skmtc.dev/imentiv/apis/welcome-to-imentiv-ai/llms.txt) - [OpenAPI document](https://skmtc.dev/imentiv/apis/welcome-to-imentiv-ai/revisions/bc15cec7e794?raw)
