Skip to content

50+ open-source generative AI apps you can clone, deploy, and monetize — image generators, video tools, virtual try-ons, AI SaaS templates, and platform integrations. One-click Vercel deploy on every template.

Restore: prisma/schema.prisma

Anil Chandra Naidu Matchaff9ca6638479
diff --git a/prisma/schema.prisma b/prisma/schema.prisma
new file mode 100644
index 0000000..e961742
--- /dev/null
+++ b/prisma/schema.prisma
@@ -0,0 +1,80 @@
+generator client {
+ provider = "prisma-client-js"
+ binaryTargets = ["native", "rhel-openssl-1.0.x", "rhel-openssl-3.0.x"]
+}
+
+datasource db {
+ provider = "postgresql"
+}
+
+model Account {
+ id String @id @default(cuid())
+ userId String
+ type String
+ provider String
+ providerAccountId String
+ refresh_token String? @db.Text
+ access_token String? @db.Text
+ expires_at Int?
+ token_type String?
+ scope String?
+ id_token String? @db.Text
+ session_state String?
+ user User @relation(fields: [userId], references: [id], onDelete: Cascade)
+
+ @@unique([provider, providerAccountId])
+}
+
+model Session {
+ id String @id @default(cuid())
+ sessionToken String @unique
+ userId String
+ expires DateTime
+ user User @relation(fields: [userId], references: [id], onDelete: Cascade)
+}
+
+model User {
+ id String @id @default(cuid())
+ name String?
+ email String? @unique
+ emailVerified DateTime?
+ image String?
+ credits Int @default(10)
+ accounts Account[]
+ sessions Session[]
+ scheduledPosts ScheduledPost[]
+}
+
+model VerificationToken {
+ identifier String
+ token String @unique
+ expires DateTime
+
+ @@unique([identifier, token])
+}
+
+model ScheduledPost {
+ id String @id @default(cuid())
+ userId String
+ accountId Int
+ platform String
+ accountName String
+ mediaUrl String @db.Text
+ title String @db.Text
+ description String? @db.Text
+ tags String? @db.Text
+ privacy String @default("public")
+ disableComment Boolean @default(false)
+ disableDuet Boolean @default(false)
+ disableStitch Boolean @default(false)
+ categoryId String?
+ madeForKids Boolean @default(false)
+ scheduledAt DateTime
+ status String @default("scheduled")
+ requestId String? @unique
+ publishedUrl String? @db.Text
+ error String? @db.Text
+ createdAt DateTime @default(now())
+ updatedAt DateTime @updatedAt
+ user User @relation(fields: [userId], references: [id], onDelete: Cascade)
+}