Create a conversation. For inbound messages the author is assumed to be the requester of the conversation (end user). For outbound messages the author is specified using the agentId field.
- Import conversation
Dixa API (beta)
- Mock serverhttps://docs.dixa.io/_mock/openapi/dixa-api/beta/beta/conversations
- https://dev.dixa.io/beta/conversations
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X POST \
https://docs.dixa.io/_mock/openapi/dixa-api/beta/beta/conversations \
-H 'Authorization: YOUR_API_KEY_HERE' \
-H 'Content-Type: application/json' \
-d '{
"requesterId": "9c2a2cce-699f-4a72-89d9-fda5bc8dec8b",
"emailIntegrationId": "my-integration@email.dixa.io",
"subject": "order #123",
"message": {
"content": {
"value": "My order hasn'\''t shipped",
"_type": "Text"
},
"attachments": [],
"_type": "Inbound"
},
"language": "en",
"_type": "Email"
}'{ "data": { "id": 100 } }
Request
Import a previously created conversation into Dixa. For inbound messages the author is assumed to be the requester of the conversation (end user), unless the specific channel supports overriding the message author through its attributes. For outbound messages the author is specified using the agentId field.
The type of conversation to import
- Mock serverhttps://docs.dixa.io/_mock/openapi/dixa-api/beta/beta/conversations/import
- https://dev.dixa.io/beta/conversations/import
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X POST \
https://docs.dixa.io/_mock/openapi/dixa-api/beta/beta/conversations/import \
-H 'Authorization: YOUR_API_KEY_HERE' \
-H 'Content-Type: application/json' \
-d '{
"genericChannelName": "MyCustomChat",
"requesterId": "9c2a2cce-699f-4a72-89d9-fda5bc8dec8b",
"requesterConnectionStatus": "Connected",
"direction": "Inbound",
"messages": [
{
"content": {
"value": "My order hasn'\''t shipped",
"_type": "Text"
},
"attachments": [],
"createdAt": "2021-12-01T13:00:00.003Z",
"_type": "InboundImport"
},
{
"content": {
"value": "Our bad, sorry",
"_type": "Text"
},
"agentId": "cd4ceb58-bb3a-443c-9cd8-4f088feafe5b",
"attachments": [
{
"url": "https://en.wikipedia.org/wiki/Shipwreck#/media/File:Titanic_wreck_bow.jpg",
"prettyName": "shipwreck"
}
],
"createdAt": "2021-12-01T14:00:00.004Z",
"_type": "OutboundImport"
}
],
"createdAt": "2021-12-01T11:00:00.001Z",
"assignment": {
"agentId": "cd4ceb58-bb3a-443c-9cd8-4f088feafe5b",
"assignedAt": "2021-12-01T12:00:00.002Z"
},
"closing": {
"closedAt": "2021-12-01T15:00:00.005Z",
"closedBy": "cd4ceb58-bb3a-443c-9cd8-4f088feafe5b"
},
"_type": "GenericConversationImport"
}'{ "data": { "id": 100, "partialErrors": [ … ] } }
The custom attributes of an conversation to be patched. This should map the custom attribute id to the desired attribute value. Format: Map[UUID, Option[AttributeValue].
AttributeValue values: String[] if the type of the custom attribute is Select or String if the type of the custom attribute is Text
AttributeValue values: String[] if the type of the custom attribute is Select or String if the type of the custom attribute is Text
- Mock serverhttps://docs.dixa.io/_mock/openapi/dixa-api/beta/beta/conversations/{conversationId}/custom-attributes
- https://dev.dixa.io/beta/conversations/{conversationId}/custom-attributes
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X PATCH \
'https://docs.dixa.io/_mock/openapi/dixa-api/beta/beta/conversations/{conversationId}/custom-attributes' \
-H 'Authorization: YOUR_API_KEY_HERE' \
-H 'Content-Type: application/json' \
-d '{
"2f5515b6-7e98-4f4d-9010-bfd2a27d4f35": "012345",
"e14708a6-eed9-495c-9d88-c72331e9e247": [
"str1",
"str2"
]
}'{ "data": [ { … }, { … } ] }