Skip to main content
POST
https://api.naga.ac
/
v1
/
audio
/
transcriptions
Transcriptions (STT)
curl --request POST \
  --url https://api.naga.ac/v1/audio/transcriptions \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "model": "<string>",
  "prompt": "<string>",
  "language": "<string>"
}
'
{
  "text": "<string>"
}

Request Parameters

model
string
required
Transcription model ID (e.g., gpt-4o-transcribe).
file
file
required
The audio file to transcribe.
prompt
string
Optional prompt to guide the transcription.
language
string
Language hint (BCP-47/ISO code if applicable).

Example Request

from openai import OpenAI

client = OpenAI(base_url="https://api.naga.ac/v1", api_key="YOUR_API_KEY")

with open("audio.mp3", "rb") as f:
    transcription = client.audio.transcriptions.create(
        model="gpt-4o-transcribe",
        file=f,
        prompt=None,
        language=None,
    )
print(transcription.text)

Response

Returns a JSON object with the transcription result, e.g.:
{ "text": "Hello and welcome to NagaAI!" }

Response Fields

text
string
The transcribed text from the audio file