Documentation ¶
Index ¶
- Variables
- func GetAuthorizerAccessToken(appid string) (string, error)
- func GetAuthorizerInfo(appid string, resp *AuthorizerInfoResp) error
- func GetAuthorizerWxApiUrl(appid string, path string, query string) (string, error)
- func GetComponentAccessToken() (string, error)
- func GetComponentWxApiUrl(path string, query string) (string, error)
- func GetRawWxApiUrl(path string, query string) string
- type AuthorizerBasicConfig
- type AuthorizerInfoResp
- type WxCommError
- func GetWxApiWithAuthToken(appid string, path string, query string) (*WxCommError, []byte, error)
- func GetWxApiWithComponentToken(path string, query string) (*WxCommError, []byte, error)
- func GetWxApiWithoutToken(path string, query string) (*WxCommError, []byte, error)
- func PostWxFormDataWithAuthToken(appid string, path string, query string, formFile multipart.File, ...) (*WxCommError, []byte, error)
- func PostWxJsonWithAuthToken(appid string, path string, query string, data interface{}) (*WxCommError, []byte, error)
- func PostWxJsonWithComponentToken(path string, query string, data interface{}) (*WxCommError, []byte, error)
- func PostWxJsonWithoutToken(path string, query string, data interface{}) (*WxCommError, []byte, error)
Constants ¶
This section is empty.
Variables ¶
Functions ¶
func GetAuthorizerAccessToken ¶
GetAuthorizerAccessToken 获取AuthorizerAccessToken
func GetAuthorizerInfo ¶
func GetAuthorizerInfo(appid string, resp *AuthorizerInfoResp) error
GetAuthorizerInfo 获取授权账号信息
func GetAuthorizerWxApiUrl ¶
GetAuthorizerWxApiUrl 拼接微信开放平台的url,带小程序token
func GetComponentAccessToken ¶
GetComponentAccessToken 获取ComponentAccessToken
func GetComponentWxApiUrl ¶
GetComponentWxApiUrl 拼接微信开放平台的url,带第三方token
func GetRawWxApiUrl ¶
GetRawWxApiUrl 拼接微信开放平台的url,不带微信令牌
Types ¶
type AuthorizerBasicConfig ¶
type AuthorizerBasicConfig struct { IsPhoneConfigured bool `json:"isPhoneConfigured" wx:"is_phone_configured"` IsEmailConfigured bool `json:"isEmailConfigured" wx:"is_email_configured"` }
AuthorizerBasicConfig 授权账号的基础配置结构体
type AuthorizerInfoResp ¶
type AuthorizerInfoResp struct { AuthorizationInfo authorizationInfo `wx:"authorization_info"` AuthorizerInfo authorizerInfo `wx:"authorizer_info"` }
AuthorizerInfoResp 授权账号信息结构体
type WxCommError ¶
WxCommError 微信开放平台api通用错误
func GetWxApiWithAuthToken ¶
GetWxApiWithAuthToken 以小程序身份向微信开放平台发起get请求
func GetWxApiWithComponentToken ¶
func GetWxApiWithComponentToken(path string, query string) (*WxCommError, []byte, error)
GetWxApiWithComponentToken 以第三方身份向微信开放平台发起get请求
func GetWxApiWithoutToken ¶
func GetWxApiWithoutToken(path string, query string) (*WxCommError, []byte, error)
GetWxApiWithoutToken 向微信开放平台发起get请求
func PostWxFormDataWithAuthToken ¶
func PostWxFormDataWithAuthToken(appid string, path string, query string, formFile multipart.File, fileName string, fieldName string) (*WxCommError, []byte, error)
PostWxFormDataWithAuthToken 以小程序身份向微信开放平台发起post请求
func PostWxJsonWithAuthToken ¶
func PostWxJsonWithAuthToken(appid string, path string, query string, data interface{}) (*WxCommError, []byte, error)
PostWxJsonWithAuthToken 以小程序身份向微信开放平台发起post请求
func PostWxJsonWithComponentToken ¶
func PostWxJsonWithComponentToken(path string, query string, data interface{}) (*WxCommError, []byte, error)
PostWxJsonWithComponentToken 以第三方身份向微信开放平台发起post请求
func PostWxJsonWithoutToken ¶
func PostWxJsonWithoutToken(path string, query string, data interface{}) (*WxCommError, []byte, error)
PostWxJsonWithoutToken 向微信开放平台发起post请求
Source Files ¶
Click to show internal directories.
Click to hide internal directories.