Actions12
- Zalo Send Message Actions
- Zalo Text To Speech Actions
Overview
This node allows users to pin or unpin conversations (threads) in Zalo, a popular messaging platform. It interacts with the Zalo API using credentials based on cookies and device identifiers to authenticate. The "Ghim/Bỏ ghim Hội thoại" operation specifically manages the pinned status of a conversation, which is useful for prioritizing important chats or cleaning up pinned lists.
Practical scenarios include:
- Automatically pinning high-priority customer support threads.
- Unpinning conversations after resolution or inactivity.
- Managing chat visibility programmatically in bulk workflows.
Properties
| Name | Meaning |
|---|---|
| Hành động (pinAction) | Choose the action: "Ghim" (Pin) or "Bỏ ghim" (Unpin) the conversation |
| ID cuộc trò chuyện / Thread ID (threadId) | The unique identifier of the conversation (thread) to pin or unpin |
| Loại cuộc trò chuyện (type) | Type of conversation: "Cá nhân" (Personal/User) or "Nhóm" (Group) |
Output
The node outputs a JSON object indicating success and the response from the Zalo API regarding the pin/unpin action. The structure is:
{
"success": true,
"response": { /* API response data */ }
}
success: Boolean indicating if the operation succeeded.response: Contains detailed information returned by the Zalo API about the pin/unpin request.
No binary data output is involved in this operation.
Dependencies
- Requires valid Zalo API credentials authenticated via cookie, IMEI, and user agent strings.
- The node depends on the external Zalo API client library (
zca-js) to perform actions. - Proper configuration of these credentials in n8n is necessary before use.
Troubleshooting
Common issues:
- Invalid or expired Zalo API credentials will cause login failures.
- Incorrect or missing thread IDs will result in errors or no effect.
- Using an unsupported conversation type value may cause unexpected behavior.
Error messages:
"Failed to initialize Zalo API. Check your credentials."— Indicates authentication failure; verify that the cookie, IMEI, and user agent are correct and active."Zalo API not initialized"— The node failed to create a valid API client instance; check credential setup.- Other errors from the Zalo API will be surfaced with their message; ensure the thread ID exists and the account has permission to modify it.
Resolution tips:
- Re-authenticate or refresh credentials if login fails.
- Double-check the thread ID and conversation type inputs.
- Enable "Continue On Fail" in the node settings to handle errors gracefully in batch operations.