Send voice note
Sent as a voice note (the audio with the microphone icon), not as an audio file. No caption: WhatsApp does not support captions on voice notes.
X-Api-Key: wpf_YOUR_KEYThe connection's API key (wpf_...), generated in the dashboard.
Authorization: Bearer wpf_YOUR_KEYThe same key in Authorization: Bearer wpf_... (what n8n, Make and HTTP libraries support out of the box).
Idempotency-Key?stringOptional. Repeating the same value within 24 h, with the same API key, returns the first response without sending again. See Idempotency in the introduction.
application/json- body
to?stringRecipient: phone number with country code and area code, digits only (5581999999999; +, spaces and dashes are ignored), or the chatId (5581999999999@c.us, ...@lid, or a group ...@g.us). Brazilian phone numbers are checked on WhatsApp before sending.
url*stringPublic http(s) address of the file. The Wappfy server downloads it (up to 50 MB, 30 s, up to 3 redirects); internal addresses are rejected. Provide url or base64, never both.
length <= 2048base64?stringThe file in base64, raw or as a data URL (data:image/png;base64,...). Counts toward the request body limit; for large files, prefer url.
1 <= lengthmimetype?stringAudio type. WhatsApp plays voice notes in OGG/OPUS (audio/ogg; codecs=opus); other audio is only accepted when the server converts it. With no type at all, the file is treated as a voice note.
length <= 255filename?stringFile name as the contact will see it (matters mostly in /messages/file).
length <= 255reply_to?stringOptional: the message_id of a message to reply to, quoting it.
replyTo?stringVeraltetOld name for reply_to, still accepted. Use reply_to.
Sent. Keep the message_id: it is what appears in the message.sent and message.status events.
application/json- response
data*curl -X POST 'https://app.wappfy.io/api/v1/messages/voice' \ -H 'X-Api-Key: wpf_YOUR_KEY' \ -H 'Content-Type: application/json' \ -d '{ "to": "5581999999999", "url": "https://exemplo.com/recado.ogg", "mimetype": "audio/ogg; codecs=opus"}'{ "data": { "message_id": "string", "chat_id": "string" }}
