Actions55
- Session Actions
- Message Actions
- Chat Actions
- Contact Actions
- Group Actions
- Webhook Actions
- Status Actions
Overview
This node integrates with the WAHA API to manage WhatsApp groups and perform various group-related operations. Specifically, the "Demote Participants" operation allows you to demote one or more participants from admin status within a WhatsApp group.
Common scenarios for this node include:
- Managing group roles dynamically in WhatsApp groups.
- Automating administrative tasks such as promoting or demoting participants based on external triggers.
- Maintaining control over group administration in large or active WhatsApp groups.
For example, if a participant no longer needs admin privileges, this node can be used to demote them automatically without manual intervention in WhatsApp.
Properties
| Name | Meaning |
|---|---|
| Session Name | The name of the WhatsApp session to use (defaults to a configured default session). |
| Chat ID | The WhatsApp group chat ID where participants will be demoted (e.g., groupid@g.us). |
| Participants | Comma-separated list of participant chat IDs to demote from admin in the group. |
| Additional Fields | Optional extra parameters (not specifically used in this operation but available). |
Output
The node outputs a JSON object containing the response from the WAHA API after attempting to demote the specified participants. This typically includes success confirmation or error details related to the demotion request.
No binary data output is involved in this operation.
Example output structure:
{
"success": true,
"message": "Participants demoted successfully",
"details": {
"demotedParticipants": [
"participant1@c.us",
"participant2@c.us"
]
}
}
Dependencies
- Requires an active WAHA API credential with a valid base URL and API key.
- Optionally uses an additional API key credential for N8N Tools API validation.
- The WhatsApp session must be active and connected for the operation to succeed.
- Proper configuration of the WhatsApp session name is necessary.
Troubleshooting
- Invalid Session: If the session name is incorrect or the session is not active, the API call will fail. Ensure the session is started and the correct session name is provided.
- Invalid Chat ID: The group chat ID must be valid and correspond to an existing WhatsApp group. Use the correct format ending with
@g.us. - Participants Format: Participants must be provided as comma-separated WhatsApp IDs. Incorrect formatting may cause errors.
- API Key Issues: Errors related to authentication usually indicate invalid or missing API keys. Verify credentials are correctly set up.
- Permission Errors: Demoting participants requires that the session user has admin rights in the group. Lack of permissions will result in failure.
- Error Messages: Common error messages include "Unknown group operation" if the operation name is mistyped, or HTTP errors indicating network or authorization problems.
Links and References
- WAHA API Documentation (replace with actual URL)
- WhatsApp Group Management Best Practices
- n8n Community Forum for WAHA API integration discussions