Zalo User icon

Zalo User

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

Overview

This node performs the "Bỏ chặn người dùng" (Unblock User) operation for Zalo users. It allows you to unblock a specific user on Zalo by providing their User ID. This is useful in scenarios where you have previously blocked a user and now wish to restore communication with them.

Practical examples:

  • Automate unblocking users as part of a customer support workflow.
  • Integrate with CRM systems to manage user relationships on Zalo.
  • Use in moderation tools to reverse accidental blocks.

Properties

Name Type Meaning
User ID String ID của người dùng cần bỏ chặn (User ID to unblock)

Output

The output will be a JSON object with the following structure:

{
  "status": "Thành công",
  "response": { /* response from the Zalo API */ }
}
  • status: Indicates the result of the operation ("Thành công" means "Success").
  • response: Contains the raw response returned by the Zalo API after attempting to unblock the user.

If an error occurs and "Continue On Fail" is enabled, the output will include:

{
  "error": "Error message"
}

Dependencies

  • Zalo API credentials: Requires valid Zalo credentials (cookie, IMEI, user agent) configured in n8n under the credential type zaloApi.
  • zca-js: Uses the zca-js library to interact with the Zalo API.
  • n8n configuration: The node must be set up with the appropriate Zalo credentials.

Troubleshooting

Common issues:

  • Invalid credentials: If the provided Zalo credentials are incorrect or expired, the node will throw an error:
    "No API instance found. Please make sure to provide valid credentials."
    Resolution: Update your Zalo credentials in n8n.

  • User ID not found or already unblocked: If the User ID does not exist or is not currently blocked, the Zalo API may return an error in the response field.
    Resolution: Double-check the User ID and ensure the user is actually blocked before running this operation.

  • Network/API errors: Any connectivity or API-side issues will be reported in the error field if "Continue On Fail" is enabled.

Links and References

Discussion