Legacy Dev Forum Posts

 View Only

Sign Up

Determining Conversation Channel Type via API

  • 1.  Determining Conversation Channel Type via API

    Posted 06-05-2025 19:24

    mh2523 | 2023-06-14 22:22:58 UTC | #1

    We have configured our system so that a conversation will be 1:1 with a channel type. We are trying to determine how we should identify the channel of the conversation via APIs.

    The following are two options we have identified. Are both options appropriate to make this determination? Is there a better approach not considered here?

    1. Use https://developer.genesys.cloud/routing/conversations/conversations-apis#get-api-v2-analytics-conversations--conversationId--details to look at a participants.sessions.mediatype value.
               "participants": [
                  {
                      "participantId": "",
                      "sessions": [
                          {
                              ...
                              "mediaType": "email",
                              ...
                          }
                          ...
                      ]
                  }
              ]
    
    1. Use https://developer.genesys.cloud/routing/conversations/conversations-apis#get-api-v2-conversations--conversationId- to look at the participants.[calls/chats/emails/messages] to see which of those arrays is not empty (e.g. if emails[] is not empty, conversation is an email).
              "participants": [
                  {
                      "id": "",
                      ...
                      "calls": [],
                      "chats": [],
                      "emails": [],
                      "messages": []
                  }
              ]

    jacobshaw | 2023-06-15 16:38:35 UTC | #2

    Hi @mh2523 I think the first approach is your best bet. You can see the list of available media types here https://developer.genesys.cloud/routing/routing/available-media-types Or get them using the API https://developer.genesys.cloud/devapps/api-explorer#get-api-v2-routing-availablemediatypes


    mh2523 | 2023-06-15 23:45:59 UTC | #3

    Thanks for the reply Jacob, we'll plan to use that approach then.


    system | 2023-07-16 23:46:51 UTC | #4

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