public class WxCpTagServiceImpl extends Object implements WxCpTagService
标签管理接口. Created by Binary Wang on 2017-6-25.
| 构造器和说明 |
|---|
WxCpTagServiceImpl() |
| 限定符和类型 | 方法和说明 |
|---|---|
WxCpTagAddOrRemoveUsersResult |
addUsers2Tag(String tagId,
List<String> userIds,
List<String> partyIds)
增加标签成员.
|
String |
create(String tagName)
创建标签.
|
String |
create(String name,
Integer id)
创建标签.
|
void |
delete(String tagId)
删除标签.
|
WxCpTagGetResult |
get(String tagId)
获取标签成员.
|
List<WxCpTag> |
listAll()
获得标签列表.
|
List<WxCpUser> |
listUsersByTagId(String tagId)
获取标签成员.
|
WxCpTagAddOrRemoveUsersResult |
removeUsersFromTag(String tagId,
List<String> userIds,
List<String> partyIds)
移除标签成员.
|
void |
update(String tagId,
String tagName)
更新标签.
|
public String create(String name, Integer id) throws WxErrorException
WxCpTagService请求地址:https://qyapi.weixin.qq.com/cgi-bin/tag/create?access_token=ACCESS_TOKEN 文档地址:https://work.weixin.qq.com/api/doc#90000/90135/90210
create 在接口中 WxCpTagServicename - 标签名称,长度限制为32个字以内(汉字或英文字母),标签名不可与其他标签重名。id - 标签id,非负整型,指定此参数时新增的标签会生成对应的标签id,不指定时则以目前最大的id自增。WxErrorException - .public String create(String tagName) throws WxErrorException
WxCpTagServicecreate 在接口中 WxCpTagServicetagName - 标签名WxErrorException - .public void update(String tagId, String tagName) throws WxErrorException
WxCpTagServiceupdate 在接口中 WxCpTagServicetagId - 标签idtagName - 标签名WxErrorException - .public void delete(String tagId) throws WxErrorException
WxCpTagServicedelete 在接口中 WxCpTagServicetagId - 标签idWxErrorException - .public List<WxCpTag> listAll() throws WxErrorException
WxCpTagServicelistAll 在接口中 WxCpTagServiceWxErrorException - .public List<WxCpUser> listUsersByTagId(String tagId) throws WxErrorException
WxCpTagServicelistUsersByTagId 在接口中 WxCpTagServicetagId - 标签IDWxErrorException - .public WxCpTagAddOrRemoveUsersResult addUsers2Tag(String tagId, List<String> userIds, List<String> partyIds) throws WxErrorException
WxCpTagServiceaddUsers2Tag 在接口中 WxCpTagServicetagId - 标签iduserIds - 用户ID 列表partyIds - 企业部门ID列表WxErrorException - .public WxCpTagAddOrRemoveUsersResult removeUsersFromTag(String tagId, List<String> userIds, List<String> partyIds) throws WxErrorException
WxCpTagServiceremoveUsersFromTag 在接口中 WxCpTagServicetagId - 标签iduserIds - 用户id列表partyIds - 企业部门ID列表WxErrorException - .public WxCpTagGetResult get(String tagId) throws WxErrorException
WxCpTagServiceget 在接口中 WxCpTagServicetagId - 标签idWxErrorException - .Copyright © 2020. All rights reserved.