I am trying to set up a Data Action so that I can retrieve the number of interactions waiting and the duration of the longest waiting interaction in a queue. Previous threads and a search of the API area lead me to:
https://developer.genesys.cloud/devapps/api-explorer#post-api-v2-analytics-queues-observations-query
the metric oWaiting returns the number of interactions waiting - fantastic.
the listed metric oLongestWaiting returns... an error:
- REST call for action execute failed. Message: Request to backend service failed. Response from web service: {"message":"unsupported metric oLongestWaiting","code":"bad.request","status":400,"messageParams":{},"contextId":"57ec79cf-a526-4ad4-81df-74610d8f9913","details":[],"errors":[]} [ca2ff8cf-c5ea-48f5-af6d-cb28b51bcc19]
To add further insult - I placed a bad metric in and received the following message:
- REST call for action execute failed. Message: Request to backend service failed. Response from web service: {"message":"Value [oLongestWait] is not valid for field type [QueueObservationMetric]. Allowable values are: oActiveUsers, oAlerting, oInteracting, oLongestInteracting, oLongestWaiting, oMemberUsers, oOffQueueUsers, oOnQueueUsers, oUserPresences, oUserRoutingStatuses, oWaiting","code":"invalid.value","status":400,"contextId":"e054705c-6aca-4c9f-8b7d-72b831e8fb85","details":[],"errors":[]} [fc80a4e9-cb35-4be9-964b-59d7673e5e6b]
Even the error message tells me that I should be able to use oLongestWaiting.
This occurs whether I am testing on the developer site, or testing from the action within Genesys Cloud.
Is this a failure of the API developer? And if so can this functionality be added?
Or, is this a failure of the documentation? and if so, can it be corrected?
If anyone knows of another way that I could get the information I'm looking for into Architect (input queue, output longest current wait time) that would be an acceptable solution.
#Architect#DataActions#PlatformAPI------------------------------
Peter DeMarco
na
------------------------------