Tenant User
Life Cycle
Route | Create | Read | Update | Delete |
---|---|---|---|---|
/register | ||||
/app/:tenant/settings/members |
Properties
Name | Title | Type | Description |
---|---|---|---|
tenantId * | Tenant | Tenant | |
userId * | User | User | |
type * | Type | TenantUserType | OWNER, ADMIN or MEMBER |
joined * | Joined | TenantUserJoined | CREATOR, JOINED_BY_INVITATION, JOINED_BY_LINK (not supported yet), or JOINED_BY_PUBLIC_URL (not supported yet) |
status * | Status | TenantUserStatus | PENDING_INVITATION, PENDING_ACCEPTANCE, ACTIVE, or INACTIVE |
roles | Tenant User Roles | TenantUserRoles[] | Not supported yet |
Model
model TenantUser {
id String @id @default(cuid())
createdAt DateTime @default(now())
tenantId String
tenant Tenant @relation(fields: [tenantId], references: [id], onDelete: Cascade)
userId String
user User @relation(fields: [userId], references: [id], onDelete: Cascade)
type Int
joined Int
status Int
roles TenantUserRole[]
}