Documentation ¶
Overview ¶
* @Name: * @Descripttion: * @Warning: * @version: * @Author: moo * @Date: 2021-01-26 18:37:21 * @LastEditors: moo * @LastEditTime: 2021-02-01 15:58:11
Index ¶
- Variables
- func Code2Session(appid string, secret string, code string) (openID string, unionID string, sessionKey string, err error)
- func GetJson(uri string, query map[string]string) ([]byte, error)
- func PostJson(uri string, param map[string]interface{}) ([]byte, error)
- func SendSubscribe(sub SubMsg) error
- type AccessToken
- type RspSubMsg
- type SubMsg
Constants ¶
This section is empty.
Variables ¶
View Source
var ACCESS_TOKEN_URI string = "https://api.weixin.qq.com/cgi-bin/token"
View Source
var CODE_URI string = "https://api.weixin.qq.com/sns/jscode2session"
View Source
var SUBSCRIBE_URI string = "https://api.weixin.qq.com/cgi-bin/message/subscribe/send?access_token=%s"
Functions ¶
func Code2Session ¶
func SendSubscribe ¶
Types ¶
type AccessToken ¶
type AccessToken struct { Token string `json:"access_token"` ExpiresIn int `json:"expires_in"` ErrCode int `json:"errcode"` ErrMsg string `json:"errmsg"` }
func GetAccessToken ¶
func GetAccessToken(appid string, secret string) (*AccessToken, error)
Click to show internal directories.
Click to hide internal directories.