WAHA API icon

WAHA API

Complete WhatsApp automation with WAHA API - Multi-engine support

Overview

This node integrates with the WAHA API to automate WhatsApp messaging and session management. Specifically, the "Edit Message" operation under the "Message" resource allows users to modify the content of an existing WhatsApp message in a specified chat.

Common scenarios for this node include:

  • Correcting typos or updating information in a previously sent message.
  • Dynamically changing message content based on workflow logic.
  • Enhancing customer support automation by editing messages after sending.

For example, a user might send a confirmation message to a client and later update it with additional details without sending a new message.

Properties

Name Meaning
Session Name The name of the WhatsApp session to use (defaults to the credential's default session).
Chat ID The WhatsApp chat identifier where the message was sent (e.g., phone number with @c.us or group ID).
Text The new text content to replace the original message text.
Message ID The unique identifier of the message to be edited.
Additional Fields Optional extra parameters; for this operation, no specific additional fields are used.

Output

The node outputs a JSON object representing the response from the WAHA API after attempting to edit the message. This typically includes status information about the edit operation and any updated message data returned by the API.

No binary data output is involved in this operation.

Dependencies

  • Requires a valid WAHA API key credential configured in n8n.
  • Requires access to the WAHA API base URL.
  • Optionally uses an additional API key credential for subscription validation via the N8N Tools API.
  • Proper WhatsApp session must be active and identified by the session name.

Troubleshooting

  • Invalid Credentials: If the API key or session name is incorrect, the node will fail. Verify credentials and session existence.
  • Unknown Message ID: Editing a message requires a valid message ID. Ensure the message ID corresponds to a message in the specified chat.
  • API Validation Errors: The node validates subscription via an external API; errors like 401 or 403 indicate invalid subscription or API key.
  • Unknown Operation or Resource: Using unsupported operations or resources will throw errors. Confirm that "editMessage" is selected under the "Message" resource.
  • Network Issues: Connectivity problems with the WAHA API endpoint can cause request failures.

Links and References

Discussion