Skip to Content
Public APISend Audio Message

Send Audio Message

Send an audio file to a customer. Like every free-form message, this works only within the 24-hour customer service window. The audio file must be reachable at a public HTTPS URL — Splashify fetches it and forwards to WhatsApp.

Endpoint

POST https://apis.splashifypro.com/api/v1/public/message

Headers

HeaderValue
AuthorizationBasic YOUR_API_KEY
Content-Typeapplication/json

Request body

{ "phoneNumber": "919876543210", "callbackData": "some_callback_data", "type": "Audio", "data": { "message": "This is a test", "mediaUrl": "https://your-cdn.example.com/voice/123.mp3", "fileName": "Test" } }
FieldRequiredNotes
phoneNumberyesRecipient phone (use fullPhoneNumber if you want to inline country code)
typeyesMust be "Audio"
data.messageoptionalCaption shown alongside the audio
data.mediaUrlyesPublic HTTPS URL of the audio file. Allowed: audio/aac, audio/mp4, audio/mpeg, audio/amr, audio/ogg. Max 16 MB
data.fileNameoptionalDisplay name in WhatsApp

Example

curl -X POST https://apis.splashifypro.com/api/v1/public/message \ -H "Authorization: Basic YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "phoneNumber": "919876543210", "callbackData": "some_callback_data", "type": "Audio", "data": { "message": "This is a test", "mediaUrl": "MEDIA_URL", "fileName": "Test" } }'

Successful response — 201 Created

{ "result": true, "message": "Message queued for sending via Splashify Pro. Check webhook for delivery status", "id": "d58aeff7-a81c-47a7-9b67-f381e13f6c4e" }

Common errors

  • Customer has not messaged within last 24 hours — outside the customer service window. Use a template instead.
  • Could not download media — the mediaUrl returned non-200, redirected too many times, or doesn’t serve a supported audio mime. Confirm the URL works in curl -I first.
  • Unsupported media type — convert to MP3 or OGG/Opus and retry.