Wuzapi AI icon

Wuzapi AI

Send WhatsApp messages using Wuzapi - optimized for AI workflows

Overview

This node allows sending WhatsApp messages with various media types using the Wuzapi service, optimized for AI workflows. It supports sending text, images, documents, audio, video, locations, contacts, stickers, buttons, lists, and polls to specified phone numbers.

The "Send Document" operation specifically enables sending document files to a WhatsApp contact. Documents can be provided as binary data from a previous node, base64-encoded strings, or URLs pointing to the document file. Users can also specify the filename and add an optional caption.

Common scenarios:

  • Sending invoices, contracts, or reports as PDF documents to clients.
  • Sharing manuals or guides in document format.
  • Automating document delivery in customer support or sales workflows.

Properties

Name Meaning
Phone Number The recipient's phone number in international format without the "+" sign (e.g., 5491155553934).
Document Source How the document is provided:
• Binary Data (from previous node)
• Base64 encoded string
• URL to the document file
Binary Property Name of the binary property containing the document when using Binary Data source (default: "data").
Base64 Document Base64 encoded document string including data URL prefix (required if Document Source is Base64).
Document URL URL to the document file (required if Document Source is URL).
File Name Name of the document file (e.g., "document.pdf") (required).
Caption Optional caption text to accompany the document message.
Additional Options Collection of extra options:
• Message ID: Custom message identifier (auto-generated if empty).
• Mentions: Mention specific users or all group members (groups only).

Output

The node outputs JSON data representing the response from the Wuzapi API after sending the document message. This typically includes metadata about the sent message such as message ID and status.

If an error occurs and "Continue On Fail" is enabled, the output will contain an error message JSON object describing the failure.

The node does not output binary data directly; it sends binary content as part of the request payload.

Dependencies

  • Requires an active Wuzapi API credential configured in n8n for authentication.
  • Relies on the Wuzapi API endpoints to send WhatsApp messages.
  • Uses internal helper functions to prepare media data and make authenticated API requests.

Troubleshooting

  • Binary Property Not Found: If the selected binary property does not exist in the input data, the node throws an error like Binary property "xyz" not found. Ensure the binary data exists and the property name matches exactly.
  • Invalid Phone Number Format: Phone numbers must be in international format without the "+" prefix. Incorrect formatting may cause message delivery failures.
  • Missing Required Fields: For example, if Document Source is "base64" but no base64 string is provided, or if the file name is missing, the node will throw errors.
  • API Errors: Network issues or invalid credentials will result in API request failures. Verify API key validity and network connectivity.
  • Mentions Misconfiguration: When using mentions, ensure user JIDs are correctly formatted and comma-separated.

To resolve most issues, verify input parameters carefully and check the Wuzapi API documentation for any service-specific constraints.

Links and References

Discussion