# Conversation Manager APIs This section provides the requisite APIs needed to create Conversation Manager accounts and to configure conversation workflows. To create the Conversation Manager acccount, use the Conversation APIs in this order when setting up a complete eGain application: * Authentication * Client Application * Participant * Channel * Orchestration * Account After the account is created you can use the following APIs to send / receive messages. * Conversation * Asset Note: You can configure your system to use third party Bots and third party Channels. The API instructions provided here assume you are using eGain's application setup. ## Servers Production Server ``` https://api.egain.cloud/conversation/conversationmgr/v3 ``` ## Security ### oAuthClient Authenticate as a client (Server to Server). Type: oauth2 ## Download OpenAPI description [Conversation Manager APIs](https://apidev.egain.com/_bundle/apis/v3/conversation/conversationmgr/api-bundled.yaml) ## Authentication Use this API to register client callback Authentication methods using oAuth or Basic Authentication. ### Create Authentication - [POST /authentications](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/authentication/createauthentication.md): # Overview Use this API to register client callback Authentication methods using oAuth or Basic Authentication. This is the first step in creating a new Conversation Account. New Account API process flow: Authenticiation > Client Application > Participant > Channel > Orchestration > Account Use the ID returned in the response when creating the client application. The Conversation Manager also uses this authentication method when sending messages to the callback URL of the client application. ## Scope Client application must have 'app.conversation.conversationmgr.manage' scope assigned. ### Get Authentications - [GET /authentications](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/authentication/getallauthentication.md): # Overview Use this API to Get details of all authentication types in the Conversation Manager. ## Scope Client application must have 'app.conversation.conversationmgr.manage' assigned to call this API ### Get Authentication - [GET /authentications/{id}](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/authentication/getauthentication.md): # Overview Use this API to get details of existing Authentication types in the Conversation Manager. ## Scope Client application must have 'app.conversation.conversationmgr.manage' or 'app.conversation.conversationmgr.read' scope assigned. ### Update Authentication - [PUT /authentications/{id}](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/authentication/updateauthentication.md): # Overview Use this API to update an existing authentication type. ## Scope Client application must have 'app.conversation.conversationmgr.manage' scope assigned. ### Delete Authentication - [DELETE /authentications/{id}](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/authentication/deleteauthentication.md): # Overview Use this API to delete an existing authentication method. An authentication method can not be deleted if it is in use in the client application. ## Scope Client application must have 'app.conversation.conversationmgr.manage' scope assigned. ## Client Application Use this API to register external client applications where we send and receive messages. ### Create Client Application - [POST /clientapplications](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/client-application/createclientapplication.md): # Overview API to register new Client Applications that can integrate with the Conversation Hub. Client applications are used to send and receive messages. New Account API process flow: Authenticiation > Client Application > Participant > Channel > Orchestration > Account ## Scope Client application must have 'app.conversation.conversationmgr.manage' scope assigned. ### Get Client Applications - [GET /clientapplications](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/client-application/getallclientapplication.md): # Overview Use this APi to get details of all Client applications. ## Scope Client application must have 'app.conversation.conversationmgr.manage' or 'app.conversation.conversationmgr.read' scope assigned. ### Get Client Application - [GET /clientapplications/{id}](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/client-application/getclientapplication.md): # Overview Use this API to get details of the Client application in the Conversation Manager. ## Scope Client application must have 'app.conversation.conversationmgr.manage' or 'app.conversation.conversationmgr.read' scope assigned. ### Update Client Application - [PUT /clientapplications/{id}](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/client-application/updateclientapplication.md): # Overview Use this API to update an existing Client application registered with the Conversation Manager. ## Scope Client application must have 'app.conversation.conversationmgr.manage' scope assigned. ### Delete Client Application - [DELETE /clientapplications/{id}](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/client-application/deleteclientapplication.md): # Overview Use this APi to delete a Client application. If client application is used by a participant then it can not be deleted. ## Scope Client application must have 'app.conversation.conversationmgr.manage' scope assigned. ## Participant Use this API to register Bots. You can register multiple Bots for each client application. ### Create Participant - [POST /participants](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/participant/createparticipant.md): # Overview This API allow you to register participant New Account API process flow: Authenticiation > Client Application > Participant > Channel > Orchestration > Account ## Scope Client application must have 'app.conversation.conversationmgr.manage' scope assigned. ### Get Participants - [GET /participants](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/participant/getallparticipant.md): # Overview Use this API to Get details of all participants. ## Scope Client application must have 'app.conversation.conversationmgr.manage' or 'app.conversation.conversationmgr.read' scope assigned. ### Get Participant - [GET /participants/{id}](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/participant/getparticipant.md): # Overview Use this API to Get details of an existing Participant ## Scope Client application must have 'app.conversation.conversationmgr.manage' or 'app.conversation.conversationmgr.read' scope assigned. ### Update Participant - [PUT /participants/{id}](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/participant/updateparticipant.md): # Overview Use this API to update an existing participant. ## Scope Client application must have 'app.conversation.conversationmgr.manage' scope assigned. ### Delete Participant - [DELETE /participants/{id}](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/participant/deleteparticipant.md): # Overview Use this API to delete an existing participant. ## Scope Client application must have 'app.conversation.conversationmgr.manage' scope assigned. ## Channel Use this API to register and define channel parameters which is used for chat messages. ### Create Channel - [POST /channels](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/channel/createchannel.md): # Overview Use this API to register and define custom channel parameters in the Conversation Manager which is used for chat messages. New Account API process flow: Authenticiation > Client Application > Participant > Channel > Orchestration > Account Note: You can configure your system to use third party Channels. The API instructions provided here assume you are using eGain's application setup. ## Scope Client application must have 'app.conversation.conversationmgr.manage' scope assigned. ### Get Channels - [GET /channels](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/channel/getallchannels.md): # Overview Use this API to Get all channel details for the Conversation Manager. ## Scope Client application must have 'app.conversation.conversationmgr.manage' or 'app.conversation.conversationmgr.read' scope assigned. ### Get Channel - [GET /channels/{id}](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/channel/getchannel.md): # Overview Use this API to Get channel detail information in the Conversation Manager. ## Scope Client application must have 'app.conversation.conversationmgr.manage' or 'app.conversation.conversationmgr.read' scope assigned. ### Update Channel - [PUT /channels/{id}](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/channel/updatechannel.md): # Overview Use this API to update an existing channel in the Conversation Manager with your specific custom requirements. ## Scope Client application must have 'app.conversation.conversationmgr.manage' scope assigned. ### Delete Channel - [DELETE /channels/{id}](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/channel/deletechannel.md): # Overview Use this API to delete a channel in the Conversation Manager. A channel can not be deleted if it is in use in the client application. ## Scope Client application must have 'app.conversation.conversationmgr.manage' scope assigned. ## Orchestration Use this API to configure workflows for conversation between participants (Customer/Agent/Bot applications). ### Create Orchestration - [POST /orchestrations](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/orchestration/createorchestration.md): # Overview Use this API to configure workflows for conversations between participants (Customer/Agent/Bot applications). New Account API process flow: Authenticiation > Client Application > Participant > Channel > Orchestration > Account ## Scope Client application must have 'app.conversation.conversationmgr.manage' scope assigned. ### Get Orchestrations - [GET /orchestrations](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/orchestration/getallorchestration.md): # Overview Use this API to Get all conversation orchestration details. ## Scope Client application must have 'app.conversation.conversationmgr.manage' or 'app.conversation.conversationmgr.read' scope assigned. ### Get Orchestration - [GET /orchestrations/{id}](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/orchestration/getorchestration.md): # Overview Use this API to Get orchestration details. ## Scope Client application must have 'app.conversation.conversationmgr.manage' or 'app.conversation.conversationmgr.read' scope assigned. ### Update Orchestration - [PUT /orchestrations/{id}](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/orchestration/updateorchestration.md): # Overview Use this API to update existing orchestration configuration. ## Scope Client application must have 'app.conversation.conversationmgr.manage' scope assigned. ### Delete Orchestration - [DELETE /orchestrations/{id}](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/orchestration/deleteorchestration.md): # Overview Use this API to delete an existing orchestration. If an orchestration object is in use in a channel account, then the orchestration object cannot be deleted. ## Scope Client application must have 'app.conversation.conversationmgr.manage' scope assigned. ## Account Use this API to create the Conversation Account for Conversation Manager. ### Create Account - [POST /accounts](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/account/createaccount.md): # Overview Use this API to create a Conversation Account for the Conversation Manager. New Account API process flow: Authentication > Client Application > Participant > Channel > Orchestration > Account ## Scope Client application must have 'app.conversation.conversationmgr.manage' scope assigned. ### Get Accounts - [GET /accounts](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/account/getallaccounts.md): # Overview This APIs allows you to get details of all accounts ## Scope Client application must have 'app.conversation.conversationmgr.manage' or 'app.conversation.conversationmgr.read' scope assigned. ### Get account - [GET /accounts/{id}](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/account/getaccount.md): # Overview Use this API to get details of a registered Conversation Manager account. ## Scope Client application must have 'app.conversation.conversationmgr.manage' or 'app.conversation.conversationmgr.read' scope assigned. ### Update account - [PUT /accounts/{id}](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/account/updateaccount.md): # Overview This APIs allows you to update an existing Conversation Manager account. ## Scope Client application must have 'app.conversation.conversationmgr.manage' scope assigned. ### Delete account - [DELETE /accounts/{id}](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/account/deleteaccount.md): # Overview Use this API to delete a Conversation Manager account. ## Scope Client application must have 'app.conversation.conversationmgr.manage' scope assigned. ## Conversation Use this API to send messages through the Conversation Manager. ### Send message - [POST /conversations/messages](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/conversation/sendmessage.md): # Overview Use this API to send different types of messages to the Conversation Hub. Conversation Hub delivers messages on a callback URL of registered client applications of recipient. Recipient client applications should discard messages of various types, if it doesn't support them. Following table tells which client app can send which type of message | Message Type | customer | egain_agent | custom_agent | egain_bot | custom_bot| | ---------------------------------------- | ---------| ------------| -------------|-----------|-----------| | text | Y | Y | Y | Y | Y | | typing.start | Y | Y | Y | Y | Y | | typing.end | Y | Y | Y | Y | Y | | escalation.transfer | N | Y | Y | Y | Y | | pagePush | N | Y | Y | Y | Y | | conversation.state | N | Y | Y | N | N | | agent.join | N | Y | Y | N | N | | agent.available | N | Y | Y | N | N | | agent.unavailable | N | Y | Y | N | N | | agent.transfer | N | Y | Y | N | N | | queue.transfer | N | Y | Y | N | N | | richMessage.listpicker | N | Y | Y | Y | Y | | richMessage.quickreply | N | Y | Y | Y | Y | | richMessage.template | N | Y | Y | Y | Y | | richMessage.timepicker | N | Y | Y | Y | Y | | richMessage.richlink | N | Y | Y | Y | Y | | richMessage.form | N | Y | Y | Y | Y | | richMessage.payment | N | Y | Y | Y | Y | | richMessage.app | N | Y | Y | Y | Y | | richMessage.authentication | N | Y | Y | Y | Y | | authentication.success | Y | N | N | N | N | | authentication.failure | Y | N | N | N | N | | customer.info | Y | Y | Y | Y | Y | | customer.active | Y | N | N | N | N | | customer.inactive | Y | N | N | N | N | | error | Y | Y | Y | Y | Y | | delete.soft | Y | N | N | N | N | | delete.permanent | Y | N | N | N | N | | undo | Y | N | N | N | N | | conversation.end | Y | Y | Y | Y | Y | ## Scope Client application must have 'app.conversation.conversationmgr.interaction.manage' assigned to call this API ### Get conversation - [GET /conversations/{id}](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/conversation/fetchconversation.md): # Overview Use this API to get details of a completed conversation using conversation id. ## Scope Client application must have 'app.conversation.conversationmgr.interaction.manage' or 'app.conversation.conversationmgr.interaction.read' scope assigned. ## Assets Use this API to upload/download Assets like attachments. ### Create Asset - [POST /assets](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/assets/createasset.md): # Overview Use this API to generate a signed URL for uploading an asset. Use contentUrl in response as it is used for uploading content. Make sure you upload files which have the same content type and size that was provided at the the time of signed url generation. ## Scope Client application must have 'app.conversation.conversationmgr.interaction.manage' assigned to call this API ### Get Asset - [GET /assets/{id}](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/assets/getasset.md): Use this API to generate a signed URL for downloading content. Use contentUrl in response as it used is for downloading content. ## Scope Client application must have 'app.conversation.conversationmgr.interaction.manage' or 'app.conversation.conversationmgr.interaction.read' assigned to call this API ### Delete Asset - [DELETE /assets/{id}](https://apidev.egain.com/apis/v3/conversation/conversationmgr/api-bundled/assets/deleteasset.md): # Overview Use this API to delete an asset. After an asset is used in a message the asset cannot be deleted. ## Scope Client application must have 'app.conversation.conversationmgr.interaction.manage' scope assigned.