WSAPI icon

WSAPI

Interact with WSAPI WhatsApp API

Overview

This node enables sending text messages via the WSAPI WhatsApp API. It is designed to send plain text messages to individual WhatsApp contacts or groups by specifying their unique WhatsApp IDs. This functionality is useful for automating communication workflows such as customer support notifications, marketing messages, alerts, or any scenario where programmatic WhatsApp messaging is needed.

Practical examples:

  • Sending a welcome message to new customers automatically.
  • Broadcasting updates or announcements to a group.
  • Replying to user inquiries with predefined text responses.
  • Mentioning specific users in group messages to draw attention.

Properties

Name Meaning
To The WhatsApp contact ID or group ID to which the message will be sent. For contacts, this is the phone number followed by @s.whatsapp.net (e.g., 1234567890@s.whatsapp.net). For groups, it is the group ID followed by @g.us (e.g., 120363123456789@g.us). Must include country code without +.
Message The text content of the message to send. Supports emojis and formatting.
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 message should be a reply.
Is Forwarded (Advanced Option) Boolean flag indicating whether the message should be marked as forwarded.

Output

The node outputs JSON data representing the result of the send operation. This typically includes details about the sent message such as its ID, status, timestamps, and any metadata returned by the WSAPI WhatsApp API.

No binary data output is produced by this operation.

Dependencies

  • Requires an API key credential for authenticating with the WSAPI WhatsApp API.
  • The node expects the base URL of the WSAPI service to be configured in the credentials.
  • Network connectivity to the WSAPI endpoint is necessary.

Troubleshooting

  • Invalid "To" format: Ensure the recipient ID includes the full phone number with country code and the correct suffix (@s.whatsapp.net for contacts, @g.us for groups). Missing or incorrect formatting will cause errors.
  • Authentication errors: Verify that the API key credential is correctly set up and has sufficient permissions.
  • Message content issues: Empty or excessively long messages may be rejected by the API.
  • Reply to invalid message ID: If using the "Reply To Message ID" option, ensure the referenced message ID exists and is accessible.
  • Network or API downtime: Check network connectivity and WSAPI service status if requests fail unexpectedly.

Links and References

Discussion