msg

package
v0.0.0-...-90ff682 Latest Latest
Warning

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

Go to latest
Published: Mar 7, 2022 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetQWechatAccessTokenString

func GetQWechatAccessTokenString(appSecretName string) (string, error)

func SendMsgToQYUserWithBuzHelper

func SendMsgToQYUserWithBuzHelper(markdownMsg string, qyUid int64) error

Types

type QWUser

type QWUser struct {
	Userid     string `json:"userid"`
	Name       string `json:"name"`
	Department []int  `json:"department"`
	Position   string `json:"position"`
	Mobile     string `json:"mobile"`
	Gender     string `json:"gender"`
	Email      string `json:"email"`
	Avatar     string `json:"avatar"`
	Status     int    `json:"status"`
	Enable     int    `json:"enable"`
	Isleader   int    `json:"isleader"`
	Extattr    struct {
		Attrs []interface{} `json:"attrs"`
	} `json:"extattr"`
	HideMobile      int     `json:"hide_mobile"`
	EnglishName     string  `json:"english_name"`
	Telephone       string  `json:"telephone"`
	Order           []int64 `json:"order"`
	MainDepartment  int     `json:"main_department"`
	QrCode          string  `json:"qr_code"`
	Alias           string  `json:"alias"`
	IsLeaderInDept  []int   `json:"is_leader_in_dept"`
	ThumbAvatar     string  `json:"thumb_avatar"`
	ExternalProfile struct {
		ExternalAttr     []interface{} `json:"external_attr"`
		ExternalCorpName string        `json:"external_corp_name"`
	} `json:"external_profile,omitempty"`
	Address string `json:"address,omitempty"`
}

type StorageToken

type StorageToken struct {
	Token     string
	StartTime time.Time
	ExpiresIn int
	EndTime   time.Time
}

type WXRes

type WXRes struct {
	Errcode     int      `json:"errcode"`
	Errmsg      string   `json:"errmsg"`
	AccessToken string   `json:"access_token"`
	ExpiresIn   int      `json:"expires_in"`
	Msgid       string   `json:"msgid"`
	Userlist    []QWUser `json:"userlist"`
}

func GetQWechatAccessToken

func GetQWechatAccessToken(appSecretName string) (*WXRes, error)

func WXSendRequest

func WXSendRequest(url string, params map[string]interface{}, accessToken string, method string) (*WXRes, error)

Jump to

Keyboard shortcuts

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