Use this API to register client callback Authentication methods using oAuth or Basic Authentication.
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.
Register new account
Timeout for conversation created for this account. Time is calculated from last message in conversation. Client applications should start new conversation after timeout.
This attribute indicates action on agent unavailability, in case of 'off_hours' if agent is not available then 'off hours' message is sent back. In case of 'retain_and_retry' message is held on Conversation Hub until agent is online
Allow agents to logout with open messages in their inbox.
Allow agents to transfer messages back to queue when no agents are available.
- Production Serverhttps://api.egain.cloud/conversation/conversationmgr/v3/accounts
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
- Create account for BYOC channel
- Create account for Google Business Messaging channel
- Create account for Twilio SMS channel
- Create account for WhatsApp channel
curl -i -X POST \
https://api.egain.cloud/conversation/conversationmgr/v3/accounts \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
-H 'Content-Type: application/json' \
-d '{
"name": "order_account",
"address": "123456789",
"channel": {
"id": "45a095f4-d0ee-4220-a689-22b541c58f67"
},
"chatConfigurations": {
"timeout": 30,
"defaultLanguage": "en-US",
"onAgentUnavailability": "off_hours",
"allowLogoutWithOpenChats": false,
"allowQueueTransferOnAgentUnavailability": false,
"orchestration": {
"id": "c37e975f-6b2f-490f-9cac-dfa05499f744"
},
"entryPoint": {
"id": "1001"
}
}
}'{ "id": "45a095f4-d0ee-4220-a689-22b541c58f67" }
- Production Serverhttps://api.egain.cloud/conversation/conversationmgr/v3/accounts
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X GET \
https://api.egain.cloud/conversation/conversationmgr/v3/accounts \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>'OK
{ "account": [ { … }, { … } ] }
- Production Serverhttps://api.egain.cloud/conversation/conversationmgr/v3/accounts/{id}
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X GET \
https://api.egain.cloud/conversation/conversationmgr/v3/accounts/7b6c5fff-036e-4a40-b68a-a67c592fc079 \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>'OK
Timeout for conversation created for this account. Time is calculated from last message in conversation. Client applications should start new conversation after timeout.
This attribute indicates action on agent unavailability, in case of 'off_hours' if agent is not available then 'off hours' message is sent back. In case of 'retain_and_retry' message is held on Conversation Hub until agent is online
Allow agents to logout with open messages in their inbox.
Allow agents to transfer messages back to queue when no agents are available.
{ "id": "ae103957-9c82-4fa8-a34e-925be85e06ec", "created": "2021-03-21T14:29:01.516Z", "modified": "2021-03-28T14:29:01.516Z", "name": "order_account", "address": "123456789", "channel": { "id": "45a095f4-d0ee-4220-a689-22b541c58f67" }, "chatConfigurations": { "timeout": 30, "defaultLanguage": "en-US", "onAgentUnavailability": "off_hours", "orchestration": { … }, "entryPoint": { … } } }
Update account
Timeout for conversation created for this account. Time is calculated from last message in conversation. Client applications should start new conversation after timeout.
This attribute indicates action on agent unavailability, in case of 'off_hours' if agent is not available then 'off hours' message is sent back. In case of 'retain_and_retry' message is held on Conversation Hub until agent is online
Allow agents to logout with open messages in their inbox.
Allow agents to transfer messages back to queue when no agents are available.
- Production Serverhttps://api.egain.cloud/conversation/conversationmgr/v3/accounts/{id}
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X PUT \
https://api.egain.cloud/conversation/conversationmgr/v3/accounts/7b6c5fff-036e-4a40-b68a-a67c592fc079 \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
-H 'Content-Type: application/json' \
-d '{
"name": "order_account",
"address": "123456789",
"modified": "2021-03-28T14:29:01.516Z",
"channel": {
"id": "45a095f4-d0ee-4220-a689-22b541c58f67"
},
"chatConfigurations": {
"timeout": 30,
"defaultLanguage": "en-US",
"onAgentUnavailability": "off_hours",
"orchestration": {
"id": "c37e975f-6b2f-490f-9cac-dfa05499f744"
},
"entryPoint": {
"id": "1001"
}
}
}'- Production Serverhttps://api.egain.cloud/conversation/conversationmgr/v3/accounts/{id}
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X DELETE \
https://api.egain.cloud/conversation/conversationmgr/v3/accounts/7b6c5fff-036e-4a40-b68a-a67c592fc079 \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>'