Zalo Web Trigger icon

Zalo Web Trigger

Zalo Web Trigger

Overview

The "Zalo Web Trigger" node listens for real-time events from the Zalo messaging platform via a web API connection. It enables workflows to react automatically when specific types of messages or reactions occur in user or group chats on Zalo. This trigger is useful for automating responses, logging conversations, monitoring chat activity, or integrating Zalo interactions with other systems.

Typical use cases include:

  • Automatically processing incoming messages or reactions in group or private chats.
  • Triggering workflows based on message edits or deletions (undo actions).
  • Monitoring sent messages or reactions by the bot itself.
  • Building chatbots that respond dynamically to user inputs on Zalo.

Properties

Name Meaning
Due to Zalo API limitations, you can use just one Zalo trigger for each bot at a time A notice informing users that only one instance of this Zalo trigger node can be active per bot due to API constraints.
Trigger On Select one or more event types to listen for. Options include:
- ALL EVENTS (listens to all event types)
- GROUP_EVENTS (any new message or reaction in groups)
- GROUP_RECEIVED_MESSAGE
- GROUP_RECEIVED_REACTION
- GROUP_RECEIVED_UNDO_MESSAGE
- GROUP_SENT_MESSAGE
- GROUP_SENT_REACTION
- GROUP_UNDO_MESSAGE
- USER_RECEIVED_MESSAGE
- USER_RECEIVED_REACTION
- USER_RECEIVED_UNDO_MESSAGE
- USER_SEND_REACTION
- USER_SENT_MESSAGE
- USER_UNDO_MESSAGE

Output

The node outputs data as JSON objects representing the event details received from Zalo. Each output item contains a json field with a data property holding the event payload. The structure of data depends on the event type but generally includes information about the message or reaction, sender, chat type (user or group), and whether the message was sent or received.

Example output structure:

{
  "data": {
    "type": "message or reaction type",
    "isSelf": true or false,
    "isGroup": true or false,
    // additional event-specific fields
  }
}

No binary data output is produced by this node.

Dependencies

  • Requires an API key credential for authenticating with the Zalo Web API.
  • Relies on persistent session management handled externally (via imported settings and login utilities).
  • Uses an external library for Zalo thread types.
  • Requires proper configuration of the Zalo API credentials within n8n.

Troubleshooting

  • Only one trigger allowed per bot: Due to Zalo API limitations, running multiple instances of this trigger for the same bot will cause conflicts. Ensure only one active trigger node per bot.
  • Authentication errors: If the node fails to connect, verify that the provided API credentials are valid and have not expired.
  • Event filtering issues: If no events are triggering, check that the selected event types in "Trigger On" match the expected incoming events.
  • Session closed unexpectedly: The node logs when the session closes; if this happens frequently, it may indicate network instability or invalid credentials requiring re-authentication.

Links and References

Discussion