Legacy Dev Forum Posts

 View Only

Sign Up

When using the analytics api does it take division into account?

  • 1.  When using the analytics api does it take division into account?

    Posted 06-05-2025 18:17

    kphung | 2020-05-06 19:43:33 UTC | #1

    If i use the endpoint /api/v2/analytics/conversations/details/query to get conversations within a range e.g. calls that ended in the last 15min. Does it take into account divisions? For example the division that the oauth has access to is DivisionA. A call was placed between agents in DivisionB. Does the query return the call that was placed in DivisionB ?

    Kathie


    Jerome.Saint-Marc | 2020-05-11 07:36:45 UTC | #2

    Hello,

    Yes, the endpoint /api/v2/analytics/conversations/details/query apparently does take into account the account/oauth client divisions (in the roles/permissions assigned to the user or to the oauth client).

    I have just done a quick test with 2 users (belonging to 2 different divisions) and checking via the Analytics Query Builder in the developer tools

    Assuming the userA (or OAuth client) making the query has permissions on Division A only.

    If a call is placed and *only* involves objects/entities belong to Division B, then the query (from userA/OAuthClient in Division A) will return nothing.

    If a call is placed and involves objects from Division A and Division B (Queues, Flows, Users), then the query will return the conversation. Ex1: a call between a user from Division A and a user from Division B Ex2: a call placed to a queue assigned to Division A and which gets delivered to a user assigned to Division B

    Of course, if the UserA (or OAuth client) has permissions on Division A and on Division B, the query will return both calls/conversations.

    When you request /api/v2/analytics/conversations/details/query to get conversations, you can see, under each conversation structure, a divisionIds attribute (array) which lists the divisionIds which were involved in the call/interaction.

    Regards,


    system | 2020-06-11 07:28:42 UTC | #3

    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: 7732