Play Audio on Calls
Play audio files to users during active calls for notifications, music, and announcements.
The Play Audio endpoint allows you to play audio files to participants in an ongoing call. This is commonly used for playing hold music, automated notifications, IVR prompts, or announcements while maintaining the call connection.
Supported Formats: Vobiz supports .mp3 and .wav audio files. Audio files must be accessible via HTTP/HTTPS URLs.
Key Features
Multiple Audio Files
Play multiple audio files in sequence by providing comma-separated URLs.
Call Leg Selection
Choose which participants hear the audio: caller (A leg), callee (B leg), or both.
Loop Playback
Play audio indefinitely for hold music or continuous announcements.
Audio Mixing
Mix playback with call audio or mute call participants during playback.
Duration Control
Limit playback duration to control costs and user experience.
Stop Anytime
Stop audio playback programmatically when needed.
Available Operations
Common Use Cases
- •
Hold Music
Play music while customers wait on hold or during call transfers.
- •
IVR Prompts
Play menu options, instructions, or navigation prompts in interactive voice systems.
- •
Announcements
Deliver pre-recorded announcements, promotions, or important information.
- •
Queue Notifications
Inform callers of their position in queue or estimated wait time.
- •
Call Recording Disclaimer
Play legal disclaimers about call recording or monitoring.
Best Practices
Use MP3 for Efficiency
MP3 files stream faster and use less bandwidth than WAV files. Convert your audio to MP3 for better performance.
Host on CDN
Host your audio files on a CDN or reliable hosting service with HTTPS support for fast, secure delivery.
Optimize Audio Length
Keep audio files concise. Use the length parameter to limit playback duration and prevent lengthy hold times.
Mix Audio Thoughtfully
Set mix=false when playing important announcements to ensure participants hear them clearly without conversation interference.
Test Audio Quality
Always test your audio files on actual calls to ensure proper volume, clarity, and compatibility across different devices.