feat: add scoped tenant api keys

This commit is contained in:
wizardchen
2026-07-05 10:25:37 +08:00
committed by lyingbug
parent 1708d6895a
commit 505bc7ddec
49 changed files with 2899 additions and 1578 deletions
+34 -3
View File
@@ -5756,12 +5756,43 @@ export default {
baseUrl: 'API Base URL',
baseUrlDesc: 'Use this base URL with REST API paths.',
apiKey: 'Tenant API Key',
apiKeyDesc: 'The API key is still tenant-level. User identity is supplied by the principal mode below.',
apiKeyDesc: 'Create API keys with operation permissions and knowledge-base scope.',
apiKeys: 'API Keys',
apiKeysDesc: 'Create separate keys per integration and restrict operation permissions plus knowledge-base access.',
createApiKey: 'Create API Key',
createApiKeyDialogDesc: 'Set permissions and available knowledge bases.',
noApiKeys: 'No API keys',
apiKeyName: 'Name',
apiKeyValue: 'API Key',
apiKeyNamePlaceholder: 'Example: MCP read-only access',
apiKeyNameRequired: 'Enter an API key name',
toggleApiKeyVisible: 'Show or hide API key',
apiKeyScopes: 'Permissions',
apiKeyScopeRequired: 'Select at least one permission',
apiKeyKnowledgeScope: 'Knowledge bases',
apiKeyKnowledgeScopePlaceholder: 'Leave empty to allow all knowledge bases',
scopeRead: 'Read',
scopeWrite: 'Write',
scopeAdmin: 'Admin',
scopeReadDesc: 'Query, search, and chat without changing knowledge-base content.',
scopeWriteDesc: 'Create, update, or delete knowledge-base content within the selected scope.',
scopeAdminDesc: 'Manage tenant-level settings; API keys cannot manage API keys.',
allKnowledgeBases: 'All knowledge bases',
createdAt: 'Created',
actions: 'Actions',
deleteApiKey: 'Delete',
deleteApiKeyConfirm: 'After deletion this API key is revoked immediately and deployed integrations using it will stop working.',
deleteApiKeySuccess: 'API key deleted',
deleteApiKeyFailed: 'Failed to delete API key',
createApiKeyFailed: 'Failed to create API key',
loadApiKeysFailed: 'Failed to load API keys',
apiKeyCreated: 'API key created',
apiKeyCreatedDesc: 'The API key has been created and can be viewed or copied from the list.',
principalMode: 'User identity mode',
principalModeDesc:
'Choose how API requests identify the end user. This identity scopes both conversation sessions and MCP tool authorization per user, without reducing the API key\'s tenant-admin access.',
'Choose how API requests identify the end user. This identity scopes both conversation sessions and MCP tool authorization per user.',
principalScope:
'End-user identity isolates conversation sessions and MCP tool authorization (OAuth) per user. The API key can still access all knowledge bases in the tenant; API permissions are not split per external user.',
'End-user identity isolates sessions and MCP OAuth. Operation permissions and knowledge-base scope are controlled by API Keys above.',
modeTenant: 'Tenant only',
modeDirect: 'Direct user ID',
modeSigned: 'Signed token',