|
@@ -45,14 +45,14 @@ type AuthEvent struct {
|
45
|
45
|
InfoType string `xml:"InfoType"`
|
46
|
46
|
}
|
47
|
47
|
|
48
|
|
-// ComponentVerifyTicket 令牌授权事件
|
49
|
|
-type ComponentVerifyTicket struct {
|
|
48
|
+// ComponentVerifyTicketEvent 令牌授权事件
|
|
49
|
+type ComponentVerifyTicketEvent struct {
|
50
|
50
|
AuthEvent
|
51
|
51
|
ComponentVerifyTicket string `xml:"ComponentVerifyTicket"`
|
52
|
52
|
}
|
53
|
53
|
|
54
|
|
-// Authorized 授权成功, 与更新授权字段属性一致
|
55
|
|
-type Authorized struct {
|
|
54
|
+// AuthorizedEvent 授权成功, 与更新授权字段属性一致
|
|
55
|
+type AuthorizedEvent struct {
|
56
|
56
|
AuthEvent
|
57
|
57
|
AuthorizerAppID string `xml:"AuthorizerAppid"`
|
58
|
58
|
AuthorizationCode string `xml:"AuthorizationCode"`
|
|
@@ -60,8 +60,8 @@ type Authorized struct {
|
60
|
60
|
PreAuthCode string `xml:"PreAuthCode"`
|
61
|
61
|
}
|
62
|
62
|
|
63
|
|
-// Unauthorized 取消授权
|
64
|
|
-type Unauthorized struct {
|
|
63
|
+// UnauthorizedEvent 取消授权
|
|
64
|
+type UnauthorizedEvent struct {
|
65
|
65
|
AuthEvent
|
66
|
66
|
AuthorizerAppID string `xml:"AuthorizerAppid"`
|
67
|
67
|
}
|
|
@@ -74,4 +74,57 @@ type AuthorizerEvent struct {
|
74
|
74
|
CreateTime int64 `xml:"CreateTime"`
|
75
|
75
|
MsgType CDATA `xml:"MsgType"`
|
76
|
76
|
Event CDATA `xml:"Event"`
|
|
77
|
+ MsgID int64 `xml:"MsgId"`
|
|
78
|
+}
|
|
79
|
+
|
|
80
|
+// TextEvent 文本消息
|
|
81
|
+type TextEvent struct {
|
|
82
|
+ AuthorizerEvent
|
|
83
|
+ Content CDATA `xml:"Content"`
|
|
84
|
+}
|
|
85
|
+
|
|
86
|
+// ImageEvent 图片消息
|
|
87
|
+type ImageEvent struct {
|
|
88
|
+ AuthorizerEvent
|
|
89
|
+ PicURL CDATA `xml:"PicUrl"`
|
|
90
|
+ MediaID CDATA `xml:"MediaId"`
|
|
91
|
+}
|
|
92
|
+
|
|
93
|
+// VoiceEvent 语音消息
|
|
94
|
+type VoiceEvent struct {
|
|
95
|
+ AuthorizerEvent
|
|
96
|
+ MediaID CDATA `xml:"MediaId"`
|
|
97
|
+ Format CDATA `xml:"Format"`
|
|
98
|
+ Recognition CDATA `xml:"Recognition"`
|
|
99
|
+}
|
|
100
|
+
|
|
101
|
+// VideoEvent 视频消息
|
|
102
|
+type VideoEvent struct {
|
|
103
|
+ AuthorizerEvent
|
|
104
|
+ MediaID CDATA `xml:"MediaId"`
|
|
105
|
+ ThumbMediaID CDATA `xml:"ThumbMediaId"`
|
|
106
|
+}
|
|
107
|
+
|
|
108
|
+// ShortVideoEvent 小视频消息
|
|
109
|
+type ShortVideoEvent struct {
|
|
110
|
+ AuthorizerEvent
|
|
111
|
+ MediaID CDATA `xml:"MediaId"`
|
|
112
|
+ ThumbMediaID CDATA `xml:"ThumbMediaId"`
|
|
113
|
+}
|
|
114
|
+
|
|
115
|
+// LocationEvent 地理位置消息
|
|
116
|
+type LocationEvent struct {
|
|
117
|
+ AuthorizerEvent
|
|
118
|
+ LocationX float64 `xml:"Location_X"`
|
|
119
|
+ LocationY float64 `xml:"Location_Y"`
|
|
120
|
+ Scale int `xml:"Scale"`
|
|
121
|
+ Label CDATA `xml:"Label"`
|
|
122
|
+}
|
|
123
|
+
|
|
124
|
+// LinkEvent 链接消息
|
|
125
|
+type LinkEvent struct {
|
|
126
|
+ AuthorizerEvent
|
|
127
|
+ Title CDATA `xml:"Title"`
|
|
128
|
+ Description CDATA `xml:"Description"`
|
|
129
|
+ URL CDATA `xml:"Url"`
|
77
|
130
|
}
|