gadget/packages/api/src/interfaces/user.ts
Rob Colbert cc6d3b901a refactor gadget-code model interfaces to @gadget/api
Moved all Mongoose model interfaces to @gadget/api to commonize the data
structures being passed around the system as JSON objects via HTTP and
Socket.IO.
2026-04-28 12:42:32 -04:00

23 lines
501 B
TypeScript

// src/interfaces/user.ts
// Copyright (C) 2026 Rob Colbert <rob.colbert@openplatform.us>
// Licensed under the Apache License, Version 2.0
export interface IUserFlags {
isEmailVerified: boolean;
isAdmin: boolean;
isTest: boolean;
isBanned: boolean;
}
import { Document, Types } from "mongoose";
export interface IUser extends Document {
_id: Types.ObjectId;
email: string;
email_lc: string;
passwordSalt?: string;
password?: string;
displayName: string;
flags: IUserFlags;
}