Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BaseResponse ¶
type CreateMessageRequest ¶ added in v0.0.13
type CreateMessageRequest struct {
MessageType int `json:"type"` // 否 POST 消息类型, 见[type], 不传默认为 9, 代表kmarkdown。 9 代表 kmarkdown 消息, 10 代表卡片消息。
TargetId string `json:"target_id"` // 是 POST 目标频道 id
Content string `json:"content"` // 是 POST 消息内容
Quote string `json:"quote,omitempty"` // 否 POST 回复某条消息的 msgId
Nonce string `json:"nonce,omitempty"` // 否 POST nonce, 服务端不做处理, 原样返回
TempTargetId string `json:"temp_target_id,omitempty"` // 否 POST 用户 id,如果传了,代表该消息是临时消息,该消息不会存数据库,但是会在频道内只给该用户推送临时消息。用于在频道内针对用户的操作进行单独的回应通知等。
TemplateId string `json:"template_id,omitempty"` // 否 POST 模板消息id, 如果使用了,content会作为模板消息的input,参见模板消息
ReplyMsgId string `json:"reply_msg_id,omitempty"` // 否 POST 当前消息回复的用户5分钟内发送到相同频道的消息的msg_id,如果是当前开发者的第一次回复,扣减当日发送量按n分之一条计算
}
type CreateMessageResp ¶ added in v0.0.13
type ViewChannelOption ¶ added in v0.0.13
type ViewChannelOption struct {
NeedChildren bool
}
type ViewChannelResp ¶ added in v0.0.13
type ViewChannelResp struct {
Id string `json:"id,omitempty"` // 频道 id
GuildId string `json:"guild_id,omitempty"` // 服务器 id
UserId string `json:"user_id,omitempty"` // 频道创建者 id
ParentId string `json:"parent_id,omitempty"` // 父分组频道 id
Name string `json:"name,omitempty"` // 频道名称
Topic string `json:"topic,omitempty"` // 频道简介
ChannelType int `json:"type,omitempty"` // 频道类型,0 分组,1 文字,2 语音
Level int `json:"level,omitempty"` // 频道排序
SlowMode int `json:"slow_mode,omitempty"` // 慢速限制,用户发送消息之后再次发送消息的等待时间,单位秒
HasPassword bool `json:"has_password,omitempty"` // 是否已设置密码
LimitAmount int `json:"limit_amount,omitempty"` // 人数限制
IsCategory bool `json:"is_category,omitempty"` // 是否为分组类型
PermissionSync int `json:"permission_sync,omitempty"` // 是否与分组频道同步权限
// PermissionOverwrites array `json:"permission_overwrites,omitempty"` // 针对角色的频道权限覆盖
// PermissionUsers array `json:"permission_users,omitempty"` // 针对用户的频道权限覆盖
VoiceQuality string `json:"voice_quality,omitempty"` // 语音频道质量级别,1 流畅,2 正常,3 高质量
ServerUrl string `json:"server_url,omitempty"` // 语音服务器地址,HOST:PORT/PATH 的格式
Children []string `json:"children,omitempty"` // 子频道的 id 列表
}
Click to show internal directories.
Click to hide internal directories.