Skip to main content
Mesh API supports audio through POST /v1/chat/completions. Use this page for:
  • audio input with input_audio
  • audio output with modalities and audio

Audio input

Send audio as a content part inside a chat message.

Audio output

Request text and audio together when the model supports audio output.
The same request shape is available through all four SDKs by setting chat-completions fields for modalities and audio.

Translate audio to English

POST /v1/audio/translations accepts audio in any language and returns the speech translated to English. It returns the same TranscriptionResponse (with a .text field) as transcription.
This is a distinct endpoint from the transcribe-and-translate helper at POST /v1/audio/transcriptions/translate. Check GET /v1/models for models that support translation — model is required.
Optional parameters: prompt (context hint for the model), response_format (json, text, or verbose_json), and temperature (0–2).

SDK coverage

  • Node: client.chat.completions.create(...)
  • Python: client.chat.completions.create(...)
  • Go: client.Chat.Completions.Create(...)
  • Java: client.chat().completions().create(...)

Notes

  • Audio payloads are base64 encoded in the request body.
  • Check GET /v1/models to find models that accept or produce audio.
  • Keep payload sizes reasonable, especially for browser-based clients.