Files
tenant-registry/migrations/0016_api_keys_active_name_unique.down.sql
T
sharang 5b4590d3bc
ci / shared (push) Successful in 13s
ci / test (push) Successful in 25m10s
ci / image (push) Successful in 36s
feat(api-keys): CI licences by API key and integration keys (#71)
2026-10-13 22:12:05 +00:00

4 lines
216 B
SQL

-- Fails if a revoked and an active key share a name; rename one first.
DROP INDEX IF EXISTS api_keys_tenant_name_active_idx;
ALTER TABLE api_keys ADD CONSTRAINT api_keys_tenant_id_name_key UNIQUE (tenant_id, name);