Overview
This node, named "Zalo Tag," is designed to manage tags (labels) within the Zalo platform. It currently supports listing all tags associated with a Zalo account. This functionality is useful for users who want to retrieve and work with their existing Zalo tags, such as for organizing contacts or messages by categories.
A practical example would be a marketing automation workflow where you need to fetch all available tags from Zalo to dynamically assign them to contacts or filter messages based on these tags.
Properties
| Name | Meaning |
|---|---|
| Hành đỘng | Action to perform; options: "Danh Sách Thẻ" (List all tags) |
Output
The node outputs an array of JSON objects, each containing:
success: A boolean indicating if the operation was successful.labels: An array of tag objects retrieved from Zalo.
Example output JSON structure:
{
"success": true,
"labels": [
{
"id": "tag_id_1",
"name": "Tag Name 1",
...
},
{
"id": "tag_id_2",
"name": "Tag Name 2",
...
}
]
}
No binary data output is produced by this node.
Dependencies
- Requires an API key credential to connect to Zalo's API.
- Uses the
zca-jslibrary to interact with Zalo services. - The node expects credentials containing a cookie, IMEI, and user agent string for authentication.
- Proper configuration of the Zalo API credentials in n8n is necessary before using this node.
Troubleshooting
- Login Initialization Failure: If the node cannot initialize the Zalo API client, it throws an error indicating that login information should be checked. This usually means the provided credentials are invalid or expired.
- Login Error Message: Errors during login will include the message
"Lỗi đăng nhập Zalo: <error message>". To resolve, verify that the cookie, IMEI, and user agent values in the credentials are correct and up to date. - Empty or Missing Labels: If the output labels array is empty, ensure that the Zalo account actually has tags created and that the credentials have sufficient permissions to access them.
Links and References
- Zalo Official API Documentation
- n8n Documentation - Creating Custom Nodes
- zca-js GitHub Repository (for the underlying Zalo API client library)