Skip to main content
POST
/
tts
/
stt
Speech-to-Text
curl --request POST \
  --url https://api.example.com/tts/stt \
  --header 'Content-Type: application/json' \
  --data '
{
  "api_key": "<string>"
}
'
{
  "text": "<string>",
  "language": "<string>"
}
Transcribe audio files to text using OpenAI’s Whisper API. Supports multiple audio formats and automatically detects language.

Request

audio
file
required
Audio file to transcribe (MP3, WAV, FLAC, etc.)
api_key
string
required
Your GistMag API key

Response

text
string
The transcribed text from the audio file
language
string
The detected or specified language code (e.g., “en”, “es”, “fr”) or “auto” if auto-detected

Credit Cost

5 credits per minute of audio (rounded up to the nearest minute). For example:
  • 30 seconds of audio = 5 credits (1 minute)
  • 2.5 minutes of audio = 15 credits (3 minutes)

Example Request

curl -X POST https://api.gistmag.co.uk/tts/stt \
  -F "audio=@recording.wav" \
  -F "api_key=your_api_key_here"

Supported Audio Formats

OpenAI Whisper supports a wide range of audio formats:
  • MP3
  • WAV
  • M4A
  • FLAC
  • OGG
  • WebM
  • And many other common audio formats

Notes

  • The API automatically detects the language in the audio (or you can specify it)
  • Audio is processed securely and not stored
  • Maximum file size: 25MB (OpenAI Whisper limit)
  • Uses OpenAI’s Whisper-1 model for high-quality transcription