namespace IM.Commons.IntegrationEvents
{
public class MsgCreatedEvent
{
public Guid Id { get; set; }
public Guid ClientId { get; set; }
public string ChatType { get; set; }
///
/// 消息类型
/// (0:文本,1:图片,2:语音,3:视频,4:文件,5:语音聊天,6:视频聊天)
///
public string MsgType { get; set; }
///
/// 发送者
///
public Guid SenderId { get; set; }
///
/// 接收者(私聊为用户ID,群聊为群聊ID)
///
public Guid TargetId { get; set; }
///
/// 消息状态(0:已发送,1:已撤回)
///
public string State { get; set; }
///
/// 消息推送唯一标识符
///
public string StreamKey { get; set; }
///
/// 消息排序标识
///
public long SequenceId { get; set; }
public MsgContent Content { get; set; }
}
public record MsgContent(string Fallback, object Body, Dictionary Ext, QuoteInfoDto Quote);
public record QuoteInfoDto(Guid MessageId, Guid SenderId, string SenderName, string MessageType, string Preview);
}