generator client { provider = "prisma-client" output = "../src/generated/prisma" } datasource db { provider = "mongodb" url = env("MONGO_URI") } type ActivitiesSnapshot { id String @map("_id") @db.ObjectId username String } type AiassistantsGrantedGroupsForAccessScope { /// Field referred in an index, but found no data to define the type. item Json? } type AiassistantsGrantedGroupsForShareScope { /// Field referred in an index, but found no data to define the type. item Json? } type PageoperationsExPage { /// Field referred in an index, but found no data to define the type. id Json? @map("_id") /// Field referred in an index, but found no data to define the type. path Json? } type PageoperationsPage { /// Field referred in an index, but found no data to define the type. id Json? @map("_id") /// Field referred in an index, but found no data to define the type. path Json? } type PagesGrantedGroups { /// Field referred in an index, but found no data to define the type. item Json? } model accesstokens { id String @id @default(auto()) @map("_id") @db.ObjectId /// Field referred in an index, but found no data to define the type. expiredAt Json? /// Field referred in an index, but found no data to define the type. tokenHash Json? @unique(map: "tokenHash_1") @@index([expiredAt], map: "expiredAt_1") } model activities { id String @id @default(auto()) @map("_id") @db.ObjectId v Int @map("__v") action String createdAt DateTime @db.Date endpoint String ip String snapshot ActivitiesSnapshot target String? @db.ObjectId targetModel String? user String? @db.ObjectId @@unique([user, target, action, createdAt], map: "user_1_target_1_action_1_createdAt_1") @@index([user], map: "user_1") @@index([snapshot.username], map: "snapshot.username_1") @@index([target, action], map: "target_1_action_1") @@index([createdAt], map: "createdAt_1") } model aiassistants { id String @id @default(auto()) @map("_id") @db.ObjectId /// Field referred in an index, but found no data to define the type. grantedGroupsForAccessScope AiassistantsGrantedGroupsForAccessScope? /// Field referred in an index, but found no data to define the type. grantedGroupsForShareScope AiassistantsGrantedGroupsForShareScope? @@index([grantedGroupsForShareScope.item], map: "grantedGroupsForShareScope.item_1") @@index([grantedGroupsForAccessScope.item], map: "grantedGroupsForAccessScope.item_1") } model attachments { id String @id @default(auto()) @map("_id") @db.ObjectId /// Field referred in an index, but found no data to define the type. creator Json? /// Field referred in an index, but found no data to define the type. fileName Json? @unique(map: "fileName_1") /// Field referred in an index, but found no data to define the type. page Json? @@index([page], map: "page_1") @@index([creator], map: "creator_1") } model bookmarkfolders { id String @id @default(auto()) @map("_id") @db.ObjectId /// Field referred in an index, but found no data to define the type. owner Json? @@index([owner], map: "owner_1") } model bookmarks { id String @id @default(auto()) @map("_id") @db.ObjectId /// Field referred in an index, but found no data to define the type. page Json? /// Field referred in an index, but found no data to define the type. user Json? @@unique([page, user], map: "page_1_user_1") @@index([page], map: "page_1") @@index([user], map: "user_1") } model comments { id String @id @default(auto()) @map("_id") @db.ObjectId /// Field referred in an index, but found no data to define the type. creator Json? /// Field referred in an index, but found no data to define the type. page Json? /// Field referred in an index, but found no data to define the type. revision Json? @@index([page], map: "page_1") @@index([creator], map: "creator_1") @@index([revision], map: "revision_1") } model configs { id String @id @default(auto()) @map("_id") @db.ObjectId v Int? @map("__v") createdAt DateTime @db.Date key String @unique(map: "key_1") updatedAt DateTime @db.Date value String } model editorsettings { id String @id @default(auto()) @map("_id") @db.ObjectId } model externalaccounts { id String @id @default(auto()) @map("_id") @db.ObjectId /// Field referred in an index, but found no data to define the type. accountId Json? /// Field referred in an index, but found no data to define the type. providerType Json? @@unique([providerType, accountId], map: "providerType_1_accountId_1") } model externalusergrouprelations { id String @id @default(auto()) @map("_id") @db.ObjectId } model externalusergroups { id String @id @default(auto()) @map("_id") @db.ObjectId /// Field referred in an index, but found no data to define the type. externalId Json? @unique(map: "externalId_1") /// Field referred in an index, but found no data to define the type. name Json? /// Field referred in an index, but found no data to define the type. parent Json? /// Field referred in an index, but found no data to define the type. provider Json? @@unique([name, provider], map: "name_1_provider_1") @@index([parent], map: "parent_1") } model failedemails { id String @id @default(auto()) @map("_id") @db.ObjectId /// Field referred in an index, but found no data to define the type. createdAt Json? @@index([createdAt], map: "createdAt_1") } model globalnotificationsettings { id String @id @default(auto()) @map("_id") @db.ObjectId } model growiplugins { id String @id @default(auto()) @map("_id") @db.ObjectId } model inappnotifications { id String @id @default(auto()) @map("_id") @db.ObjectId /// Field referred in an index, but found no data to define the type. action Json? /// Field referred in an index, but found no data to define the type. createdAt Json? /// Field referred in an index, but found no data to define the type. status Json? /// Field referred in an index, but found no data to define the type. target Json? /// Field referred in an index, but found no data to define the type. user Json? @@index([user], map: "user_1") @@index([status], map: "status_1") @@index([createdAt], map: "createdAt_1") @@index([user, target, action, createdAt], map: "user_1_target_1_action_1_createdAt_1") } model inappnotificationsettings { id String @id @default(auto()) @map("_id") @db.ObjectId } model migrations { id String @id @default(auto()) @map("_id") @db.ObjectId appliedAt DateTime @db.Date fileName String } model namedqueries { id String @id @default(auto()) @map("_id") @db.ObjectId v Int @map("__v") /// Could not determine type: the field only had null or empty values in the sample set. creator Json? delegatorName String name String @unique(map: "name_1") @@index([creator], map: "creator_1") } model pagebulkexportjobs { id String @id @default(auto()) @map("_id") @db.ObjectId } model pagebulkexportpagesnapshots { id String @id @default(auto()) @map("_id") @db.ObjectId } model pageoperations { id String @id @default(auto()) @map("_id") @db.ObjectId /// Field referred in an index, but found no data to define the type. actionStage Json? /// Field referred in an index, but found no data to define the type. actionType Json? /// Field referred in an index, but found no data to define the type. exPage PageoperationsExPage? /// Field referred in an index, but found no data to define the type. fromPath Json? /// Field referred in an index, but found no data to define the type. page PageoperationsPage? /// Field referred in an index, but found no data to define the type. toPath Json? @@index([actionType], map: "actionType_1") @@index([actionStage], map: "actionStage_1") @@index([fromPath], map: "fromPath_1") @@index([toPath], map: "toPath_1") @@index([page.id], map: "page._id_1") @@index([page.path], map: "page.path_1") @@index([exPage.id], map: "exPage._id_1") @@index([exPage.path], map: "exPage.path_1") } model pageredirects { id String @id @default(auto()) @map("_id") @db.ObjectId /// Field referred in an index, but found no data to define the type. fromPath Json? @unique(map: "fromPath_1") } model pages { id String @id @default(auto()) @map("_id") @db.ObjectId v Int @map("__v") commentCount Int createdAt DateTime @db.Date creator String? @db.ObjectId descendantCount Int grant Int /// Nested objects had no data in the sample dataset to introspect a nested type. grantedGroups Json? /// Could not determine type: the field only had null or empty values in the sample set. grantedUsers Json? isEmpty Boolean lastUpdateUser String? @db.ObjectId latestRevisionBodyLength Int? /// Could not determine type: the field only had null or empty values in the sample set. liker Json? parent String? @db.ObjectId path String revision String? @db.ObjectId seenUsers String[] status String ttlTimestamp DateTime? @db.Date updatedAt DateTime @db.Date wip Boolean? revisions revisions[] @@index([parent], map: "parent_1") @@index([path], map: "path_1") @@index([status], map: "status_1") @@index([grant], map: "grant_1") @@index([creator], map: "creator_1") @@index([createdAt], map: "createdAt_1") @@index([updatedAt], map: "updatedAt_1") @@index([ttlTimestamp], map: "ttlTimestamp_1") } model pagetagrelations { id String @id @default(auto()) @map("_id") @db.ObjectId /// Field referred in an index, but found no data to define the type. isPageTrashed Json? /// Field referred in an index, but found no data to define the type. relatedPage Json? /// Field referred in an index, but found no data to define the type. relatedTag Json? @@unique([relatedPage, relatedTag], map: "relatedPage_1_relatedTag_1") @@index([relatedPage], map: "relatedPage_1") @@index([relatedTag], map: "relatedTag_1") @@index([isPageTrashed], map: "isPageTrashed_1") } model passwordresetorders { id String @id @default(auto()) @map("_id") @db.ObjectId /// Field referred in an index, but found no data to define the type. token Json? @unique(map: "token_1") } model revisions { id String @id @default(auto()) @map("_id") @db.ObjectId v Int @map("__v") author String @db.ObjectId body String createdAt DateTime @db.Date format String origin String? pageId String @db.ObjectId page pages @relation(fields: [pageId], references: [id]) @@index([pageId], map: "pageId_1") } model rlflx { id String @id @default(auto()) @map("_id") @db.ObjectId /// Field referred in an index, but found no data to define the type. expire Json? /// Field referred in an index, but found no data to define the type. key Json? @unique(map: "key_1") @@index([expire(sort: Desc)], map: "expire_-1") } model sessions { id String @id @map("_id") expires DateTime @db.Date session String @@index([expires], map: "expires_1") } model sharelinks { id String @id @default(auto()) @map("_id") @db.ObjectId /// Field referred in an index, but found no data to define the type. relatedPage Json? @@index([relatedPage], map: "relatedPage_1") } model slackappintegrations { id String @id @default(auto()) @map("_id") @db.ObjectId /// Field referred in an index, but found no data to define the type. isPrimary Json? @unique(map: "isPrimary_1") /// Field referred in an index, but found no data to define the type. tokenGtoP Json? @unique(map: "tokenGtoP_1") /// Field referred in an index, but found no data to define the type. tokenPtoG Json? @unique(map: "tokenPtoG_1") } model subscriptions { id String @id @default(auto()) @map("_id") @db.ObjectId /// Field referred in an index, but found no data to define the type. user Json? @@index([user], map: "user_1") } model tags { id String @id @default(auto()) @map("_id") @db.ObjectId /// Field referred in an index, but found no data to define the type. name Json? @unique(map: "name_1") } model threadrelations { id String @id @default(auto()) @map("_id") @db.ObjectId /// Field referred in an index, but found no data to define the type. threadId Json? @unique(map: "threadId_1") } model transferkeys { id String @id @default(auto()) @map("_id") @db.ObjectId /// Field referred in an index, but found no data to define the type. expireAt Json? /// Field referred in an index, but found no data to define the type. key Json? @unique(map: "key_1") /// Field referred in an index, but found no data to define the type. keyString Json? @unique(map: "keyString_1") @@index([expireAt], map: "expireAt_1") } model updateposts { id String @id @default(auto()) @map("_id") @db.ObjectId /// Field referred in an index, but found no data to define the type. creator Json? @@index([creator], map: "creator_1") } model usergrouprelations { id String @id @default(auto()) @map("_id") @db.ObjectId v Int @map("__v") createdAt DateTime @db.Date relatedGroup String @db.ObjectId relatedUser String @db.ObjectId } model usergroups { id String @id @default(auto()) @map("_id") @db.ObjectId v Int @map("__v") createdAt DateTime @db.Date description String name String @unique(map: "name_1") /// Could not determine type: the field only had null or empty values in the sample set. parent Json? updatedAt DateTime @db.Date @@index([parent], map: "parent_1") } model userregistrationorders { id String @id @default(auto()) @map("_id") @db.ObjectId /// Field referred in an index, but found no data to define the type. token Json? @unique(map: "token_1") } model users { id String @id @default(auto()) @map("_id") @db.ObjectId v Int @map("__v") admin Boolean /// Field referred in an index, but found no data to define the type. apiToken Json? createdAt DateTime @db.Date email String @unique(map: "email_1") imageUrlCached String isEmailPublished Boolean isGravatarEnabled Boolean isInvitationEmailSended Boolean lang String /// Field referred in an index, but found no data to define the type. lastLoginAt Json? name String password String readOnly Boolean /// Field referred in an index, but found no data to define the type. slackMemberId Json? @unique(map: "slackMemberId_1") status Int updatedAt DateTime @db.Date username String @unique(map: "username_1") @@index([name], map: "name_1") @@index([apiToken], map: "apiToken_1") @@index([status], map: "status_1") @@index([lastLoginAt], map: "lastLoginAt_1") @@index([admin], map: "admin_1") } model useruisettings { id String @id @default(auto()) @map("_id") @db.ObjectId /// Field referred in an index, but found no data to define the type. user Json? @unique(map: "user_1") } model vectorstorefilerelations { id String @id @default(auto()) @map("_id") @db.ObjectId /// Field referred in an index, but found no data to define the type. attachment Json? /// Field referred in an index, but found no data to define the type. page Json? /// Field referred in an index, but found no data to define the type. vectorStoreRelationId Json? @@unique([vectorStoreRelationId, page, attachment], map: "vectorStoreRelationId_1_page_1_attachment_1") } model vectorstores { id String @id @default(auto()) @map("_id") @db.ObjectId /// Field referred in an index, but found no data to define the type. vectorStoreId Json? @unique(map: "vectorStoreId_1") } model yjs_writings { id String @id @default(auto()) @map("_id") @db.ObjectId action String? clock Int? docName String metaKey String? /// Field referred in an index, but found no data to define the type. part Json? /// Multiple data types found: Float: 33.3%, Binary: 66.7% out of 3 sampled entries value Json version String @@index([version, docName, action, clock, part], map: "version_1_docName_1_action_1_clock_1_part_1") @@index([version, docName, metaKey], map: "version_1_docName_1_metaKey_1") @@index([docName, clock], map: "docName_1_clock_1") @@map("yjs-writings") }