Documentation ¶
Index ¶
- Constants
- type CgiBinGetApiDomainIpResponse
- type CgiBinGetApiDomainIpResult
- type CgiBinGetCallBackIpResponse
- type CgiBinGetCallBackIpResult
- type CgiBinGetTokenResponse
- type CgiBinGetTokenResult
- type CgiBinUserGetUserInfoResponse
- type CgiBinUserGetUserInfoResult
- type Client
- func (c *Client) CgiBinGetApiDomainIp(ctx context.Context, accessToken string, notMustParams ...*gorequest.Params) (*CgiBinGetApiDomainIpResult, error)
- func (c *Client) CgiBinGetCallBackIp(ctx context.Context, accessToken string, notMustParams ...*gorequest.Params) (*CgiBinGetCallBackIpResult, error)
- func (c *Client) CgiBinGetToken(ctx context.Context, notMustParams ...*gorequest.Params) (*CgiBinGetTokenResult, error)
- func (c *Client) CgiBinUserGetUserInfo(ctx context.Context, accessToken, code string, ...) (*CgiBinUserGetUserInfoResult, error)
- func (c *Client) ConnectOauth2Authorize(ctx context.Context) string
- func (c *Client) GetAgentId() int
- func (c *Client) GetAppId() string
- func (c *Client) GetRedirectUri() string
- func (c *Client) GetSecret() string
- func (c *Client) SetAgentId(v int) *Client
- func (c *Client) SetAppId(v string) *Client
- func (c *Client) SetClientIP(clientIP string) *Client
- func (c *Client) SetLogFun(logFun gorequest.LogFunc)
- func (c *Client) SetRedirectUri(v string) *Client
- func (c *Client) SetSecret(v string) *Client
- func (c *Client) WebhookSend(ctx context.Context, key string, Type string, ...) (*WebhookSendResult, error)
- func (c *Client) WebhookSendURL(ctx context.Context, url string, Type string, ...) (*WebhookSendResult, error)
- func (c *Client) WwOpenSsoQrConnect(ctx context.Context) string
- type ClientConfig
- type WebhookSendResponse
- type WebhookSendResult
Constants ¶
const (
LogTable = "wechatqy"
)
const (
Version = "1.0.27"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CgiBinGetApiDomainIpResponse ¶ added in v1.0.24
type CgiBinGetApiDomainIpResult ¶ added in v1.0.24
type CgiBinGetApiDomainIpResult struct { Result CgiBinGetApiDomainIpResponse // 结果 Body []byte // 内容 Http gorequest.Response // 请求 }
func NewCgiBinGetApiDomainIpResult ¶ added in v1.0.24
func NewCgiBinGetApiDomainIpResult(result CgiBinGetApiDomainIpResponse, body []byte, http gorequest.Response) *CgiBinGetApiDomainIpResult
type CgiBinGetCallBackIpResponse ¶ added in v1.0.24
type CgiBinGetCallBackIpResult ¶ added in v1.0.24
type CgiBinGetCallBackIpResult struct { Result CgiBinGetCallBackIpResponse // 结果 Body []byte // 内容 Http gorequest.Response // 请求 }
func NewCgiBinGetCallBackIpResult ¶ added in v1.0.24
func NewCgiBinGetCallBackIpResult(result CgiBinGetCallBackIpResponse, body []byte, http gorequest.Response) *CgiBinGetCallBackIpResult
type CgiBinGetTokenResponse ¶
type CgiBinGetTokenResult ¶
type CgiBinGetTokenResult struct { Result CgiBinGetTokenResponse // 结果 Body []byte // 内容 Http gorequest.Response // 请求 }
type CgiBinUserGetUserInfoResponse ¶
type CgiBinUserGetUserInfoResponse struct { Errcode int `json:"errcode"` // 返回码 Errmsg string `json:"errmsg"` // 对返回码的文本描述内容 UserId string `json:"userId"` // 成员UserID。若需要获得用户详情信息 OpenId string `json:"OpenId"` // 非企业成员的标识,对当前企业唯一。不超过64字节 DeviceId string `json:"DeviceId"` // 手机设备号(由企业微信在安装时随机生成,删除重装会改变,升级不受影响) ExternalUserid string `json:"external_userid"` // 外部联系人id,当且仅当用户是企业的客户,且跟进人在应用的可见范围内时返回。如果是第三方应用调用,针对同一个客户,同一个服务商不同应用获取到的id相同 }
type CgiBinUserGetUserInfoResult ¶
type CgiBinUserGetUserInfoResult struct { Result CgiBinUserGetUserInfoResponse // 结果 Body []byte // 内容 Http gorequest.Response // 请求 }
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client 实例
func (*Client) CgiBinGetApiDomainIp ¶ added in v1.0.24
func (c *Client) CgiBinGetApiDomainIp(ctx context.Context, accessToken string, notMustParams ...*gorequest.Params) (*CgiBinGetApiDomainIpResult, error)
CgiBinGetApiDomainIp 获取企业微信接口IP段 https://developer.work.weixin.qq.com/document/path/97073
func (*Client) CgiBinGetCallBackIp ¶ added in v1.0.24
func (c *Client) CgiBinGetCallBackIp(ctx context.Context, accessToken string, notMustParams ...*gorequest.Params) (*CgiBinGetCallBackIpResult, error)
CgiBinGetCallBackIp 获取企业微信回调IP段 https://developer.work.weixin.qq.com/document/path/98988
func (*Client) CgiBinGetToken ¶
func (c *Client) CgiBinGetToken(ctx context.Context, notMustParams ...*gorequest.Params) (*CgiBinGetTokenResult, error)
CgiBinGetToken 获取access_token https://open.work.weixin.qq.com/api/doc/90000/90135/91039
func (*Client) CgiBinUserGetUserInfo ¶
func (c *Client) CgiBinUserGetUserInfo(ctx context.Context, accessToken, code string, notMustParams ...*gorequest.Params) (*CgiBinUserGetUserInfoResult, error)
CgiBinUserGetUserInfo 获取访问用户身份 https://open.work.weixin.qq.com/api/doc/90000/90135/91023
func (*Client) ConnectOauth2Authorize ¶
ConnectOauth2Authorize 构造网页授权链接 https://work.weixin.qq.com/api/doc/90000/90135/91022
func (*Client) GetAgentId ¶
func (*Client) GetRedirectUri ¶
func (*Client) SetAgentId ¶
func (*Client) SetRedirectUri ¶
func (*Client) WebhookSend ¶
func (c *Client) WebhookSend(ctx context.Context, key string, Type string, notMustParams ...*gorequest.Params) (*WebhookSendResult, error)
WebhookSend 群机器人 发送消息 https://developer.work.weixin.qq.com/document/path/99110
func (*Client) WebhookSendURL ¶ added in v1.0.24
func (c *Client) WebhookSendURL(ctx context.Context, url string, Type string, notMustParams ...*gorequest.Params) (*WebhookSendResult, error)
WebhookSendURL 群机器人 发送消息 https://developer.work.weixin.qq.com/document/path/99110
func (*Client) WwOpenSsoQrConnect ¶
WwOpenSsoQrConnect 构造独立窗口登录二维码 https://open.work.weixin.qq.com/api/doc/90000/90135/91019
type ClientConfig ¶
ClientConfig 实例配置
type WebhookSendResponse ¶
type WebhookSendResult ¶
type WebhookSendResult struct { Result WebhookSendResponse // 结果 Body []byte // 内容 Http gorequest.Response // 请求 }