ENS Event Data Code Samples

All event data is sent in XML format using UTF-8 encoding. Depending on the event type, the specific structure of the XML tags may vary. Additionally, some values may be set to null. For those reasons, separate code samples for each specific event as well as explanatory notes, when necessary, are provided below.

Either an Agent, a Lead Agent – which includes the API user – or the System can create an event.

  • If an Agent or Lead Agent has initiated an event, that person’s email address is contained in the email tags in the event message. An example would be henryjones@tannis.com.
  • If the API agent has initiated an event, the email is whatever address you set up for the API such as api@tannis.com.
  • If the system has initiated an event, such as detecting a change in the purchaser’s network or geographic location, the value in the email tags is system@company.com where company is the organization providing the Agent Web Console (AWC) web service.

The date and time between the occurred tags for all events is in yyyy/MM/dd'T'HH:mm:ss format by default.

The general formatting of tags in the event data is as follows:

  • Name
  • Key
  • Old Value
  • New Value
  • Agent
  • Occurred
NOTE: Exceptions are noted in the relevant code examples.

ENS General Event Code Example

Regardless of how many events you receive in a single Event Notification from Kount, the complete group of events is surrounded by an events tag. This is the root tag of the notification. The events tag has a total attribute which tells us how many events the notification contains and a merchant attribute (which is your merchantID).

Each individual event, regardless of type, is surrounded by an event tag.

Also, preceding the events tag is the xml header which contains the required information detailing the XML version and encoding.

<?xml version="1.0" encoding="UTF-8"?>
<events merchant="999999" total="2">
  <event>
    <name>DMC_EMAIL_ADD</name>
    <key>TEST@MENOW.com</key>
    <old value></old value>
    <new value>decline</new value>
    <agent>abc1@keynetics.com</agent>
    <occurred>2010-12-01 12:11:21</occurred>
  </event>
  <event>
    <name>DMC_EMAIL_ADD</name>
    <key>JOHN@TEST.com</key>
    <old_value></old_value>
    <new_value></new_value>
    <agent>def2@keynetics.com</agent>
    <occurred>2010-12-01 13:19:24</occurred>
  </event>
</events>

ENS Agent Web Console DMC Event Sample

Workflow Events

For WORKFLOW_QUEUE_ASSIGN events, initially the old value tag contains a null value and the new value tag contains the email address of the Agent being assigned a transaction. When a suspect order first enters the queue, an Agent is assigned automatically through a round robin process. However, that assignment is registered as an update so that agent’s email address is recorded in the new value tag.

If the Lead Agent is reassigning a transaction from one agent to another, the old value tag contains the original Agent’s email address and the new value tag contains the new Agent’s email address.

In the Agent Web Console (AWC) on the Workflow tab in the Suspect Orders page, when the Lead Agent opens the Agent drop-down menu, only the initials of available agents appear, rather than their full email addresses. This is done in the GUI to conserve space. The actual value transmitted when the assignment is made however, is an email address.

WORKFLOW_NOTES_ADD

<event>
  <name>WORKFLOW_NOTES_ADD</name>
  <key order_number="?" site="?">Transaction ID </key>
  <old_value>null </old_value>
  <new_value reason_code="code">New Note </new_value>
  <agent>agent@email.com </agent>
  <occurred>2019-09-05 13:19:24 </occurred>
</event>

WORKFLOW_QUEUE_ASSIGN

<event>
  <name>WORKFLOW_QUEUE_ASSIGN</name>
  <key order_number="?" site="?">Transaction ID </key>
  <old_value>old email address </old_value>
  <new_value>new email address </new_value>
  <agent>agent@email.com </agent>
  <occurred>2019-09-05 13:19:24 </occurred>
</event>

WORKFLOW_REEVALUATE

<event>
  <name>WORKFLOW_REEVALUATE</name>
  <key order_number="?" site="?">Transaction ID </key>
  <old_value>Old Score </old_value>
  <new_value>New Score </new_value>
  <agent>agent@email.com </agent>
  <occurred>2019-09-05 13:19:24 </occurred>
</event>

WORKFLOW_STATUS_EDIT

<event>
  <name>WORKFLOW_STATUS_EDIT</name>
  <key order_number="?" site="?">Transaction ID </key>
  <old_value>Old Status </old_value>
  <new_value>New Status </new_value>
  <agent>agent@email.com </agent>
  <occurred>2019-05-11 08:56:14 </occurred>
</event>

ENS Workflow Event Code Example

Workflow Events

For WORKFLOW_QUEUE_ASSIGN events, initially the old value tag contains a null value and the new value tag contains the email address of the Agent being assigned a transaction. When a suspect order first enters the queue, an Agent is assigned automatically through a round robin process. However, that assignment is registered as an update so that agent’s email address is recorded in the new value tag.

If the Lead Agent is reassigning a transaction from one agent to another, the old value tag contains the original Agent’s email address and the new value tag contains the new Agent’s email address.

In the Agent Web Console (AWC) on the Workflow tab in the Suspect Orders page, when the Lead Agent opens the Agent drop-down menu, only the initials of available agents appear, rather than their full email addresses. This is done in the GUI to conserve space. The actual value transmitted when the assignment is made however, is an email address.

WORKFLOW_NOTES_ADD

<event>
  <name>WORKFLOW_NOTES_ADD</name>
  <key order_number="?" site="?">Transaction ID </key>
  <old_value>null </old_value>
  <new_value reason_code="code">New Note </new_value>
  <agent>agent@email.com </agent>
  <occurred>2019-09-05 13:19:24 </occurred>
</event>

WORKFLOW_QUEUE_ASSIGN

<event>
  <name>WORKFLOW_QUEUE_ASSIGN</name>
  <key order_number="?" site="?">Transaction ID </key>
  <old_value>old email address </old_value>
  <new_value>new email address </new_value>
  <agent>agent@email.com </agent>
  <occurred>2019-09-05 13:19:24 </occurred>
</event>

WORKFLOW_REEVALUATE

<event>
  <name>WORKFLOW_REEVALUATE</name>
  <key order_number="?" site="?">Transaction ID </key>
  <old_value>Old Score </old_value>
  <new_value>New Score </new_value>
  <agent>agent@email.com </agent>
  <occurred>2019-09-05 13:19:24 </occurred>
</event>

WORKFLOW_STATUS_EDIT

<event>
  <name>WORKFLOW_STATUS_EDIT</name>
  <key order_number="?" site="?">Transaction ID </key>
  <old_value>Old Status </old_value>
  <new_value>New Status </new_value>
  <agent>agent@email.com </agent>
  <occurred>2019-05-11 08:56:14 </occurred>
</event>

ENS Risk Change Event Code Example

Risk Change Events

Each of the events in this section correspond to a column in the Risk Evaluation Table on the Transaction Detail page for any transaction. RISK_CHANGE events only occur when the Reevaluate Risk button is clicked on that page. When an Agent clicks the button, the system looks at the risk factors in the table to see if any change can be detected. If the system detects a change in score, the event is sent.

The clicking of the button itself is considered an event, even if the score has not changed in any of the Risk Evaluation Table columns. The button click event is recorded as a WORKFLOW_REEVALUATE event.

All RISK_CHANGE events are considered to be triggered by the System since Kount, in the process of evaluating the risk of suspect orders, detects the actual changes that occur. For that reason, the email address system@company.com appears in the agent tag rather than the email address of a person or the “API agent”. To determine the email address of the person initiating the Reevaluate Risk button click, review the WORKFLOW_REEVALUATE event.

For RISK_CHANGE_REAS events, if more than one reason is recorded as having changed, the reasons appear in the new value tag as a comma-delimited list, such as NETW, SCOR.

RISK_CHANGE_GEOX

<event>
  <name>RISK_CHANGE_GEOX</name>
  <key order_number="?" site="?">Transaction ID </key>
  <old_value>Old Value </old_value>
  <new_value>New Value </new_value>
  <agent>system@company.com </agent>
  <occurred>2019-09-05 13:19:24 </occurred>
</event>

RISK_CHANGE_NETW

<event>
  <name>RISK_CHANGE_NETW</name>
  <key order_number="?" site="?">Transaction ID </key>
  <old_value>Old Value </old_value>
  <new_value>New Value </new_value>
  <agent>system@company.com </agent>
  <occurred>2019-09-05 13:19:24 </occurred>
</event>

RISK_CHANGE_REAS

<event>
  <name>RISK_CHANGE_REAS</name>
  <key order_number="?" site="?">Transaction ID </key>
  <old_value>Old Reason </old_value>
  <new_value>New Reason </new_value>
  <agent>system@company.com </agent>
  <occurred>2019-09-05 13:19:24 </occurred>
</event>

RISK_CHANGE_REPLY

<event>
  <name>RISK_CHANGE_REPLY</name>
  <key order_number="?" site="?">Transaction ID </key>
  <old_value>Old Status </old_value>
  <new_value>New Status </new_value>
  <agent>system@company.com </agent>
  <occurred>2019-09-05 13:19:24 </occurred>
</event>

RISK_CHANGE_SCOR

<event>
  <name>RISK_CHANGE_SCOR</name>
  <key order_number="?" site="?">Transaction ID </key>
  <old_value>Old Score </old_value>
  <new_value>New Score </new_value>
  <agent>system@company.com </agent>
  <occurred>2019-09-05 13:19:24 </occurred>
</event>

RISK_CHANGE_VELO

<event>
  <name>RISK_CHANGE_VELO</name>
  <key order_number="?" site="?">Transaction ID </key>
  <old_value>Old Score </old_value>
  <new_value>New Score </new_value>
  <agent>system@company.com </agent>
  <occurred>2019-09-05 13:19:24 </occurred>
</event>

RISK_CHANGE_VMAX

<event>
  <name>RISK_CHANGE_VMAX</name>
  <key order_number="?" site="?">Transaction ID </key>
  <old_value>Old Score </old_value>
  <new_value>New Score </new_value>
  <agent>system@company.com </agent>
  <occurred>2019-09-05 13:19:24 </occurred>
</event>

ENS Special Alert Event Code Example

There is only one special alert event and it applies to transactions that have previously been manually approved and subsequently triggered the special alert threshold.

SPECIAL_ALERT_TRANSACTION

<event>
  <name>SPECIAL_ALERT_TRANACTION</name>
  <key order_number="?" site="?">Transaction ID </key>
  <old_value>Old Score </old_value>
  <new_value>New Score </new_value>
  <agent>system@company.com </agent>
<occurred>2015-09-05 13:19:24 </occurred>
</event>
Was this article helpful?
0 out of 0 found this helpful