wecom

package
v0.0.32 Latest Latest
Warning

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

Go to latest
Published: Aug 25, 2022 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Overview

basic.go 对应的是 https://work.weixin.qq.com/api/doc/90000/90135/90193 文档内容

basic.go 对应的是 https://work.weixin.qq.com/api/doc/90000/90135/90226 文档内容

basic.go 对应的是 https://work.weixin.qq.com/api/doc/90000/90135/91054 文档内容 basic.go 对应的是 文档内容

basic.go 对应的是 https://work.weixin.qq.com/api/doc/90000/90135/91020 文档内容

basic.go 对应的是 https://work.weixin.qq.com/api/doc/90000/90135/90664 文档内容 主要实现了是获取 access_token 的 API

basic.go 对应的是 https://work.weixin.qq.com/api/doc/90000/90135/92109 文档内容

basic.go 对应的是 https://work.weixin.qq.com/api/doc/90000/90135/90283 文档内容

basic.go 对应的是 https://work.weixin.qq.com/api/doc/90000/90135/93360 文档内容

basic.go 对应的是 https://work.weixin.qq.com/api/doc/90000/90135/90273 文档内容

basic.go 对应的是 https://work.weixin.qq.com/api/doc/90000/90135/93512 文档内容

basic.go 对应的是 https://work.weixin.qq.com/api/doc/90000/90135/90235 文档内容

basic.go 对应的是 https://work.weixin.qq.com/api/doc/90000/90135/90261 文档内容

basic.go 对应的是 https://work.weixin.qq.com/api/doc/90000/90135/93674 文档内容

basic.go 对应的是 https://work.weixin.qq.com/api/doc/90000/90135/91638 文档内容

basic.go 对应的是 https://work.weixin.qq.com/api/doc/90000/90135/91360 文档内容

basic.go 对应的是 https://work.weixin.qq.com/api/doc/90000/90135/93623 文档内容

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewWithHTTPClientOption added in v0.0.2

func NewWithHTTPClientOption(client *http.Client) options

func NewWithHostOption added in v0.0.2

func NewWithHostOption(host string) options

func NewWithMaxRetryTimesOption added in v0.0.24

func NewWithMaxRetryTimesOption(maxRetryTimes uint) options

func NewWithPrintPayloadOption added in v0.0.16

func NewWithPrintPayloadOption(printPayload bool) options

Types

type Attrs added in v0.0.11

type Attrs struct {
	Type int    `json:"type,omitempty"`
	Name string `json:"name,omitempty"`
	Text Text   `json:"text,omitempty"`
	Web  Web    `json:"web,omitempty"`
}

type Basic

type Basic struct {
	AccessToken string `json:"access_token"`
	ExpiresIn   int64  `json:"expires_in"`
	// contains filtered or unexported fields
}

func (Basic) GetErrCode added in v0.0.2

func (b Basic) GetErrCode() int

func (Basic) GetErrMsg added in v0.0.2

func (b Basic) GetErrMsg() string

type Client

type Client struct {
	Basic   *basicService
	Address *addressService
	// contains filtered or unexported fields
}

客户端

func NewClient

func NewClient(enterpriseID, agentSecret string, opts ...options) (c *Client, err error)

func (Client) String added in v0.0.3

func (c Client) String() string

type Department added in v0.0.10

type Department struct {
	ID       int    `json:"id"`
	Name     string `json:"name"`
	Parentid int    `json:"parentid"`
	Order    int    `json:"order"`
}

type DepartmentList added in v0.0.10

type DepartmentList struct {
	Department []Department `json:"department"`
	// contains filtered or unexported fields
}

部门列表

func (DepartmentList) GetErrCode added in v0.0.10

func (b DepartmentList) GetErrCode() int

func (DepartmentList) GetErrMsg added in v0.0.10

func (b DepartmentList) GetErrMsg() string

type DetailUserList added in v0.0.32

type DetailUserList struct {
	Userlist []User `json:"userlist"`
	// contains filtered or unexported fields
}

func (DetailUserList) GetErrCode added in v0.0.32

func (b DetailUserList) GetErrCode() int

func (DetailUserList) GetErrMsg added in v0.0.32

func (b DetailUserList) GetErrMsg() string

type Extattr added in v0.0.11

type Extattr struct {
	Attrs []Attrs `json:"attrs,omitempty"`
}

type ExternalAttr added in v0.0.11

type ExternalAttr struct {
	Type        int         `json:"type,omitempty"`
	Name        string      `json:"name,omitempty"`
	Text        Text        `json:"text,omitempty"`
	Web         Web         `json:"web,omitempty"`
	Miniprogram Miniprogram `json:"miniprogram,omitempty"`
}

type ExternalProfile added in v0.0.11

type ExternalProfile struct {
	ExternalCorpName string         `json:"external_corp_name,omitempty"`
	ExternalAttr     []ExternalAttr `json:"external_attr,omitempty"`
}

type Miniprogram added in v0.0.11

type Miniprogram struct {
	Appid    string `json:"appid"`
	Pagepath string `json:"pagepath"`
	Title    string `json:"title"`
}

type SimpleUser added in v0.0.28

type SimpleUser struct {
	Userid     string `json:"userid"`
	Name       string `json:"name"`
	Department []int  `json:"department"`
}

type SimpleUserList added in v0.0.28

type SimpleUserList struct {
	Userlist []SimpleUser `json:"userlist"`
	// contains filtered or unexported fields
}

func (SimpleUserList) GetErrCode added in v0.0.28

func (b SimpleUserList) GetErrCode() int

func (SimpleUserList) GetErrMsg added in v0.0.28

func (b SimpleUserList) GetErrMsg() string

type SimpleUserWithMainDepartment added in v0.0.30

type SimpleUserWithMainDepartment struct {
	Userid         string `json:"userid"`
	Name           string `json:"name"`
	Department     []int  `json:"department"`
	MainDepartment int    `json:"main_department"`
}

type Text added in v0.0.11

type Text struct {
	Value string `json:"value"`
}

type User

type User struct {
	Userid           string           `json:"userid"`
	Name             string           `json:"name,omitempty"`
	Alias            string           `json:"alias,omitempty"`
	Mobile           string           `json:"mobile,omitempty"`
	Department       []int            `json:"department,omitempty"`
	Order            []int            `json:"order,omitempty"`
	Position         string           `json:"position,omitempty"`
	Gender           string           `json:"gender,omitempty"`
	Email            string           `json:"email,omitempty"`
	IsLeaderInDept   []int            `json:"is_leader_in_dept,omitempty"`
	Enable           *int             `json:"enable,omitempty"`
	AvatarMediaid    string           `json:"avatar_mediaid,omitempty"`
	Telephone        string           `json:"telephone,omitempty"`
	Address          string           `json:"address,omitempty"`
	MainDepartment   int              `json:"main_department,omitempty"`
	Extattr          *Extattr         `json:"extattr,omitempty"`
	ToInvite         *bool            `json:"to_invite,omitempty"`
	ExternalPosition string           `json:"external_position,omitempty"`
	ExternalProfile  *ExternalProfile `json:"external_profile,omitempty"`
	DirectLeader     []string         `json:"direct_leader,omitempty"`
	// contains filtered or unexported fields
}

https://work.weixin.qq.com/api/doc/90000/90135/90195

func (User) GetErrCode added in v0.0.2

func (b User) GetErrCode() int

func (User) GetErrMsg added in v0.0.2

func (b User) GetErrMsg() string

type UserList added in v0.0.30

type UserList struct {
	Userlist []SimpleUserWithMainDepartment `json:"userlist"`
	// contains filtered or unexported fields
}

func (UserList) GetErrCode added in v0.0.30

func (b UserList) GetErrCode() int

func (UserList) GetErrMsg added in v0.0.30

func (b UserList) GetErrMsg() string

type UserResp

type UserResp struct {
	// contains filtered or unexported fields
}

func (UserResp) GetErrCode added in v0.0.2

func (b UserResp) GetErrCode() int

func (UserResp) GetErrMsg added in v0.0.2

func (b UserResp) GetErrMsg() string

type Web added in v0.0.11

type Web struct {
	URL   string `json:"url"`
	Title string `json:"title"`
}

Jump to

Keyboard shortcuts

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