Actions83
- Instances Actions
- Client Actions
- Message Actions
- Chat Actions
- Contact Actions
- Number Actions
- Group Actions
- Channel Actions
- Label Actions
- Story Actions
Overview
This node operation allows you to create a poll message in a chat using the WaAPI service. It is useful for gathering opinions, votes, or feedback from participants within a chat group or individual chat. For example, you can ask "What's your favorite color?" and provide multiple options for users to select from. The poll can be configured to allow single or multiple answers.
Common scenarios include:
- Conducting quick surveys in group chats.
- Collecting preferences or decisions from team members.
- Engaging community members with interactive questions.
Properties
| Name | Meaning |
|---|---|
| Id | Instance ID of the poll message to create (number). |
| Chat Id | Identifier of the chat where the poll will be sent. Format: <countrycode><usernumber>@c.us for individuals or @g.us for groups. |
| Caption | The question or caption text displayed as the poll prompt. |
| Options | JSON array of poll options. Must contain between 2 and 12 string values representing choices. |
| Multiple Answers | Boolean flag indicating if participants can select more than one option (true) or only one (false). |
Output
The node outputs JSON data representing the result of the poll creation request. This typically includes confirmation details such as poll ID, status, or any metadata returned by the API. There is no binary output associated with this operation.
Dependencies
- Requires an active connection to the WaAPI service via an API key credential.
- The node uses HTTP requests to interact with the WaAPI endpoint at
https://waapi.app/api/v1. - Proper configuration of the API authentication token in n8n credentials is necessary.
Troubleshooting
- Invalid Chat Id: Ensure the chat ID follows the correct format (
<countrycode><usernumber>@c.usfor individuals or@g.usfor groups). Incorrect formats will cause errors. - Options Array Issues: The poll options must be a valid JSON array containing between 2 and 12 items. Providing fewer or more options, or invalid JSON, will result in failure.
- API Authentication Errors: Missing or incorrect API credentials will prevent the poll from being created. Verify that the API key is correctly set up in n8n.
- Network or Service Unavailability: If the WaAPI service is down or unreachable, the node will fail to send the poll. Check network connectivity and service status.
Links and References
- WaAPI Official Documentation (for detailed API usage and capabilities)
- n8n Documentation on Creating Polls (general guidance on custom node operations)