Request Body
Audio file to transcribe. Supported formats: flac, mp3, mp4, mpeg, mpga, m4a, ogg, wav, webm.
Language of the audio in ISO-639-1 format (e.g., en, zh, ja).
Optional text to guide the model’s style or continue a previous segment.
Output format: json, text, srt, verbose_json, vtt.
Sampling temperature (0 to 1).
Timestamp granularity: word and/or segment. Requires verbose_json.
Response
For verbose_json:
Audio duration in seconds.
Transcription segments with timestamps.
Word-level timestamps (if requested).
curl -X POST "https://api.lemondata.cc/v1/audio/transcriptions" \
-H "Authorization: Bearer sk-your-api-key" \
-F file="@audio.mp3" \
-F model="whisper-1" \
-F language="en"
{
"text": "Hello, this is a test of the transcription API."
}
Translation
To translate audio to English, use the translations endpoint:
response = client.audio.translations.create(
model="whisper-1",
file=audio_file
)