Zalo User icon

Zalo User

Quản lý người dùng Zalo

Overview

This node allows interaction with Zalo user accounts through various operations such as sending friend requests, accepting friend requests, blocking/unblocking users, updating profile settings, retrieving user information, managing friends list, and handling message states. It is particularly useful for automating social interactions on the Zalo platform, such as managing contacts or messaging workflows.

The "Gửi Lời Mời Kết Bạn" (Send Friend Request) operation specifically enables sending a friend request to a specified Zalo user along with a custom message. This can be used in scenarios like automating outreach campaigns, onboarding new contacts, or integrating Zalo social features into broader automation processes.

Properties

Name Meaning
User ID The unique identifier of the Zalo user to whom the friend request will be sent.
Message The accompanying message text that will be sent along with the friend request invitation.

Output

The output JSON object contains:

  • status: A string indicating the result status, typically "Thành công" meaning "Success".
  • response: The raw response data returned from the Zalo API after attempting to send the friend request. This may include confirmation details or error information from the API.

The output is paired with the input item index to maintain correspondence between inputs and outputs.

No binary data output is produced by this operation.

Dependencies

  • Requires valid Zalo API credentials including authentication tokens such as cookies, device IMEI, and user agent strings.
  • Uses an external Zalo API client library (zca-js) to perform API calls.
  • The node expects these credentials to be configured in n8n under a generic API key credential setup for Zalo.

Troubleshooting

  • Invalid Credentials: If the node throws an error about missing or invalid API instance, verify that the Zalo API credentials are correctly set up and contain valid cookie, IMEI, and user agent values.
  • API Errors: Errors returned from the Zalo API (e.g., user not found, request limit exceeded) will appear in the response field or as thrown errors. Check the message content for specific causes.
  • Continue On Fail: If enabled, the node will continue processing subsequent items even if one fails, returning error messages per item.
  • Input Validation: Ensure that the User ID and Message fields are provided and correctly formatted; missing required parameters will cause execution errors.

Links and References

Discussion