Vinay | 2017-06-13 12:16:23 UTC | #1
Hi,
I wanted to know is Estimated Wait Time is equivalent to Maximum wait time in Queue for an interaction?
tim.smith | 2017-06-13 12:41:27 UTC | #2
No, EWT is a calculation based on several data points.
Vinay | 2017-06-13 12:49:51 UTC | #3
How can I get the Maximum wait time off a queue?
tim.smith | 2017-06-13 12:54:20 UTC | #4
https://developer.mypurecloud.com/forum/t/list-of-queue-names-and-and-max-wait-timing-of-interactions/1398/2
Vinay | 2017-06-13 12:58:18 UTC | #5
Thank you, Tim. My problem got resolved I am able to pull the data by using above information.
matthew | 2017-06-28 21:34:13 UTC | #6
Hi Tim, This aggregation query would get the max wait time across that interval in question (12th-13th June). How about the current max wait time for the calls waiting in the queue?
Matthew
tim.smith | 2017-06-29 13:19:51 UTC | #7
Adjust your filter to only include calls that aren't disconnected (conversation end not exists and media type is voice).
matthew | 2017-06-29 19:27:08 UTC | #8
ok great, I will give that a try. Are wait times not applicable to other media types?
tim.smith | 2017-06-29 19:29:47 UTC | #9
They are. I was responding to your question:
matthew, post:6, topic:1401
How about the current max wait time for the calls waiting in the queue?
matthew | 2017-06-30 14:22:14 UTC | #10
ok :) Anyway, I tried, but it seems to fail with an error message :
Dimension conversationEnd is not valid in context AGGREGATION
my query :
{
"interval": "2017-06-29T17:30:00/2017-06-29T20:00:00",
"granularity": "PT30M",
"groupBy": [
"queueId",
"mediaType"
],
"filter": {
"type": "and",
"clauses": [
{
"type": "and",
"predicates": [
{
"type": "dimension",
"dimension": "conversationEnd",
"operator": "notExists"
},
{
"type": "dimension",
"dimension": "queueId",
"value": "f6dbd28c-1f6a-41dc-bb61-3eae084f65b8"
},
{
"type": "dimension",
"dimension": "mediaType",
"value": "voice"
}
]
}
]
},
"metrics": [
"tWait"
]
}
Any idea what i'm doing wrong?
thanks!
tim.smith | 2017-06-30 14:35:13 UTC | #11
Sorry, I didn't realize that only works for conversation detail queries, but not aggregate. In discussions with the analytics team, they identified that it's impossible to get tWait for active calls because that metric is not calculated for a conversation until the wait segment has completed. I've submitted an enhancement request for this use case.
To determine the longest waiting call, you'll have to do a conversation detail query where you can filter on conversationEnd as part of the conversation filter. Make sure you get all the results by requesting additional pages until you get an empty result set. Then parse all of the conversations and determine how long each has been waiting. Then find the max duration from that dataset.
It might be a better approach to use queue notifications so your app can keep a state of the queue at all times and easily identify waiting conversations and their duration, rather than having to retrieve the whole queue every time you want to check the current longest wait time.
matthew | 2017-06-30 18:42:57 UTC | #12
thanks for the info. i will give this a try.
matthew | 2017-08-03 20:27:14 UTC | #13
Hi Tim, Just following up on this. I've got the code working now which gives me the current segment time ie. currentdate() - SegmentStartTime for all conversations with a null ConversationEnd that are linked to a queue. But I think there must be another filter I need to show the conversation segments that are in a waiting state? I'm trying to distinguish between the conversations that are waiting, and the ones that are in progress and not ended? is it segments that are not Purpose='Agent'?
matthew
tim.smith | 2017-08-04 15:45:15 UTC | #14
Look for the ACD participant that has an interact segment that hasn't yet ended. This segment represents the ACD routing segment. If that segment hasn't yet ended, the conversation is still awaiting ACD assignment.
{
"participantId": "d14a09b7-316e-48da-803b-927afa2ab335",
"participantName": "Queue 1",
"purpose": "acd",
"sessions": [
{
"mediaType": "voice",
"sessionId": "82f54971-ee6d-421a-adf9-afe59e5d62dc",
"ani": "tel:+13177158561",
"direction": "inbound",
"edgeId": "224678e6-e015-47b0-9d1d-df3cafedfa2b",
"segments": [
{
"segmentStart": "2017-08-04T15:43:36.926Z",
"segmentEnd": "2017-08-04T15:43:36.934Z",
"queueId": "636f60d4-04d9-4715-9350-7125b9b553db",
"segmentType": "delay",
"conference": false
},
{
"segmentStart": "2017-08-04T15:43:36.934Z",
"queueId": "636f60d4-04d9-4715-9350-7125b9b553db",
"segmentType": "interact",
"conference": false
}
]
}
]
}
matthew | 2017-08-07 18:57:42 UTC | #15
thanks tim, this is now working well :)
system | 2017-08-28 19:35:02 UTC | #16
This post was migrated from the old Developer Forum.
ref: 1401