Actions17
Overview
This node enables sending WhatsApp messages through the Z-API service, specifically supporting a variety of message types including text, images, documents, audio, video, locations, contacts, buttons, carousels, and more. The "Send Image With Buttons" operation allows users to send an image accompanied by interactive buttons, which recipients can click to trigger predefined actions or responses.
Common scenarios for this node include:
- Marketing campaigns where you want to showcase a product image with quick-reply buttons.
- Customer support interactions that provide options directly on an image message.
- Interactive notifications or surveys sent via WhatsApp with visual context and actionable buttons.
Example: Sending a promotional image of a washing machine with buttons labeled "Buy Now", "More Info", and "Contact Support" to engage customers interactively.
Properties
| Name | Meaning |
|---|---|
| Instance | Your Z-API instance ID used to identify your WhatsApp API instance. |
| Token | Your Z-API token for authenticating API requests. |
| Client Token | Your Z-API client token for additional authentication header required by the API. |
| Phone | The recipient's phone number or group ID to which the message will be sent. |
| Message | The text message content sent alongside the image and buttons. |
| Image URL | The URL of the image to be sent with the buttons. |
| Buttons | A collection of interactive buttons attached to the image message. Each button has: |
| - Button ID: Unique identifier for the button. | |
| - Button Label: Text displayed on the button. |
Output
The node outputs a JSON array containing the response from the Z-API service for each input item processed. The JSON typically includes details about the success or failure of the message sending request.
No binary data output is produced by this operation.
Dependencies
- Requires access to the Z-API WhatsApp service.
- Needs three credentials configured in the node parameters: instance ID, token, and client token.
- The node makes HTTP POST requests to the Z-API endpoints using these credentials.
- No additional environment variables or n8n credential types are explicitly required beyond what the user provides in the node properties.
Troubleshooting
- Invalid Credentials: If the instance ID, token, or client token are incorrect or expired, the API will reject requests. Verify and update credentials accordingly.
- Invalid Phone Number: Ensure the phone number or group ID is correctly formatted and registered with WhatsApp.
- Button Configuration Errors: Each button must have a unique ID and label; missing or duplicate IDs may cause errors.
- Network Issues: Connectivity problems can cause request failures; check network access to
api.z-api.io. - API Limits: Exceeding rate limits or quotas on the Z-API service may result in errors; consult Z-API documentation for limits.
- Error Messages: The node throws errors if unsupported operations or resources are selected. Confirm that "send-image-buttons" is chosen under the "messages" resource.
Links and References
- Z-API Official Documentation (for API usage and authentication)
- WhatsApp Business API Overview
- n8n Documentation (for general node usage and error handling)