Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

larksuiteoapi.api.Request 不支持服务台API的token #12

Closed
ssz66666 opened this issue May 26, 2021 · 2 comments
Closed

larksuiteoapi.api.Request 不支持服务台API的token #12

ssz66666 opened this issue May 26, 2021 · 2 comments

Comments

@ssz66666
Copy link

飞书服务台API要求在HTTP请求头中加入X-Lark-Helpdesk-Authorization字段。

请求中代入服务台token,表示拥有和服务台负责人相同的权限(查看修改服务台实体)。
使用方法,设置在请求Header中:

  • Header Key: X-Lark-Helpdesk-Authorization
  • Header Value: base64(helpdesk_id:helpdesk_token), 通过base64加密将helpdesk_id和helpdesk_token用':'连接而成的字符串。

目前SDK中的larksuiteoapi.api.Request没有自定义header的选项。若调用服务台API,需要直接修改存在larksuiteoapi.api.Request.sessionrequests.Session对象的headers,暴露了其实现细节。

建议SDK在后续添加服务台API服务的支持,并优化Request对象的接口。

@zhaoche27
Copy link
Contributor

谢谢你的反馈,这个能力我们应该会支持的。 支持了,会同步到这。

@zhaoche27
Copy link
Contributor

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants