Actions21
- Message Actions
- Group Actions
- Chat Actions
- Contact Actions
Overview
This node enables sending WhatsApp location messages via the Green API service. It is designed to send a geographic location with optional descriptive details such as a name and address to a specified chat on WhatsApp. This functionality is useful in scenarios where you want to share a precise location with contacts or groups, for example:
- Sharing a restaurant or meeting point location during event planning.
- Sending a delivery or pickup location to customers.
- Providing directions or points of interest in customer support conversations.
The node operates in "Action" mode (not as a webhook trigger) and requires specifying the target chat and location coordinates.
Properties
| Name | Meaning |
|---|---|
| Mode | Select between "Action" (execute WhatsApp actions) or "Listen for Incoming Webhook" (trigger). |
| Chat ID | The identifier of the chat to send the location to. For private chats use phone@c.us, for groups use chatId@g.us. |
| Location Name | Optional name of the location (e.g., "Restaurant"). |
| Address | Optional address description of the location (e.g., "123456, Perm"). |
| Latitude | Required latitude coordinate of the location (decimal number). |
| Longitude | Required longitude coordinate of the location (decimal number). |
| Quoted Message ID | Optional ID of a message to quote when sending the location message. |
Output
The node outputs a JSON array containing the response from the Green API after attempting to send the location message. The structure typically includes confirmation details or error information returned by the API.
Example output JSON structure (simplified):
{
"idMessage": "string",
"sent": true,
"chatId": "string",
...
}
No binary data output is produced by this operation.
Dependencies
- Requires an active Green API account with valid credentials: an instance ID and an API token.
- The node uses these credentials to authenticate requests to the Green API endpoints.
- Network access to
https://api.green-api.comis required. - No additional environment variables are needed beyond the configured credentials.
Troubleshooting
Error: "This node is configured as a trigger. Please use it as a trigger node, not an action node."
Occurs if the node is set to "Listen for Incoming Webhook" mode but used as an action. To fix, switch the mode to "Action" when sending messages.Failed to send location: [error message]
Indicates an issue communicating with the Green API or invalid parameters. Check that:- The chat ID is correctly formatted.
- Latitude and longitude are valid decimal numbers.
- Credentials (instance ID and API token) are correct and active.
- The network connection allows outbound HTTPS requests.
Invalid or missing required parameters
Ensure all required fields (Chat ID, Latitude, Longitude) are provided and properly formatted.API rate limits or quota exceeded
If the API returns rate limit errors, consider reducing request frequency or upgrading your Green API plan.
Links and References
- Green API Documentation – Official API docs for message sending and other operations.
- WhatsApp Location Message Format – General WhatsApp location message format reference.
- n8n Documentation – For general guidance on using n8n nodes and workflows.