@EnableConfigurationProperties(value=WXWorkProperties.class) @EnableRetry @Service public class WXWorkServiceImpl extends Object implements WXWorkService, org.springframework.beans.factory.InitializingBean
| 限定符和类型 | 字段和说明 |
|---|---|
static com.fasterxml.jackson.databind.ObjectMapper |
OBJECT_MAPPER |
| 构造器和说明 |
|---|
WXWorkServiceImpl() |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
afterPropertiesSet() |
Map<String,Object> |
callback(int callbackIndex,
String msg_signature,
String timestamp,
String nonce,
String xml,
javax.servlet.http.HttpServletResponse response)
企业内部开发 > 服务端API > 开发指南 > 回调配置 > 支持Http Post请求接收业务数据
|
byte[] |
downloadTemp(int appIndex,
String mediaId)
企业内部开发 > 服务端API > 素材管理 > 获取临时素材
|
byte[] |
downloadVoice(int appIndex,
String mediaId)
企业内部开发 > 服务端API > 素材管理 > 获取高清语音素材
|
String |
get(int appIndex,
URI url) |
Map<String,Object> |
getAppConfig(int appIndex,
String webUrl)
企业内部开发 > 客户端API > JS-SDK > 基础接口 > wx.agentConfig > 通过agentConfig注入应用的权限
|
String |
getAppTicket(int appIndex)
企业内部开发 > 客户端API > JS-SDK > 附录 > JS-SDK使用权限签名算法 > 获取应用的jsapi_ticket
|
String |
getAppTicketCache(int appIndex)
企业内部开发 > 客户端API > JS-SDK > 附录 > JS-SDK使用权限签名算法 > 获取应用的jsapi_ticket
|
String |
getAuth(int appIndex,
URI url) |
CheckinRecord |
getCheckinRecord(int openCheckinDataType,
long startTime,
long endTime,
List<String> userIdList)
企业内部开发 > 服务端API > OA > 打卡 > 获取打卡记录数据
|
Map<String,Object> |
getCorpConfig(int appIndex,
String webUrl)
企业内部开发 > 客户端API > JS-SDK > 开始开发 > 使用说明 > 通过config接口注入权限验证配置
|
String |
getCorpTicket(int appIndex)
企业内部开发 > 客户端API > JS-SDK > 附录 > JS-SDK使用权限签名算法 > 获取企业的jsapi_ticket
|
String |
getCorpTicketCache(int appIndex)
企业内部开发 > 客户端API > JS-SDK > 附录 > JS-SDK使用权限签名算法 > 获取企业的jsapi_ticket
|
DepartmentList |
getDepartmentList(int appIndex,
int departmentId)
企业内部开发 > 服务端API > 通讯录管理 > 部门管理 > 获取部门列表
|
DepartmentUser |
getDepartmentUser(int appIndex,
int departmentId,
int fetchChild)
企业内部开发 > 服务端API > 通讯录管理 > 成员管理 > 获取部门成员
|
TagList |
getTagList()
企业内部开发 > 服务端API > 通讯录管理 > 标签管理 > 获取标签列表
|
TagUser |
getTagUser(int tagId)
企业内部开发 > 服务端API > 通讯录管理 > 标签管理 > 获取标签成员
|
String |
getToken(int appIndex)
企业内部开发 > 服务端API > 开发指南 > 获取access_token
|
String |
getTokenCache(int appIndex)
企业内部开发 > 服务端API > 开发指南 > 获取access_token
|
User |
getUser(int appIndex,
String code)
企业内部开发 > 服务端API > 身份验证 > 网页授权登录 > 获取访问用户身份
|
UserInfo |
getUserInfo(int appIndex,
String userId)
企业内部开发 > 服务端API > 通讯录管理 > 成员管理 > 读取成员
|
byte[] |
post(int appIndex,
URI url) |
String |
post(int appIndex,
URI url,
Object body) |
String |
post(int appIndex,
URI url,
String filePath) |
AppMsg |
sendAppMarkdownMsg(int appIndex,
AppMarkdownMsg object)
企业内部开发 > 服务端API > 消息推送 > 发送应用消息 > markdown消息
|
AppMsg |
sendAppTextMsg(int appIndex,
AppTextMsg object)
企业内部开发 > 服务端API > 消息推送 > 发送应用消息 > 文本消息
|
BotMsg |
sendBotMarkdownMsg(int botIndex,
BotMarkdownMsg object)
企业内部开发 > 客户端API > 群机器人 > 群机器人配置说明 > markdown类型
|
BotMsg |
sendBotTextMsg(int botIndex,
BotTextMsg object)
企业内部开发 > 客户端API > 群机器人 > 群机器人配置说明 > 文本类型
|
UploadImage |
uploadImage(int appIndex,
String filePath)
企业内部开发 > 服务端API > 素材管理 > 上传图片
|
UploadTemp |
uploadTemp(int appIndex,
UploadTempType tempType,
String filePath)
企业内部开发 > 服务端API > 素材管理 > 上传临时素材
|
void |
verifyUrl(int callbackIndex,
String msg_signature,
String timestamp,
String nonce,
String echostr,
javax.servlet.http.HttpServletResponse response)
企业内部开发 > 服务端API > 开发指南 > 回调配置 > 支持Http Get请求验证URL有效性
|
public void afterPropertiesSet()
afterPropertiesSet 在接口中 org.springframework.beans.factory.InitializingBeanpublic String getToken(int appIndex)
WXWorkServicegetToken 在接口中 WXWorkServiceappIndex - 索引public String getTokenCache(int appIndex)
WXWorkServicegetTokenCache 在接口中 WXWorkServiceappIndex - 索引WXWorkService.getToken(int)public void verifyUrl(int callbackIndex,
String msg_signature,
String timestamp,
String nonce,
String echostr,
javax.servlet.http.HttpServletResponse response)
WXWorkServiceverifyUrl 在接口中 WXWorkServicecallbackIndex - 索引msg_signature - 企业微信加密签名,msg_signature计算结合了企业填写的token、请求中的timestamp、nonce、加密的消息体timestamp - 时间戳(与nonce结合使用,用于防止请求重放攻击)nonce - 随机数(与timestamp结合使用,用于防止请求重放攻击)echostr - 加密的字符串(需要解密得到消息内容明文,解密后有random、msg_len、msg、receiveid四个字段,其中msg即为消息内容明文)response - 响应public Map<String,Object> callback(int callbackIndex, String msg_signature, String timestamp, String nonce, String xml, javax.servlet.http.HttpServletResponse response)
WXWorkServicecallback 在接口中 WXWorkServicecallbackIndex - 索引msg_signature - 企业微信加密签名,msg_signature结合了企业填写的token、请求中的timestamp、nonce参数、加密的消息体timestamp - 时间戳(与nonce结合使用,用于防止请求重放攻击)nonce - 随机数(与timestamp结合使用,用于防止请求重放攻击)xml - 回调数据(放在 HTTP 请求体中,使用注解 RequestBody 接收)response - 响应Mappublic UserInfo getUserInfo(int appIndex, String userId)
WXWorkServicegetUserInfo 在接口中 WXWorkServiceappIndex - 索引userId - 工号UserInfopublic DepartmentUser getDepartmentUser(int appIndex, int departmentId, int fetchChild)
WXWorkServicegetDepartmentUser 在接口中 WXWorkServiceappIndex - 索引departmentId - 部门 idfetchChild - 是否递归获取子部门下面的成员(1-递归获取,0-只获取本部门)DepartmentUserpublic DepartmentList getDepartmentList(int appIndex, int departmentId)
WXWorkServicegetDepartmentList 在接口中 WXWorkServiceappIndex - 索引departmentId - 部门 id,获取指定部门及其下的子部门(以及子部门的子部门等等,递归);如果不填,默认获取全量组织架构DepartmentListpublic TagUser getTagUser(int tagId)
WXWorkServicegetTagUser 在接口中 WXWorkServicetagId - 标签 idTagUserpublic TagList getTagList()
WXWorkServicegetTagList 在接口中 WXWorkServiceTagListpublic User getUser(int appIndex, String code)
WXWorkServicegetUser 在接口中 WXWorkServiceappIndex - 索引code - 企业微信授权码,仅可使用一次,5 分钟内有效Userpublic AppMsg sendAppTextMsg(int appIndex, AppTextMsg object)
WXWorkServicesendAppTextMsg 在接口中 WXWorkServiceappIndex - 索引object - AppTextMsgAppMsgpublic AppMsg sendAppMarkdownMsg(int appIndex, AppMarkdownMsg object)
WXWorkServicesendAppMarkdownMsg 在接口中 WXWorkServiceappIndex - 索引object - AppMarkdownMsgAppMsgpublic UploadTemp uploadTemp(int appIndex, UploadTempType tempType, String filePath)
WXWorkServiceuploadTemp 在接口中 WXWorkServiceappIndex - 索引tempType - UploadTempTypefilePath - 临时素材绝对路径UploadTemppublic UploadImage uploadImage(int appIndex, String filePath)
WXWorkServiceuploadImage 在接口中 WXWorkServiceappIndex - 索引filePath - 图片绝对路径UploadImagepublic byte[] downloadTemp(int appIndex,
String mediaId)
WXWorkServicedownloadTemp 在接口中 WXWorkServiceappIndex - 索引mediaId - 媒体文件 idpublic byte[] downloadVoice(int appIndex,
String mediaId)
WXWorkServicedownloadVoice 在接口中 WXWorkServiceappIndex - 索引mediaId - 媒体文件 idpublic CheckinRecord getCheckinRecord(int openCheckinDataType, long startTime, long endTime, List<String> userIdList)
WXWorkServicegetCheckinRecord 在接口中 WXWorkServiceopenCheckinDataType - 打卡类型(1-上下班打卡,2-外出打卡,3-全部打卡)startTime - 获取打卡记录的开始时间(10 位 Unix 时间戳)endTime - 获取打卡记录的结束时间(10 位 Unix 时间戳)userIdList - 工号集合(至多 100 个)CheckinRecordpublic String getCorpTicket(int appIndex)
WXWorkServicegetCorpTicket 在接口中 WXWorkServiceappIndex - 索引public String getCorpTicketCache(int appIndex)
WXWorkServicegetCorpTicketCache 在接口中 WXWorkServiceappIndex - 索引WXWorkService.getCorpTicket(int)public String getAppTicket(int appIndex)
WXWorkServicegetAppTicket 在接口中 WXWorkServiceappIndex - 索引public String getAppTicketCache(int appIndex)
WXWorkServicegetAppTicketCache 在接口中 WXWorkServiceappIndex - 索引WXWorkService.getAppTicket(int)public Map<String,Object> getCorpConfig(int appIndex, String webUrl)
WXWorkServicegetCorpConfig 在接口中 WXWorkServiceappIndex - 索引webUrl - window.location.hrefMappublic Map<String,Object> getAppConfig(int appIndex, String webUrl)
WXWorkServicegetAppConfig 在接口中 WXWorkServiceappIndex - 索引webUrl - window.location.hrefMappublic BotMsg sendBotTextMsg(int botIndex, BotTextMsg object)
WXWorkServicesendBotTextMsg 在接口中 WXWorkServicebotIndex - 索引object - BotTextMsgBotMsgpublic BotMsg sendBotMarkdownMsg(int botIndex, BotMarkdownMsg object)
WXWorkServicesendBotMarkdownMsg 在接口中 WXWorkServicebotIndex - 索引object - BotMarkdownMsgBotMsg@Retryable
public byte[] post(int appIndex,
URI url)
Copyright © 2022. All rights reserved.