Skip to main content
ASAPP provides real-time access to events, enabling customers to power internal use cases. Typical use cases that benefit from real-time ASAPP events include:
  • Tracking the end-user journey through ASAPP
  • Supporting workforce management needs
  • Integrating with customer-maintained CRM systems
ASAPP’s real-time events provide raw data. Batch analytics and reporting handle complex processing, such as aggregation or deduplication. ASAPP presently supports three real-time event feeds:
  1. Activity: Agent status change events, for tracking schedule adherence
  2. Journey: Events denoting milestones in a conversation, for tracking the customer journey
  3. Queue State: Updates on queues for tracking size and estimated wait times
In order to utilize these available real-time events, a customer will need to configure an API endpoint service under the customer’s control. The balance of this document provides information about the high-level tasks a customer will need to accomplish in order to receive real-time events from ASAPP, as well as further information on the events available from ASAPP.

Architecture Discussion

Upon a customer’s request, ASAPP can provide several types of real-time event data.
Note that ASAPP can separately enhance standard real-time events to accommodate specific customer requirements. Such enhancements would usually be specified and implemented as part of ASAPP’s regular product development process.
Data-ERTAPI-Arch
The diagram above provides a high-level view of how a customer-maintained service that receives real-time ASAPP events might be designed; a service that runs on ASAPP-controlled infrastructure will push real-time event data to one or more HTTP endpoints maintained by the customer. For each individual event, the ASAPP service makes one POST request to the endpoint. ASAPP transmits event data using mTLS-based authentication (See the separate document Securing Endpoints with Mutual TLS for details).

Customer Requirements

  • The customer must implement a POST API endpoint to handle the event messages.
  • The customer and ASAPP must develop the mTLS authentication integration to secure the API endpoint
  • All ASAPP real-time “raw” events will post to the same endpoint; the customer is expected to filter the received events to their needs based on name and event type.
  • Each ASAPP real-time “processed” reporting feed can be configured to post to one arbitrary endpoint, at the customer’s specified preference (i.e., each feed can post to a separate URI, or each can post to the same URI, or any combination required by the customer’s use case.)
It should be noted that real-time events do not implement the de-duplication and grouping of ASAPP’s batch reporting feeds; rather these real-time events provide building blocks for the customer to aggregate and build on. When making use of ASAPP’s real-time events, the customer will be responsible for grouping, de-duplication, and aggregation of related events as required by the customer’s particular use case. The events include metadata fields to facilitate such tasks.

Endpoint Sizing

The endpoint configured by the customer should provisioned with sufficient scale to receive events at the rate generated by the customer’s ASAPP implementation. As a rule of thumb, customers can expect:
  • A voice call will generate on the order of 100 events per issue
  • A text chat will generate on the order of 10 events per issue
So, for example, if the customer’s application services 1000 issues per minute, that customer should expect their endpoint to receive 10,000 — 100,000 messages per minute, or on the order of 1,000 messages per second.

Endpoint Configuration

ASAPP can configure its service with the following parameters:
  • url: The destination URL of the customer API endpoint that is set up to handle POST http requests.
  • timeout_ms: The number of milliseconds to wait for a HTTP 200 “OK” response before timing out.
  • retries: The number of times to retry to send a message after a failed delivery.
  • (optional)event_list: List of event_types to send.
If event_type is empty it will default to send all events for this feed. List the necessary event_type to reduce unnecessary traffic.
If the number of retries is exceeded and the customer’s API is unable to handle any particular message, that message will be dropped. Real-time information lost in this way will typically be available in historical reporting feeds.

Real-time Overview

ASAPP’s standard real-time events include data representing human interactions and general issue lifecycle information from the ASAPP feeds named com.asapp.event.activity, com.asapp.event.journey, and com.asapp.event.queue. In the future, when additional event sources are added, the name of the stream will reflect the event source.

Payload Schema

Each of ASAPP’s feeds will deliver a single event’s data in a payload comprised of a two-level JSON object. The delivered payload includes:
  1. Routing metadata at the top level common to all events. A small set of fields that should always be present for all events, used for routing, filtering, and deduplication.
  2. Metadata common to all events. These fields should usually be present for all events to provide meta-information on the event. Some fields may be omitted if they do not apply to the specific feed.
  3. Data specific to the event feed. Some fields may be omitted but the same total set can be expected for each event of the same origin
  4. Details specific to the event type.
The schema omits null fields — the customer’s API is expected to interpret missing keys as null. Versioning Minor-versions upgrades to the events are expected to be backwards-compatible; major-version updates typically include an interface-breaking change that may require the customer to update their API in order to take advantage of new features.

Activity Feed

The agent activity feed provides a series of events for agent login and status changes. ASAPP processes the event data minimally before pushing it into the activity feed to:
  • Convert internal flags to meaningful human-readable strings
  • Filter the feed to include only data fields of potential interest to the customer
ASAPP’s activity feed does not implement complex event processing (e.g., aggregation based on time windows, groups of events, de-duplication, or system state tracking). Any required aggregation or deduplication should be executed by the customer after receiving activity events.

Sample Event JSON

Field Explanations

Adding the event_list filter in the configuration allows the receiver of the real-time feed to indicate for which event types they want to receive an Activity message.This message will still contain all the fields that have been populated, as the events are being accumulated in the Activity message for that same rep_id.For example: If the event_list contains only agent_activity_status_updated, the Activity messages will still contain all the fields (status_description, routing_status, previous_routing_status, assigned_customer_ct, utilization_5_min_active, etc), but will only be sent whenever the agent status was updated.

Event Types

  • agent_activity_identity_updated
  • agent_activity_status_updated
  • agent_activity_capacity_updated
  • agent_activity_assignment_load_updated
  • agent_activity_routing_status_updated
  • agent_activity_previous_routing_status
  • agent_activity_queue_membership
  • agent_activity_utilization_5_min

Journey Feed

The customer journey feed tracks important events in the customer’s interaction with ASAPP. ASAPP processes the event data before pushing it into the journey feed to:
  • Collect conversation and session events into a single feed of the customer journey
  • Add metadata properties to the events to assist with contextualizing the events
This feature is available only for ASAPP Messaging.
ASAPP’s journey feed does not implement aggregation. Any aggregation or deduplication required by the customer’s use case will need to be executed by the customer after receiving journey events.

Sample Event JSON

Field Explanations

Event Types

  • ISSUE_CREATED
  • ISSUE_ENDED
  • INTENT_CHANGE
  • FIRST_INTENT_UPDATED
  • INTENT_PATH_UPDATED
  • NODE_VISITED
  • LINK_RESOLVED
  • FLOW_SUCCESS
  • FLOW_SUCCESS_NEGATED
  • END_SRS_RESPONSE
  • SURVEY_SUBMITTED
  • CONVERSATION_ENDED
  • CUSTOMER_ENDED
  • ISSUE_SESSION_UPDATED
  • DETECTED
  • OPPORTUNITY_ENDED
  • OPPORTUNITY_ESCALATED
  • QUEUED
  • QUEUE_ABANDONED
  • TIMED_OUT
  • TEXT_MESSAGE
  • FIRST_OPPORTUNITY
  • QUEUED_DURATION
  • CUSTOMER_RESPONSE_BY_OPPORTUNITY
  • ISSUE_OPPORTUNITY_QUEUE_INFO_UPDATED
  • ASSIGNED
  • ASSIGNMENT_ENDED
  • AGENT_RESPONSE_BY_OPPORTUNITY
  • SUPERVISOR_UTTERANCE_BY_OPPORTUNITY
  • AGENT_FIRST_RESPONDED
  • ISSUE_ASSIGNMENT_AGENT_INFO_UPDATED
  • LAST_FLOW_ACTION_CALLED
  • JOURNEY_CUSTOMER_PARAMETERS
  • FILE_UPLOAD_DETECTED
  • DISPOSITION
  • LAST_ASSIGNMENT_SUMMARY
Adding the event_list filter in the configuration allows the receiver of the real-time feed to indicate for which event types they want to receive a Journey message.This message will still contain all the fields that have been populated, as the events are being accumulated in the Journey message for that same issue_id.Example: if the event_list contains only SURVEY_SUBMITTED the Journey messages will still contain all the fields (issue_start_ts, assigned_ts, survey_responses, etc), but will only be sent whenever the survey submitted event happens.

Queue State Feed

The queue state feed provides a set of events describing the state of a queue over the course of time. ASAPP processes the event data before pushing it into the queue feed to:
  • Collect queue volume, queue time and queue hours events into a single feed of the queue state
  • Add metadata properties to the events to assist with contextualizing the events
ASAPP’s queue feed does not implement aggregation. Any aggregation or deduplication required by the customer’s use case will need to be executed by the customer after receiving queue events.

Sample Event JSON

Field Explanations

For a complete detail of all the fields please refer to the full openapi schema.

Event Types

  • queue_info_updated
  • queue_size_updated
  • queue_estimated_wait_time_updated
  • business_hours_settings_updated
  • holiday_settings_updated
  • queue_capping_settings_updated
  • queue_mitigation_updated
  • queue_availability_updated