JsonDataMessage

data class JsonDataMessage(timestamp: Long?, attachments: List<JsonAttachment>, body: String?, group: JsonGroupInfo?, groupV2: JsonGroupV2Info?, endSession: Boolean?, expiresInSeconds: Int?, profileKeyUpdate: Boolean?, quote: JsonQuote?, contacts: List<SharedContact>, previews: List<JsonPreview>, sticker: JsonSticker?, viewOnce: Boolean?, reaction: JsonReaction?, remoteDelete: RemoteDelete?, mentions: List<JsonMention>, payment: Payment?, isExpirationUpdate: Boolean?, groupCallUpdate: String?, storyContext: StoryContext?)

Properties

Link copied to clipboard
val attachments: List<JsonAttachment>

files attached to the incoming message

Link copied to clipboard
val body: String? = null

the text body of the incoming message.

Link copied to clipboard
val contacts: List<SharedContact>

if the incoming message has a shared contact, the contact's information will be here

Link copied to clipboard
val endSession: Boolean? = null
Link copied to clipboard
val expiresInSeconds: Int? = null

the expiry timer on the incoming message. Clients should delete records of the message within this number of seconds

Link copied to clipboard
val group: JsonGroupInfo? = null

if the incoming message was sent to a v1 group, information about that group will be here

Link copied to clipboard
val groupCallUpdate: String? = null

the eraId string from a group call message update

Link copied to clipboard
val groupV2: JsonGroupV2Info? = null

if the incoming message was sent to a v2 group, basic identifying information about that group will be here. If group information changes, JsonGroupV2Info.revision is incremented. If the group revision is higher than previously seen, a client can retrieve the group information by calling get_group.

Link copied to clipboard
val isExpirationUpdate: Boolean? = null

whether or not this message changes the expiresInSeconds value for the whole chat. Some messages (remote deletes, reactions, etc) will have expiresInSeconds=0 even though the chat has disappearing messages enabled.

Link copied to clipboard
val mentions: List<JsonMention>

list of mentions in the message

Link copied to clipboard
val payment: Payment? = null

details about the MobileCoin payment attached to the message, if present

Link copied to clipboard
val previews: List<JsonPreview>

if the incoming message has a link preview, information about that preview will be here

Link copied to clipboard
val profileKeyUpdate: Boolean? = null
Link copied to clipboard
val quote: JsonQuote? = null

if the incoming message is a quote or reply to another message, this will contain information about that message

Link copied to clipboard
val reaction: JsonReaction? = null

if the message adds or removes a reaction to another message, this will indicate what change is being made

Link copied to clipboard
val remoteDelete: RemoteDelete? = null

if the inbound message is deleting a previously sent message, indicates which message should be deleted

Link copied to clipboard
val sticker: JsonSticker? = null

if the incoming message is a sticker, information about the sicker will be here

Link copied to clipboard
val storyContext: StoryContext? = null
Link copied to clipboard
val timestamp: Long? = null

the timestamp that the message was sent at, according to the sender's device. This is used to uniquely identify this message for things like reactions and quotes.

Link copied to clipboard
val viewOnce: Boolean? = null

indicates the message is a view once message. View once messages typically include no body and a single image attachment. Official Signal clients will prevent the user from saving the image, and once the user has viewed the image once they will destroy the image.