wx

package
v0.0.0-...-0e6b51b Latest Latest
Warning

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

Go to latest
Published: May 11, 2020 License: MIT Imports: 23 Imported by: 0

Documentation

Index

Constants

View Source
const ERROR_BODY = 0x0003
View Source
const ERROR_CONFIG = 0x0002
View Source
const ERROR_FORM_ID = 0x0007
View Source
const ERROR_MESSAGE_TYPE = 0x0004
View Source
const ERROR_NOT_FOUND = 0x0001
View Source
const ERROR_QR = 0x0006
View Source
const ERROR_SIGN = 0x0005
View Source
const MessageType_Image = "image"
View Source
const MessageType_Link = "link"
View Source
const MessageType_Miniprogrampage = "miniprogrampage"
View Source
const MessageType_Mpnews = "mpnews"
View Source
const MessageType_Msgmenu = "msgmenu"
View Source
const MessageType_Music = "music"
View Source
const MessageType_News = "news"
View Source
const MessageType_Subscribe_Template = "subscribe_template"
View Source
const MessageType_Template = "template"
View Source
const MessageType_Text = "text"
View Source
const MessageType_TransferCustomerService = "transfer_customer_service"
View Source
const MessageType_Video = "video"
View Source
const MessageType_Voice = "voice"
View Source
const MessageType_Wxcard = "wxcard"
View Source
const OpenMPAuthType_App = 2
View Source
const OpenMPAuthType_MP = 1
View Source
const OpenMPAuthType_MP_APP = 3
View Source
const OpenMPOpenType_WX = 1
View Source
const OpenMPOpenType_Web = 2
View Source
const Scope_BASE = "snsapi_base"
View Source
const Scope_USERINFO = "snsapi_userinfo"
View Source
const TicketType_Card = "wx-card"
View Source
const TicketType_Jsapi = "jsapi"
View Source
const UserState_Subscribe = 0
View Source
const UserState_UnSubscribe = 1
View Source
const UserType_APP = 1
View Source
const UserType_MP = 0

Variables

This section is empty.

Functions

func MP_AppDecrypt

func MP_AppDecrypt(app micro.IContext, sessionKey string, encryptedData string, iv string) ([]byte, error)

func MP_GetAccessToken

func MP_GetAccessToken(app micro.IContext, userType int32, appid string, forceUpdate bool) (string, error)

func MP_GetSecret

func MP_GetSecret(mp interface{}, appid string) (string, error)

func MP_GetTicket

func MP_GetTicket(app micro.IContext, appid string, ticketType string) (string, error)

func MP_NewNonceStr

func MP_NewNonceStr() string

func MP_Open_GetAccessToken

func MP_Open_GetAccessToken(app micro.IContext, appid string) (string, error)

func MP_Open_GetTicket

func MP_Open_GetTicket(app micro.IContext) (string, error)

func MP_Send

func MP_Send(app micro.IContext, mp interface{}, method string, u string, data interface{}) (interface{}, error)

func MP_SendWithType

func MP_SendWithType(app micro.IContext, mp interface{}, method string, u string, data interface{}, dataType string) (interface{}, error)

func MP_UpdateUser

func MP_UpdateUser(app micro.IContext, user *User) error

func PKCS5Padding

func PKCS5Padding(ciphertext []byte, blockSize int) []byte

func PKCS5UnPadding

func PKCS5UnPadding(origData []byte) []byte

Types

type AppEncTask

type AppEncTask struct {
	Appid       string      `json:"appid,omitempty" title:"appid"`
	Type        interface{} `json:"type,omitempty" title:"内容类型 json/xml 默认 json"`
	EncodingKey string      `json:"encodingKey,omitempty" title:"encodingKey"`
	Content     string      `json:"content,omitempty" title:"内容"`
}

func (*AppEncTask) GetName

func (T *AppEncTask) GetName() string

func (*AppEncTask) GetTitle

func (T *AppEncTask) GetTitle() string

type AppFormIdUseData

type AppFormIdUseData struct {
	Formid string `json:"formid" name:"formid" title:""`
}

type AppFormidAddTask

type AppFormidAddTask struct {
	Appid  string `json:"appid" name:"appid" title:"appid"`
	Openid string `json:"openid" name:"openid" title:"openid"`
	Items  string `json:"items" name:"items" title:"JSON\n[\n   {\"formid\":\"123\",\"etime\":1}\n]"`
}

func (*AppFormidAddTask) GetName

func (T *AppFormidAddTask) GetName() string

func (*AppFormidAddTask) GetTitle

func (T *AppFormidAddTask) GetTitle() string

type AppFormidUseTask

type AppFormidUseTask struct {
	Appid  string `json:"appid" name:"appid" title:"appid"`
	Openid string `json:"openid" name:"openid" title:"openid"`
}

func (*AppFormidUseTask) GetName

func (T *AppFormidUseTask) GetName() string

func (*AppFormidUseTask) GetTitle

func (T *AppFormidUseTask) GetTitle() string

type AppLoginData

type AppLoginData struct {
	SessionKey string `json:"session_key" name:"session_key" title:"session_key"`
	User       *User  `json:"user,omitempty" name:"user" title:"用户"`
}

type AppLoginTask

type AppLoginTask struct {
	Appid         string      `json:"appid" name:"appid" title:"appid"`
	Code          string      `json:"code" name:"code" title:"js_code"`
	EncryptedData interface{} `json:"encryptedData,omitempty" name:"encrypteddata" title:"用户信息编码数据"`
	Iv            interface{} `json:"iv,omitempty" name:"iv" title:"加密算法的初始向量"`
}

func (*AppLoginTask) GetName

func (T *AppLoginTask) GetName() string

func (*AppLoginTask) GetTitle

func (T *AppLoginTask) GetTitle() string

type AppPhoneData

type AppPhoneData struct {
	Phone   string `json:"phone" name:"phone" title:"手机号"`
	Country string `json:"country" name:"country" title:"国家区号"`
	User    *User  `json:"user,omitempty" name:"user" title:"用户"`
}

type AppPhoneTask

type AppPhoneTask struct {
	Appid         string      `json:"appid" name:"appid" title:"appid"`
	Openid        interface{} `json:"openid,omitempty" name:"openid" title:"openid"`
	SessionKey    interface{} `json:"session_key,omitempty" name:"session_key" title:"session_key"`
	EncryptedData string      `json:"encryptedData" name:"encrypteddata" title:"用户信息编码数据"`
	Iv            string      `json:"iv" name:"iv" title:"加密算法的初始向量"`
}

func (*AppPhoneTask) GetName

func (T *AppPhoneTask) GetName() string

func (*AppPhoneTask) GetTitle

func (T *AppPhoneTask) GetTitle() string

type AppQrTask

type AppQrTask struct {
	Appid string      `json:"appid" name:"appid" title:"appid"`
	Scene string      `` /* 272-byte string literal not displayed */
	Page  interface{} `` /* 268-byte string literal not displayed */
	Width interface{} `json:"width,omitempty" name:"width" title:"二维码的宽度,单位 px,最小 280px,最大 1280px"`
}

func (*AppQrTask) GetName

func (T *AppQrTask) GetName() string

func (*AppQrTask) GetTitle

func (T *AppQrTask) GetTitle() string

type AppRecvTask

type AppRecvTask struct {
	Appid       string      `json:"appid" name:"appid" title:"appid"`
	Type        interface{} `json:"type,omitempty" name:"type" title:"内容类型 json/xml 默认 json"`
	EncodingKey string      `json:"encodingKey" name:"encodingkey" title:"encodingKey"`
	Echostr     string      `json:"echostr" name:"echostr" title:"echostr"`
	Nonce       string      `json:"nonce" name:"nonce" title:"nonce"`
	Timestamp   string      `json:"timestamp" name:"timestamp" title:"timestamp"`
	Signature   string      `json:"signature" name:"signature" title:"signature"`
	Token       string      `json:"token" name:"token" title:"token"`
	Content     string      `json:"content" name:"content" title:"内容"`
}

func (*AppRecvTask) GetName

func (T *AppRecvTask) GetName() string

func (*AppRecvTask) GetTitle

func (T *AppRecvTask) GetTitle() string

type AppSendTask

type AppSendTask struct {
	Appid     string      `json:"appid" name:"appid" title:"appid"`
	Openid    string      `json:"openid" name:"openid" title:"openid"`
	Type      string      `json:"type" name:"type" title:"消息类型"`
	Body      string      `` /* 1887-byte string literal not displayed */
	KfAccount interface{} `json:"kf_account,omitempty" name:"kf_account" title:"客服账号"`
}

func (*AppSendTask) GetName

func (T *AppSendTask) GetName() string

func (*AppSendTask) GetTitle

func (T *AppSendTask) GetTitle() string

type AppUpData

type AppUpData struct {
	Type      string `json:"type" name:"type" title:"文件类型"`
	MediaId   string `json:"media_id" name:"media_id" title:"媒体标示"`
	CreatedAt int64  `json:"created_at" name:"created_at" title:"创建时间"`
}

type AppUpTask

type AppUpTask struct {
	Appid   string      `json:"appid" name:"appid" title:"appid"`
	Type    interface{} `json:"type,omitempty" name:"type" title:"文件类型, 默认 image"`
	Name    string      `json:"name" name:"name" title:"文件名"`
	Content string      `json:"content" name:"content" title:"文件内容 base64"`
}

func (*AppUpTask) GetName

func (T *AppUpTask) GetName() string

func (*AppUpTask) GetTitle

func (T *AppUpTask) GetTitle() string

type BindTask

type BindTask struct {
	Type    interface{} `json:"type,omitempty" name:"type" title:"类型"`
	Appid   interface{} `json:"appid,omitempty" name:"appid" title:"appid"`
	Openid  interface{} `json:"openid,omitempty" name:"openid" title:"openid"`
	Unionid interface{} `json:"unionid,omitempty" name:"unionid" title:"unionid"`
	Uid     int64       `json:"uid" name:"uid" title:"用户ID"`
}

func (*BindTask) GetName

func (T *BindTask) GetName() string

func (*BindTask) GetTitle

func (T *BindTask) GetTitle() string

type CheckImageTask

type CheckImageTask struct {
	Appid string `json:"appid" name:"appid" title:"appid"`
	Url   string `json:"url" name:"url" title:"消息"`
}

func (*CheckImageTask) GetName

func (T *CheckImageTask) GetName() string

func (*CheckImageTask) GetTitle

func (T *CheckImageTask) GetTitle() string

type CheckTextTask

type CheckTextTask struct {
	Appid   string `json:"appid" name:"appid" title:"appid"`
	Content string `json:"content" name:"content" title:"消息"`
}

func (*CheckTextTask) GetName

func (T *CheckTextTask) GetName() string

func (*CheckTextTask) GetTitle

func (T *CheckTextTask) GetTitle() string

type Content

type Content struct {
	db.Object
	Talker                 string `json:"talker" name:"talker" title:"微信原始数据库 的 talker"`
	Content                string `json:"content" name:"content" title:"微信原始数据库 的 content 消息内容" length:"512"`
	CreateTime             string `json:"createTime" name:"createtime" title:"微信原始数据库 的 createTime 消息时间(毫秒)"`
	Ctime                  int32  `json:"ctime" name:"ctime" title:"处理后的消息时间"`
	Etime                  int64  `json:"etime" name:"etime" title:"入库时间"`
	Type                   string `json:"type" name:"type" title:"微信原始数据库 的 type 判断消息类型"`
	IsSend                 string `json:"isSend" name:"issend" title:"微信原始数据库 的 isSend 判断是否是自己发送的消息"`
	MsgId                  string `json:"msgId" name:"msgid" title:"微信原始数据库的msgId 消息id自增" index:"ASC"`
	RobotUserAlias         string `json:"robotUserAlias" name:"robotuseralias" title:"机器人id" index:"ASC"`
	RobotUserName          string `json:"robotUserName" name:"robotusername" title:"机器人的微信用户名"`
	RobotUserNickName      string `json:"robotUserNickName" name:"robotusernickname" title:"机器人的微信昵称"`
	MsgTalkerUserName      string `json:"msgTalkerUserName" name:"msgtalkerusername" title:"消息发送者的微信用户名"`
	MsgTalkerUserAlias     string `json:"msgTalkerUserAlias" name:"msgtalkeruseralias" title:"消息发送者的微信id"`
	MsgTalkerUserNickName  string `json:"msgTalkerUserNickName" name:"msgtalkerusernickname" title:"消息发送者的微信昵称"`
	MsgTalkerUserReserved1 string `json:"msgTalkerUserReserved1" name:"msgtalkeruserreserved1" title:"消息发送者的微信头像大图"`
	MsgTalkerUserReserved2 string `json:"msgTalkerUserReserved2" name:"msgtalkeruserreserved2" title:"消息发送者的微信头像小图"`
	MsgGroupName           string `json:"msgGroupName" name:"msggroupname" title:"微信群的微信用户名"`
	MsgGroupNickName       string `json:"msgGroupNickName" name:"msggroupnickname" title:"微信群的微信昵称"`
	MsgContent             string `json:"msgContent" name:"msgcontent" title:"处理过的聊天内容"`
}

func (*Content) GetName

func (O *Content) GetName() string

func (*Content) GetTitle

func (O *Content) GetTitle() string

type ContentCountTask

type ContentCountTask struct {
	Id                    interface{} `json:"id,omitempty" name:"id" title:"ID"`
	MsgId                 string      `json:"msgId" name:"msgid" title:"微信原始数据库的msgId 消息id自增" index:"ASC"`
	CreateTime            string      `json:"createTime" name:"createtime" title:"微信原始数据库 的 createTime 消息时间(毫秒)"`
	MsgTalkerUserAlias    string      `json:"msgTalkerUserAlias" name:"msgtalkeruseralias" title:"消息发送者的微信id"`
	MsgTalkerUserNickName string      `json:"msgTalkerUserNickName" name:"msgtalkerusernickname" title:"消息发送者的微信昵称"`
	Type                  string      `json:"type" name:"type" title:"微信原始数据库 的 type 判断消息类型"`
	MsgGroupName          string      `json:"msgGroupName" name:"msggroupname" title:"微信群的微信用户名"`
	StartTime             interface{} `json:"startTime,omitempty" name:"starttime" title:"开始时间"`
	EndTime               interface{} `json:"endTime,omitempty" name:"endtime" title:"结束时间"`
	Q                     interface{} `json:"q,omitempty" name:"q" title:"模糊匹配关键字"`
	P                     interface{} `json:"p,omitempty" name:"p" title:"分页位置, 从1开始, 0 不处理分页"`
	N                     interface{} `json:"n,omitempty" name:"n" title:"分页大小,默认 20"`
}

func (*ContentCountTask) GetName

func (T *ContentCountTask) GetName() string

func (*ContentCountTask) GetTitle

func (T *ContentCountTask) GetTitle() string

type ContentList

type ContentList struct {
	Items []*Content `json:"items,omitempty" name:"items" title:"内容"`
	Page  *Page      `json:"page,omitempty" name:"page" title:"分页"`
}

type ContentQueryTask

type ContentQueryTask struct {
	Id                    interface{} `json:"id,omitempty" name:"id" title:"ID"`
	MsgId                 string      `json:"msgId" name:"msgid" title:"微信原始数据库的msgId 消息id自增"`
	CreateTime            string      `json:"createTime" name:"createtime" title:"微信原始数据库 的 createTime 消息时间(毫秒)"`
	MsgTalkerUserAlias    string      `json:"msgTalkerUserAlias" name:"msgtalkeruseralias" title:"消息发送者的微信id"`
	MsgTalkerUserNickName string      `json:"msgTalkerUserNickName" name:"msgtalkerusernickname" title:"消息发送者的微信昵称"`
	Type                  string      `json:"type" name:"type" title:"微信原始数据库 的 type 判断消息类型"`
	MsgGroupName          string      `json:"msgGroupName" name:"msggroupname" title:"微信群的微信用户名"`
	StartTime             interface{} `json:"startTime,omitempty" name:"starttime" title:"开始时间"`
	EndTime               interface{} `json:"endTime,omitempty" name:"endtime" title:"结束时间"`
	Q                     interface{} `json:"q,omitempty" name:"q" title:"模糊匹配关键字"`
	P                     interface{} `json:"p,omitempty" name:"p" title:"分页位置, 从1开始, 0 不处理分页"`
	N                     interface{} `json:"n,omitempty" name:"n" title:"分页大小,默认 20"`
}

func (*ContentQueryTask) GetName

func (T *ContentQueryTask) GetName() string

func (*ContentQueryTask) GetTitle

func (T *ContentQueryTask) GetTitle() string

type ContentRecvTask

type ContentRecvTask struct {
	Talker                 string `json:"talker" name:"talker" title:"微信原始数据库 的 talker"`
	Content                string `json:"content" name:"content" title:"微信原始数据库 的 content 消息内容" length:"512"`
	CreateTime             string `json:"createTime" name:"createtime" title:"微信原始数据库 的 createTime 消息时间(毫秒)"`
	Ctime                  int32  `json:"ctime" name:"ctime" title:"处理后的消息时间"`
	Etime                  int64  `json:"etime" name:"etime" title:"入库时间"`
	Type                   string `json:"type" name:"type" title:"微信原始数据库 的 type 判断消息类型"`
	IsSend                 string `json:"isSend" name:"issend" title:"微信原始数据库 的 isSend 判断是否是自己发送的消息"`
	MsgId                  string `json:"msgId" name:"msgid" title:"微信原始数据库的msgId 消息id自增" index:"ASC"`
	RobotUserAlias         string `json:"robotUserAlias" name:"robotuseralias" title:"机器人id" index:"ASC"`
	RobotUserName          string `json:"robotUserName" name:"robotusername" title:"机器人的微信用户名"`
	RobotUserNickName      string `json:"robotUserNickName" name:"robotusernickname" title:"机器人的微信昵称"`
	MsgTalkerUserName      string `json:"msgTalkerUserName" name:"msgtalkerusername" title:"消息发送者的微信用户名"`
	MsgTalkerUserAlias     string `json:"msgTalkerUserAlias" name:"msgtalkeruseralias" title:"消息发送者的微信id"`
	MsgTalkerUserNickName  string `json:"msgTalkerUserNickName" name:"msgtalkerusernickname" title:"消息发送者的微信昵称"`
	MsgTalkerUserReserved1 string `json:"msgTalkerUserReserved1" name:"msgtalkeruserreserved1" title:"消息发送者的微信头像大图"`
	MsgTalkerUserReserved2 string `json:"msgTalkerUserReserved2" name:"msgtalkeruserreserved2" title:"消息发送者的微信头像小图"`
	MsgGroupName           string `json:"msgGroupName" name:"msggroupname" title:"微信群的微信用户名"`
	MsgGroupNickName       string `json:"msgGroupNickName" name:"msggroupnickname" title:"微信群的微信昵称"`
	MsgContent             string `json:"msgContent" name:"msgcontent" title:"处理过的聊天内容"`
}

func (*ContentRecvTask) GetName

func (T *ContentRecvTask) GetName() string

func (*ContentRecvTask) GetTitle

func (T *ContentRecvTask) GetTitle() string

type ContentRmTask

type ContentRmTask struct {
	Id      int64       `json:"id" name:"id" title:"内容ID"`
	Uid     interface{} `json:"uid,omitempty" name:"uid" title:"用户ID"`
	Groupid interface{} `json:"groupid,omitempty" name:"groupid" title:"群ID"`
}

func (*ContentRmTask) GetName

func (T *ContentRmTask) GetName() string

func (*ContentRmTask) GetTitle

func (T *ContentRmTask) GetTitle() string

type CountData

type CountData struct {
	Total int32 `json:"total" name:"total" title:"总记录数"`
}

type CountTask

type CountTask struct {
	Uid       interface{} `json:"uid,omitempty" name:"uid" title:"用户ID"`
	Type      interface{} `json:"type,omitempty" name:"type" title:"类型,多个逗号分割"`
	Appid     interface{} `json:"appid,omitempty" name:"appid" title:"appid"`
	Openid    interface{} `json:"openid,omitempty" name:"openid" title:"openid"`
	Unionid   interface{} `json:"unionid,omitempty" name:"unionid" title:"uniqueid"`
	Q         interface{} `json:"q,omitempty" name:"q" title:"模糊匹配关键字"`
	State     interface{} `json:"state,omitempty" name:"state" title:"状态 多个逗号分割"`
	Bind      interface{} `json:"bind,omitempty" name:"bind" title:"是否绑定"`
	Info      interface{} `json:"info,omitempty" name:"info" title:"是否有用户信息"`
	StartTime interface{} `json:"startTime,omitempty" name:"starttime" title:"绑定开始时间"`
	EndTime   interface{} `json:"endTime,omitempty" name:"endtime" title:"绑定结束时间"`
}

func (*CountTask) GetName

func (T *CountTask) GetName() string

func (*CountTask) GetTitle

func (T *CountTask) GetTitle() string

type FormId

type FormId struct {
	db.Object
	Appid  string `json:"appid" name:"appid" title:"appid" length:"64" index:"ASC"`
	Openid string `json:"openid" name:"openid" title:"openid" length:"128" index:"ASC"`
	Formid string `json:"formid" name:"formid" title:"formid" length:"128"`
	Etime  int64  `json:"etime" name:"etime" title:"过期时间" index:"DESC"`
}

func (*FormId) GetName

func (O *FormId) GetName() string

func (*FormId) GetTitle

func (O *FormId) GetTitle() string

type GetTask

type GetTask struct {
	Type   int32       `json:"type" name:"type" title:"类型,多个逗号分割"`
	Appid  string      `json:"appid" name:"appid" title:"appid"`
	Openid string      `json:"openid" name:"openid" title:"openid"`
	Update interface{} `json:"update,omitempty" name:"update" title:"是否更新用户信息"`
}

func (*GetTask) GetName

func (T *GetTask) GetName() string

func (*GetTask) GetTitle

func (T *GetTask) GetTitle() string

type MPAuthorizeData

type MPAuthorizeData struct {
	Url string `json:"url" name:"url" title:"授权URL"`
}

type MPConfigData

type MPConfigData struct {
	Appid     string `json:"appid" name:"appid" title:"appid"`
	Timestamp int64  `json:"timestamp" name:"timestamp" title:"timestamp"`
	NonceStr  string `json:"nonceStr" name:"noncestr" title:"nonceStr"`
	Signature string `json:"signature" name:"signature" title:"signature"`
}

type MpAuthorizeTask

type MpAuthorizeTask struct {
	Appid       string      `json:"appid" name:"appid" title:"appid"`
	State       interface{} `json:"state,omitempty" name:"state" title:"state"`
	Scope       interface{} `json:"scope,omitempty" name:"scope" title:"scope"`
	RedirectUri string      `json:"redirect_uri" name:"redirect_uri" title:"redirect_uri"`
}

func (*MpAuthorizeTask) GetName

func (T *MpAuthorizeTask) GetName() string

func (*MpAuthorizeTask) GetTitle

func (T *MpAuthorizeTask) GetTitle() string

type MpConfigTask

type MpConfigTask struct {
	Appid     string      `json:"appid" name:"appid" title:"appid"`
	Noncestr  interface{} `json:"noncestr,omitempty" name:"noncestr" title:"noncestr 不存在是自动生成"`
	Timestamp interface{} `json:"timestamp,omitempty" name:"timestamp" title:"noncestr 不存时是自动生成"`
	Url       string      `json:"url" name:"url" title:"签名URL"`
}

func (*MpConfigTask) GetName

func (T *MpConfigTask) GetName() string

func (*MpConfigTask) GetTitle

func (T *MpConfigTask) GetTitle() string

type MpConfirmTask

type MpConfirmTask struct {
	Appid string      `json:"appid" name:"appid" title:"appid"`
	State interface{} `json:"state,omitempty" name:"state" title:"state"`
	Code  string      `json:"code" name:"code" title:"code"`
}

func (*MpConfirmTask) GetName

func (T *MpConfirmTask) GetName() string

func (*MpConfirmTask) GetTitle

func (T *MpConfirmTask) GetTitle() string

type MpPullTask

type MpPullTask struct {
	Appid string `json:"appid" name:"appid" title:"appid"`
}

func (*MpPullTask) GetName

func (T *MpPullTask) GetName() string

func (*MpPullTask) GetTitle

func (T *MpPullTask) GetTitle() string

type MpRecvTask

type MpRecvTask struct {
	Appid       string      `json:"appid" name:"appid" title:"appid"`
	Type        interface{} `json:"type,omitempty" name:"type" title:"内容类型 json/xml 默认 json"`
	EncodingKey string      `json:"encodingKey" name:"encodingkey" title:"encodingKey"`
	Echostr     string      `json:"echostr" name:"echostr" title:"echostr"`
	Nonce       string      `json:"nonce" name:"nonce" title:"nonce"`
	Timestamp   string      `json:"timestamp" name:"timestamp" title:"timestamp"`
	Signature   string      `json:"signature" name:"signature" title:"signature"`
	Token       string      `json:"token" name:"token" title:"token"`
	Content     string      `json:"content" name:"content" title:"内容"`
}

func (*MpRecvTask) GetName

func (T *MpRecvTask) GetName() string

func (*MpRecvTask) GetTitle

func (T *MpRecvTask) GetTitle() string

type MpSendTask

type MpSendTask struct {
	Appid     string      `json:"appid" name:"appid" title:"appid"`
	Openid    string      `json:"openid" name:"openid" title:"openid"`
	Type      string      `json:"type" name:"type" title:"消息类型"`
	Body      string      `` /* 2327-byte string literal not displayed */
	KfAccount interface{} `json:"kf_account,omitempty" name:"kf_account" title:"客服账号"`
}

func (*MpSendTask) GetName

func (T *MpSendTask) GetName() string

func (*MpSendTask) GetTitle

func (T *MpSendTask) GetTitle() string

type Open

type Open struct {
	db.Object
	Appid        string      `json:"appid" name:"appid" title:"appid" length:"64" index:"ASC"`
	Ticket       string      `json:"-" name:"ticket" title:"ticket" length:"255"`
	AccessToken  string      `json:"-" name:"access_token" title:"access_token" length:"255"`
	RefreshToken string      `json:"-" name:"refresh_token" title:"refresh_token" length:"255"`
	Etime        int64       `json:"etime" name:"etime" title:"过期时间"`
	Options      interface{} `json:"options,omitempty" name:"options" title:"其他数据" length:"-1"`
}

func (*Open) GetName

func (O *Open) GetName() string

func (*Open) GetTitle

func (O *Open) GetTitle() string

type OpenAuthorizeData

type OpenAuthorizeData struct {
	Url string `json:"url" name:"url" title:"授权URL"`
}

type OpenAuthorizeTask

type OpenAuthorizeTask struct {
	Appid       string      `json:"appid" name:"appid" title:"appid"`
	State       interface{} `json:"state,omitempty" name:"state" title:"state"`
	Scope       interface{} `json:"scope,omitempty" name:"scope" title:"scope"`
	RedirectUri string      `json:"redirect_uri" name:"redirect_uri" title:"redirect_uri"`
}

func (*OpenAuthorizeTask) GetName

func (T *OpenAuthorizeTask) GetName() string

func (*OpenAuthorizeTask) GetTitle

func (T *OpenAuthorizeTask) GetTitle() string

type OpenConfigData

type OpenConfigData struct {
	Appid     string `json:"appid" name:"appid" title:"appid"`
	Timestamp int64  `json:"timestamp" name:"timestamp" title:"timestamp"`
	NonceStr  string `json:"nonceStr" name:"noncestr" title:"nonceStr"`
	Signature string `json:"signature" name:"signature" title:"signature"`
}

type OpenConfigTask

type OpenConfigTask struct {
	Appid     string      `json:"appid" name:"appid" title:"appid"`
	Noncestr  interface{} `json:"noncestr,omitempty" name:"noncestr" title:"noncestr 不存在是自动生成"`
	Timestamp interface{} `json:"timestamp,omitempty" name:"timestamp" title:"noncestr 不存时是自动生成"`
	Url       string      `json:"url" name:"url" title:"签名URL"`
}

func (*OpenConfigTask) GetName

func (T *OpenConfigTask) GetName() string

func (*OpenConfigTask) GetTitle

func (T *OpenConfigTask) GetTitle() string

type OpenConfirmTask

type OpenConfirmTask struct {
	Appid string      `json:"appid" name:"appid" title:"appid"`
	State interface{} `json:"state,omitempty" name:"state" title:"state"`
	Code  string      `json:"code" name:"code" title:"code"`
}

func (*OpenConfirmTask) GetName

func (T *OpenConfirmTask) GetName() string

func (*OpenConfirmTask) GetTitle

func (T *OpenConfirmTask) GetTitle() string

type OpenDecryptTask

type OpenDecryptTask struct {
	Token       string `json:"token" name:"token" title:"Token"`
	EncodingKey string `json:"encodingKey" name:"encodingkey" title:"encodingKey"`
	Nonce       string `json:"nonce" name:"nonce" title:"nonce"`
	Timestamp   string `json:"timestamp" name:"timestamp" title:"timestamp"`
	Signature   string `json:"signature" name:"signature" title:"签名"`
	Content     string `json:"content" name:"content" title:"内容 XML"`
}

func (*OpenDecryptTask) GetName

func (T *OpenDecryptTask) GetName() string

func (*OpenDecryptTask) GetTitle

func (T *OpenDecryptTask) GetTitle() string

type OpenEncryptData

type OpenEncryptData struct {
	Nonce     string `json:"nonce" name:"nonce" title:"nonce"`
	Timestamp string `json:"timestamp" name:"timestamp" title:"timestamp"`
	Signature string `json:"signature" name:"signature" title:"签名"`
	Content   string `json:"content" name:"content" title:"编码后内容"`
}

type OpenEncryptTask

type OpenEncryptTask struct {
	Token       string      `json:"token" name:"token" title:"Token"`
	EncodingKey string      `json:"encodingKey" name:"encodingkey" title:"encodingKey"`
	Nonce       interface{} `json:"nonce,omitempty" name:"nonce" title:"nonce"`
	Timestamp   interface{} `json:"timestamp,omitempty" name:"timestamp" title:"timestamp"`
	Content     string      `json:"content" name:"content" title:"内容 JSON"`
}

func (*OpenEncryptTask) GetName

func (T *OpenEncryptTask) GetName() string

func (*OpenEncryptTask) GetTitle

func (T *OpenEncryptTask) GetTitle() string

type OpenMPAuthorizeData

type OpenMPAuthorizeData struct {
	Url string `json:"url" name:"url" title:"授权URL"`
}

type OpenMpAuthorizeTask

type OpenMpAuthorizeTask struct {
	OpenType    interface{} `json:"openType,omitempty" name:"opentype" title:"授权方式"`
	AuthType    interface{} `json:"authType,omitempty" name:"authtype" title:"授权类型"`
	Appid       interface{} `json:"appid,omitempty" name:"appid" title:"公众号/小程序 Appid"`
	RedirectUri string      `json:"redirect_uri" name:"redirect_uri" title:"redirect_uri"`
}

func (*OpenMpAuthorizeTask) GetName

func (T *OpenMpAuthorizeTask) GetName() string

func (*OpenMpAuthorizeTask) GetTitle

func (T *OpenMpAuthorizeTask) GetTitle() string

type OpenMpTicketSetTask

type OpenMpTicketSetTask struct {
	Ticket string `json:"ticket" name:"ticket" title:"Ticket"`
}

func (*OpenMpTicketSetTask) GetName

func (T *OpenMpTicketSetTask) GetName() string

func (*OpenMpTicketSetTask) GetTitle

func (T *OpenMpTicketSetTask) GetTitle() string

type OpenRecvTask

type OpenRecvTask struct {
	Appid       string      `json:"appid" title:"appid"`
	Type        interface{} `json:"type,omitempty" title:"内容类型 json/xml 默认 json"`
	EncodingKey string      `json:"encodingKey" title:"encodingKey"`
	Echostr     string      `json:"echostr" title:"echostr"`
	Nonce       string      `json:"nonce" title:"nonce"`
	Timestamp   string      `json:"timestamp" title:"timestamp"`
	Signature   string      `json:"signature" title:"signature"`
	Token       string      `json:"token" title:"token"`
	Content     string      `json:"content" title:"内容"`
}

func (*OpenRecvTask) GetName

func (T *OpenRecvTask) GetName() string

func (*OpenRecvTask) GetTitle

func (T *OpenRecvTask) GetTitle() string

type Page

type Page struct {
	P     int32 `json:"p" name:"p" title:"分页位置"`
	N     int32 `json:"n" name:"n" title:"单页记录数"`
	Count int32 `json:"count" name:"count" title:"总页数"`
	Total int32 `json:"total" name:"total" title:"总记录数"`
}

type QueryData

type QueryData struct {
	Items []*User `json:"items,omitempty" name:"items" title:"用户"`
	Page  *Page   `json:"page,omitempty" name:"page" title:"分页"`
}

type QueryTask

type QueryTask struct {
	Uid       interface{} `json:"uid,omitempty" name:"uid" title:"用户ID"`
	Type      interface{} `json:"type,omitempty" name:"type" title:"类型,多个逗号分割"`
	Appid     interface{} `json:"appid,omitempty" name:"appid" title:"appid"`
	Openid    interface{} `json:"openid,omitempty" name:"openid" title:"openid"`
	Unionid   interface{} `json:"unionid,omitempty" name:"unionid" title:"unionid"`
	State     interface{} `json:"state,omitempty" name:"state" title:"状态 多个逗号分割"`
	Bind      interface{} `json:"bind,omitempty" name:"bind" title:"是否绑定"`
	StartTime interface{} `json:"startTime,omitempty" name:"starttime" title:"绑定开始时间"`
	EndTime   interface{} `json:"endTime,omitempty" name:"endtime" title:"绑定结束时间"`
	Info      interface{} `json:"info,omitempty" name:"info" title:"是否有用户信息"`
	Q         interface{} `json:"q,omitempty" name:"q" title:"模糊匹配关键字"`
	P         interface{} `json:"p,omitempty" name:"p" title:"分页位置, 从1开始, 0 不处理分页"`
	N         interface{} `json:"n,omitempty" name:"n" title:"分页大小,默认 20"`
}

func (*QueryTask) GetName

func (T *QueryTask) GetName() string

func (*QueryTask) GetTitle

func (T *QueryTask) GetTitle() string

type SendTask

type SendTask struct {
	Uid       interface{} `json:"uid,omitempty" title:"用户ID"`
	Uniqueid  interface{} `json:"uniqueid,omitempty" title:"uniqueid"`
	Type      string      `json:"type,omitempty" title:"消息类型"`
	Body      string      `` /* 2325-byte string literal not displayed */
	KfAccount interface{} `json:"kf_account,omitempty" title:"客服账号"`
}

func (*SendTask) GetName

func (T *SendTask) GetName() string

func (*SendTask) GetTitle

func (T *SendTask) GetTitle() string

type Service

type Service struct {
}

func (*Service) AppFormidAdd

func (S *Service) AppFormidAdd(app micro.IContext, task *AppFormidAddTask) (interface{}, error)

func (*Service) AppFormidUse

func (S *Service) AppFormidUse(app micro.IContext, task *AppFormidUseTask) (*AppFormIdUseData, error)

func (*Service) AppLogin

func (S *Service) AppLogin(app micro.IContext, task *AppLoginTask) (*AppLoginData, error)

func (*Service) AppPhone

func (S *Service) AppPhone(app micro.IContext, task *AppPhoneTask) (*AppPhoneData, error)

func (*Service) AppQr

func (S *Service) AppQr(app micro.IContext, task *AppQrTask) (*WXAppQRData, error)

func (*Service) AppRecv

func (S *Service) AppRecv(app micro.IContext, task *AppRecvTask) (interface{}, error)

func (*Service) AppSend

func (S *Service) AppSend(app micro.IContext, task *AppSendTask) (interface{}, error)

func (*Service) AppUp

func (S *Service) AppUp(app micro.IContext, task *AppUpTask) (*AppUpData, error)

func (*Service) Bind

func (S *Service) Bind(app micro.IContext, task *BindTask) (interface{}, error)

func (*Service) CheckImage

func (S *Service) CheckImage(app micro.IContext, task *CheckImageTask) (interface{}, error)

func (*Service) CheckText

func (S *Service) CheckText(app micro.IContext, task *CheckTextTask) (interface{}, error)

func (*Service) ContentCount

func (S *Service) ContentCount(app micro.IContext, task *ContentCountTask) (*CountData, error)

func (*Service) ContentQuery

func (S *Service) ContentQuery(app micro.IContext, task *ContentQueryTask) (*ContentList, error)

func (*Service) ContentRecv

func (S *Service) ContentRecv(app micro.IContext, task *ContentRecvTask) (*Content, error)

func (*Service) ContentRm

func (S *Service) ContentRm(app micro.IContext, task *ContentRmTask) (interface{}, error)

func (*Service) Count

func (S *Service) Count(app micro.IContext, task *CountTask) (*CountData, error)

func (*Service) Get

func (S *Service) Get(app micro.IContext, task *GetTask) (*User, error)

func (*Service) GetName

func (S *Service) GetName() string

func (*Service) GetTitle

func (S *Service) GetTitle() string

func (*Service) MpAuthorize

func (S *Service) MpAuthorize(app micro.IContext, task *MpAuthorizeTask) (*MPAuthorizeData, error)

func (*Service) MpConfig

func (S *Service) MpConfig(app micro.IContext, task *MpConfigTask) (*MPConfigData, error)

func (*Service) MpConfirm

func (S *Service) MpConfirm(app micro.IContext, task *MpConfirmTask) (*User, error)

func (*Service) MpPull

func (S *Service) MpPull(app micro.IContext, task *MpPullTask) (*WXMPPullData, error)

func (*Service) MpRecv

func (S *Service) MpRecv(app micro.IContext, task *MpRecvTask) (interface{}, error)

func (*Service) MpSend

func (S *Service) MpSend(app micro.IContext, task *MpSendTask) (interface{}, error)

func (*Service) OpenAuthorize

func (S *Service) OpenAuthorize(app micro.IContext, task *OpenAuthorizeTask) (*OpenAuthorizeData, error)

func (*Service) OpenConfig

func (S *Service) OpenConfig(app micro.IContext, task *OpenConfigTask) (*OpenConfigData, error)

func (*Service) OpenConfirm

func (S *Service) OpenConfirm(app micro.IContext, task *OpenConfirmTask) (*User, error)

func (*Service) OpenDecrypt

func (S *Service) OpenDecrypt(app micro.IContext, task *OpenDecryptTask) (interface{}, error)

func (*Service) OpenEncrypt

func (S *Service) OpenEncrypt(app micro.IContext, task *OpenEncryptTask) (*OpenEncryptData, error)

func (*Service) OpenMpAuthorize

func (S *Service) OpenMpAuthorize(app micro.IContext, task *OpenMpAuthorizeTask) (*OpenMPAuthorizeData, error)

func (*Service) OpenMpTicketSet

func (S *Service) OpenMpTicketSet(app micro.IContext, task *OpenMpTicketSetTask) (*Open, error)

func (*Service) Query

func (S *Service) Query(app micro.IContext, task *QueryTask) (*QueryData, error)

func (*Service) Set

func (S *Service) Set(app micro.IContext, task *SetTask) (*User, error)

func (*Service) Unbind

func (S *Service) Unbind(app micro.IContext, task *UnbindTask) (interface{}, error)

type SetTask

type SetTask struct {
	Type    interface{} `json:"type,omitempty" name:"type" title:"类型"`
	Appid   interface{} `json:"appid,omitempty" name:"appid" title:"appid"`
	Openid  interface{} `json:"openid,omitempty" name:"openid" title:"openid"`
	Unionid interface{} `json:"unionid,omitempty" name:"unionid" title:"unionid"`
	State   int32       `json:"state" name:"state" title:"关注状态"`
}

func (*SetTask) GetName

func (T *SetTask) GetName() string

func (*SetTask) GetTitle

func (T *SetTask) GetTitle() string

type Ticket

type Ticket struct {
	db.Object
	Type   string `json:"type" name:"type" title:"类型" length:"32" index:"ASC"`
	Appid  string `json:"appid" name:"appid" title:"appid" length:"64" index:"ASC"`
	Ticket string `json:"-" name:"ticket" title:"ticket" length:"255"`
	Etime  int64  `json:"etime" name:"etime" title:"过期时间"`
}

func (*Ticket) GetName

func (O *Ticket) GetName() string

func (*Ticket) GetTitle

func (O *Ticket) GetTitle() string

type Token

type Token struct {
	db.Object
	Type        int32  `json:"type" name:"type" title:"类型" index:"ASC"`
	Appid       string `json:"appid" name:"appid" title:"appid" length:"64" index:"ASC"`
	AccessToken string `json:"-" name:"access_token" title:"access_token" length:"255"`
	Etime       int64  `json:"etime" name:"etime" title:"过期时间"`
}

func (*Token) GetName

func (O *Token) GetName() string

func (*Token) GetTitle

func (O *Token) GetTitle() string

type UnbindTask

type UnbindTask struct {
	Type    interface{} `json:"type,omitempty" name:"type" title:"类型"`
	Appid   interface{} `json:"appid,omitempty" name:"appid" title:"appid"`
	Openid  interface{} `json:"openid,omitempty" name:"openid" title:"openid"`
	Unionid interface{} `json:"unionid,omitempty" name:"unionid" title:"unionid"`
	Uid     int64       `json:"uid" name:"uid" title:"用户ID"`
}

func (*UnbindTask) GetName

func (T *UnbindTask) GetName() string

func (*UnbindTask) GetTitle

func (T *UnbindTask) GetTitle() string

type User

type User struct {
	db.Object
	Uid          int64       `json:"uid" name:"uid" title:"用户ID" index:"ASC"`
	Type         int32       `json:"type" name:"type" title:"类型" index:"ASC"`
	Appid        string      `json:"appid" name:"appid" title:"appid" length:"64" index:"ASC"`
	Openid       string      `json:"openid" name:"openid" title:"openid" length:"128" index:"ASC"`
	Unionid      string      `json:"unionid" name:"unionid" title:"unionid" length:"128" index:"ASC"`
	AccessToken  string      `json:"access_token" name:"access_token" title:"access_token" length:"255"`
	RefreshToken string      `json:"refresh_token" name:"refresh_token" title:"refresh_token" length:"255"`
	SessionKey   string      `json:"session_key" name:"session_key" title:"session_key" length:"128"`
	Nick         string      `json:"nick" name:"nick" title:"昵称" length:"255"`
	Country      string      `json:"country" name:"country" title:"国家" length:"64"`
	Lang         string      `json:"lang" name:"lang" title:"语言" length:"64"`
	Province     string      `json:"province" name:"province" title:"省份" length:"64"`
	City         string      `json:"city" name:"city" title:"城市" length:"64"`
	Gender       int32       `json:"gender" name:"gender" title:"性别"`
	Options      interface{} `json:"options,omitempty" name:"options" title:"其他数据" length:"-1"`
	Ctime        int64       `json:"ctime" name:"ctime" title:"创建时间"`
	Etime        int64       `json:"etime" name:"etime" title:"过期时间"`
	State        int32       `json:"state" name:"state" title:"关注状态"`
	Mtime        int64       `json:"mtime" name:"mtime" title:"最后绑定时间"`
}

func (*User) GetName

func (O *User) GetName() string

func (*User) GetTitle

func (O *User) GetTitle() string

type WXAppQRData

type WXAppQRData struct {
	Type    string `json:"type" name:"type" title:"类型"`
	Content string `json:"content" name:"content" title:"内容"`
}

type WXMPPullData

type WXMPPullData struct {
	Count int32 `json:"count" name:"count" title:"拉取的数量"`
}

Source Files

Jump to

Keyboard shortcuts

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