File tree Expand file tree Collapse file tree 4 files changed +11
-7
lines changed Expand file tree Collapse file tree 4 files changed +11
-7
lines changed Original file line number Diff line number Diff line change 1
1
package keyboard
2
2
3
+ // ActionType 按钮操作类型
3
4
type ActionType uint32
5
+
6
+ // PermissionType 按钮的权限类型
4
7
type PermissionType uint32
5
8
6
9
const (
Original file line number Diff line number Diff line change @@ -4,11 +4,12 @@ import "github.com/tencent-connect/botgo/dto/keyboard"
4
4
5
5
// MessageToCreate 发送消息结构体定义
6
6
type MessageToCreate struct {
7
- Content string `json:"content,omitempty"`
8
- Embed * Embed `json:"embed,omitempty"`
9
- Ark * Ark `json:"ark,omitempty"`
10
- Image string `json:"image,omitempty"`
11
- MsgID string `json:"msg_id,omitempty"` // 要回复的消息id,为空是主动消息,公域机器人会异步审核,不为空是被动消息,公域机器人会校验语料
7
+ Content string `json:"content,omitempty"`
8
+ Embed * Embed `json:"embed,omitempty"`
9
+ Ark * Ark `json:"ark,omitempty"`
10
+ Image string `json:"image,omitempty"`
11
+ // 要回复的消息id,为空是主动消息,公域机器人会异步审核,不为空是被动消息,公域机器人会校验语料
12
+ MsgID string `json:"msg_id,omitempty"`
12
13
MessageReference * MessageReference `json:"message_reference,omitempty"`
13
14
Markdown * Markdown `json:"markdown,omitempty"`
14
15
Keyboard * keyboard.MessageKeyboard `json:"keyboard,omitempty"` // 消息按钮组件
Original file line number Diff line number Diff line change @@ -18,7 +18,7 @@ const maxRespBuffer = 65535
18
18
19
19
// Config 搜索请求配置
20
20
type Config struct {
21
- AppID uint64
21
+ AppID string
22
22
EndPoint string // 回调url地址
23
23
Secret string
24
24
}
Original file line number Diff line number Diff line change 9
9
func TestSimulateSearch (t * testing.T ) {
10
10
got , err := SimulateSearch (
11
11
& Config {
12
- AppID : 1 ,
12
+ AppID : "1" ,
13
13
EndPoint : "https://www.qq.com" ,
14
14
Secret : "a" ,
15
15
}, "hello" ,
You can’t perform that action at this time.
0 commit comments