How to properly get handled call count w/multi divisions and xfers

Good afternoon,

I've created a small c# app which queries for specified divisions guids, then obtains the total tHandle count by user, by day. We've run into an issue where users in one division are also showing handled calls in another division. This is caused when a user in division one, answers a call. Then that user transfers the call to a user in division two. The user in division one only shows the tHandled for their division but the user in division 2 shows to have a tHandled in both division one AND in division two. This doesn't seem to be the case when viewing interactions in the web front end when both divisions are selected.

Is there any way to differentiate which calls were transferred to division two, so we can avoid duplication? We can't simply use the data for division two as this could potentially lead to missed call counts. I tried adding the NTransfers metric as well but it didn't seem to include the correct number of results.
Using

var convoBody = new ConversationAggregationQuery
            {
                Interval = interval,
                GroupBy = new List<ConversationAggregationQuery.GroupByEnum>
                {
                    ConversationAggregationQuery.GroupByEnum.Userid

                },
                Filter = new ConversationAggregateQueryFilter
                {
                    Type = ConversationAggregateQueryFilter.TypeEnum.Or,
                    Predicates = new List<ConversationAggregateQueryPredicate>
                    {
                        //this is programmatically added prior to running the query, in case we want to query multiple divisions at once. 
                    }
                },
                Metrics = new List<ConversationAggregationQuery.MetricsEnum>()
                {
                    ConversationAggregationQuery.MetricsEnum.Thandle
                }
            };
...
var convoResults = analyticsApi.PostAnalyticsConversationsAggregatesQuery(convoBody);

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.