model

package
v0.1.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 18, 2022 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Private = 0
	Group   = 1
)
View Source
const (
	Android = "Android"
	IOS     = "IOS"
	Windows = "Windows"
	Linux   = "Linux"
	MacOS   = "MacOS"
)

Variables

View Source
var (
	ErrPermission = errors.New("权限不足")
)

Functions

This section is empty.

Types

type AddressLoginNotAllowedErr

type AddressLoginNotAllowedErr struct {
	UUid       string `json:"uuid"`
	Device     int32  `json:"device"`
	DeviceName string `json:"deviceName"`
	Datetime   uint64 `json:"datetime"`
}

type AddressLoginReq

type AddressLoginReq struct {
	ConnType int32 `json:"connType" example:"0"`
}

type AddressLoginResp

type AddressLoginResp struct {
	// 用户地址
	Address string `json:"address" example:"123"`
}

用户地址登录请求结果

type FocusMsgReq

type FocusMsgReq struct {
	Type  int   `json:"type" enums:"0,1"`
	LogId int64 `json:"logId" binding:"required"`
}

type GeneralResponse

type GeneralResponse struct {
	Result  int         `json:"result"`
	Message string      `json:"message"`
	Data    interface{} `json:"data"`
}

type GetModuleResp

type GetModuleResp struct {
	Name      string   `json:"name" enums:"wallet,oa,redpacket"`
	IsEnabled bool     `json:"isEnabled"`
	EndPoints []string `json:"endPoints"`
}

type GetPriRecordsReq

type GetPriRecordsReq struct {
	// 发送者 ID
	FromId string `json:"-"`

	// 接受者 ID
	TargetId string `json:"targetId" binding:"required"`
	// 消息数量
	RecordCount int64 `json:"count" binding:"required,min=1,max=100"`
	// 消息 ID
	Mid string `json:"logId"`
}

type GetPriRecordsResp

type GetPriRecordsResp struct {
	// 聊天记录数量
	RecordCount int `json:"record_count"`
	// 聊天记录
	Records []*Record `json:"records"`
}

type Record

type Record struct {
	// log id
	Mid string `json:"logId"`
	// msg id (uuid)
	Seq string `json:"msgId"`
	// 发送者 id
	FromId string `json:"fromId"`
	// 接收者 id
	TargetId string `json:"targetId"`
	// 消息类型
	MsgType int32 `json:"msgType"`
	// 消息内容
	Content interface{} `json:"content"`
	// 消息发送时间
	CreateTime uint64 `json:"createTime"`
}

type RevokeMsgReq

type RevokeMsgReq struct {
	Type int   `json:"type" enums:"0,1"`
	Mid  int64 `json:"logId" binding:"required"`
}

type SyncRecordsReq

type SyncRecordsReq struct {
	// 消息数量
	MaxCount int64 `json:"count" binding:"required,min=1,max=1000"`
	// 消息 ID
	StartMid int64 `json:"start"`
}

type SyncRecordsResp

type SyncRecordsResp struct {
	// 聊天记录数量
	RecordCount int `json:"record_count"`
	// 聊天记录 base64 encoding
	Records []string `json:"records"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL