Actions9
Overview
This node interacts with the Zalo social platform to manage user-related actions. Specifically, for the "Zalo User" resource and the "Lấy danh sách bạn bè" (Get all friends) operation, it retrieves a list of friends from a Zalo user account.
Common scenarios where this node is useful include:
- Synchronizing a user's Zalo friend list with another system.
- Analyzing or processing a user's social connections on Zalo.
- Automating workflows that depend on a user's social graph.
For example, you could use this node to fetch up to 50 friends of a Zalo user and then send personalized messages or invitations based on that list.
Properties
| Name | Meaning |
|---|---|
| Limit | The maximum number of friends to retrieve from the user's friend list. |
Output
The output JSON contains a single field:
friends: An array of friend objects representing the retrieved friends from the Zalo account. Each object corresponds to one friend’s data as returned by the Zalo API.
No binary data output is produced by this operation.
Example output structure:
{
"friends": [
{
"id": "123456789",
"name": "Friend Name",
"avatar": "https://example.com/avatar.jpg",
...
},
...
]
}
Dependencies
- Requires valid Zalo API credentials including an API key credential that provides authentication details such as cookie, device IMEI, and user agent.
- Uses the external
zca-jslibrary to interact with the Zalo API. - The node expects these credentials to be configured in n8n beforehand.
Troubleshooting
- No API instance found: This error indicates invalid or missing credentials. Ensure that the Zalo API credentials are correctly set up and contain valid authentication tokens.
- Empty or incomplete friend list: Verify that the authenticated user has friends and that the limit parameter is set appropriately.
- API request failures: Network issues or changes in the Zalo API may cause errors. Check connectivity and update credentials if necessary.
- If the node is set to continue on fail, errors for individual items will be included in the output under an
errorfield.
Links and References
- Zalo Official Developer Documentation
- zca-js GitHub Repository (for the underlying Zalo API client used)