Actions50
- Message Actions
- Contact Actions
- Account Actions
- Call Actions
- Chat Actions
- Group Actions
- Instance Actions
- Media Actions
- Session Actions
- User Actions
Overview
This node integrates with the WSAPI WhatsApp API to send various types of WhatsApp messages. Specifically, the Send Audio operation under the Message resource allows users to send audio files to individual contacts or groups on WhatsApp by providing a publicly accessible media URL.
Common scenarios where this node is beneficial include:
- Sending voice notes or audio announcements automatically from workflows.
- Broadcasting audio messages to groups or multiple contacts.
- Automating customer support or marketing communications with audio content.
For example, a user can automate sending an MP3 audio file to a customer after a purchase confirmation or share a recorded message in a group chat.
Properties
| Name | Meaning |
|---|---|
| To | The WhatsApp contact ID or group ID to which the audio will be sent. For contacts, use the phone number with country code (no plus sign) followed by @s.whatsapp.net (e.g., 1234567890@s.whatsapp.net). For groups, use the group ID followed by @g.us. This is required. |
| Media URL | The direct HTTP or HTTPS URL of the audio file to send. Must be publicly accessible. Supported audio formats typically include MP3. |
| Mentions | (Advanced Option) Comma-separated list of phone numbers (without @) to mention in the message. |
| Reply To Message ID | (Advanced Option) The ID of an existing message to which this audio message should reply. |
| Is Forwarded | (Advanced Option) Boolean flag indicating whether the message should be marked as forwarded. |
| View Once | (Advanced Option) Boolean flag indicating if the media should disappear after being viewed once. Note: This option applies only to image and video messages, so it is not relevant for audio messages. |
Output
The node outputs JSON data representing the result of the send audio operation. This typically includes metadata about the sent message such as message ID, status, timestamps, and recipient information.
If the operation involves binary data (e.g., media download), the node would output binary data accordingly, but for sending audio via URL, the output is primarily JSON confirming the message was sent.
Dependencies
- Requires an active connection to the WSAPI WhatsApp API service.
- Requires an API key credential configured in n8n to authenticate requests.
- The media URL must be publicly accessible over HTTP or HTTPS; private or protected URLs will not work.
- Proper permissions and valid WhatsApp contact or group IDs are necessary.
Troubleshooting
- Invalid "To" format: Ensure the phone number includes the country code without a plus sign and uses the correct suffix (
@s.whatsapp.netfor contacts,@g.usfor groups). - Media URL inaccessible: Verify that the media URL is publicly accessible and points directly to the audio file. Unsupported formats or broken links will cause failures.
- Authentication errors: Confirm that the API key credential is correctly set up and has sufficient permissions.
- Operation not implemented error: If the node throws an error about the operation not being implemented, verify that the selected resource and operation match the node's capabilities.
- Forwarding or reply options ignored: Some advanced options may not apply to audio messages; check documentation or test behavior accordingly.
Links and References
- WSAPI WhatsApp API Documentation (general reference for API endpoints and message types)
- WhatsApp Business API Media Messages (for supported media formats and usage)
- n8n Documentation - Creating Custom Nodes