Skip to content

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.

Download OpenAPI description
Languages
Servers
Production Server
https://api.egain.cloud/conversation/conversationmgr/v3

Authentication

Use this API to register client callback Authentication methods using oAuth or Basic Authentication.

Operations

Client Application

Use this API to register external client applications where we send and receive messages.

Operations

Participant

Use this API to register Bots. You can register multiple Bots for each client application.

Operations

Channel

Use this API to register and define channel parameters which is used for chat messages.

Operations

Orchestration

Use this API to configure workflows for conversation between participants (Customer/Agent/Bot applications).

Operations

Create Orchestration

Request

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.

Security
oAuthClient(Required scopes:
https://api.egain.cloud/auth/.de...
)
Bodyapplication/json

Register new conversation orchestration

namestringrequired

Name for orchestration

Example: "default_orhchestration"
descriptionstring[ 1 .. 1023 ] characters
activeboolean
Default true
applicationsobjectrequired
applications.​botConfigurationobject

Required if agentConfiguration is not provided

applications.​customerConfigurationobject

details of customer client app, this object must be specified for custom channels.

applications.​agentConfigurationobject

Details of agent client app. Required if botConfiguration is not provided.

curl -i -X POST \
  https://api.egain.cloud/conversation/conversationmgr/v3/orchestrations \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "name": "default_orchestration",
    "description": "Created for Custom channel",
    "active": true,
    "applications": {
      "botConfiguration": {
        "forwardTranscript": true,
        "bots": [
          {
            "id": "a09dddd6-394b-4039-86bc-a5dd89ee5e8d",
            "participant": {
              "id": "a09dddd6-394b-4039-86bc-a5dd89ee5e8d"
            },
            "onEscalation": {
              "agent": {
                "id": "c09dddd6-394b-4039-86bc-a5dd89ee5e8d"
              }
            }
          }
        ]
      },
      "customerConfiguration": {
        "customer": {
          "id": "b09dddd6-394b-4039-86bc-a5dd89ee5e8d"
        }
      }
    }
  }'

Responses

Created

Bodyapplication/json
idstring= 36 characters

UUID generated for the object.

Response
application/json
{ "id": "45a095f4-d0ee-4220-a689-22b541c58f67" }

Get Orchestrations

Request

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.

Security
oAuthClient(Required scopes:
https://api.egain.cloud/auth/.de...
)
curl -i -X GET \
  https://api.egain.cloud/conversation/conversationmgr/v3/orchestrations \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'

Responses

OK

Bodyapplication/json
paginationInfoobject(PaginationInfo)
orchestrationArray of objects(GetOrchestrationData)
Example: [{"id":"45a095f4-d0ee-4220-a689-22b541c58f67","name":"default_orchestration","description":"Created for Custom channel.","active":true,"created":"2021-03-21T14:29:01.516Z","modified":"2021-03-28T14:29:01.516Z","applications":{"botConfiguration":{"forwardTranscript":true,"bots":[{"id":"a09dddd6-394b-4039-86bc-a5dd89ee5e8d","participant":{"id":"b09dddd6-394b-4039-86bc-a5dd89ee5e8d"},"onEscalation":{"agent":{"id":"c09dddd6-394b-4039-86bc-a5dd89ee5e8d"}}}]},"customerConfiguration":{"customer":{"id":"b09dddd6-394b-4039-86bc-a5dd89ee5e8d"}}}},{"id":"b5fc053c-77f4-4445-b6df-2e744aef8f4f","name":"default_orchestration_2","description":"Created for Custom channel","active":true,"created":"2021-03-21T14:29:01.516Z","modified":"2021-03-28T14:29:01.516Z","applications":{"customerConfiguration":{"customer":{"id":"b09dddd6-394b-4039-86bc-a5dd89ee5e8d"}},"agentConfiguration":{"agents":[{"id":"c09dddd6-394b-4039-86bc-a5dd89ee5e8d"}]}}}]
Response
application/json
{ "orchestration": [ {}, {} ] }

Get Orchestration

Request

Overview

Use this API to Get orchestration details.

Scope

Client application must have 'app.conversation.conversationmgr.manage' or 'app.conversation.conversationmgr.read' scope assigned.

Security
oAuthClient(Required scopes:
https://api.egain.cloud/auth/.de...
)
Path
idstring= 36 charactersrequired

id of object

Example: 7b6c5fff-036e-4a40-b68a-a67c592fc079
curl -i -X GET \
  https://api.egain.cloud/conversation/conversationmgr/v3/orchestrations/7b6c5fff-036e-4a40-b68a-a67c592fc079 \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'

Responses

OK

Bodyapplication/json
idstring= 36 characters
createdstring(date-time)

Last modified time in GMT

modifiedstring(date-time)

Last modified time in GMT

namestring

Name for orchestration

Example: "default_orhchestration"
descriptionstring[ 1 .. 1023 ] characters
activeboolean
Default true
applicationsobject
Response
application/json
{ "id": "45a095f4-d0ee-4220-a689-22b541c58f67", "name": "default_orchestration", "description": "Created for custom channel.", "active": true, "created": "2021-03-21T14:29:01.516Z", "modified": "2021-03-28T14:29:01.516Z", "applications": { "botConfiguration": {}, "customerConfiguration": {} } }

Update Orchestration

Request

Overview

Use this API to update existing orchestration configuration.

Scope

Client application must have 'app.conversation.conversationmgr.manage' scope assigned.

Security
oAuthClient(Required scopes:
https://api.egain.cloud/auth/.de...
)
Path
idstring= 36 charactersrequired

id of object

Example: 7b6c5fff-036e-4a40-b68a-a67c592fc079
Bodyapplication/json

Update orchestration

namestringrequired

Name for orchestration

Example: "default_orhchestration"
descriptionstring[ 1 .. 1023 ] characters
activeboolean
Default true
applicationsobjectrequired
applications.​botConfigurationobject

Required if agentConfiguration is not provided

applications.​customerConfigurationobject

details of customer client app, this object must be specified for custom channels.

applications.​agentConfigurationobject

Details of agent client app. Required if botConfiguration is not provided.

modifiedstring(date-time)

Last modified time in GMT

curl -i -X PUT \
  https://api.egain.cloud/conversation/conversationmgr/v3/orchestrations/7b6c5fff-036e-4a40-b68a-a67c592fc079 \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "name": "default_orchestration",
    "description": "Created for custom channel.",
    "active": true,
    "modified": "2021-06-11T23:14:41.836Z",
    "applications": {
      "botConfiguration": {
        "forwardTranscript": true,
        "bots": [
          {
            "id": "a09dddd6-394b-4039-86bc-a5dd89ee5e8d",
            "participant": {
              "id": "b09dddd6-394b-4039-86bc-a5dd89ee5e8d"
            },
            "onEscalation": {
              "agent": {
                "id": "c09dddd6-394b-4039-86bc-a5dd89ee5e8d"
              }
            }
          }
        ]
      },
      "customerConfiguration": {
        "customer": {
          "id": "b09dddd6-394b-4039-86bc-a5dd89ee5e8d"
        }
      }
    }
  }'

Responses

No Content

Response
No content

Delete Orchestration

Request

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.

Security
oAuthClient(Required scopes:
https://api.egain.cloud/auth/.de...
)
Path
idstring= 36 charactersrequired

id of object

Example: 7b6c5fff-036e-4a40-b68a-a67c592fc079
curl -i -X DELETE \
  https://api.egain.cloud/conversation/conversationmgr/v3/orchestrations/7b6c5fff-036e-4a40-b68a-a67c592fc079 \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'

Responses

No Content

Response
No content

Account

Use this API to create the Conversation Account for Conversation Manager.

Operations

Conversation

Use this API to send messages through the Conversation Manager.

Operations

Assets

Use this API to upload/download Assets like attachments.

Operations