Documentation ¶
Index ¶
- Constants
- func GetPush(config conf.Config) func(id string, kind string, message string)
- func HandleWechat(rep http.ResponseWriter, req *http.Request)
- func InitPushDeer() func(id, kind, message string)
- func MarkDown(title, text string, ats ...string) map[string]interface{}
- func RegisterHandler(key string, action WechatHandler)
- func Text(text string, ats ...string) map[string]interface{}
- func TgInit()
- type Ding
- type Event
- type Files
- type Handle
- type Mather
- type MessageIds
- type PushPlus
- type QQ
- type Senders
- type Status
- type Telegram
- type TypeSecret
- type WechatHandler
Constants ¶
View Source
const ( StartStudy = "start_study" SCORE = "score" )
Variables ¶
This section is empty.
Functions ¶
func HandleWechat ¶
func HandleWechat(rep http.ResponseWriter, req *http.Request)
HandleWechat
@Description:处理wechat的请求接口 * @param rep * @param req
func InitPushDeer ¶
func InitPushDeer() func(id, kind, message string)
func RegisterHandler ¶
func RegisterHandler(key string, action WechatHandler)
Types ¶
type Event ¶
type Event struct { Anonymous anonymous `json:"anonymous"` Font int `json:"font"` GroupId int64 `json:"group_id"` Message string `json:"message"` MessageType string `json:"message_type"` PostType string `json:"post_type"` RawMessage string `json:"raw_message"` SelfId int64 `json:"self_id"` Sender Senders `json:"sender"` SubType string `json:"sub_type"` UserId int64 `json:"user_id"` Time int `json:"time"` NoticeType string `json:"notice_type"` RequestType string `json:"request_type"` Comment string `json:"comment"` Flag string `json:"flag"` OperatorID int `json:"operator_id"` File Files `json:"file"` Duration int64 `json:"duration"` TargetId int64 `json:"target_id"` // 运气王id HonorType string `json:"honor_type"` MetaEventType string `json:"meta_event_type"` Status Status `json:"status"` Interval int `json:"interval"` CardNew string `json:"card_new"` // 新名片 CardOld string `json:"card_old"` // 旧名片 MessageIds GuildID int64 `json:"guild_id"` ChannelID int64 `json:"channel_id"` // contains filtered or unexported fields }
Event
- 事件 *
type MessageIds ¶
type MessageIds struct {
MessageID int32 `json:"message_id"`
}
type Status ¶
type Status struct { AppEnabled bool `json:"app_enabled"` AppGood bool `json:"app_good"` AppInitialized bool `json:"app_initialized"` Good bool `json:"good"` Online bool `json:"online"` PluginsGood interface{} `json:"plugins_good"` Stat struct { PacketReceived int `json:"packet_received"` PacketSent int `json:"packet_sent"` PacketLost int `json:"packet_lost"` MessageReceived int `json:"message_received"` MessageSent int `json:"message_sent"` DisconnectTimes int `json:"disconnect_times"` LostTimes int `json:"lost_times"` LastMessageTime int `json:"last_message_time"` } `json:"stat"` }
type Telegram ¶
type Telegram struct { Token string ChatId int64 Proxy string // contains filtered or unexported fields }
Telegram @Description:
type TypeSecret ¶
func (*TypeSecret) SendMessage ¶
func (t *TypeSecret) SendMessage(data map[string]interface{}) error
SendMessage Function to send message
type WechatHandler ¶
Click to show internal directories.
Click to hide internal directories.