Skip to content
Last updated

Webhook payloads

Every type of outbound webhook can contain different information according to the domain event that generated it, but all webhook types will adhere to the same general structure.

General webhook payload structure

FieldTypeDescription
event_idUUID stringid of the event
event_fqnstringfully qualified name of the event (uppercase words separated by underscore, i.e. CONVERSATION_MESSAGE_ADDED)
event_versionstringversion of the event
event_timestamptimestamptime when the event was emitted
organizationOrganization objectorganization that owns the event
dataData objecttype specific payload of the event

Data

Each type of webhook you can configure through the UI will have a different structure that contains information from the specific domain event that generated it. The type-specific structure will be as follows.

Created

A conversation is created inside Dixa

FieldTypeDescription
conversationConversation objectconversation associated with the event

Open

A conversation is reopened (after it was closed).

FieldTypeDescription
conversationConversation objectconversation associated with the event

Pending

A follow-up is added to a conversation, placing the conversation in pending status.

FieldTypeDescription
conversationConversation objectconversation associated with the event

Pending expired

A follow-up added to the conversation has expired.

FieldTypeDescription
conversationConversation objectconversation associated with the event
pendingByUseroptional User objectagent who placed the conversation in pending state

Closed

A conversation IS closed.

FieldTypeDescription
conversationConversation objectconversation associated with the event

Abandoned

A conversation is closed without an agent being assigned to it.

FieldTypeDescription
conversationConversation objectconversation associated with the event
queueQueue objectqueue of the conversation

Enqueued

A conversation enters a queue in Dixa.

FieldTypeDescription
conversationConversation objectconversation associated with the event

Assigned

A conversation gets assigned to an agent.

FieldTypeDescription
conversationConversation objectconversation associated with the event

Unassigned

A conversation gets unassigned from an agent.

FieldTypeDescription
conversationConversation objectconversation associated with the event
agentUser objectagent who was unassigned from this conversation

Note added

An internal note is added to a conversation.

FieldTypeDescription
conversationConversation objectconversation associated with the event
note_idUUID stringid of the note
textoptional stringtext content of the note
created_attimestamptime when the note was created
authorUser objectagent who added the note

Message added

A message is added to the conversation.

FieldTypeDescription
conversationConversation objectconversation associated with the event
authorUser objectuser who authored the message
created_attimestamptime when the message was created
message_idUUID stringid of the message
textoptional stringtext content of the message
directionstringdirection of the message (inbound / outbound)1
channelstringchannel of the conversation (uppercase channel name, i.e. EMAIL)
contentContent objectmessage content
attachmentsoptional array of Attachment objectsmessage attachments
external_idoptional stringid of the message in a third party system

Tag added

A tag is added to a conversation.

FieldTypeDescription
conversationConversationconversation associated with the event
tagstringname of the tag
authorUser objectagent who added the tag

Tag removed

A tag is removed from a conversation.

FieldTypeDescription
conversationConversation objectconversation associated with the event
tagstringname of the tag
authorUser objectagent who removed the tag

Rated

A conversation was rated by an enduser.

FieldTypeDescription
conversationConversation objectconversation associated with the event
agentUser objectagent assigned to the conversation
userUser objectuser who rated the conversation
scoreintegerrating score
commentoptional stringuser comment
typestringtype of rating

Transferred to Agent

A conversation is transferred to an agent.

FieldTypeDescription
conversationConversation objectconversation associated with the event
transfer_idUUID stringid of the transfer
initiatorUser objectagent who initiated the transfer
typestringtype of transfer (BLIND, ASSISTED)
statusstringstatus of the transfer
destinationoptional User objecttarget agent for the transfer
destination_typeStringtype of transfer target

Transferred to Queue

A conversation is transferred to a queue.

FieldTypeDescription
conversationConversation objectconversation associated with the event
transfer_idUUID stringid of the transfer
initiatorUser objectagent who initiated the transfer
typestringtype of transfer (BLIND, ASSISTED)
statusstringstatus of the transfer
destinationoptional Queue objecttarget queue for the transfer
destination_typeStringtype of transfer target

Banned enduser

An enduser is banned.

FieldTypeDescription
agentUser objectagent who banned the enduser
userUser objectenduser who was banned
reasonoptional stringreason for banning the enduser
channelsarray of stringchannels from which enduser was banned (WIDGET_CHAT only)

Unbanned enduser

An enduser ban is removed.

FieldTypeDescription
agentUser objectagent who unbanned the enduser
userUser objectenduser who was unbanned
reasonoptional stringreason for unbanning the enduser
channelsarray of stringchannels from which enduser was unbanned (WIDGET_CHAT only)

Banned ip

An ip address is banned.

FieldTypeDescription
agentUser objectagent who banned the ip address
ip_addressstringbanned ip address
csidintegerid of the conversation
reasonoptional stringreason for banning the ip address

Unbanned ip

An ip address ban is removed.

FieldTypeDescription
agentUser objectagent who unbanned the ip address
ip_addressstringunbanned ip address
csidintegerid of the conversation
reasonoptional stringreason for unbanning the ip address

End user replaced

The enduser for this conversation is updated as a result of a contact merge or because an anonymous contact was identified.

FieldTypeDescription
conversationConversation objectconversation associated with the event
authorUser objectagent who replaced the enduser
old_userUser objectprevious enduser
new_userUser objectcurrent enduser
reasonstringreason for replacing the enduser

Custom Attribute Updated

Custom attributes of a conversation are updated.

FieldTypeDescription
conversationConversation objectconversation associated with the event
updated_attributesarray of CustomAttributelist of updated custom attributes with new values
authorUser objectagent who updated the custom attributes

Typing started

The agent is typing a message to the end user in Dixa's conversation view. The intention is to use the webhook to indicate agent activity to an end user.

FieldTypeDescription
conversationConversation objectconversation associated with the event
started_by_user_idstringagent's id who started typing

Payload objects

The type-specific event payloads can contain fields that are objects related to the event, such as an Organization, a User or a Conversation. The structure of these objects is as follows.

Organization

FieldTypeDescription
idUUID stringid of the organization
namestringname of the organization

Conversation

FieldTypeDescription
csidUUID stringid of the conversation
channelstringchannel of the conversation (uppercase channel name, i.e. EMAIL)
statusstringstatus of the conversation (OPEN / CLOSED / PENDING / AWAITING_PENDING)
directionstringdirection of the conversation (INBOUND / OUTBOUND)1
queueoptional Queue objectqueue of the conversation
contact_pointoptional stringcontact point of the organization
requesterUser objectenduser who requested the conversation
assigneeoptional User objectagent assigned to the conversation
subjectoptional stringsubject of the conversation
tagsarray of stringconversation tags
custom_attributesarray of CustomAttributecustom attributes associated with the conversation
created_attimestamptime the conversation was created

Queue

FieldTypeDescription
idUUID stringid of the queue
namestringname of the queue

User

FieldTypeDescription
idUUID stringid of the user
nameoptional stringname of the user
emailoptional stringemail of the user
phoneoptional stringphone number of the user
user_typestringone of Contact (end user), Member (agent/admin) or Bot
roles - deprecated, see user_typearray of stringuser role/s
additional_emailsoptional array of stringadditional email addresses
additional_phone_numbersoptional array of stringadditional e164 format phone numbers

Content

FieldTypeDescription
textoptional stringtext content of the message
content_typestringtype of the content(text, html)
original_content_urlstringurl of the original message content
processed_content_urlstringurl of the processed message content

CustomAttribute

Custom attributes can be of different types, each with their own value structure.

Common Fields (for all attribute types)

FieldTypeRequiredDescription
typestringYesType of the attribute. One of: string, string_list
labelstringNoHuman-readable label for the attribute
valueSee belowYesThe attribute's value (structure depends on the attribute type)

String Attribute

FieldTypeRequiredDescriptionExample
typestringYesMust be stringstring
valuestringYesThe string value"text value"

String List Attribute

FieldTypeRequiredDescriptionExample
typestringYesMust be string_liststring_list
valuearrayYesArray of strings["list", "of", "strings"]

Attachment

FieldTypeDescription
urlstringurl of the attachment
pretty_namestringshort name of the attachment

1 Be aware that the value of the direction field are lower case in the message payload, and upper case in the conversation payload.