feat(api-keys): add api keys management and authentication for n8n workflows
Deploy Canina / deploy (push) Successful in 3m11s
E2E Playwright Tests / Run Full E2E & Security Suites (push) Failing after 9s

This commit is contained in:
parsa aghaei committed 2026-09-08 12:57:32 +03:30
1 parent ba9472c938
commit 1fff11ee4f
24 files changed
+158204 -5768

No files matched your search

+18
View File
@@ -865,3 +865,21 @@ model MenuItem {
@@index([parentId])
@@map("menu_items")
}
model ApiKey {
id String @id @default(uuid()) @db.Uuid
name String @db.VarChar(150)
keyHash String @unique @map("key_hash") @db.VarChar(255)
keyPrefix String @map("key_prefix") @db.VarChar(30)
scopes String @default("*") @db.Text
status String @default("ACTIVE") @db.VarChar(20)
expiresAt DateTime? @map("expires_at") @db.Timestamptz()
lastUsedAt DateTime? @map("last_used_at") @db.Timestamptz()
description String? @db.VarChar(255)
createdAt DateTime @default(now()) @map("created_at") @db.Timestamptz()
updatedAt DateTime @updatedAt @map("updated_at") @db.Timestamptz()
@@index([keyHash])
@@index([status])
@@map("api_keys")
}