Send a voice message
Make an outbound call and then play your media
This method lets you deliver a voice message to a PSTN number, and deliver voice message to multiple PSTN numbers.
Arguments
to The destination to be called. The destination should be a regular number. A regular number should be specified with the country code followed by the number.
Example 2348020000000
You can deliver voice message to multiple numbers at once by adding all the numbers in a square bracket. For example, if you want to deliver to two numbers, specify them in the to field:
["2348020000000", "2348030000000"]
Note: The maximum number of unique destinations accepted in the "to" field is 1000.
media_url The location of the media/audio file. This specifies where the media file is located.
Example https://www.learningcontainer.com/wp-content/uploads/2020/02/Kalimba.mp3
The media file will be fetched and then converted to the most suitable format for the best audio quality over the GSM network.
Example POST request
Specifying from is not necessary as your registered caller id will be fetched and used. If there are multiple caller ids, then only one will be randomly selected.
Callbacks
For every attempt to deliver a voice message, 9bits sends a status update to your URL configured as a callback.
Last updated