Start Audio Stream Transcription
Start real-time audio stream transcription with ElevenLabs or AssemblyAI, controlled by a provider parameter.
https://mavi-backend.memories.ai/serve/api/v2
Auth: Authorization: sk-mavi-... (no Bearer prefix)- Use this HTTP endpoint when you have a stream URL (RTMP/RTSP/HLS) and want the server to handle audio decoding and streaming.
- Use the WebSocket endpoint when your client can send audio directly (e.g., browser microphone).
duration: Audio duration in secondsrate: 0.39 (ElevenLabs)- Charges: pre-check at start, then billed every 5 seconds of audio streamed
Supported Protocols
- RTMP (Recommended)
- RTSP
- HLS (.m3u8)
- HTTP/HTTPS (direct audio URLs)
Key Features
- Real-time transcription via ElevenLabs or AssemblyAI (controlled by
providerparameter) - Server-side audio decoding (FFmpeg) — no client-side processing needed
- Verbatim callback: every upstream message forwarded as-is to your webhook
- Real-time billing every 5 seconds of audio
- Auto-stop on insufficient balance (status 402)
- All provider-specific parameters transparently forwarded
Architecture
Code Example
Response
Returns the task information for the started audio stream.Request Parameters
Required
Common Parameters
ElevenLabs Parameters
These parameters are forwarded whenprovider=elevenlabs.
AssemblyAI Parameters
These parameters are forwarded whenprovider=assemblyai.
Response Parameters
Callback Response Parameters
Callbacks are sent continuously — one for each message received from the upstream provider.Status Codes
Important Notes
provideris required: You must specifyelevenlabsorassemblyai. Without it the request will fail.- Webhook required: Configure your webhook URL in user settings before using this API.
- Verbatim callbacks: Each callback contains the exact JSON message from the provider — the server does not transform or aggregate the data.
- Real-time billing: Billing occurs every 5 seconds of audio data streamed to the provider. Auto-stops when balance is insufficient.
- Pre-charge: Balance is checked at start (one 5-second unit). If insufficient, the task is not started (status 402).
- Parameter transparency: Parameters specific to a provider are forwarded as-is. Parameters not relevant to the selected provider are silently ignored by the provider.
Supported Languages
Common language codes (supported by both providers):en- Englishzh- Chinesees- Spanishfr- Frenchde- Germanja- Japaneseko- Korean- And many more…
Rate Limiting
- Maximum concurrent streams: Each user can run N concurrent stream tasks (video + audio combined)
- Capacity check: Returns status 16 if server capacity is reached
- Balance check: Returns status 402 if insufficient balance at start
Authorizations
Body
Audio stream URL (RTMP or RTSP protocol)
"rtmp://example.com/live/audio"
Language code for transcription
"en"
Add punctuation to the transcript
Format text in the transcript
Enable automatic language detection
Confidence threshold for language detection
Start transcription from this timestamp (milliseconds)
End transcription at this timestamp (milliseconds)
Enable multi-channel audio processing
Array of speech models to use
Speech detection threshold (0.0-1.0)
Include disfluencies in the transcript
Enable speaker diarization
Expected number of speakers
Enable sentiment analysis
Enable entity detection
Enable automatic highlights extraction
Enable content safety detection
Enable IAB category classification
Enable automatic chapter generation
Enable automatic summarization
Model to use for summarization
Type of summary to generate
Enable custom topic detection
Array of custom topics to detect
Redact personally identifiable information
PII redaction substitution method
Array of PII policies to apply
Redact PII from audio
Quality setting for PII audio redaction
Filter profanity from transcript
Array of custom spelling corrections
Speech understanding configuration
