Check Seize Agent Event

Node

Check Seize Agent Event

Description

This node check seize action.png filters messages coming from the Seize Agent node by checking the reservation status in each message. Routes the message to one of two outputs depending on whether the status matches the configured action.

Overview

The Seize Agent node sends each reservation result as a separate, asynchronous message. The Check Seize Agent Event node sits downstream and acts as a router — it inspects the outboundMetadata.seizeResult.status field in each incoming message and compares it to the action you've selected.

  • Output 1 (True / Match): The message's status matches the selected action.

  • Output 2 (False / No Match): The message's status does not match.

This allows your flow to branch on specific reservation outcomes, such as handling a successfully reserved agent differently from a timeout or a no-agent-available result.

Category

Inputs

Outputs

Default Label

Contact Operations

1

2

Node name, or "Check Seize Agent Event" if left blank

Configuration Options

Setting

Default

Description

Name

(blank)

Optional label shown on the node in the canvas. Falls back to "Check Seize Agent Event" if left blank.

Seize Agent Event

AGENT_RESERVED

The reservation status to match against. Select one from the dropdown.

Available Actions

Value

Meaning

AGENT_RESERVED

An agent was successfully reserved.

RESERVATION_TIMEOUT

The routing engine did not fulfill the reservation before the TTL expired.

RONA

The reserved agent did not answer (Ring on No Answer) or has logged out.

NO_AGENT_AVAILABLE

No eligible agent was available to fulfill the reservation request.

How It Works

  1. A message arrives from the Seize Agent node (or any node that populates outboundMetadata.seizeResult.status).

  2. The node reads the status field from msg.outboundMetadata.seizeResult.status.

  3. It compares the status to the Seize Agent Event value configured on the node.

  4. If they match → the message is sent to Output 1, and the node status updates to Matched (n).

  5. If they don't match → the message is sent to Output 2, and the node status updates to Not matched: n.

  6. If an unexpected error occurs, the node logs the error, sets a red error status, and calls done(error).

seize action config.png


Node Status

Status

Meaning

🟢 Green dot — Matched (n)

The last message matched the selected action. n is the running match count.

⚪ Grey ring — Not matched: n

The last message did not match. n is the running non-match count.

🔴 Red ring — Error

An unexpected error occurred while processing a message. Check the Node-RED logs for details.

Note: Counters (n) are in-memory and reset when the flow is redeployed or Node-RED restarts.


Outputs

Output

Label

When it fires

1

True (Match)

msg.outboundMetadata.seizeResult.status equals the selected action

2

False (No Match)

msg.outboundMetadata.seizeResult.status does not equal the selected action

The original msg object is forwarded unchanged in both cases. No fields are added or removed.

Input Message Structure

This node expects messages in the format produced by the Seize Agent node:

{
  "outboundMetadata": {
    "seizeResult": {
      "status": "AGENT_RESERVED",
      "agent": { "...": "..." },
      "flowId": "..."
    },
    "seizeId": "<node id>"
  }
}

If msg.outboundMetadata.seizeResult.status is missing or undefined, the status comparison will evaluate to false and the message will be routed to Output 2.