Init Project

This is a pretty far-developed starting point. Authentication has been intialized with Better-Auth, a database has been setup with Prisma, and Google + email logins have been enabled, as well as Google + Email registration.
This commit is contained in:
NeilClack
2026-01-13 16:21:12 -06:00
commit ef855ae9a9
82 changed files with 20988 additions and 0 deletions
+109
View File
@@ -0,0 +1,109 @@
// This is your Prisma schema file,
// learn more about it in the docs: https://pris.ly/d/prisma-schema
// Looking for ways to speed up your queries, or scale easily with your serverless or edge functions?
// Try Prisma Accelerate: https://pris.ly/cli/accelerate-init
generator client {
provider = "prisma-client"
output = "../src/lib/generated/prisma"
}
datasource db {
provider = "postgresql"
}
model User {
id String @id
name String
email String
emailVerified Boolean @default(false)
image String?
createdAt DateTime @default(now())
updatedAt DateTime @updatedAt
roleId Int?
role UserRole? @relation(fields: [roleId], references: [id])
sessions Session[]
accounts Account[]
@@unique([email])
@@map("user")
}
model Session {
id String @id
expiresAt DateTime
token String
createdAt DateTime @default(now())
updatedAt DateTime @updatedAt
ipAddress String?
userAgent String?
userId String
user User @relation(fields: [userId], references: [id], onDelete: Cascade)
@@unique([token])
@@index([userId])
@@map("session")
}
model Account {
id String @id
accountId String
providerId String
userId String
user User @relation(fields: [userId], references: [id], onDelete: Cascade)
accessToken String?
refreshToken String?
idToken String?
accessTokenExpiresAt DateTime?
refreshTokenExpiresAt DateTime?
scope String?
password String?
createdAt DateTime @default(now())
updatedAt DateTime @updatedAt
@@index([userId])
@@map("account")
}
model UserRole {
id Int @id @default(autoincrement())
name String
users User[]
}
model Verification {
id String @id
identifier String
value String
expiresAt DateTime
createdAt DateTime @default(now())
updatedAt DateTime @updatedAt
@@index([identifier])
@@map("verification")
}
model Affirmation {
id String @id @default(uuid())
name String @unique
content String @unique
solfeggioFrequencyId Int
solfeggioFrequency SolfeggioFrequency @relation(fields: [solfeggioFrequencyId], references: [id])
categoryId Int
category AffirmationCategory @relation(fields: [categoryId], references: [id])
price Float @default(0.99)
}
model SolfeggioFrequency {
id Int @id @default(autoincrement())
name String @unique
value Float @unique
affirmations Affirmation[]
}
model AffirmationCategory {
id Int @id @default(autoincrement())
name String @unique
affirmations Affirmation[]
}