Documentation
¶
Index ¶
- type Changes
- type Wechat
- func (w *Wechat) AccessToken(c context.Context, app *model.AppConfig) (token string, err error)
- func (w *Wechat) AnalysisContacts(c context.Context) (err error)
- func (w *Wechat) NewTxtNotify(content string) (txtMsg *model.TxtNotification)
- func (w *Wechat) PushMsg(c context.Context, userNames []string, content string) (err error)
- func (w *Wechat) QueryWechatContacts(c context.Context) (contacts []*model.ContactInfo, err error)
- func (w *Wechat) SyncContacts(c context.Context) (err error)
- func (w *Wechat) UpdateVisible(c context.Context) (err error)
- func (w *Wechat) UserIds(userNames []string) (ids string, err error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Changes ¶
type Changes struct { Adds []*model.ContactInfo Upts []*model.ContactInfo Dels []*model.ContactInfo }
Changes changes structure
type Wechat ¶
type Wechat struct {
// contains filtered or unexported fields
}
Wechat 企业微信应用
func (*Wechat) AccessToken ¶
AccessToken get access_token from cache first, if not found, get it via wechat api.
func (*Wechat) AnalysisContacts ¶
AnalysisContacts analysis the contact difference and save them 从企业微信更新用户列表最新
func (*Wechat) NewTxtNotify ¶
func (w *Wechat) NewTxtNotify(content string) (txtMsg *model.TxtNotification)
NewTxtNotify create wechat format text notification 从配置初始化企业微信TxtNotification
func (*Wechat) PushMsg ¶
PushMsg push text message via wechat notification api with access_token.推送企业微信
func (*Wechat) QueryWechatContacts ¶
QueryWechatContacts query wechat contacts with access token 获取用户信息列表
func (*Wechat) SyncContacts ¶
SyncContacts sync the contacts from wechat work 更新用户信息列表
func (*Wechat) UpdateVisible ¶
UpdateVisible update the visible property 更新用户saga信息
Click to show internal directories.
Click to hide internal directories.