Chris_Phillips | 2019-07-02 04:37:40 UTC | #1
Hi, I would like to get an agents Email and SMS history.
For Voice I can call
/api/v2/conversations/calls/history
I haven't been able to find anything similar for email or sms?
thanks
Chris
tim.smith | 2019-07-02 16:26:38 UTC | #2
Use POST /api/v2/analytics/conversations/details/query with a segment filter on the agent's userid.
Chris_Phillips | 2019-07-02 17:15:29 UTC | #3
Hi Tim
Unfortunately I tried that one before and it returns this error if you wish to limit results by user
{ "status": 400, "code": "bad.request", "message": "Dimension userId is not yet supported. Allowed dimensions include [organizationId, mediaStatsMinConversationMos, mediaStatsMinConversationRFactor, conversationId, conversationEnd, originatingDirection, divisionId]", "messageParams": {}, "contextId": "227731ed-26bd-4084-b8b4-f16e7eea61c9", "details": [], "errors": [] }
This is the query I used
{ "interval": "2019-07-02T07:00:00.000Z/2019-07-03T07:00:00.000Z", "order": "asc", "orderBy": "conversationStart", "paging": { "pageSize": 25, "pageNumber": 1 }, "conversationFilters": [ { "type": "and", "clauses": [ { "type": "or", "predicates": [ { "type": "dimension", "dimension": "userId", "value":"123abc" } ] } ] } ] }
tim.smith | 2019-07-03 20:07:42 UTC | #4
Use a segment filter, not conversation filter.
Chris_Phillips | 2019-07-03 21:16:03 UTC | #5
Chris_Phillips, post:3, topic:5471
{ "interval": "2019-07-02T07:00:00.000Z/2019-07-03T07:00:00.000Z", "order": "asc", "orderBy": "conversationStart", "paging": { "pageSize": 25, "pageNumber": 1 }, "conversationFilters": [ { "type": "and", "clauses": [ { "type": "or", "predicates": [ { "type": "dimension", "dimension": "userId", "value":"123abc" } ] } ] } ] }
Great that works! thanks!
Chris
system | 2019-08-03 21:16:04 UTC | #6
This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.
This post was migrated from the old Developer Forum.
ref: 5471