Skip to content

Open AI UGC — free, open-source alternative to Arcads and MakeUGC. Generate AI UGC video ads with realistic AI actors using Veo 3.1, Seedance 2, Grok Video, and Happy Horse 1. Self-host on Next.js + Stripe + MUAPI.

1.9 KB
Raw Blame
generator client {
  provider      = "prisma-client-js"
}

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)
  customApiKey  String?   @db.Text
  accounts      Account[]
  sessions      Session[]
  creations     Creation[]
}

model Creation {
  id           String   @id @default(cuid())
  type         String?  // video or image
  title        String?
  prompt       String?  @db.Text
  url          String?  @db.Text
  createdAt    DateTime @default(now())
  userId       String
  
  requestId    String?  @unique
  status       String   @default("processing")
  error        String?  @db.Text

  // Generation parameters
  modelId      String?
  aspectRatio  String?
  resolution   String?
  duration     Int?
  mode         String?
  inputImages  String?  @db.Text
  
  user User @relation(fields: [userId], references: [id], onDelete: Cascade)
}

model VerificationToken {
  identifier String
  token      String   @unique
  expires    DateTime

  @@unique([identifier, token])
}