txim/callback/message.go

22 lines
1.5 KiB
Go
Raw Normal View History

package callback
// MessageCallbackData 单聊消息回调数据
type MessageCallbackData struct {
MsgBody []TIMMessage `json:"MsgBody"` // 消息体
CallbackCommand string `json:"CallbackCommand"` // 回调命令
FromAccount string `json:"From_Account"` // 发送者帐号
ToAccount string `json:"To_Account"` // 接收者帐号
MsgRandom int `json:"MsgRandom"` // 消息随机数
MsgSeq int `json:"MsgSeq"` // 消息序列号
MsgTime int `json:"MsgTime"` // 消息的发送时间戳,单位为秒
MsgKey string `json:"MsgKey"` //消息的唯一标识,可用于 REST API 撤回单聊消息
OnlineOnlyFlag int `json:"OnlineOnlyFlag"` //在线消息为1否则为0
2022-01-12 14:25:36 +08:00
CloudCustomData string `json:"CloudCustomData"` // 消息自定义数据(云端保存,会发送到对端,程序卸载重装后还能拉取到)
SendMsgResult int `json:"SendMsgResult"` // 消息发送之后独有
ErrorInfo string `json:"ErrorInfo"` // 消息发送之后独有
2022-10-18 15:48:57 +08:00
UnreadMsgNum int `json:"UnreadMsgNum"` // 消息发送之后、已读回调、撤回消息共有
ReportAccount string `json:"Report_Account"` // 已读回调独有
PeerAccount string `json:"Peer_Account"` // 已读回调独有
LastReadTime int `json:"LastReadTime"` // 已读回调独有
}