Hi,
I'm trying to retrieve the active conversations for a user. I ended up using the "/api/v2/analytics/conversations/details/query" endpoint using a query you will see below. basicly i'm filtering on userid and checking if conversationEnd does not exists.
The problem is that if a user transfers a call it still ends up in the result of this query, because one of the segments contains the userid and the call is not ended.
What i need is a query that filters for a userid with an active segment. Has anyone experience with this?
{
"interval": "2021-07-05T22:00:00.000Z/2021-07-06T22:00:00.000Z",
"order": "desc",
"orderBy": "conversationStart",
"paging": {
"pageSize": 25,
"pageNumber": 1
},
"segmentFilters": [
{
"type": "or",
"predicates": [
{
"type": "dimension",
"dimension": "userId",
"operator": "matches",
"value": "USERID"
}
]
}
],
"conversationFilters": [
{
"type": "or",
"predicates": [
{
"type": "dimension",
"dimension": "conversationEnd",
"operator": "notExists",
"value": null
}
]
}
]
}