Skip to content

获取会话内容存档开启成员列表,提示“API接口无权限调用” #3563

Open
@zhanghuijun0

Description

@zhanghuijun0

简要描述

使用调用「获取会话内容存档开启成员列表」接口 get_permit_user_list

me.chanjar.weixin.cp.api.WxCpMsgAuditService#getPermitUserList

https://qyapi.weixin.qq.com/cgi-bin/msgaudit/get_permit_user_list?access_token=ACCESS_TOKEN

模块版本情况

  • WxJava 模块名: weixin-java-cp
  • WxJava 版本号: 4.7.0

详细描述

调用接口get_permit_user_list ,应该使用“会话内容存档”页面的secret生成的accessToken,而不是应用的secret,accessToken获得页面为:https://work.weixin.qq.com/wework_admin/frame#/financial/corpEncryptData

日志

Caused by: me.chanjar.weixin.common.error.WxErrorException: 错误代码:48002, 错误信息:API接口无权限调用,微信原始报文:{"errcode":48002,"errmsg":"api forbidden, hint: [1745481144594130532181532], from ip: 47.98.*.*, more info at https://open.work.weixin.qq.com/devtool/query?e=48002","ids":[]}
	at me.chanjar.weixin.common.util.http.SimplePostRequestExecutor.handleResponse(SimplePostRequestExecutor.java:57) ~[weixin-java-common-4.7.0.jar!/:?]
	at me.chanjar.weixin.common.util.http.apache.ApacheSimplePostRequestExecutor.execute(ApacheSimplePostRequestExecutor.java:44) ~[weixin-java-common-4.7.0.jar!/:?]
	at me.chanjar.weixin.common.util.http.apache.ApacheSimplePostRequestExecutor.execute(ApacheSimplePostRequestExecutor.java:23) ~[weixin-java-common-4.7.0.jar!/:?]
	at me.chanjar.weixin.cp.api.impl.BaseWxCpServiceImpl.executeInternal(BaseWxCpServiceImpl.java:364) ~[weixin-java-cp-4.7.0.jar!/:?]

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions