Legacy Dev Forum Posts

 View Only

Sign Up

Analytics Conversations Query on another org

  • 1.  Analytics Conversations Query on another org

    Posted 06-05-2025 18:13

    StueyMcT | 2018-03-13 13:17:15 UTC | #1

    Our main org virtuateldemo has authorisation for another org, but the query

    /api/v2/analytics/conversations/details/query

    { "interval": "2018-03-13T00:00:00.000Z/2018-03-14T00:00:00.000Z", "order": "asc", "orderBy": "conversationStart", "paging": { "pageSize": 25, "pageNumber": 1 }, "conversationFilters": [ { "type": "or", "predicates": [ { "type": "dimension", "dimension": "purpose", "operator": "matches", "value": "customer" } ] } ] }

    returns nothing (when the other org does have a recent conversation).

    If we specify the actual conversation id in a query we get permission error e.g. GET /api/v2/conversations/chats/f6467243-068c-4399-ae9c-d82e99ca4809 { "status": 403, "code": "not.authorized", "message": "Access to Conversation f6467243-068c-4399-ae9c-d82e99ca4809 is forbidden.", "messageWithParams": "Access to {type} {id} is forbidden.", "messageParams": { "id": "f6467243-068c-4399-ae9c-d82e99ca4809", "type": "Conversation" }, "contextId": "02cad5f6-b920-41d5-84b7-6495e850ac5d", "details": [], "errors": [] }


    tim.smith | 2018-03-13 19:15:27 UTC | #2

    Are you obtaining a new auth token by logging in to the "other org" that you're authorized for? Org trust allows a user to log in to other orgs; it does not conflate data between orgs.


    StueyMcT | 2018-03-14 10:13:36 UTC | #3

    So does this mean for each org we need to create an oauth and use that clientid/secret


    tim.smith | 2018-03-14 14:45:57 UTC | #4

    The Authorized Organizations feature only grants access to users. If you want access to an org via client credentials, you will need to have someone in the target org create a new client credentials OAuth client and share the client ID and secret with you.


    system | 2018-04-14 14:46:02 UTC | #5

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