Files
Enterprise-Knowledge-Base/migrations/versioned/000071_platform_api_keys.down.sql
T
wizardchen 23db592c4a feat(api-keys): add platform-scoped API keys for control-plane automation
Introduce platform API keys with capability-based access to tenant management,
system settings, runtime queues, and audit logs, plus admin UI for key lifecycle
and system audit log viewing.
2026-07-21 17:21:35 +08:00

13 lines
336 B
SQL

DELETE FROM tenant_api_keys WHERE scope_type = 'platform';
DROP INDEX IF EXISTS idx_tenant_api_keys_scope_type;
ALTER TABLE tenant_api_keys
DROP CONSTRAINT IF EXISTS chk_tenant_api_keys_scope;
ALTER TABLE tenant_api_keys
ALTER COLUMN tenant_id SET NOT NULL;
ALTER TABLE tenant_api_keys
DROP COLUMN IF EXISTS scope_type;