管理员令牌
🌐 Admin tokens
Page summary:管理员令牌用于验证对 Strapi 管理 API 的程序化访问。每个令牌的权限范围是其所有者权限的一个子集,并设计用于自动化工作流程,例如 MCP 代理、CI/CD 管道和脚本。
管理员令牌允许自动化客户端对 Strapi 管理 API 的请求进行身份验证。若要对内容 API 的请求进行身份验证,请参见 API 令牌。
🌐 Admin tokens allow automated clients to authenticate requests to the Strapi Admin API. For authenticating requests to the Content API, see API Tokens.
管理员令牌和API令牌严格分开:每种令牌在另一种令牌的路由上都会被拒绝。
🌐 Admin tokens and API tokens are strictly separated: each is rejected on the other's routes.
免费功能
默认对超级管理员激活。每个更底层的角色需要在“角色 > 设置 - 管理令牌”中显式授予权限。
默认可用并已激活
在开发和生产环境中均可用

配置
🌐 Configuration
管理员令牌完全通过管理员面板进行配置。没有基于代码的配置是专门针对管理员令牌的。适用于所有令牌类型的共享盐值和加密密钥通过你在 /config/admin 文件中的 apiToken.salt 和 apiToken.secrets.encryptionKey 设置(参见 API 令牌)。
🌐 Admin tokens are configured entirely from the admin panel. No code-based configuration is specific to Admin tokens. The shared salt and encryption key that apply to all token kinds are set via apiToken.salt and apiToken.secrets.encryptionKey in your /config/admin file (see API tokens).
配置此功能的路径: 设置 > 管理面板 > 管理员令牌