UNPKG

@replyke/express

Version:

Replyke: Build interactive apps with social features like comments, votes, feeds, user lists, notifications, and more.

32 lines (31 loc) 1.15 kB
import { Model, Optional } from "sequelize"; import ILocation from "./ILocation"; export interface IUserAttributes { id: string; projectId: string; referenceId: string | null; foreignId: string | null; role: "admin" | "editor" | "visitor"; hash: string | null; salt: string | null; email: string | null; name: string | null; username: string | null; avatar: string | null; bio: string | null; birthdate: Date | null; reputation: number; location: ILocation | null; isVerified: boolean; isActive: boolean; lastActive: Date; metadata: Record<string, any>; secureMetadata: Record<string, any>; createdAt: Date; updatedAt: Date; deletedAt: Date | null; } export interface IUserCreationAttributes extends Optional<IUserAttributes, "id" | "referenceId" | "createdAt" | "updatedAt" | "deletedAt" | "role" | "name" | "username" | "avatar" | "hash" | "salt" | "email" | "reputation" | "metadata" | "secureMetadata" | "isVerified" | "isActive" | "lastActive"> { } export default interface IUser extends Model<IUserAttributes, IUserCreationAttributes>, IUserAttributes { }