tag

package
v0.1.3 Latest Latest
Warning

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

Go to latest
Published: Mar 15, 2023 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Overview

Package tag 通讯录管理/标签管理

Index

Examples

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddTagUsers

func AddTagUsers(ctx *corporation.App, payload []byte) (resp []byte, err error)

增加标签成员

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

POST https://qyapi.weixin.qq.com/cgi-bin/tag/addtagusers?access_token=ACCESS_TOKEN

Example
package main

import (
	"fmt"

	"github.com/arkii/wxwork/corporation"
	"github.com/arkii/wxwork/corporation/apis/contact/tag"
)

func main() {
	var ctx *corporation.App

	payload := []byte("{}")
	resp, err := tag.AddTagUsers(ctx, payload)

	fmt.Println(resp, err)
}
Output:

func Create

func Create(ctx *corporation.App, payload []byte) (resp []byte, err error)

创建标签

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

POST https://qyapi.weixin.qq.com/cgi-bin/tag/create?access_token=ACCESS_TOKEN

Example
package main

import (
	"fmt"

	"github.com/arkii/wxwork/corporation"
	"github.com/arkii/wxwork/corporation/apis/contact/tag"
)

func main() {
	var ctx *corporation.App

	payload := []byte("{}")
	resp, err := tag.Create(ctx, payload)

	fmt.Println(resp, err)
}
Output:

func DelTagUsers

func DelTagUsers(ctx *corporation.App, payload []byte) (resp []byte, err error)

删除标签成员

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

POST https://qyapi.weixin.qq.com/cgi-bin/tag/deltagusers?access_token=ACCESS_TOKEN

Example
package main

import (
	"fmt"

	"github.com/arkii/wxwork/corporation"
	"github.com/arkii/wxwork/corporation/apis/contact/tag"
)

func main() {
	var ctx *corporation.App

	payload := []byte("{}")
	resp, err := tag.DelTagUsers(ctx, payload)

	fmt.Println(resp, err)
}
Output:

func Delete

func Delete(ctx *corporation.App, params url.Values) (resp []byte, err error)

删除标签

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

GET https://qyapi.weixin.qq.com/cgi-bin/tag/delete?access_token=ACCESS_TOKEN&tagid=TAGID

Example
package main

import (
	"fmt"
	"net/url"

	"github.com/arkii/wxwork/corporation"
	"github.com/arkii/wxwork/corporation/apis/contact/tag"
)

func main() {
	var ctx *corporation.App

	params := url.Values{}
	resp, err := tag.Delete(ctx, params)

	fmt.Println(resp, err)
}
Output:

func Get

func Get(ctx *corporation.App, params url.Values) (resp []byte, err error)

获取标签成员

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

GET https://qyapi.weixin.qq.com/cgi-bin/tag/get?access_token=ACCESS_TOKEN&tagid=TAGID

Example
package main

import (
	"fmt"
	"net/url"

	"github.com/arkii/wxwork/corporation"
	"github.com/arkii/wxwork/corporation/apis/contact/tag"
)

func main() {
	var ctx *corporation.App

	params := url.Values{}
	resp, err := tag.Get(ctx, params)

	fmt.Println(resp, err)
}
Output:

func List

func List(ctx *corporation.App) (resp []byte, err error)

获取标签列表

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

GET https://qyapi.weixin.qq.com/cgi-bin/tag/list?access_token=ACCESS_TOKEN

Example
package main

import (
	"fmt"

	"github.com/arkii/wxwork/corporation"
	"github.com/arkii/wxwork/corporation/apis/contact/tag"
)

func main() {
	var ctx *corporation.App

	resp, err := tag.List(ctx)

	fmt.Println(resp, err)
}
Output:

func Update

func Update(ctx *corporation.App, payload []byte) (resp []byte, err error)

更新标签名字

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

POST https://qyapi.weixin.qq.com/cgi-bin/tag/update?access_token=ACCESS_TOKEN

Example
package main

import (
	"fmt"

	"github.com/arkii/wxwork/corporation"
	"github.com/arkii/wxwork/corporation/apis/contact/tag"
)

func main() {
	var ctx *corporation.App

	payload := []byte("{}")
	resp, err := tag.Update(ctx, payload)

	fmt.Println(resp, err)
}
Output:

Types

This section is empty.

Jump to

Keyboard shortcuts

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