Zalo Friend Trigger icon

Zalo Friend Trigger

Lắng nghe sự kiện kết bạn trên Zalo

Overview

This node listens for friend-related events on the Zalo platform, specifically friend requests. It acts as a trigger that activates workflows when such events occur. This is useful for automating responses or actions based on incoming friend requests on Zalo, such as sending notifications, logging events, or updating CRM systems.

Practical examples:

  • Automatically notify a team via chat or email when a new friend request is received.
  • Log friend request data into a database for analytics.
  • Trigger follow-up workflows to welcome new contacts.

Properties

Name Meaning
Event Types Friend events to listen for. Options: "Friend Requests" (listens for incoming friend requests).

Output

The node outputs JSON data representing the friend event received from Zalo. The output structure includes a friendEvent object containing details about the specific friend event (e.g., friend request data).

Example output JSON structure:

{
  "friendEvent": {
    // Details of the friend request event from Zalo
  }
}

No binary data output is produced by this node.

Dependencies

  • Requires an API key credential to connect with the Zalo platform.
  • Uses the Zalo SDK (zca-js) internally to manage connection and event listening.
  • Needs proper webhook URL configuration in n8n to receive POST requests from Zalo.
  • Requires valid credentials including cookie, IMEI, and user agent information for authentication.

Troubleshooting

  • Connection failures: If the node throws "Zalo connection failed," verify that the provided credentials are correct and include valid cookie, IMEI, and user agent values.
  • No credentials found: Ensure that the required API key credential is configured in n8n before activating the node.
  • Webhook not triggered: Confirm that the webhook URL is correctly set up and accessible by Zalo's servers.
  • Event types mismatch: Make sure the selected event types match the actual events sent by Zalo; currently, only friend requests are supported.

Links and References

Discussion