英文:
Is the slack bot access token will be same for all distributed workspace when app will be published in app directory?
问题
- Slack 应用凭证,如应用ID、客户端ID、客户端密钥和签名密钥,在我尝试在不同的工作区安装我的Slack应用或保持相同的情况下是否会变化?
- 当应用被发布到应用目录中时,Slack机器人访问令牌是否会在所有分发的工作区中相同?
- 应用级令牌是否对所有工作区相同,还是仅属于应用本身?
英文:
I am working on a slack bot project. I have some questions about slack App Credentials, bot tokens, and app-level tokens.
- Are the slack app credentials like App id, Client id, Client Secret, and Signing Secret varies when I try to install my slack app on different workspaces or keep the same?
- Is the slack bot access token will be the same for all distributed workspaces when the app will be published in the app directory?
- Is the app-level token is same for all workspaces or only belong to the app?
答案1
得分: 1
你好,欢迎来到Slack应用开发!
-
你的Slack应用凭证,如应用ID、客户端ID和客户端密钥,是特定于你的应用并且除非重新生成其中任何一个或创建一个新的应用容器,否则保持不变。如果你正在构建公共Slack应用目录的应用,你的应用还会有一个具有不同ID和密钥集的开发版本。这些密钥和标识是你用来告诉Slack你的应用是你的应用,并有权与Slack一起工作的方式。
-
机器人访问令牌是特定于安装的,你将机器人用户安装到的每个工作区都会有一个不同的机器人访问令牌。根据特定交互或调用所涉及的工作区,由你的应用来切换上下文并使用正确的令牌。
-
应用级别令牌代表你的应用和Slack之间的代理关系,不明确与安装在上面的任何工作区相关联。它有非常有限的用例之一,但其中之一允许你从包括你的应用同时安装的所有工作区的角度连接到事件API的Socket Mode接口。
要在每个工作区安装时接收机器人用户令牌,你需要支持OAuth令牌协商序列。 Bolt SDKs Slack提供对OAuth的支持。
英文:
Hello there and welcome to Slack app development!
-
Your Slack app's credentials like app ID, client ID, and client secret are specific to your app and remain constant unless you regenerate any of them or create a new app container. If you're building for the public Slack app directory, your app will also have a development edition with a different set of IDs and secrets. These secrets and identifiers are how you identify to Slack that your app is your app and is entitled to work with Slack.
-
A bot access token is specific to an installation, each workspace you install a bot user into will have a different bot access token. It's up to your app to switch contexts and use the right token based on the workspace involved in a specific interaction or invocation.
-
The app-level token represents agency between your app and Slack and does not explicitly relate to any workspace it is installed on. It has a very limited set of use cases, but one of them allows you to connect to the Socket Mode interface for the Events API, from a perspective that includes all workspaces your app is installed on simultaneously.
To receive a bot user token upon each workspace installation, you will need to support the OAuth token negotiation sequence. The Bolt SDKs Slack provides support OAuth.
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论