This commit is contained in:
Nareshkumar Rao
2025-04-07 17:07:15 +02:00
parent f28c2defc4
commit 9c6c0b315c
7 changed files with 678 additions and 10 deletions

View File

@ -0,0 +1,13 @@
-- CreateTable
CREATE TABLE "Tokens" (
"id" SERIAL NOT NULL,
"application" TEXT NOT NULL,
"access_token" TEXT NOT NULL,
"refresh_token" TEXT NOT NULL,
"expires_at" TIMESTAMP(6) NOT NULL,
CONSTRAINT "Tokens_pkey" PRIMARY KEY ("id")
);
-- CreateIndex
CREATE UNIQUE INDEX "Tokens_application_key" ON "Tokens"("application");

View File

@ -30,3 +30,11 @@ model User {
username String @unique
password String
}
model Tokens {
id Int @id @default(autoincrement())
application String @unique
access_token String
refresh_token String
expires_at DateTime @db.Timestamp(6)
}