Transcribe audio and analyze spoken content through Muapi’s unified Speech-to-Text API. This repository compares OpenAI Whisper transcription with Gemini Audio Vision analysis and provides direct HTTP examples for asynchronous jobs, subtitles, language hints, and structured audio questions.
Open the Speech-to-Text API landing page · Get an API key · API reference
- Text-to-Speech API examples — companion speech-generation workflows.
- Voice Cloning API examples — voice identity and consent-aware workflows.
- AI Voice Agent — downstream voice-agent use cases.
- Muapi Python — general Python API integration.
- Muapi CLI — command-line access to Muapi models.
- When to choose Whisper transcription versus Gemini Audio Vision analysis.
- Audio URL requirements, language hints, response formats, and prompt design.
curland Python examples for transcription and audio-question workflows.- Polling, subtitle output handling, long-audio segmentation, and privacy considerations.
| Endpoint | Best for | Important inputs | Output focus |
|---|---|---|---|
openai-whisper |
Reliable speech transcription | audio_url, optional language, prompt, response_format |
Text, JSON, SRT, or VTT depending on the selected format |
gemini-audio-vision |
Audio understanding beyond a transcript | audio_url, prompt, optional system_prompt, model |
Answers, summaries, extraction, and audio analysis |
Use Whisper when you need a transcript or subtitle file. Use Gemini Audio Vision when the job is “listen and answer,” such as identifying speakers, summarizing a meeting, or extracting an event from speech. Check the live page for current model availability and pricing.
export MUAPI_API_KEY="your_key"
export AUDIO_URL="https://example.com/interview.mp3"
curl -X POST "https://api.muapi.ai/api/v1/openai-whisper" \
-H "x-api-key: $MUAPI_API_KEY" \
-H "Content-Type: application/json" \
-d "{\"audio_url\":\"$AUDIO_URL\",\"language\":\"en\",\"response_format\":\"json\"}"For audio understanding, ask a specific question:
curl -X POST "https://api.muapi.ai/api/v1/gemini-audio-vision" \
-H "x-api-key: $MUAPI_API_KEY" \
-H "Content-Type: application/json" \
-d "{\"audio_url\":\"$AUDIO_URL\",\"prompt\":\"Summarize the decisions and list each action item with its owner.\"}"Both requests return a job identifier. Poll the result endpoint:
export REQUEST_ID="id_from_the_submission_response"
curl "https://api.muapi.ai/api/v1/predictions/$REQUEST_ID/result" \
-H "x-api-key: $MUAPI_API_KEY"See examples/quickstart.py for the complete Python flow.
- Pass a language hint when it is known; it can improve accuracy and reduce ambiguity.
- Use a prompt for names, technical terms, or expected vocabulary, not as a substitute for clean audio.
- Select SRT/VTT when the next step is captions; select JSON when you need timestamps and metadata.
- For long recordings, preserve segment order and speaker metadata in your own database.
- Treat recordings and transcripts as potentially sensitive personal data; obtain permission and apply retention controls.
| Problem | Check |
|---|---|
| Audio cannot be fetched | Public URL, supported media type, redirect behavior, and file availability. |
| Names are misspelled | Add names/terms to prompt and improve source audio quality. |
| Transcript is not a subtitle file | Set the model’s documented response_format to SRT or VTT. |
| Analysis is too vague | Ask one concrete question and request a structured answer. |
Documentation and examples are MIT licensed. Audio, transcripts, and model-provider usage remain subject to applicable Muapi terms and user consent obligations.