How to check agent availability at a given time

Written by Charlotte Driscoll, Technical Support Engineer @ Kustomer

Have you ever looked at a conversation and wondered why it routed the way it did? With so many different configurations of Queues and Routing (QnR) available, it can be hard to find the answer to this question, but after reading this article, you’ll be a QnR pro!

Typical QnR questions can be narrowed down to the following categories:

  1. Why was a conversation routed to a specific queue?

  2. Why was a conversation not routed to a specific agent?

To help answer these questions, we will make use of a few troubleshooting tools available on Kustomer. These include the conversation audit log, the work-session audit log, and GET requests using our API.

Question 1: Why was a conversation routed to a queue?

Let’s say you’re looking at an email conversation that routed differently than you expected. The conversation ended up routing to Queue A instead of Queue B and you’d like to know why. The best way to find this answer is to view the conversation audit log.

To do this, just click on the options menu of the conversation and select “View Audit Log”:

After selecting “View Audit Log”, we will be taken to a history of all actions that took place regarding the conversation. There’s a lot of useful information stored here, but in our scenario, we want to focus mainly on anything that has “Router” in the “Performed By” column.

Any events that are done by the Router, and have New -> Queued in the Before and After columns can be expanded to get more information by clicking on the small arrow on the left.

When we expand the event, we are able to see three important things: We can see the time a conversation entered a Queue, the queue it entered, and the Queue Rule that determined which queue the conversation entered.

In this conversation, the Queue was assigned on 2/20/2022 at 12:26 PM EST, it entered the “Test” Queue, and it entered this queue because of the “Route all email conversations”.

To answer our original question of why a conversation entered a certain queue, we will need to look at the “Route all email conversations” Queue Rule pictured here: 

The only condition for this rule is that the conversation needs to be an email conversation. Now we know that the conversation was routed to the “Test” queue because it satisfied the “Route All Email Conversations” Queue Rule.

Question 2: Why didn’t a conversation route to a specific agent?

There are two common reasons why a conversation didn’t route to one of your agents. The first is that they don’t have the available capacity to accept the conversation. The second reason is that they are signed in to a team that is not associated with the queue a conversation ended up in.

To determine which of these reasons is the true cause, we will need to take a look at your organization's audit log. To do so, navigate to the security section of the settings page and select “Audit Log”.

This log gives you an overview of all actions that have been taken in your organization from conversations routing, to messages being sent out, to SLA’s being broken. In our case, we only need to focus on “Work-session” events.

To drill down what we are looking for, we will need to add a filter like this:

Now that we are looking at the session history for the agent we expected our conversation to route to, we can get a bigger picture of what their capacity looked like: 

From the audit log, I see that my agent signed in at 1:22:29 PM EST, far after our conversation was routed to the test queue, so why wasn’t the conversation assigned to her? The answer is found in the very top row. 

The “Before” and “After” columns show an agent’s capacity after a conversation is assigned to them and after a conversation is marked done. In our case, it looks like as soon as Charlotte signed in, a conversation was assigned to her and because her capacity was set to 0, she wasn’t available to be routed.

 To see exactly what conversation was assigned, we will need to take a look at the work-item listed. In this case it is “61fd631f5f778416d6a44bda”.

Work-items are different from conversations, so to see exactly what conversation this work-item is associated with, we will need to make a simple GET request . To do this, all you’ll need to do is paste the following in your address bar:

yourOrgName.api.kustomerapp.com/v1/routing/work-items/ID

In my case when I paste: https://zzz-charlotte-lesly.api.kustomerapp.com/v1/routing/work-items/61fd631f5f778416d6a44bda

Into my address bar, I see a JSON file like this:

And when I scroll down to the “Conversation” section, I see that the ID is '61fd631d59450967e20aa220'.

If we navigate to that ID by entering in: yourOrgName.kustomerapp.com/app/conversations/conversationID to the address bar, we will be taken to the exact conversation:

This conversation is not the same as the one we were looking at earlier, so we can conclude that the reason our conversation was not routed to Charlotte is because she was working on another conversation and did not have any available capacity to take on a new one.

Let’s look at another one of my agents to see why she wasn’t routed the conversation either:

Based on this image, it looks like Jenny did have enough capacity to accept our conversation, so something else must be going on here.

For more information, we are going to do some investigation into the work-session to see exactly what team she was signed into while she was online. If the team she is signed into is not associated with the “Test” queue, then she won’t be able to take the conversation.

To do this, we are going to copy the work-item ID (62128db68eb1bc7317a638be) and paste it into the URL just like we did before. When we hit enter, we will be taken to a similar JSON file, and if you scroll down to the “Teams” section, you will see a link that you can click on:

Clicking that link will take you to the Team JSON file where you can see the name of the team the agent was signed into:

Based on this, it looks like she was signed into the “Team 2 - Chat” team. Taking a look at that team’s Queue assignment here:

Team 2 is not associated with the Test queue in any way. Because of this, Jenny was not available to take the conversation.

When you run into any QnR issues, these steps are a great way to start troubleshooting, but if you need any assistance with this, please reach out to Kustomer Support! We are always here to help!


Â