Webhook Payload

Below document will describe the details of a webhook message payload

Payload Fields

FieldTypeDescription

messageID

string

The message ID from server side.

localID

string

The message ID from client side.

type

integer

The message type.

typeName

string

The message type name.

body

string

The content of the message.

data

string

The actual data payload for custom message type, in JSON string.

filterID

string

The filter ID.

isHidden

boolean

If the message should be hidden.

quote

object

Quoted message.

title

string

The quoted message's title.

content

string

The quoted message's content.

imageURL

string

Quoted image URL, if any.

fileID

string

Quoted file ID, if any.

fileType

string

Quoted file type, if any.

replyTo

object

Info of the replied source message.

userID

string

User ID of the replied message's sender.

xcUserID

string

The user ID from customer's server.

fullname

string

Full name of the original message's sender.

messageID

string

The replied message ID.

localID

string

The replied message's local ID.

messageType

integer

The replied message type.

forwardFrom

object

Info of the forwarded source message.

userID

string

User ID of the original message's sender.

xcUserID

string

The user ID from customer's server.

fullname

string

Full name of the original message's sender.

messageID

string

The original message ID.

localID

string

The original message's local ID.

room

object

The room's details.

roomID

string

Room ID.

xcRoomID

string

The room ID from customer's server.

name

string

The room's name (chat partner's full name for personal chat, or group name for group chat).

type

integer

The room type.

imageURL

object

The room's picture image URL.

thumbnail

string

Image URL for thumbnail picture.

fullsize

string

Image URL for fullsize picture.

isLocked

boolean

If the room was locked.

lockedTime

long

The time the room was locked, in Unix milliseconds.

deleted

long

The room's deleted time, in Unix milliseconds.

isDeleted

boolean

If the room was deleted.

user

object

The sender user's profile.

userID

integer

The user ID.

xcUserID

string

The user ID from customer's server.

fullname

string

The user's full name.

imageURL

object

The user's picture image URL.

thumbnail

string

Image URL for thumbnail picture.

fullsize

string

Image URL for fullsize picture.

recipientID

string

The recipient's user ID or group ID, depending on the room type.

action

string

The action for system message.

target

object

The target of the action for system message.

targetType

string

The target type (e.g.: "user").

targetID

string

The target's ID (user ID for target type "user").

targetXCID

string

The target's XC ID.

targetName

string

The target's name.

isDelivered

boolean

If the message has been delivered to the recipient.

isRead

boolean

If the message has been read by the recipient.

isDeleted

boolean

If the message was deleted.

created

long

The message's created time.

updated

long

The message's last updated time.

deleted

long

The message's deleted time.

{
  "messageID": "130",
  "localID": "ee9fa71d70d6",
  "type": 1001,
  "typeName": "text",
  "body": "This is the body of the message",
  "data": "",
  "filterID": "",
  "isHidden": false,
  "quote": {
    "title": "",
    "content": "",
    "imageURL": "",
    "fileID": "",
    "fileType": ""
  },
  "replyTo": {
    "userID": "0",
    "xcUserID": "",
    "fullname": "",
    "messageID": "0",
    "localID": "",
    "messageType": 0
  },
  "forwardFrom": {
    "userID": "0",
    "xcUserID": "",
    "fullname": "",
    "messageID": "0",
    "localID": ""
  },
  "room": {
    "roomID": "2-7",
    "xcRoomID": "",
    "name": "Macy Sanderson, John Doe",
    "type": 1,
    "imageURL": {
      "thumbnail": "",
      "fullsize": ""
    },
    "isLocked": false,
    "lockedTime": 0,
    "deleted": 0,
    "isDeleted": false
  },
  "user": {
    "userID": 7,
    "xcUserID": "1",
    "fullname": "John Doe",
    "imageURL": {
      "thumbnail": "https://www.example.com/photos/thumb/thumbnail.jpg",
      "fullsize": "https://www.example.com/photos/full/fullsize.jpg"
    }
  },
  "recipientID": "2",
  "action": "",
  "target": {
    "targetType": "",
    "targetID": "0",
    "targetXCID": "",
    "targetName": ""
  },
  "isDelivered": false,
  "isRead": false,
  "isDeleted": false,
  "created": 1651067084218,
  "updated": 1651067084218,
  "deleted": 0
}

Last updated