Actions9
Overview
This node manages Zalo groups, specifically allowing users to perform various group-related operations via the Zalo API. The "Add User To Group" operation lets you add one or multiple members to an existing Zalo group by specifying the group's ID and a list of user IDs.
Common scenarios include:
- Automating group membership management in Zalo for community or team chats.
- Adding new members to a group after onboarding or registration processes.
- Integrating Zalo group management into broader workflows that involve communication or collaboration.
Example: Automatically add newly registered users to a specific Zalo group by passing their user IDs and the target group ID.
Properties
| Name | Meaning |
|---|---|
| ID Nhóm (groupId) | The unique identifier of the Zalo group where members will be added. |
| Danh Sách ID Thành Viên (userIds) | A comma-separated list of user IDs to add to the group. Multiple users can be added at once. |
Output
The output JSON contains the response from the Zalo API after attempting to add the specified users to the group. It typically includes details about the success or failure of the operation and any relevant metadata returned by the API.
Example output structure:
{
"json": {
// API response data confirming added users or error details
},
"pairedItem": {
"item": 0
}
}
No binary data is output by this operation.
Dependencies
- Requires valid Zalo API credentials including an API key credential with cookie, IMEI, and user agent information.
- The node depends on the external
zca-jslibrary to interact with the Zalo API. - Proper configuration of the Zalo API credential in n8n is necessary to authenticate requests.
Troubleshooting
- Invalid Credentials: If the node throws "No API instance found," verify that the Zalo API credentials are correctly configured and valid.
- Incorrect Group ID or User IDs: Ensure the group ID exists and user IDs are correct and active in Zalo; otherwise, the API may return errors or fail silently.
- Malformed User ID List: The user IDs must be comma-separated without extra spaces or invalid characters.
- API Rate Limits or Permissions: The Zalo API might restrict adding users based on permissions or rate limits; check API documentation and ensure your account has sufficient rights.
Links and References
- Zalo Official API Documentation
- n8n Documentation on Creating Custom Nodes
- zca-js GitHub Repository (for the underlying Zalo API client library)