/** * Client **/ import * as runtime from './runtime/library'; type UnwrapPromise

= P extends Promise ? R : P type UnwrapTuple = { [K in keyof Tuple]: K extends `${number}` ? Tuple[K] extends Prisma.PrismaPromise ? X : UnwrapPromise : UnwrapPromise }; export type PrismaPromise = runtime.Types.Public.PrismaPromise /** * Model Account * */ export type Account = { id: string name: string userId: string roles: string[] email: string salt: string password: string createdAt: Date | null updatedAt: Date | null lastSignedInAt: Date | null inactive: boolean inactiveAt: Date | null } /** * Model Role * */ export type Role = { id: string name: string roleId: string description: string createdAt: Date | null updatedAt: Date | null inactive: boolean inactiveAt: Date | null } /** * Model CasbinModel * */ export type CasbinModel = { id: string bizRealm: string sec: string pType: string v0: string | null v1: string | null v2: string | null v3: string | null v4: string | null v5: string | null createdAt: Date | null updatedAt: Date | null } /** * Model CasbinPolicy * */ export type CasbinPolicy = { id: string bizRealm: string sec: string pType: string v0: string | null v1: string | null v2: string | null v3: string | null v4: string | null v5: string | null createdAt: Date | null updatedAt: Date | null } /** * ## Prisma Client ʲˢ * * Type-safe database client for TypeScript & Node.js * @example * ``` * const prisma = new PrismaClient() * // Fetch zero or more Accounts * const accounts = await prisma.account.findMany() * ``` * * * Read more in our [docs](https://www.prisma.io/docs/reference/tools-and-interfaces/prisma-client). */ export class PrismaClient< T extends Prisma.PrismaClientOptions = Prisma.PrismaClientOptions, U = 'log' extends keyof T ? T['log'] extends Array ? Prisma.GetEvents : never : never, GlobalReject extends Prisma.RejectOnNotFound | Prisma.RejectPerOperation | false | undefined = 'rejectOnNotFound' extends keyof T ? T['rejectOnNotFound'] : false > { /** * ## Prisma Client ʲˢ * * Type-safe database client for TypeScript & Node.js * @example * ``` * const prisma = new PrismaClient() * // Fetch zero or more Accounts * const accounts = await prisma.account.findMany() * ``` * * * Read more in our [docs](https://www.prisma.io/docs/reference/tools-and-interfaces/prisma-client). */ constructor(optionsArg ?: Prisma.Subset); $on(eventType: V, callback: (event: V extends 'query' ? Prisma.QueryEvent : V extends 'beforeExit' ? () => Promise : Prisma.LogEvent) => void): void; /** * Connect with the database */ $connect(): Promise; /** * Disconnect from the database */ $disconnect(): Promise; /** * Add a middleware */ $use(cb: Prisma.Middleware): void /** * Allows the running of a sequence of read/write operations that are guaranteed to either succeed or fail as a whole. * @example * ``` * const [george, bob, alice] = await prisma.$transaction([ * prisma.user.create({ data: { name: 'George' } }), * prisma.user.create({ data: { name: 'Bob' } }), * prisma.user.create({ data: { name: 'Alice' } }), * ]) * ``` * * Read more in our [docs](https://www.prisma.io/docs/concepts/components/prisma-client/transactions). */ $transaction

[]>(arg: [...P]): Promise> $transaction(fn: (prisma: Omit) => Promise, options?: { maxWait?: number, timeout?: number }): Promise /** * Executes a raw MongoDB command and returns the result of it. * @example * ``` * const user = await prisma.$runCommandRaw({ * aggregate: 'User', * pipeline: [{ $match: { name: 'Bob' } }, { $project: { email: true, _id: false } }], * explain: false, * }) * ``` * * Read more in our [docs](https://www.prisma.io/docs/reference/tools-and-interfaces/prisma-client/raw-database-access). */ $runCommandRaw(command: Prisma.InputJsonObject): Prisma.PrismaPromise /** * `prisma.account`: Exposes CRUD operations for the **Account** model. * Example usage: * ```ts * // Fetch zero or more Accounts * const accounts = await prisma.account.findMany() * ``` */ get account(): Prisma.AccountDelegate; /** * `prisma.role`: Exposes CRUD operations for the **Role** model. * Example usage: * ```ts * // Fetch zero or more Roles * const roles = await prisma.role.findMany() * ``` */ get role(): Prisma.RoleDelegate; /** * `prisma.casbinModel`: Exposes CRUD operations for the **CasbinModel** model. * Example usage: * ```ts * // Fetch zero or more CasbinModels * const casbinModels = await prisma.casbinModel.findMany() * ``` */ get casbinModel(): Prisma.CasbinModelDelegate; /** * `prisma.casbinPolicy`: Exposes CRUD operations for the **CasbinPolicy** model. * Example usage: * ```ts * // Fetch zero or more CasbinPolicies * const casbinPolicies = await prisma.casbinPolicy.findMany() * ``` */ get casbinPolicy(): Prisma.CasbinPolicyDelegate; } export namespace Prisma { export import DMMF = runtime.DMMF export type PrismaPromise = runtime.Types.Public.PrismaPromise /** * Prisma Errors */ export import PrismaClientKnownRequestError = runtime.PrismaClientKnownRequestError export import PrismaClientUnknownRequestError = runtime.PrismaClientUnknownRequestError export import PrismaClientRustPanicError = runtime.PrismaClientRustPanicError export import PrismaClientInitializationError = runtime.PrismaClientInitializationError export import PrismaClientValidationError = runtime.PrismaClientValidationError export import NotFoundError = runtime.NotFoundError /** * Re-export of sql-template-tag */ export import sql = runtime.sqltag export import empty = runtime.empty export import join = runtime.join export import raw = runtime.raw export import Sql = runtime.Sql /** * Decimal.js */ export import Decimal = runtime.Decimal export type DecimalJsLike = runtime.DecimalJsLike /** * Metrics */ export type Metrics = runtime.Metrics export type Metric = runtime.Metric export type MetricHistogram = runtime.MetricHistogram export type MetricHistogramBucket = runtime.MetricHistogramBucket /** * Prisma Client JS version: 4.14.1 * Query Engine version: d9a4c5988f480fa576d43970d5a23641aa77bc9c */ export type PrismaVersion = { client: string } export const prismaVersion: PrismaVersion /** * Utility Types */ /** * From https://github.com/sindresorhus/type-fest/ * Matches a JSON object. * This type can be useful to enforce some input to be JSON-compatible or as a super-type to be extended from. */ export type JsonObject = {[Key in string]?: JsonValue} /** * From https://github.com/sindresorhus/type-fest/ * Matches a JSON array. */ export interface JsonArray extends Array {} /** * From https://github.com/sindresorhus/type-fest/ * Matches any valid JSON value. */ export type JsonValue = string | number | boolean | JsonObject | JsonArray | null /** * Matches a JSON object. * Unlike `JsonObject`, this type allows undefined and read-only properties. */ export type InputJsonObject = {readonly [Key in string]?: InputJsonValue | null} /** * Matches a JSON array. * Unlike `JsonArray`, readonly arrays are assignable to this type. */ export interface InputJsonArray extends ReadonlyArray {} /** * Matches any valid value that can be used as an input for operations like * create and update as the value of a JSON field. Unlike `JsonValue`, this * type allows read-only arrays and read-only object properties and disallows * `null` at the top level. * * `null` cannot be used as the value of a JSON field because its meaning * would be ambiguous. Use `Prisma.JsonNull` to store the JSON null value or * `Prisma.DbNull` to clear the JSON value and set the field to the database * NULL value instead. * * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-by-null-values */ export type InputJsonValue = string | number | boolean | InputJsonObject | InputJsonArray /** * Types of the values used to represent different kinds of `null` values when working with JSON fields. * * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field */ namespace NullTypes { /** * Type of `Prisma.DbNull`. * * You cannot use other instances of this class. Please use the `Prisma.DbNull` value. * * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field */ class DbNull { private DbNull: never private constructor() } /** * Type of `Prisma.JsonNull`. * * You cannot use other instances of this class. Please use the `Prisma.JsonNull` value. * * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field */ class JsonNull { private JsonNull: never private constructor() } /** * Type of `Prisma.AnyNull`. * * You cannot use other instances of this class. Please use the `Prisma.AnyNull` value. * * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field */ class AnyNull { private AnyNull: never private constructor() } } /** * Helper for filtering JSON entries that have `null` on the database (empty on the db) * * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field */ export const DbNull: NullTypes.DbNull /** * Helper for filtering JSON entries that have JSON `null` values (not empty on the db) * * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field */ export const JsonNull: NullTypes.JsonNull /** * Helper for filtering JSON entries that are `Prisma.DbNull` or `Prisma.JsonNull` * * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field */ export const AnyNull: NullTypes.AnyNull type SelectAndInclude = { select: any include: any } type HasSelect = { select: any } type HasInclude = { include: any } type CheckSelect = T extends SelectAndInclude ? 'Please either choose `select` or `include`' : T extends HasSelect ? U : T extends HasInclude ? U : S /** * Get the type of the value, that the Promise holds. */ export type PromiseType> = T extends PromiseLike ? U : T; /** * Get the return type of a function which returns a Promise. */ export type PromiseReturnType Promise> = PromiseType> /** * From T, pick a set of properties whose keys are in the union K */ type Prisma__Pick = { [P in K]: T[P]; }; export type Enumerable = T | Array; export type RequiredKeys = { [K in keyof T]-?: {} extends Prisma__Pick ? never : K }[keyof T] export type TruthyKeys = keyof { [K in keyof T as T[K] extends false | undefined | null ? never : K]: K } export type TrueKeys = TruthyKeys>> /** * Subset * @desc From `T` pick properties that exist in `U`. Simple version of Intersection */ export type Subset = { [key in keyof T]: key extends keyof U ? T[key] : never; }; /** * SelectSubset * @desc From `T` pick properties that exist in `U`. Simple version of Intersection. * Additionally, it validates, if both select and include are present. If the case, it errors. */ export type SelectSubset = { [key in keyof T]: key extends keyof U ? T[key] : never } & (T extends SelectAndInclude ? 'Please either choose `select` or `include`.' : {}) /** * Subset + Intersection * @desc From `T` pick properties that exist in `U` and intersect `K` */ export type SubsetIntersection = { [key in keyof T]: key extends keyof U ? T[key] : never } & K type Without = { [P in Exclude]?: never }; /** * XOR is needed to have a real mutually exclusive union type * https://stackoverflow.com/questions/42123407/does-typescript-support-mutually-exclusive-types */ type XOR = T extends object ? U extends object ? (Without & U) | (Without & T) : U : T /** * Is T a Record? */ type IsObject = T extends Array ? False : T extends Date ? False : T extends Uint8Array ? False : T extends BigInt ? False : T extends object ? True : False /** * If it's T[], return T */ export type UnEnumerate = T extends Array ? U : T /** * From ts-toolbelt */ type __Either = Omit & { // Merge all but K [P in K]: Prisma__Pick // With K possibilities }[K] type EitherStrict = Strict<__Either> type EitherLoose = ComputeRaw<__Either> type _Either< O extends object, K extends Key, strict extends Boolean > = { 1: EitherStrict 0: EitherLoose }[strict] type Either< O extends object, K extends Key, strict extends Boolean = 1 > = O extends unknown ? _Either : never export type Union = any type PatchUndefined = { [K in keyof O]: O[K] extends undefined ? At : O[K] } & {} /** Helper Types for "Merge" **/ export type IntersectOf = ( U extends unknown ? (k: U) => void : never ) extends (k: infer I) => void ? I : never export type Overwrite = { [K in keyof O]: K extends keyof O1 ? O1[K] : O[K]; } & {}; type _Merge = IntersectOf; }>>; type Key = string | number | symbol; type AtBasic = K extends keyof O ? O[K] : never; type AtStrict = O[K & keyof O]; type AtLoose = O extends unknown ? AtStrict : never; export type At = { 1: AtStrict; 0: AtLoose; }[strict]; export type ComputeRaw = A extends Function ? A : { [K in keyof A]: A[K]; } & {}; export type OptionalFlat = { [K in keyof O]?: O[K]; } & {}; type _Record = { [P in K]: T; }; // cause typescript not to expand types and preserve names type NoExpand = T extends unknown ? T : never; // this type assumes the passed object is entirely optional type AtLeast = NoExpand< O extends unknown ? | (K extends keyof O ? { [P in K]: O[P] } & O : O) | {[P in keyof O as P extends K ? K : never]-?: O[P]} & O : never>; type _Strict = U extends unknown ? U & OptionalFlat<_Record, keyof U>, never>> : never; export type Strict = ComputeRaw<_Strict>; /** End Helper Types for "Merge" **/ export type Merge = ComputeRaw<_Merge>>; /** A [[Boolean]] */ export type Boolean = True | False // /** // 1 // */ export type True = 1 /** 0 */ export type False = 0 export type Not = { 0: 1 1: 0 }[B] export type Extends = [A1] extends [never] ? 0 // anything `never` is false : A1 extends A2 ? 1 : 0 export type Has = Not< Extends, U1> > export type Or = { 0: { 0: 0 1: 1 } 1: { 0: 1 1: 1 } }[B1][B2] export type Keys = U extends unknown ? keyof U : never type Cast = A extends B ? A : B; export const type: unique symbol; export function validator(): (select: runtime.Types.Utils.LegacyExact) => S; /** * Used by group by */ export type GetScalarType = O extends object ? { [P in keyof T]: P extends keyof O ? O[P] : never } : never type FieldPaths< T, U = Omit > = IsObject extends True ? U : T type GetHavingFields = { [K in keyof T]: Or< Or, Extends<'AND', K>>, Extends<'NOT', K> > extends True ? // infer is only needed to not hit TS limit // based on the brilliant idea of Pierre-Antoine Mills // https://github.com/microsoft/TypeScript/issues/30188#issuecomment-478938437 T[K] extends infer TK ? GetHavingFields extends object ? Merge> : never> : never : {} extends FieldPaths ? never : K }[keyof T] /** * Convert tuple to union */ type _TupleToUnion = T extends (infer E)[] ? E : never type TupleToUnion = _TupleToUnion type MaybeTupleToUnion = T extends any[] ? TupleToUnion : T /** * Like `Pick`, but with an array */ type PickArray> = Prisma__Pick> /** * Exclude all keys with underscores */ type ExcludeUnderscoreKeys = T extends `_${string}` ? never : T export type FieldRef = runtime.FieldRef type FieldRefInputType = Model extends never ? never : FieldRef export const ModelName: { Account: 'Account', Role: 'Role', CasbinModel: 'CasbinModel', CasbinPolicy: 'CasbinPolicy' }; export type ModelName = (typeof ModelName)[keyof typeof ModelName] export type Datasources = { db?: Datasource } export type DefaultPrismaClient = PrismaClient export type RejectOnNotFound = boolean | ((error: Error) => Error) export type RejectPerModel = { [P in ModelName]?: RejectOnNotFound } export type RejectPerOperation = { [P in "findUnique" | "findFirst"]?: RejectPerModel | RejectOnNotFound } type IsReject = T extends true ? True : T extends (err: Error) => Error ? True : False export type HasReject< GlobalRejectSettings extends Prisma.PrismaClientOptions['rejectOnNotFound'], LocalRejectSettings, Action extends PrismaAction, Model extends ModelName > = LocalRejectSettings extends RejectOnNotFound ? IsReject : GlobalRejectSettings extends RejectPerOperation ? Action extends keyof GlobalRejectSettings ? GlobalRejectSettings[Action] extends RejectOnNotFound ? IsReject : GlobalRejectSettings[Action] extends RejectPerModel ? Model extends keyof GlobalRejectSettings[Action] ? IsReject : False : False : False : IsReject export type ErrorFormat = 'pretty' | 'colorless' | 'minimal' export interface PrismaClientOptions { /** * Configure findUnique/findFirst to throw an error if the query returns null. * @deprecated since 4.0.0. Use `findUniqueOrThrow`/`findFirstOrThrow` methods instead. * @example * ``` * // Reject on both findUnique/findFirst * rejectOnNotFound: true * // Reject only on findFirst with a custom error * rejectOnNotFound: { findFirst: (err) => new Error("Custom Error")} * // Reject on user.findUnique with a custom error * rejectOnNotFound: { findUnique: {User: (err) => new Error("User not found")}} * ``` */ rejectOnNotFound?: RejectOnNotFound | RejectPerOperation /** * Overwrites the datasource url from your schema.prisma file */ datasources?: Datasources /** * @default "colorless" */ errorFormat?: ErrorFormat /** * @example * ``` * // Defaults to stdout * log: ['query', 'info', 'warn', 'error'] * * // Emit as events * log: [ * { emit: 'stdout', level: 'query' }, * { emit: 'stdout', level: 'info' }, * { emit: 'stdout', level: 'warn' } * { emit: 'stdout', level: 'error' } * ] * ``` * Read more in our [docs](https://www.prisma.io/docs/reference/tools-and-interfaces/prisma-client/logging#the-log-option). */ log?: Array } /* Types for Logging */ export type LogLevel = 'info' | 'query' | 'warn' | 'error' export type LogDefinition = { level: LogLevel emit: 'stdout' | 'event' } export type GetLogType = T extends LogDefinition ? T['emit'] extends 'event' ? T['level'] : never : never export type GetEvents = T extends Array ? GetLogType | GetLogType | GetLogType | GetLogType : never export type QueryEvent = { timestamp: Date query: string params: string duration: number target: string } export type LogEvent = { timestamp: Date message: string target: string } /* End Types for Logging */ export type PrismaAction = | 'findUnique' | 'findMany' | 'findFirst' | 'create' | 'createMany' | 'update' | 'updateMany' | 'upsert' | 'delete' | 'deleteMany' | 'executeRaw' | 'queryRaw' | 'aggregate' | 'count' | 'runCommandRaw' | 'findRaw' /** * These options are being passed into the middleware as "params" */ export type MiddlewareParams = { model?: ModelName action: PrismaAction args: any dataPath: string[] runInTransaction: boolean } /** * The `T` type makes sure, that the `return proceed` is not forgotten in the middleware implementation */ export type Middleware = ( params: MiddlewareParams, next: (params: MiddlewareParams) => Promise, ) => Promise // tested in getLogLevel.test.ts export function getLogLevel(log: Array): LogLevel | undefined; /** * `PrismaClient` proxy available in interactive transactions. */ export type TransactionClient = Omit export type Datasource = { url?: string } /** * Count Types */ /** * Models */ /** * Model Account */ export type AggregateAccount = { _count: AccountCountAggregateOutputType | null _min: AccountMinAggregateOutputType | null _max: AccountMaxAggregateOutputType | null } export type AccountMinAggregateOutputType = { id: string | null name: string | null userId: string | null email: string | null salt: string | null password: string | null createdAt: Date | null updatedAt: Date | null lastSignedInAt: Date | null inactive: boolean | null inactiveAt: Date | null } export type AccountMaxAggregateOutputType = { id: string | null name: string | null userId: string | null email: string | null salt: string | null password: string | null createdAt: Date | null updatedAt: Date | null lastSignedInAt: Date | null inactive: boolean | null inactiveAt: Date | null } export type AccountCountAggregateOutputType = { id: number name: number userId: number roles: number email: number salt: number password: number createdAt: number updatedAt: number lastSignedInAt: number inactive: number inactiveAt: number _all: number } export type AccountMinAggregateInputType = { id?: true name?: true userId?: true email?: true salt?: true password?: true createdAt?: true updatedAt?: true lastSignedInAt?: true inactive?: true inactiveAt?: true } export type AccountMaxAggregateInputType = { id?: true name?: true userId?: true email?: true salt?: true password?: true createdAt?: true updatedAt?: true lastSignedInAt?: true inactive?: true inactiveAt?: true } export type AccountCountAggregateInputType = { id?: true name?: true userId?: true roles?: true email?: true salt?: true password?: true createdAt?: true updatedAt?: true lastSignedInAt?: true inactive?: true inactiveAt?: true _all?: true } export type AccountAggregateArgs = { /** * Filter which Account to aggregate. */ where?: AccountWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Accounts to fetch. */ orderBy?: Enumerable /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the start position */ cursor?: AccountWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Accounts from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Accounts. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Count returned Accounts **/ _count?: true | AccountCountAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the minimum value **/ _min?: AccountMinAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the maximum value **/ _max?: AccountMaxAggregateInputType } export type GetAccountAggregateType = { [P in keyof T & keyof AggregateAccount]: P extends '_count' | 'count' ? T[P] extends true ? number : GetScalarType : GetScalarType } export type AccountGroupByArgs = { where?: AccountWhereInput orderBy?: Enumerable by: AccountScalarFieldEnum[] having?: AccountScalarWhereWithAggregatesInput take?: number skip?: number _count?: AccountCountAggregateInputType | true _min?: AccountMinAggregateInputType _max?: AccountMaxAggregateInputType } export type AccountGroupByOutputType = { id: string name: string userId: string roles: string[] email: string salt: string password: string createdAt: Date | null updatedAt: Date | null lastSignedInAt: Date | null inactive: boolean inactiveAt: Date | null _count: AccountCountAggregateOutputType | null _min: AccountMinAggregateOutputType | null _max: AccountMaxAggregateOutputType | null } type GetAccountGroupByPayload = Prisma.PrismaPromise< Array< PickArray & { [P in ((keyof T) & (keyof AccountGroupByOutputType))]: P extends '_count' ? T[P] extends boolean ? number : GetScalarType : GetScalarType } > > export type AccountSelect = { id?: boolean name?: boolean userId?: boolean roles?: boolean email?: boolean salt?: boolean password?: boolean createdAt?: boolean updatedAt?: boolean lastSignedInAt?: boolean inactive?: boolean inactiveAt?: boolean } export type AccountGetPayload = S extends { select: any, include: any } ? 'Please either choose `select` or `include`' : S extends true ? Account : S extends undefined ? never : S extends { include: any } & (AccountArgs | AccountFindManyArgs) ? Account : S extends { select: any } & (AccountArgs | AccountFindManyArgs) ? { [P in TruthyKeys]: P extends keyof Account ? Account[P] : never } : Account type AccountCountArgs = Omit & { select?: AccountCountAggregateInputType | true } export interface AccountDelegate { /** * Find zero or one Account that matches the filter. * @param {AccountFindUniqueArgs} args - Arguments to find a Account * @example * // Get one Account * const account = await prisma.account.findUnique({ * where: { * // ... provide filter here * } * }) **/ findUnique( args: SelectSubset ): HasReject extends True ? Prisma__AccountClient> : Prisma__AccountClient | null, null> /** * Find one Account that matches the filter or throw an error with `error.code='P2025'` * if no matches were found. * @param {AccountFindUniqueOrThrowArgs} args - Arguments to find a Account * @example * // Get one Account * const account = await prisma.account.findUniqueOrThrow({ * where: { * // ... provide filter here * } * }) **/ findUniqueOrThrow( args?: SelectSubset ): Prisma__AccountClient> /** * Find the first Account that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {AccountFindFirstArgs} args - Arguments to find a Account * @example * // Get one Account * const account = await prisma.account.findFirst({ * where: { * // ... provide filter here * } * }) **/ findFirst( args?: SelectSubset ): HasReject extends True ? Prisma__AccountClient> : Prisma__AccountClient | null, null> /** * Find the first Account that matches the filter or * throw `NotFoundError` if no matches were found. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {AccountFindFirstOrThrowArgs} args - Arguments to find a Account * @example * // Get one Account * const account = await prisma.account.findFirstOrThrow({ * where: { * // ... provide filter here * } * }) **/ findFirstOrThrow( args?: SelectSubset ): Prisma__AccountClient> /** * Find zero or more Accounts that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {AccountFindManyArgs=} args - Arguments to filter and select certain fields only. * @example * // Get all Accounts * const accounts = await prisma.account.findMany() * * // Get first 10 Accounts * const accounts = await prisma.account.findMany({ take: 10 }) * * // Only select the `id` * const accountWithIdOnly = await prisma.account.findMany({ select: { id: true } }) * **/ findMany( args?: SelectSubset ): Prisma.PrismaPromise>> /** * Create a Account. * @param {AccountCreateArgs} args - Arguments to create a Account. * @example * // Create one Account * const Account = await prisma.account.create({ * data: { * // ... data to create a Account * } * }) * **/ create( args: SelectSubset ): Prisma__AccountClient> /** * Create many Accounts. * @param {AccountCreateManyArgs} args - Arguments to create many Accounts. * @example * // Create many Accounts * const account = await prisma.account.createMany({ * data: { * // ... provide data here * } * }) * **/ createMany( args?: SelectSubset ): Prisma.PrismaPromise /** * Delete a Account. * @param {AccountDeleteArgs} args - Arguments to delete one Account. * @example * // Delete one Account * const Account = await prisma.account.delete({ * where: { * // ... filter to delete one Account * } * }) * **/ delete( args: SelectSubset ): Prisma__AccountClient> /** * Update one Account. * @param {AccountUpdateArgs} args - Arguments to update one Account. * @example * // Update one Account * const account = await prisma.account.update({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * **/ update( args: SelectSubset ): Prisma__AccountClient> /** * Delete zero or more Accounts. * @param {AccountDeleteManyArgs} args - Arguments to filter Accounts to delete. * @example * // Delete a few Accounts * const { count } = await prisma.account.deleteMany({ * where: { * // ... provide filter here * } * }) * **/ deleteMany( args?: SelectSubset ): Prisma.PrismaPromise /** * Update zero or more Accounts. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {AccountUpdateManyArgs} args - Arguments to update one or more rows. * @example * // Update many Accounts * const account = await prisma.account.updateMany({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * **/ updateMany( args: SelectSubset ): Prisma.PrismaPromise /** * Create or update one Account. * @param {AccountUpsertArgs} args - Arguments to update or create a Account. * @example * // Update or create a Account * const account = await prisma.account.upsert({ * create: { * // ... data to create a Account * }, * update: { * // ... in case it already exists, update * }, * where: { * // ... the filter for the Account we want to update * } * }) **/ upsert( args: SelectSubset ): Prisma__AccountClient> /** * Find zero or more Accounts that matches the filter. * @param {AccountFindRawArgs} args - Select which filters you would like to apply. * @example * const account = await prisma.account.findRaw({ * filter: { age: { $gt: 25 } } * }) **/ findRaw( args?: AccountFindRawArgs ): Prisma.PrismaPromise /** * Perform aggregation operations on a Account. * @param {AccountAggregateRawArgs} args - Select which aggregations you would like to apply. * @example * const account = await prisma.account.aggregateRaw({ * pipeline: [ * { $match: { status: "registered" } }, * { $group: { _id: "$country", total: { $sum: 1 } } } * ] * }) **/ aggregateRaw( args?: AccountAggregateRawArgs ): Prisma.PrismaPromise /** * Count the number of Accounts. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {AccountCountArgs} args - Arguments to filter Accounts to count. * @example * // Count the number of Accounts * const count = await prisma.account.count({ * where: { * // ... the filter for the Accounts we want to count * } * }) **/ count( args?: Subset, ): Prisma.PrismaPromise< T extends _Record<'select', any> ? T['select'] extends true ? number : GetScalarType : number > /** * Allows you to perform aggregations operations on a Account. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {AccountAggregateArgs} args - Select which aggregations you would like to apply and on what fields. * @example * // Ordered by age ascending * // Where email contains prisma.io * // Limited to the 10 users * const aggregations = await prisma.user.aggregate({ * _avg: { * age: true, * }, * where: { * email: { * contains: "prisma.io", * }, * }, * orderBy: { * age: "asc", * }, * take: 10, * }) **/ aggregate(args: Subset): Prisma.PrismaPromise> /** * Group by Account. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {AccountGroupByArgs} args - Group by arguments. * @example * // Group by city, order by createdAt, get count * const result = await prisma.user.groupBy({ * by: ['city', 'createdAt'], * orderBy: { * createdAt: true * }, * _count: { * _all: true * }, * }) * **/ groupBy< T extends AccountGroupByArgs, HasSelectOrTake extends Or< Extends<'skip', Keys>, Extends<'take', Keys> >, OrderByArg extends True extends HasSelectOrTake ? { orderBy: AccountGroupByArgs['orderBy'] } : { orderBy?: AccountGroupByArgs['orderBy'] }, OrderFields extends ExcludeUnderscoreKeys>>, ByFields extends TupleToUnion, ByValid extends Has, HavingFields extends GetHavingFields, HavingValid extends Has, ByEmpty extends T['by'] extends never[] ? True : False, InputErrors extends ByEmpty extends True ? `Error: "by" must not be empty.` : HavingValid extends False ? { [P in HavingFields]: P extends ByFields ? never : P extends string ? `Error: Field "${P}" used in "having" needs to be provided in "by".` : [ Error, 'Field ', P, ` in "having" needs to be provided in "by"`, ] }[HavingFields] : 'take' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "take", you also need to provide "orderBy"' : 'skip' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "skip", you also need to provide "orderBy"' : ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] >(args: SubsetIntersection & InputErrors): {} extends InputErrors ? GetAccountGroupByPayload : Prisma.PrismaPromise } /** * The delegate class that acts as a "Promise-like" for Account. * Why is this prefixed with `Prisma__`? * Because we want to prevent naming conflicts as mentioned in * https://github.com/prisma/prisma-client-js/issues/707 */ export class Prisma__AccountClient implements Prisma.PrismaPromise { private readonly _dmmf; private readonly _queryType; private readonly _rootField; private readonly _clientMethod; private readonly _args; private readonly _dataPath; private readonly _errorFormat; private readonly _measurePerformance?; private _isList; private _callsite; private _requestPromise?; readonly [Symbol.toStringTag]: 'PrismaPromise'; constructor(_dmmf: runtime.DMMFClass, _queryType: 'query' | 'mutation', _rootField: string, _clientMethod: string, _args: any, _dataPath: string[], _errorFormat: ErrorFormat, _measurePerformance?: boolean | undefined, _isList?: boolean); private get _document(); /** * Attaches callbacks for the resolution and/or rejection of the Promise. * @param onfulfilled The callback to execute when the Promise is resolved. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of which ever callback is executed. */ then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): Promise; /** * Attaches a callback for only the rejection of the Promise. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of the callback. */ catch(onrejected?: ((reason: any) => TResult | PromiseLike) | undefined | null): Promise; /** * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The * resolved value cannot be modified from the callback. * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected). * @returns A Promise for the completion of the callback. */ finally(onfinally?: (() => void) | undefined | null): Promise; } // Custom InputTypes /** * Account base type for findUnique actions */ export type AccountFindUniqueArgsBase = { /** * Select specific fields to fetch from the Account */ select?: AccountSelect | null /** * Filter, which Account to fetch. */ where: AccountWhereUniqueInput } /** * Account findUnique */ export interface AccountFindUniqueArgs extends AccountFindUniqueArgsBase { /** * Throw an Error if query returns no results * @deprecated since 4.0.0: use `findUniqueOrThrow` method instead */ rejectOnNotFound?: RejectOnNotFound } /** * Account findUniqueOrThrow */ export type AccountFindUniqueOrThrowArgs = { /** * Select specific fields to fetch from the Account */ select?: AccountSelect | null /** * Filter, which Account to fetch. */ where: AccountWhereUniqueInput } /** * Account base type for findFirst actions */ export type AccountFindFirstArgsBase = { /** * Select specific fields to fetch from the Account */ select?: AccountSelect | null /** * Filter, which Account to fetch. */ where?: AccountWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Accounts to fetch. */ orderBy?: Enumerable /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for Accounts. */ cursor?: AccountWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Accounts from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Accounts. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of Accounts. */ distinct?: Enumerable } /** * Account findFirst */ export interface AccountFindFirstArgs extends AccountFindFirstArgsBase { /** * Throw an Error if query returns no results * @deprecated since 4.0.0: use `findFirstOrThrow` method instead */ rejectOnNotFound?: RejectOnNotFound } /** * Account findFirstOrThrow */ export type AccountFindFirstOrThrowArgs = { /** * Select specific fields to fetch from the Account */ select?: AccountSelect | null /** * Filter, which Account to fetch. */ where?: AccountWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Accounts to fetch. */ orderBy?: Enumerable /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for Accounts. */ cursor?: AccountWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Accounts from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Accounts. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of Accounts. */ distinct?: Enumerable } /** * Account findMany */ export type AccountFindManyArgs = { /** * Select specific fields to fetch from the Account */ select?: AccountSelect | null /** * Filter, which Accounts to fetch. */ where?: AccountWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Accounts to fetch. */ orderBy?: Enumerable /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for listing Accounts. */ cursor?: AccountWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Accounts from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Accounts. */ skip?: number distinct?: Enumerable } /** * Account create */ export type AccountCreateArgs = { /** * Select specific fields to fetch from the Account */ select?: AccountSelect | null /** * The data needed to create a Account. */ data: XOR } /** * Account createMany */ export type AccountCreateManyArgs = { /** * The data used to create many Accounts. */ data: Enumerable } /** * Account update */ export type AccountUpdateArgs = { /** * Select specific fields to fetch from the Account */ select?: AccountSelect | null /** * The data needed to update a Account. */ data: XOR /** * Choose, which Account to update. */ where: AccountWhereUniqueInput } /** * Account updateMany */ export type AccountUpdateManyArgs = { /** * The data used to update Accounts. */ data: XOR /** * Filter which Accounts to update */ where?: AccountWhereInput } /** * Account upsert */ export type AccountUpsertArgs = { /** * Select specific fields to fetch from the Account */ select?: AccountSelect | null /** * The filter to search for the Account to update in case it exists. */ where: AccountWhereUniqueInput /** * In case the Account found by the `where` argument doesn't exist, create a new Account with this data. */ create: XOR /** * In case the Account was found with the provided `where` argument, update it with this data. */ update: XOR } /** * Account delete */ export type AccountDeleteArgs = { /** * Select specific fields to fetch from the Account */ select?: AccountSelect | null /** * Filter which Account to delete. */ where: AccountWhereUniqueInput } /** * Account deleteMany */ export type AccountDeleteManyArgs = { /** * Filter which Accounts to delete */ where?: AccountWhereInput } /** * Account findRaw */ export type AccountFindRawArgs = { /** * The query predicate filter. If unspecified, then all documents in the collection will match the predicate. ${@link https://docs.mongodb.com/manual/reference/operator/query MongoDB Docs}. */ filter?: InputJsonValue /** * Additional options to pass to the `find` command ${@link https://docs.mongodb.com/manual/reference/command/find/#command-fields MongoDB Docs}. */ options?: InputJsonValue } /** * Account aggregateRaw */ export type AccountAggregateRawArgs = { /** * An array of aggregation stages to process and transform the document stream via the aggregation pipeline. ${@link https://docs.mongodb.com/manual/reference/operator/aggregation-pipeline MongoDB Docs}. */ pipeline?: InputJsonValue[] /** * Additional options to pass to the `aggregate` command ${@link https://docs.mongodb.com/manual/reference/command/aggregate/#command-fields MongoDB Docs}. */ options?: InputJsonValue } /** * Account without action */ export type AccountArgs = { /** * Select specific fields to fetch from the Account */ select?: AccountSelect | null } /** * Model Role */ export type AggregateRole = { _count: RoleCountAggregateOutputType | null _min: RoleMinAggregateOutputType | null _max: RoleMaxAggregateOutputType | null } export type RoleMinAggregateOutputType = { id: string | null name: string | null roleId: string | null description: string | null createdAt: Date | null updatedAt: Date | null inactive: boolean | null inactiveAt: Date | null } export type RoleMaxAggregateOutputType = { id: string | null name: string | null roleId: string | null description: string | null createdAt: Date | null updatedAt: Date | null inactive: boolean | null inactiveAt: Date | null } export type RoleCountAggregateOutputType = { id: number name: number roleId: number description: number createdAt: number updatedAt: number inactive: number inactiveAt: number _all: number } export type RoleMinAggregateInputType = { id?: true name?: true roleId?: true description?: true createdAt?: true updatedAt?: true inactive?: true inactiveAt?: true } export type RoleMaxAggregateInputType = { id?: true name?: true roleId?: true description?: true createdAt?: true updatedAt?: true inactive?: true inactiveAt?: true } export type RoleCountAggregateInputType = { id?: true name?: true roleId?: true description?: true createdAt?: true updatedAt?: true inactive?: true inactiveAt?: true _all?: true } export type RoleAggregateArgs = { /** * Filter which Role to aggregate. */ where?: RoleWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Roles to fetch. */ orderBy?: Enumerable /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the start position */ cursor?: RoleWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Roles from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Roles. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Count returned Roles **/ _count?: true | RoleCountAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the minimum value **/ _min?: RoleMinAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the maximum value **/ _max?: RoleMaxAggregateInputType } export type GetRoleAggregateType = { [P in keyof T & keyof AggregateRole]: P extends '_count' | 'count' ? T[P] extends true ? number : GetScalarType : GetScalarType } export type RoleGroupByArgs = { where?: RoleWhereInput orderBy?: Enumerable by: RoleScalarFieldEnum[] having?: RoleScalarWhereWithAggregatesInput take?: number skip?: number _count?: RoleCountAggregateInputType | true _min?: RoleMinAggregateInputType _max?: RoleMaxAggregateInputType } export type RoleGroupByOutputType = { id: string name: string roleId: string description: string createdAt: Date | null updatedAt: Date | null inactive: boolean inactiveAt: Date | null _count: RoleCountAggregateOutputType | null _min: RoleMinAggregateOutputType | null _max: RoleMaxAggregateOutputType | null } type GetRoleGroupByPayload = Prisma.PrismaPromise< Array< PickArray & { [P in ((keyof T) & (keyof RoleGroupByOutputType))]: P extends '_count' ? T[P] extends boolean ? number : GetScalarType : GetScalarType } > > export type RoleSelect = { id?: boolean name?: boolean roleId?: boolean description?: boolean createdAt?: boolean updatedAt?: boolean inactive?: boolean inactiveAt?: boolean } export type RoleGetPayload = S extends { select: any, include: any } ? 'Please either choose `select` or `include`' : S extends true ? Role : S extends undefined ? never : S extends { include: any } & (RoleArgs | RoleFindManyArgs) ? Role : S extends { select: any } & (RoleArgs | RoleFindManyArgs) ? { [P in TruthyKeys]: P extends keyof Role ? Role[P] : never } : Role type RoleCountArgs = Omit & { select?: RoleCountAggregateInputType | true } export interface RoleDelegate { /** * Find zero or one Role that matches the filter. * @param {RoleFindUniqueArgs} args - Arguments to find a Role * @example * // Get one Role * const role = await prisma.role.findUnique({ * where: { * // ... provide filter here * } * }) **/ findUnique( args: SelectSubset ): HasReject extends True ? Prisma__RoleClient> : Prisma__RoleClient | null, null> /** * Find one Role that matches the filter or throw an error with `error.code='P2025'` * if no matches were found. * @param {RoleFindUniqueOrThrowArgs} args - Arguments to find a Role * @example * // Get one Role * const role = await prisma.role.findUniqueOrThrow({ * where: { * // ... provide filter here * } * }) **/ findUniqueOrThrow( args?: SelectSubset ): Prisma__RoleClient> /** * Find the first Role that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {RoleFindFirstArgs} args - Arguments to find a Role * @example * // Get one Role * const role = await prisma.role.findFirst({ * where: { * // ... provide filter here * } * }) **/ findFirst( args?: SelectSubset ): HasReject extends True ? Prisma__RoleClient> : Prisma__RoleClient | null, null> /** * Find the first Role that matches the filter or * throw `NotFoundError` if no matches were found. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {RoleFindFirstOrThrowArgs} args - Arguments to find a Role * @example * // Get one Role * const role = await prisma.role.findFirstOrThrow({ * where: { * // ... provide filter here * } * }) **/ findFirstOrThrow( args?: SelectSubset ): Prisma__RoleClient> /** * Find zero or more Roles that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {RoleFindManyArgs=} args - Arguments to filter and select certain fields only. * @example * // Get all Roles * const roles = await prisma.role.findMany() * * // Get first 10 Roles * const roles = await prisma.role.findMany({ take: 10 }) * * // Only select the `id` * const roleWithIdOnly = await prisma.role.findMany({ select: { id: true } }) * **/ findMany( args?: SelectSubset ): Prisma.PrismaPromise>> /** * Create a Role. * @param {RoleCreateArgs} args - Arguments to create a Role. * @example * // Create one Role * const Role = await prisma.role.create({ * data: { * // ... data to create a Role * } * }) * **/ create( args: SelectSubset ): Prisma__RoleClient> /** * Create many Roles. * @param {RoleCreateManyArgs} args - Arguments to create many Roles. * @example * // Create many Roles * const role = await prisma.role.createMany({ * data: { * // ... provide data here * } * }) * **/ createMany( args?: SelectSubset ): Prisma.PrismaPromise /** * Delete a Role. * @param {RoleDeleteArgs} args - Arguments to delete one Role. * @example * // Delete one Role * const Role = await prisma.role.delete({ * where: { * // ... filter to delete one Role * } * }) * **/ delete( args: SelectSubset ): Prisma__RoleClient> /** * Update one Role. * @param {RoleUpdateArgs} args - Arguments to update one Role. * @example * // Update one Role * const role = await prisma.role.update({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * **/ update( args: SelectSubset ): Prisma__RoleClient> /** * Delete zero or more Roles. * @param {RoleDeleteManyArgs} args - Arguments to filter Roles to delete. * @example * // Delete a few Roles * const { count } = await prisma.role.deleteMany({ * where: { * // ... provide filter here * } * }) * **/ deleteMany( args?: SelectSubset ): Prisma.PrismaPromise /** * Update zero or more Roles. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {RoleUpdateManyArgs} args - Arguments to update one or more rows. * @example * // Update many Roles * const role = await prisma.role.updateMany({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * **/ updateMany( args: SelectSubset ): Prisma.PrismaPromise /** * Create or update one Role. * @param {RoleUpsertArgs} args - Arguments to update or create a Role. * @example * // Update or create a Role * const role = await prisma.role.upsert({ * create: { * // ... data to create a Role * }, * update: { * // ... in case it already exists, update * }, * where: { * // ... the filter for the Role we want to update * } * }) **/ upsert( args: SelectSubset ): Prisma__RoleClient> /** * Find zero or more Roles that matches the filter. * @param {RoleFindRawArgs} args - Select which filters you would like to apply. * @example * const role = await prisma.role.findRaw({ * filter: { age: { $gt: 25 } } * }) **/ findRaw( args?: RoleFindRawArgs ): Prisma.PrismaPromise /** * Perform aggregation operations on a Role. * @param {RoleAggregateRawArgs} args - Select which aggregations you would like to apply. * @example * const role = await prisma.role.aggregateRaw({ * pipeline: [ * { $match: { status: "registered" } }, * { $group: { _id: "$country", total: { $sum: 1 } } } * ] * }) **/ aggregateRaw( args?: RoleAggregateRawArgs ): Prisma.PrismaPromise /** * Count the number of Roles. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {RoleCountArgs} args - Arguments to filter Roles to count. * @example * // Count the number of Roles * const count = await prisma.role.count({ * where: { * // ... the filter for the Roles we want to count * } * }) **/ count( args?: Subset, ): Prisma.PrismaPromise< T extends _Record<'select', any> ? T['select'] extends true ? number : GetScalarType : number > /** * Allows you to perform aggregations operations on a Role. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {RoleAggregateArgs} args - Select which aggregations you would like to apply and on what fields. * @example * // Ordered by age ascending * // Where email contains prisma.io * // Limited to the 10 users * const aggregations = await prisma.user.aggregate({ * _avg: { * age: true, * }, * where: { * email: { * contains: "prisma.io", * }, * }, * orderBy: { * age: "asc", * }, * take: 10, * }) **/ aggregate(args: Subset): Prisma.PrismaPromise> /** * Group by Role. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {RoleGroupByArgs} args - Group by arguments. * @example * // Group by city, order by createdAt, get count * const result = await prisma.user.groupBy({ * by: ['city', 'createdAt'], * orderBy: { * createdAt: true * }, * _count: { * _all: true * }, * }) * **/ groupBy< T extends RoleGroupByArgs, HasSelectOrTake extends Or< Extends<'skip', Keys>, Extends<'take', Keys> >, OrderByArg extends True extends HasSelectOrTake ? { orderBy: RoleGroupByArgs['orderBy'] } : { orderBy?: RoleGroupByArgs['orderBy'] }, OrderFields extends ExcludeUnderscoreKeys>>, ByFields extends TupleToUnion, ByValid extends Has, HavingFields extends GetHavingFields, HavingValid extends Has, ByEmpty extends T['by'] extends never[] ? True : False, InputErrors extends ByEmpty extends True ? `Error: "by" must not be empty.` : HavingValid extends False ? { [P in HavingFields]: P extends ByFields ? never : P extends string ? `Error: Field "${P}" used in "having" needs to be provided in "by".` : [ Error, 'Field ', P, ` in "having" needs to be provided in "by"`, ] }[HavingFields] : 'take' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "take", you also need to provide "orderBy"' : 'skip' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "skip", you also need to provide "orderBy"' : ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] >(args: SubsetIntersection & InputErrors): {} extends InputErrors ? GetRoleGroupByPayload : Prisma.PrismaPromise } /** * The delegate class that acts as a "Promise-like" for Role. * Why is this prefixed with `Prisma__`? * Because we want to prevent naming conflicts as mentioned in * https://github.com/prisma/prisma-client-js/issues/707 */ export class Prisma__RoleClient implements Prisma.PrismaPromise { private readonly _dmmf; private readonly _queryType; private readonly _rootField; private readonly _clientMethod; private readonly _args; private readonly _dataPath; private readonly _errorFormat; private readonly _measurePerformance?; private _isList; private _callsite; private _requestPromise?; readonly [Symbol.toStringTag]: 'PrismaPromise'; constructor(_dmmf: runtime.DMMFClass, _queryType: 'query' | 'mutation', _rootField: string, _clientMethod: string, _args: any, _dataPath: string[], _errorFormat: ErrorFormat, _measurePerformance?: boolean | undefined, _isList?: boolean); private get _document(); /** * Attaches callbacks for the resolution and/or rejection of the Promise. * @param onfulfilled The callback to execute when the Promise is resolved. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of which ever callback is executed. */ then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): Promise; /** * Attaches a callback for only the rejection of the Promise. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of the callback. */ catch(onrejected?: ((reason: any) => TResult | PromiseLike) | undefined | null): Promise; /** * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The * resolved value cannot be modified from the callback. * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected). * @returns A Promise for the completion of the callback. */ finally(onfinally?: (() => void) | undefined | null): Promise; } // Custom InputTypes /** * Role base type for findUnique actions */ export type RoleFindUniqueArgsBase = { /** * Select specific fields to fetch from the Role */ select?: RoleSelect | null /** * Filter, which Role to fetch. */ where: RoleWhereUniqueInput } /** * Role findUnique */ export interface RoleFindUniqueArgs extends RoleFindUniqueArgsBase { /** * Throw an Error if query returns no results * @deprecated since 4.0.0: use `findUniqueOrThrow` method instead */ rejectOnNotFound?: RejectOnNotFound } /** * Role findUniqueOrThrow */ export type RoleFindUniqueOrThrowArgs = { /** * Select specific fields to fetch from the Role */ select?: RoleSelect | null /** * Filter, which Role to fetch. */ where: RoleWhereUniqueInput } /** * Role base type for findFirst actions */ export type RoleFindFirstArgsBase = { /** * Select specific fields to fetch from the Role */ select?: RoleSelect | null /** * Filter, which Role to fetch. */ where?: RoleWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Roles to fetch. */ orderBy?: Enumerable /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for Roles. */ cursor?: RoleWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Roles from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Roles. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of Roles. */ distinct?: Enumerable } /** * Role findFirst */ export interface RoleFindFirstArgs extends RoleFindFirstArgsBase { /** * Throw an Error if query returns no results * @deprecated since 4.0.0: use `findFirstOrThrow` method instead */ rejectOnNotFound?: RejectOnNotFound } /** * Role findFirstOrThrow */ export type RoleFindFirstOrThrowArgs = { /** * Select specific fields to fetch from the Role */ select?: RoleSelect | null /** * Filter, which Role to fetch. */ where?: RoleWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Roles to fetch. */ orderBy?: Enumerable /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for Roles. */ cursor?: RoleWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Roles from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Roles. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of Roles. */ distinct?: Enumerable } /** * Role findMany */ export type RoleFindManyArgs = { /** * Select specific fields to fetch from the Role */ select?: RoleSelect | null /** * Filter, which Roles to fetch. */ where?: RoleWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Roles to fetch. */ orderBy?: Enumerable /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for listing Roles. */ cursor?: RoleWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Roles from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Roles. */ skip?: number distinct?: Enumerable } /** * Role create */ export type RoleCreateArgs = { /** * Select specific fields to fetch from the Role */ select?: RoleSelect | null /** * The data needed to create a Role. */ data: XOR } /** * Role createMany */ export type RoleCreateManyArgs = { /** * The data used to create many Roles. */ data: Enumerable } /** * Role update */ export type RoleUpdateArgs = { /** * Select specific fields to fetch from the Role */ select?: RoleSelect | null /** * The data needed to update a Role. */ data: XOR /** * Choose, which Role to update. */ where: RoleWhereUniqueInput } /** * Role updateMany */ export type RoleUpdateManyArgs = { /** * The data used to update Roles. */ data: XOR /** * Filter which Roles to update */ where?: RoleWhereInput } /** * Role upsert */ export type RoleUpsertArgs = { /** * Select specific fields to fetch from the Role */ select?: RoleSelect | null /** * The filter to search for the Role to update in case it exists. */ where: RoleWhereUniqueInput /** * In case the Role found by the `where` argument doesn't exist, create a new Role with this data. */ create: XOR /** * In case the Role was found with the provided `where` argument, update it with this data. */ update: XOR } /** * Role delete */ export type RoleDeleteArgs = { /** * Select specific fields to fetch from the Role */ select?: RoleSelect | null /** * Filter which Role to delete. */ where: RoleWhereUniqueInput } /** * Role deleteMany */ export type RoleDeleteManyArgs = { /** * Filter which Roles to delete */ where?: RoleWhereInput } /** * Role findRaw */ export type RoleFindRawArgs = { /** * The query predicate filter. If unspecified, then all documents in the collection will match the predicate. ${@link https://docs.mongodb.com/manual/reference/operator/query MongoDB Docs}. */ filter?: InputJsonValue /** * Additional options to pass to the `find` command ${@link https://docs.mongodb.com/manual/reference/command/find/#command-fields MongoDB Docs}. */ options?: InputJsonValue } /** * Role aggregateRaw */ export type RoleAggregateRawArgs = { /** * An array of aggregation stages to process and transform the document stream via the aggregation pipeline. ${@link https://docs.mongodb.com/manual/reference/operator/aggregation-pipeline MongoDB Docs}. */ pipeline?: InputJsonValue[] /** * Additional options to pass to the `aggregate` command ${@link https://docs.mongodb.com/manual/reference/command/aggregate/#command-fields MongoDB Docs}. */ options?: InputJsonValue } /** * Role without action */ export type RoleArgs = { /** * Select specific fields to fetch from the Role */ select?: RoleSelect | null } /** * Model CasbinModel */ export type AggregateCasbinModel = { _count: CasbinModelCountAggregateOutputType | null _min: CasbinModelMinAggregateOutputType | null _max: CasbinModelMaxAggregateOutputType | null } export type CasbinModelMinAggregateOutputType = { id: string | null bizRealm: string | null sec: string | null pType: string | null v0: string | null v1: string | null v2: string | null v3: string | null v4: string | null v5: string | null createdAt: Date | null updatedAt: Date | null } export type CasbinModelMaxAggregateOutputType = { id: string | null bizRealm: string | null sec: string | null pType: string | null v0: string | null v1: string | null v2: string | null v3: string | null v4: string | null v5: string | null createdAt: Date | null updatedAt: Date | null } export type CasbinModelCountAggregateOutputType = { id: number bizRealm: number sec: number pType: number v0: number v1: number v2: number v3: number v4: number v5: number createdAt: number updatedAt: number _all: number } export type CasbinModelMinAggregateInputType = { id?: true bizRealm?: true sec?: true pType?: true v0?: true v1?: true v2?: true v3?: true v4?: true v5?: true createdAt?: true updatedAt?: true } export type CasbinModelMaxAggregateInputType = { id?: true bizRealm?: true sec?: true pType?: true v0?: true v1?: true v2?: true v3?: true v4?: true v5?: true createdAt?: true updatedAt?: true } export type CasbinModelCountAggregateInputType = { id?: true bizRealm?: true sec?: true pType?: true v0?: true v1?: true v2?: true v3?: true v4?: true v5?: true createdAt?: true updatedAt?: true _all?: true } export type CasbinModelAggregateArgs = { /** * Filter which CasbinModel to aggregate. */ where?: CasbinModelWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of CasbinModels to fetch. */ orderBy?: Enumerable /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the start position */ cursor?: CasbinModelWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` CasbinModels from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` CasbinModels. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Count returned CasbinModels **/ _count?: true | CasbinModelCountAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the minimum value **/ _min?: CasbinModelMinAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the maximum value **/ _max?: CasbinModelMaxAggregateInputType } export type GetCasbinModelAggregateType = { [P in keyof T & keyof AggregateCasbinModel]: P extends '_count' | 'count' ? T[P] extends true ? number : GetScalarType : GetScalarType } export type CasbinModelGroupByArgs = { where?: CasbinModelWhereInput orderBy?: Enumerable by: CasbinModelScalarFieldEnum[] having?: CasbinModelScalarWhereWithAggregatesInput take?: number skip?: number _count?: CasbinModelCountAggregateInputType | true _min?: CasbinModelMinAggregateInputType _max?: CasbinModelMaxAggregateInputType } export type CasbinModelGroupByOutputType = { id: string bizRealm: string sec: string pType: string v0: string | null v1: string | null v2: string | null v3: string | null v4: string | null v5: string | null createdAt: Date | null updatedAt: Date | null _count: CasbinModelCountAggregateOutputType | null _min: CasbinModelMinAggregateOutputType | null _max: CasbinModelMaxAggregateOutputType | null } type GetCasbinModelGroupByPayload = Prisma.PrismaPromise< Array< PickArray & { [P in ((keyof T) & (keyof CasbinModelGroupByOutputType))]: P extends '_count' ? T[P] extends boolean ? number : GetScalarType : GetScalarType } > > export type CasbinModelSelect = { id?: boolean bizRealm?: boolean sec?: boolean pType?: boolean v0?: boolean v1?: boolean v2?: boolean v3?: boolean v4?: boolean v5?: boolean createdAt?: boolean updatedAt?: boolean } export type CasbinModelGetPayload = S extends { select: any, include: any } ? 'Please either choose `select` or `include`' : S extends true ? CasbinModel : S extends undefined ? never : S extends { include: any } & (CasbinModelArgs | CasbinModelFindManyArgs) ? CasbinModel : S extends { select: any } & (CasbinModelArgs | CasbinModelFindManyArgs) ? { [P in TruthyKeys]: P extends keyof CasbinModel ? CasbinModel[P] : never } : CasbinModel type CasbinModelCountArgs = Omit & { select?: CasbinModelCountAggregateInputType | true } export interface CasbinModelDelegate { /** * Find zero or one CasbinModel that matches the filter. * @param {CasbinModelFindUniqueArgs} args - Arguments to find a CasbinModel * @example * // Get one CasbinModel * const casbinModel = await prisma.casbinModel.findUnique({ * where: { * // ... provide filter here * } * }) **/ findUnique( args: SelectSubset ): HasReject extends True ? Prisma__CasbinModelClient> : Prisma__CasbinModelClient | null, null> /** * Find one CasbinModel that matches the filter or throw an error with `error.code='P2025'` * if no matches were found. * @param {CasbinModelFindUniqueOrThrowArgs} args - Arguments to find a CasbinModel * @example * // Get one CasbinModel * const casbinModel = await prisma.casbinModel.findUniqueOrThrow({ * where: { * // ... provide filter here * } * }) **/ findUniqueOrThrow( args?: SelectSubset ): Prisma__CasbinModelClient> /** * Find the first CasbinModel that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CasbinModelFindFirstArgs} args - Arguments to find a CasbinModel * @example * // Get one CasbinModel * const casbinModel = await prisma.casbinModel.findFirst({ * where: { * // ... provide filter here * } * }) **/ findFirst( args?: SelectSubset ): HasReject extends True ? Prisma__CasbinModelClient> : Prisma__CasbinModelClient | null, null> /** * Find the first CasbinModel that matches the filter or * throw `NotFoundError` if no matches were found. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CasbinModelFindFirstOrThrowArgs} args - Arguments to find a CasbinModel * @example * // Get one CasbinModel * const casbinModel = await prisma.casbinModel.findFirstOrThrow({ * where: { * // ... provide filter here * } * }) **/ findFirstOrThrow( args?: SelectSubset ): Prisma__CasbinModelClient> /** * Find zero or more CasbinModels that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CasbinModelFindManyArgs=} args - Arguments to filter and select certain fields only. * @example * // Get all CasbinModels * const casbinModels = await prisma.casbinModel.findMany() * * // Get first 10 CasbinModels * const casbinModels = await prisma.casbinModel.findMany({ take: 10 }) * * // Only select the `id` * const casbinModelWithIdOnly = await prisma.casbinModel.findMany({ select: { id: true } }) * **/ findMany( args?: SelectSubset ): Prisma.PrismaPromise>> /** * Create a CasbinModel. * @param {CasbinModelCreateArgs} args - Arguments to create a CasbinModel. * @example * // Create one CasbinModel * const CasbinModel = await prisma.casbinModel.create({ * data: { * // ... data to create a CasbinModel * } * }) * **/ create( args: SelectSubset ): Prisma__CasbinModelClient> /** * Create many CasbinModels. * @param {CasbinModelCreateManyArgs} args - Arguments to create many CasbinModels. * @example * // Create many CasbinModels * const casbinModel = await prisma.casbinModel.createMany({ * data: { * // ... provide data here * } * }) * **/ createMany( args?: SelectSubset ): Prisma.PrismaPromise /** * Delete a CasbinModel. * @param {CasbinModelDeleteArgs} args - Arguments to delete one CasbinModel. * @example * // Delete one CasbinModel * const CasbinModel = await prisma.casbinModel.delete({ * where: { * // ... filter to delete one CasbinModel * } * }) * **/ delete( args: SelectSubset ): Prisma__CasbinModelClient> /** * Update one CasbinModel. * @param {CasbinModelUpdateArgs} args - Arguments to update one CasbinModel. * @example * // Update one CasbinModel * const casbinModel = await prisma.casbinModel.update({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * **/ update( args: SelectSubset ): Prisma__CasbinModelClient> /** * Delete zero or more CasbinModels. * @param {CasbinModelDeleteManyArgs} args - Arguments to filter CasbinModels to delete. * @example * // Delete a few CasbinModels * const { count } = await prisma.casbinModel.deleteMany({ * where: { * // ... provide filter here * } * }) * **/ deleteMany( args?: SelectSubset ): Prisma.PrismaPromise /** * Update zero or more CasbinModels. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CasbinModelUpdateManyArgs} args - Arguments to update one or more rows. * @example * // Update many CasbinModels * const casbinModel = await prisma.casbinModel.updateMany({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * **/ updateMany( args: SelectSubset ): Prisma.PrismaPromise /** * Create or update one CasbinModel. * @param {CasbinModelUpsertArgs} args - Arguments to update or create a CasbinModel. * @example * // Update or create a CasbinModel * const casbinModel = await prisma.casbinModel.upsert({ * create: { * // ... data to create a CasbinModel * }, * update: { * // ... in case it already exists, update * }, * where: { * // ... the filter for the CasbinModel we want to update * } * }) **/ upsert( args: SelectSubset ): Prisma__CasbinModelClient> /** * Find zero or more CasbinModels that matches the filter. * @param {CasbinModelFindRawArgs} args - Select which filters you would like to apply. * @example * const casbinModel = await prisma.casbinModel.findRaw({ * filter: { age: { $gt: 25 } } * }) **/ findRaw( args?: CasbinModelFindRawArgs ): Prisma.PrismaPromise /** * Perform aggregation operations on a CasbinModel. * @param {CasbinModelAggregateRawArgs} args - Select which aggregations you would like to apply. * @example * const casbinModel = await prisma.casbinModel.aggregateRaw({ * pipeline: [ * { $match: { status: "registered" } }, * { $group: { _id: "$country", total: { $sum: 1 } } } * ] * }) **/ aggregateRaw( args?: CasbinModelAggregateRawArgs ): Prisma.PrismaPromise /** * Count the number of CasbinModels. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CasbinModelCountArgs} args - Arguments to filter CasbinModels to count. * @example * // Count the number of CasbinModels * const count = await prisma.casbinModel.count({ * where: { * // ... the filter for the CasbinModels we want to count * } * }) **/ count( args?: Subset, ): Prisma.PrismaPromise< T extends _Record<'select', any> ? T['select'] extends true ? number : GetScalarType : number > /** * Allows you to perform aggregations operations on a CasbinModel. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CasbinModelAggregateArgs} args - Select which aggregations you would like to apply and on what fields. * @example * // Ordered by age ascending * // Where email contains prisma.io * // Limited to the 10 users * const aggregations = await prisma.user.aggregate({ * _avg: { * age: true, * }, * where: { * email: { * contains: "prisma.io", * }, * }, * orderBy: { * age: "asc", * }, * take: 10, * }) **/ aggregate(args: Subset): Prisma.PrismaPromise> /** * Group by CasbinModel. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CasbinModelGroupByArgs} args - Group by arguments. * @example * // Group by city, order by createdAt, get count * const result = await prisma.user.groupBy({ * by: ['city', 'createdAt'], * orderBy: { * createdAt: true * }, * _count: { * _all: true * }, * }) * **/ groupBy< T extends CasbinModelGroupByArgs, HasSelectOrTake extends Or< Extends<'skip', Keys>, Extends<'take', Keys> >, OrderByArg extends True extends HasSelectOrTake ? { orderBy: CasbinModelGroupByArgs['orderBy'] } : { orderBy?: CasbinModelGroupByArgs['orderBy'] }, OrderFields extends ExcludeUnderscoreKeys>>, ByFields extends TupleToUnion, ByValid extends Has, HavingFields extends GetHavingFields, HavingValid extends Has, ByEmpty extends T['by'] extends never[] ? True : False, InputErrors extends ByEmpty extends True ? `Error: "by" must not be empty.` : HavingValid extends False ? { [P in HavingFields]: P extends ByFields ? never : P extends string ? `Error: Field "${P}" used in "having" needs to be provided in "by".` : [ Error, 'Field ', P, ` in "having" needs to be provided in "by"`, ] }[HavingFields] : 'take' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "take", you also need to provide "orderBy"' : 'skip' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "skip", you also need to provide "orderBy"' : ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] >(args: SubsetIntersection & InputErrors): {} extends InputErrors ? GetCasbinModelGroupByPayload : Prisma.PrismaPromise } /** * The delegate class that acts as a "Promise-like" for CasbinModel. * Why is this prefixed with `Prisma__`? * Because we want to prevent naming conflicts as mentioned in * https://github.com/prisma/prisma-client-js/issues/707 */ export class Prisma__CasbinModelClient implements Prisma.PrismaPromise { private readonly _dmmf; private readonly _queryType; private readonly _rootField; private readonly _clientMethod; private readonly _args; private readonly _dataPath; private readonly _errorFormat; private readonly _measurePerformance?; private _isList; private _callsite; private _requestPromise?; readonly [Symbol.toStringTag]: 'PrismaPromise'; constructor(_dmmf: runtime.DMMFClass, _queryType: 'query' | 'mutation', _rootField: string, _clientMethod: string, _args: any, _dataPath: string[], _errorFormat: ErrorFormat, _measurePerformance?: boolean | undefined, _isList?: boolean); private get _document(); /** * Attaches callbacks for the resolution and/or rejection of the Promise. * @param onfulfilled The callback to execute when the Promise is resolved. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of which ever callback is executed. */ then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): Promise; /** * Attaches a callback for only the rejection of the Promise. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of the callback. */ catch(onrejected?: ((reason: any) => TResult | PromiseLike) | undefined | null): Promise; /** * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The * resolved value cannot be modified from the callback. * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected). * @returns A Promise for the completion of the callback. */ finally(onfinally?: (() => void) | undefined | null): Promise; } // Custom InputTypes /** * CasbinModel base type for findUnique actions */ export type CasbinModelFindUniqueArgsBase = { /** * Select specific fields to fetch from the CasbinModel */ select?: CasbinModelSelect | null /** * Filter, which CasbinModel to fetch. */ where: CasbinModelWhereUniqueInput } /** * CasbinModel findUnique */ export interface CasbinModelFindUniqueArgs extends CasbinModelFindUniqueArgsBase { /** * Throw an Error if query returns no results * @deprecated since 4.0.0: use `findUniqueOrThrow` method instead */ rejectOnNotFound?: RejectOnNotFound } /** * CasbinModel findUniqueOrThrow */ export type CasbinModelFindUniqueOrThrowArgs = { /** * Select specific fields to fetch from the CasbinModel */ select?: CasbinModelSelect | null /** * Filter, which CasbinModel to fetch. */ where: CasbinModelWhereUniqueInput } /** * CasbinModel base type for findFirst actions */ export type CasbinModelFindFirstArgsBase = { /** * Select specific fields to fetch from the CasbinModel */ select?: CasbinModelSelect | null /** * Filter, which CasbinModel to fetch. */ where?: CasbinModelWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of CasbinModels to fetch. */ orderBy?: Enumerable /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for CasbinModels. */ cursor?: CasbinModelWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` CasbinModels from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` CasbinModels. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of CasbinModels. */ distinct?: Enumerable } /** * CasbinModel findFirst */ export interface CasbinModelFindFirstArgs extends CasbinModelFindFirstArgsBase { /** * Throw an Error if query returns no results * @deprecated since 4.0.0: use `findFirstOrThrow` method instead */ rejectOnNotFound?: RejectOnNotFound } /** * CasbinModel findFirstOrThrow */ export type CasbinModelFindFirstOrThrowArgs = { /** * Select specific fields to fetch from the CasbinModel */ select?: CasbinModelSelect | null /** * Filter, which CasbinModel to fetch. */ where?: CasbinModelWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of CasbinModels to fetch. */ orderBy?: Enumerable /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for CasbinModels. */ cursor?: CasbinModelWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` CasbinModels from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` CasbinModels. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of CasbinModels. */ distinct?: Enumerable } /** * CasbinModel findMany */ export type CasbinModelFindManyArgs = { /** * Select specific fields to fetch from the CasbinModel */ select?: CasbinModelSelect | null /** * Filter, which CasbinModels to fetch. */ where?: CasbinModelWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of CasbinModels to fetch. */ orderBy?: Enumerable /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for listing CasbinModels. */ cursor?: CasbinModelWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` CasbinModels from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` CasbinModels. */ skip?: number distinct?: Enumerable } /** * CasbinModel create */ export type CasbinModelCreateArgs = { /** * Select specific fields to fetch from the CasbinModel */ select?: CasbinModelSelect | null /** * The data needed to create a CasbinModel. */ data: XOR } /** * CasbinModel createMany */ export type CasbinModelCreateManyArgs = { /** * The data used to create many CasbinModels. */ data: Enumerable } /** * CasbinModel update */ export type CasbinModelUpdateArgs = { /** * Select specific fields to fetch from the CasbinModel */ select?: CasbinModelSelect | null /** * The data needed to update a CasbinModel. */ data: XOR /** * Choose, which CasbinModel to update. */ where: CasbinModelWhereUniqueInput } /** * CasbinModel updateMany */ export type CasbinModelUpdateManyArgs = { /** * The data used to update CasbinModels. */ data: XOR /** * Filter which CasbinModels to update */ where?: CasbinModelWhereInput } /** * CasbinModel upsert */ export type CasbinModelUpsertArgs = { /** * Select specific fields to fetch from the CasbinModel */ select?: CasbinModelSelect | null /** * The filter to search for the CasbinModel to update in case it exists. */ where: CasbinModelWhereUniqueInput /** * In case the CasbinModel found by the `where` argument doesn't exist, create a new CasbinModel with this data. */ create: XOR /** * In case the CasbinModel was found with the provided `where` argument, update it with this data. */ update: XOR } /** * CasbinModel delete */ export type CasbinModelDeleteArgs = { /** * Select specific fields to fetch from the CasbinModel */ select?: CasbinModelSelect | null /** * Filter which CasbinModel to delete. */ where: CasbinModelWhereUniqueInput } /** * CasbinModel deleteMany */ export type CasbinModelDeleteManyArgs = { /** * Filter which CasbinModels to delete */ where?: CasbinModelWhereInput } /** * CasbinModel findRaw */ export type CasbinModelFindRawArgs = { /** * The query predicate filter. If unspecified, then all documents in the collection will match the predicate. ${@link https://docs.mongodb.com/manual/reference/operator/query MongoDB Docs}. */ filter?: InputJsonValue /** * Additional options to pass to the `find` command ${@link https://docs.mongodb.com/manual/reference/command/find/#command-fields MongoDB Docs}. */ options?: InputJsonValue } /** * CasbinModel aggregateRaw */ export type CasbinModelAggregateRawArgs = { /** * An array of aggregation stages to process and transform the document stream via the aggregation pipeline. ${@link https://docs.mongodb.com/manual/reference/operator/aggregation-pipeline MongoDB Docs}. */ pipeline?: InputJsonValue[] /** * Additional options to pass to the `aggregate` command ${@link https://docs.mongodb.com/manual/reference/command/aggregate/#command-fields MongoDB Docs}. */ options?: InputJsonValue } /** * CasbinModel without action */ export type CasbinModelArgs = { /** * Select specific fields to fetch from the CasbinModel */ select?: CasbinModelSelect | null } /** * Model CasbinPolicy */ export type AggregateCasbinPolicy = { _count: CasbinPolicyCountAggregateOutputType | null _min: CasbinPolicyMinAggregateOutputType | null _max: CasbinPolicyMaxAggregateOutputType | null } export type CasbinPolicyMinAggregateOutputType = { id: string | null bizRealm: string | null sec: string | null pType: string | null v0: string | null v1: string | null v2: string | null v3: string | null v4: string | null v5: string | null createdAt: Date | null updatedAt: Date | null } export type CasbinPolicyMaxAggregateOutputType = { id: string | null bizRealm: string | null sec: string | null pType: string | null v0: string | null v1: string | null v2: string | null v3: string | null v4: string | null v5: string | null createdAt: Date | null updatedAt: Date | null } export type CasbinPolicyCountAggregateOutputType = { id: number bizRealm: number sec: number pType: number v0: number v1: number v2: number v3: number v4: number v5: number createdAt: number updatedAt: number _all: number } export type CasbinPolicyMinAggregateInputType = { id?: true bizRealm?: true sec?: true pType?: true v0?: true v1?: true v2?: true v3?: true v4?: true v5?: true createdAt?: true updatedAt?: true } export type CasbinPolicyMaxAggregateInputType = { id?: true bizRealm?: true sec?: true pType?: true v0?: true v1?: true v2?: true v3?: true v4?: true v5?: true createdAt?: true updatedAt?: true } export type CasbinPolicyCountAggregateInputType = { id?: true bizRealm?: true sec?: true pType?: true v0?: true v1?: true v2?: true v3?: true v4?: true v5?: true createdAt?: true updatedAt?: true _all?: true } export type CasbinPolicyAggregateArgs = { /** * Filter which CasbinPolicy to aggregate. */ where?: CasbinPolicyWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of CasbinPolicies to fetch. */ orderBy?: Enumerable /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the start position */ cursor?: CasbinPolicyWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` CasbinPolicies from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` CasbinPolicies. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Count returned CasbinPolicies **/ _count?: true | CasbinPolicyCountAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the minimum value **/ _min?: CasbinPolicyMinAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the maximum value **/ _max?: CasbinPolicyMaxAggregateInputType } export type GetCasbinPolicyAggregateType = { [P in keyof T & keyof AggregateCasbinPolicy]: P extends '_count' | 'count' ? T[P] extends true ? number : GetScalarType : GetScalarType } export type CasbinPolicyGroupByArgs = { where?: CasbinPolicyWhereInput orderBy?: Enumerable by: CasbinPolicyScalarFieldEnum[] having?: CasbinPolicyScalarWhereWithAggregatesInput take?: number skip?: number _count?: CasbinPolicyCountAggregateInputType | true _min?: CasbinPolicyMinAggregateInputType _max?: CasbinPolicyMaxAggregateInputType } export type CasbinPolicyGroupByOutputType = { id: string bizRealm: string sec: string pType: string v0: string | null v1: string | null v2: string | null v3: string | null v4: string | null v5: string | null createdAt: Date | null updatedAt: Date | null _count: CasbinPolicyCountAggregateOutputType | null _min: CasbinPolicyMinAggregateOutputType | null _max: CasbinPolicyMaxAggregateOutputType | null } type GetCasbinPolicyGroupByPayload = Prisma.PrismaPromise< Array< PickArray & { [P in ((keyof T) & (keyof CasbinPolicyGroupByOutputType))]: P extends '_count' ? T[P] extends boolean ? number : GetScalarType : GetScalarType } > > export type CasbinPolicySelect = { id?: boolean bizRealm?: boolean sec?: boolean pType?: boolean v0?: boolean v1?: boolean v2?: boolean v3?: boolean v4?: boolean v5?: boolean createdAt?: boolean updatedAt?: boolean } export type CasbinPolicyGetPayload = S extends { select: any, include: any } ? 'Please either choose `select` or `include`' : S extends true ? CasbinPolicy : S extends undefined ? never : S extends { include: any } & (CasbinPolicyArgs | CasbinPolicyFindManyArgs) ? CasbinPolicy : S extends { select: any } & (CasbinPolicyArgs | CasbinPolicyFindManyArgs) ? { [P in TruthyKeys]: P extends keyof CasbinPolicy ? CasbinPolicy[P] : never } : CasbinPolicy type CasbinPolicyCountArgs = Omit & { select?: CasbinPolicyCountAggregateInputType | true } export interface CasbinPolicyDelegate { /** * Find zero or one CasbinPolicy that matches the filter. * @param {CasbinPolicyFindUniqueArgs} args - Arguments to find a CasbinPolicy * @example * // Get one CasbinPolicy * const casbinPolicy = await prisma.casbinPolicy.findUnique({ * where: { * // ... provide filter here * } * }) **/ findUnique( args: SelectSubset ): HasReject extends True ? Prisma__CasbinPolicyClient> : Prisma__CasbinPolicyClient | null, null> /** * Find one CasbinPolicy that matches the filter or throw an error with `error.code='P2025'` * if no matches were found. * @param {CasbinPolicyFindUniqueOrThrowArgs} args - Arguments to find a CasbinPolicy * @example * // Get one CasbinPolicy * const casbinPolicy = await prisma.casbinPolicy.findUniqueOrThrow({ * where: { * // ... provide filter here * } * }) **/ findUniqueOrThrow( args?: SelectSubset ): Prisma__CasbinPolicyClient> /** * Find the first CasbinPolicy that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CasbinPolicyFindFirstArgs} args - Arguments to find a CasbinPolicy * @example * // Get one CasbinPolicy * const casbinPolicy = await prisma.casbinPolicy.findFirst({ * where: { * // ... provide filter here * } * }) **/ findFirst( args?: SelectSubset ): HasReject extends True ? Prisma__CasbinPolicyClient> : Prisma__CasbinPolicyClient | null, null> /** * Find the first CasbinPolicy that matches the filter or * throw `NotFoundError` if no matches were found. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CasbinPolicyFindFirstOrThrowArgs} args - Arguments to find a CasbinPolicy * @example * // Get one CasbinPolicy * const casbinPolicy = await prisma.casbinPolicy.findFirstOrThrow({ * where: { * // ... provide filter here * } * }) **/ findFirstOrThrow( args?: SelectSubset ): Prisma__CasbinPolicyClient> /** * Find zero or more CasbinPolicies that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CasbinPolicyFindManyArgs=} args - Arguments to filter and select certain fields only. * @example * // Get all CasbinPolicies * const casbinPolicies = await prisma.casbinPolicy.findMany() * * // Get first 10 CasbinPolicies * const casbinPolicies = await prisma.casbinPolicy.findMany({ take: 10 }) * * // Only select the `id` * const casbinPolicyWithIdOnly = await prisma.casbinPolicy.findMany({ select: { id: true } }) * **/ findMany( args?: SelectSubset ): Prisma.PrismaPromise>> /** * Create a CasbinPolicy. * @param {CasbinPolicyCreateArgs} args - Arguments to create a CasbinPolicy. * @example * // Create one CasbinPolicy * const CasbinPolicy = await prisma.casbinPolicy.create({ * data: { * // ... data to create a CasbinPolicy * } * }) * **/ create( args: SelectSubset ): Prisma__CasbinPolicyClient> /** * Create many CasbinPolicies. * @param {CasbinPolicyCreateManyArgs} args - Arguments to create many CasbinPolicies. * @example * // Create many CasbinPolicies * const casbinPolicy = await prisma.casbinPolicy.createMany({ * data: { * // ... provide data here * } * }) * **/ createMany( args?: SelectSubset ): Prisma.PrismaPromise /** * Delete a CasbinPolicy. * @param {CasbinPolicyDeleteArgs} args - Arguments to delete one CasbinPolicy. * @example * // Delete one CasbinPolicy * const CasbinPolicy = await prisma.casbinPolicy.delete({ * where: { * // ... filter to delete one CasbinPolicy * } * }) * **/ delete( args: SelectSubset ): Prisma__CasbinPolicyClient> /** * Update one CasbinPolicy. * @param {CasbinPolicyUpdateArgs} args - Arguments to update one CasbinPolicy. * @example * // Update one CasbinPolicy * const casbinPolicy = await prisma.casbinPolicy.update({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * **/ update( args: SelectSubset ): Prisma__CasbinPolicyClient> /** * Delete zero or more CasbinPolicies. * @param {CasbinPolicyDeleteManyArgs} args - Arguments to filter CasbinPolicies to delete. * @example * // Delete a few CasbinPolicies * const { count } = await prisma.casbinPolicy.deleteMany({ * where: { * // ... provide filter here * } * }) * **/ deleteMany( args?: SelectSubset ): Prisma.PrismaPromise /** * Update zero or more CasbinPolicies. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CasbinPolicyUpdateManyArgs} args - Arguments to update one or more rows. * @example * // Update many CasbinPolicies * const casbinPolicy = await prisma.casbinPolicy.updateMany({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * **/ updateMany( args: SelectSubset ): Prisma.PrismaPromise /** * Create or update one CasbinPolicy. * @param {CasbinPolicyUpsertArgs} args - Arguments to update or create a CasbinPolicy. * @example * // Update or create a CasbinPolicy * const casbinPolicy = await prisma.casbinPolicy.upsert({ * create: { * // ... data to create a CasbinPolicy * }, * update: { * // ... in case it already exists, update * }, * where: { * // ... the filter for the CasbinPolicy we want to update * } * }) **/ upsert( args: SelectSubset ): Prisma__CasbinPolicyClient> /** * Find zero or more CasbinPolicies that matches the filter. * @param {CasbinPolicyFindRawArgs} args - Select which filters you would like to apply. * @example * const casbinPolicy = await prisma.casbinPolicy.findRaw({ * filter: { age: { $gt: 25 } } * }) **/ findRaw( args?: CasbinPolicyFindRawArgs ): Prisma.PrismaPromise /** * Perform aggregation operations on a CasbinPolicy. * @param {CasbinPolicyAggregateRawArgs} args - Select which aggregations you would like to apply. * @example * const casbinPolicy = await prisma.casbinPolicy.aggregateRaw({ * pipeline: [ * { $match: { status: "registered" } }, * { $group: { _id: "$country", total: { $sum: 1 } } } * ] * }) **/ aggregateRaw( args?: CasbinPolicyAggregateRawArgs ): Prisma.PrismaPromise /** * Count the number of CasbinPolicies. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CasbinPolicyCountArgs} args - Arguments to filter CasbinPolicies to count. * @example * // Count the number of CasbinPolicies * const count = await prisma.casbinPolicy.count({ * where: { * // ... the filter for the CasbinPolicies we want to count * } * }) **/ count( args?: Subset, ): Prisma.PrismaPromise< T extends _Record<'select', any> ? T['select'] extends true ? number : GetScalarType : number > /** * Allows you to perform aggregations operations on a CasbinPolicy. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CasbinPolicyAggregateArgs} args - Select which aggregations you would like to apply and on what fields. * @example * // Ordered by age ascending * // Where email contains prisma.io * // Limited to the 10 users * const aggregations = await prisma.user.aggregate({ * _avg: { * age: true, * }, * where: { * email: { * contains: "prisma.io", * }, * }, * orderBy: { * age: "asc", * }, * take: 10, * }) **/ aggregate(args: Subset): Prisma.PrismaPromise> /** * Group by CasbinPolicy. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CasbinPolicyGroupByArgs} args - Group by arguments. * @example * // Group by city, order by createdAt, get count * const result = await prisma.user.groupBy({ * by: ['city', 'createdAt'], * orderBy: { * createdAt: true * }, * _count: { * _all: true * }, * }) * **/ groupBy< T extends CasbinPolicyGroupByArgs, HasSelectOrTake extends Or< Extends<'skip', Keys>, Extends<'take', Keys> >, OrderByArg extends True extends HasSelectOrTake ? { orderBy: CasbinPolicyGroupByArgs['orderBy'] } : { orderBy?: CasbinPolicyGroupByArgs['orderBy'] }, OrderFields extends ExcludeUnderscoreKeys>>, ByFields extends TupleToUnion, ByValid extends Has, HavingFields extends GetHavingFields, HavingValid extends Has, ByEmpty extends T['by'] extends never[] ? True : False, InputErrors extends ByEmpty extends True ? `Error: "by" must not be empty.` : HavingValid extends False ? { [P in HavingFields]: P extends ByFields ? never : P extends string ? `Error: Field "${P}" used in "having" needs to be provided in "by".` : [ Error, 'Field ', P, ` in "having" needs to be provided in "by"`, ] }[HavingFields] : 'take' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "take", you also need to provide "orderBy"' : 'skip' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "skip", you also need to provide "orderBy"' : ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] >(args: SubsetIntersection & InputErrors): {} extends InputErrors ? GetCasbinPolicyGroupByPayload : Prisma.PrismaPromise } /** * The delegate class that acts as a "Promise-like" for CasbinPolicy. * Why is this prefixed with `Prisma__`? * Because we want to prevent naming conflicts as mentioned in * https://github.com/prisma/prisma-client-js/issues/707 */ export class Prisma__CasbinPolicyClient implements Prisma.PrismaPromise { private readonly _dmmf; private readonly _queryType; private readonly _rootField; private readonly _clientMethod; private readonly _args; private readonly _dataPath; private readonly _errorFormat; private readonly _measurePerformance?; private _isList; private _callsite; private _requestPromise?; readonly [Symbol.toStringTag]: 'PrismaPromise'; constructor(_dmmf: runtime.DMMFClass, _queryType: 'query' | 'mutation', _rootField: string, _clientMethod: string, _args: any, _dataPath: string[], _errorFormat: ErrorFormat, _measurePerformance?: boolean | undefined, _isList?: boolean); private get _document(); /** * Attaches callbacks for the resolution and/or rejection of the Promise. * @param onfulfilled The callback to execute when the Promise is resolved. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of which ever callback is executed. */ then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): Promise; /** * Attaches a callback for only the rejection of the Promise. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of the callback. */ catch(onrejected?: ((reason: any) => TResult | PromiseLike) | undefined | null): Promise; /** * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The * resolved value cannot be modified from the callback. * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected). * @returns A Promise for the completion of the callback. */ finally(onfinally?: (() => void) | undefined | null): Promise; } // Custom InputTypes /** * CasbinPolicy base type for findUnique actions */ export type CasbinPolicyFindUniqueArgsBase = { /** * Select specific fields to fetch from the CasbinPolicy */ select?: CasbinPolicySelect | null /** * Filter, which CasbinPolicy to fetch. */ where: CasbinPolicyWhereUniqueInput } /** * CasbinPolicy findUnique */ export interface CasbinPolicyFindUniqueArgs extends CasbinPolicyFindUniqueArgsBase { /** * Throw an Error if query returns no results * @deprecated since 4.0.0: use `findUniqueOrThrow` method instead */ rejectOnNotFound?: RejectOnNotFound } /** * CasbinPolicy findUniqueOrThrow */ export type CasbinPolicyFindUniqueOrThrowArgs = { /** * Select specific fields to fetch from the CasbinPolicy */ select?: CasbinPolicySelect | null /** * Filter, which CasbinPolicy to fetch. */ where: CasbinPolicyWhereUniqueInput } /** * CasbinPolicy base type for findFirst actions */ export type CasbinPolicyFindFirstArgsBase = { /** * Select specific fields to fetch from the CasbinPolicy */ select?: CasbinPolicySelect | null /** * Filter, which CasbinPolicy to fetch. */ where?: CasbinPolicyWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of CasbinPolicies to fetch. */ orderBy?: Enumerable /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for CasbinPolicies. */ cursor?: CasbinPolicyWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` CasbinPolicies from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` CasbinPolicies. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of CasbinPolicies. */ distinct?: Enumerable } /** * CasbinPolicy findFirst */ export interface CasbinPolicyFindFirstArgs extends CasbinPolicyFindFirstArgsBase { /** * Throw an Error if query returns no results * @deprecated since 4.0.0: use `findFirstOrThrow` method instead */ rejectOnNotFound?: RejectOnNotFound } /** * CasbinPolicy findFirstOrThrow */ export type CasbinPolicyFindFirstOrThrowArgs = { /** * Select specific fields to fetch from the CasbinPolicy */ select?: CasbinPolicySelect | null /** * Filter, which CasbinPolicy to fetch. */ where?: CasbinPolicyWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of CasbinPolicies to fetch. */ orderBy?: Enumerable /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for CasbinPolicies. */ cursor?: CasbinPolicyWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` CasbinPolicies from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` CasbinPolicies. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of CasbinPolicies. */ distinct?: Enumerable } /** * CasbinPolicy findMany */ export type CasbinPolicyFindManyArgs = { /** * Select specific fields to fetch from the CasbinPolicy */ select?: CasbinPolicySelect | null /** * Filter, which CasbinPolicies to fetch. */ where?: CasbinPolicyWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of CasbinPolicies to fetch. */ orderBy?: Enumerable /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for listing CasbinPolicies. */ cursor?: CasbinPolicyWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` CasbinPolicies from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` CasbinPolicies. */ skip?: number distinct?: Enumerable } /** * CasbinPolicy create */ export type CasbinPolicyCreateArgs = { /** * Select specific fields to fetch from the CasbinPolicy */ select?: CasbinPolicySelect | null /** * The data needed to create a CasbinPolicy. */ data: XOR } /** * CasbinPolicy createMany */ export type CasbinPolicyCreateManyArgs = { /** * The data used to create many CasbinPolicies. */ data: Enumerable } /** * CasbinPolicy update */ export type CasbinPolicyUpdateArgs = { /** * Select specific fields to fetch from the CasbinPolicy */ select?: CasbinPolicySelect | null /** * The data needed to update a CasbinPolicy. */ data: XOR /** * Choose, which CasbinPolicy to update. */ where: CasbinPolicyWhereUniqueInput } /** * CasbinPolicy updateMany */ export type CasbinPolicyUpdateManyArgs = { /** * The data used to update CasbinPolicies. */ data: XOR /** * Filter which CasbinPolicies to update */ where?: CasbinPolicyWhereInput } /** * CasbinPolicy upsert */ export type CasbinPolicyUpsertArgs = { /** * Select specific fields to fetch from the CasbinPolicy */ select?: CasbinPolicySelect | null /** * The filter to search for the CasbinPolicy to update in case it exists. */ where: CasbinPolicyWhereUniqueInput /** * In case the CasbinPolicy found by the `where` argument doesn't exist, create a new CasbinPolicy with this data. */ create: XOR /** * In case the CasbinPolicy was found with the provided `where` argument, update it with this data. */ update: XOR } /** * CasbinPolicy delete */ export type CasbinPolicyDeleteArgs = { /** * Select specific fields to fetch from the CasbinPolicy */ select?: CasbinPolicySelect | null /** * Filter which CasbinPolicy to delete. */ where: CasbinPolicyWhereUniqueInput } /** * CasbinPolicy deleteMany */ export type CasbinPolicyDeleteManyArgs = { /** * Filter which CasbinPolicies to delete */ where?: CasbinPolicyWhereInput } /** * CasbinPolicy findRaw */ export type CasbinPolicyFindRawArgs = { /** * The query predicate filter. If unspecified, then all documents in the collection will match the predicate. ${@link https://docs.mongodb.com/manual/reference/operator/query MongoDB Docs}. */ filter?: InputJsonValue /** * Additional options to pass to the `find` command ${@link https://docs.mongodb.com/manual/reference/command/find/#command-fields MongoDB Docs}. */ options?: InputJsonValue } /** * CasbinPolicy aggregateRaw */ export type CasbinPolicyAggregateRawArgs = { /** * An array of aggregation stages to process and transform the document stream via the aggregation pipeline. ${@link https://docs.mongodb.com/manual/reference/operator/aggregation-pipeline MongoDB Docs}. */ pipeline?: InputJsonValue[] /** * Additional options to pass to the `aggregate` command ${@link https://docs.mongodb.com/manual/reference/command/aggregate/#command-fields MongoDB Docs}. */ options?: InputJsonValue } /** * CasbinPolicy without action */ export type CasbinPolicyArgs = { /** * Select specific fields to fetch from the CasbinPolicy */ select?: CasbinPolicySelect | null } /** * Enums */ // Based on // https://github.com/microsoft/TypeScript/issues/3192#issuecomment-261720275 export const AccountScalarFieldEnum: { id: 'id', name: 'name', userId: 'userId', roles: 'roles', email: 'email', salt: 'salt', password: 'password', createdAt: 'createdAt', updatedAt: 'updatedAt', lastSignedInAt: 'lastSignedInAt', inactive: 'inactive', inactiveAt: 'inactiveAt' }; export type AccountScalarFieldEnum = (typeof AccountScalarFieldEnum)[keyof typeof AccountScalarFieldEnum] export const CasbinModelScalarFieldEnum: { id: 'id', bizRealm: 'bizRealm', sec: 'sec', pType: 'pType', v0: 'v0', v1: 'v1', v2: 'v2', v3: 'v3', v4: 'v4', v5: 'v5', createdAt: 'createdAt', updatedAt: 'updatedAt' }; export type CasbinModelScalarFieldEnum = (typeof CasbinModelScalarFieldEnum)[keyof typeof CasbinModelScalarFieldEnum] export const CasbinPolicyScalarFieldEnum: { id: 'id', bizRealm: 'bizRealm', sec: 'sec', pType: 'pType', v0: 'v0', v1: 'v1', v2: 'v2', v3: 'v3', v4: 'v4', v5: 'v5', createdAt: 'createdAt', updatedAt: 'updatedAt' }; export type CasbinPolicyScalarFieldEnum = (typeof CasbinPolicyScalarFieldEnum)[keyof typeof CasbinPolicyScalarFieldEnum] export const QueryMode: { default: 'default', insensitive: 'insensitive' }; export type QueryMode = (typeof QueryMode)[keyof typeof QueryMode] export const RoleScalarFieldEnum: { id: 'id', name: 'name', roleId: 'roleId', description: 'description', createdAt: 'createdAt', updatedAt: 'updatedAt', inactive: 'inactive', inactiveAt: 'inactiveAt' }; export type RoleScalarFieldEnum = (typeof RoleScalarFieldEnum)[keyof typeof RoleScalarFieldEnum] export const SortOrder: { asc: 'asc', desc: 'desc' }; export type SortOrder = (typeof SortOrder)[keyof typeof SortOrder] /** * Deep Input Types */ export type AccountWhereInput = { AND?: Enumerable OR?: Enumerable NOT?: Enumerable id?: StringFilter | string name?: StringFilter | string userId?: StringFilter | string roles?: StringNullableListFilter email?: StringFilter | string salt?: StringFilter | string password?: StringFilter | string createdAt?: DateTimeNullableFilter | Date | string | null updatedAt?: DateTimeNullableFilter | Date | string | null lastSignedInAt?: DateTimeNullableFilter | Date | string | null inactive?: BoolFilter | boolean inactiveAt?: DateTimeNullableFilter | Date | string | null } export type AccountOrderByWithRelationInput = { id?: SortOrder name?: SortOrder userId?: SortOrder roles?: SortOrder email?: SortOrder salt?: SortOrder password?: SortOrder createdAt?: SortOrder updatedAt?: SortOrder lastSignedInAt?: SortOrder inactive?: SortOrder inactiveAt?: SortOrder } export type AccountWhereUniqueInput = { id?: string userId?: string email?: string } export type AccountOrderByWithAggregationInput = { id?: SortOrder name?: SortOrder userId?: SortOrder roles?: SortOrder email?: SortOrder salt?: SortOrder password?: SortOrder createdAt?: SortOrder updatedAt?: SortOrder lastSignedInAt?: SortOrder inactive?: SortOrder inactiveAt?: SortOrder _count?: AccountCountOrderByAggregateInput _max?: AccountMaxOrderByAggregateInput _min?: AccountMinOrderByAggregateInput } export type AccountScalarWhereWithAggregatesInput = { AND?: Enumerable OR?: Enumerable NOT?: Enumerable id?: StringWithAggregatesFilter | string name?: StringWithAggregatesFilter | string userId?: StringWithAggregatesFilter | string roles?: StringNullableListFilter email?: StringWithAggregatesFilter | string salt?: StringWithAggregatesFilter | string password?: StringWithAggregatesFilter | string createdAt?: DateTimeNullableWithAggregatesFilter | Date | string | null updatedAt?: DateTimeNullableWithAggregatesFilter | Date | string | null lastSignedInAt?: DateTimeNullableWithAggregatesFilter | Date | string | null inactive?: BoolWithAggregatesFilter | boolean inactiveAt?: DateTimeNullableWithAggregatesFilter | Date | string | null } export type RoleWhereInput = { AND?: Enumerable OR?: Enumerable NOT?: Enumerable id?: StringFilter | string name?: StringFilter | string roleId?: StringFilter | string description?: StringFilter | string createdAt?: DateTimeNullableFilter | Date | string | null updatedAt?: DateTimeNullableFilter | Date | string | null inactive?: BoolFilter | boolean inactiveAt?: DateTimeNullableFilter | Date | string | null } export type RoleOrderByWithRelationInput = { id?: SortOrder name?: SortOrder roleId?: SortOrder description?: SortOrder createdAt?: SortOrder updatedAt?: SortOrder inactive?: SortOrder inactiveAt?: SortOrder } export type RoleWhereUniqueInput = { id?: string name?: string roleId?: string } export type RoleOrderByWithAggregationInput = { id?: SortOrder name?: SortOrder roleId?: SortOrder description?: SortOrder createdAt?: SortOrder updatedAt?: SortOrder inactive?: SortOrder inactiveAt?: SortOrder _count?: RoleCountOrderByAggregateInput _max?: RoleMaxOrderByAggregateInput _min?: RoleMinOrderByAggregateInput } export type RoleScalarWhereWithAggregatesInput = { AND?: Enumerable OR?: Enumerable NOT?: Enumerable id?: StringWithAggregatesFilter | string name?: StringWithAggregatesFilter | string roleId?: StringWithAggregatesFilter | string description?: StringWithAggregatesFilter | string createdAt?: DateTimeNullableWithAggregatesFilter | Date | string | null updatedAt?: DateTimeNullableWithAggregatesFilter | Date | string | null inactive?: BoolWithAggregatesFilter | boolean inactiveAt?: DateTimeNullableWithAggregatesFilter | Date | string | null } export type CasbinModelWhereInput = { AND?: Enumerable OR?: Enumerable NOT?: Enumerable id?: StringFilter | string bizRealm?: StringFilter | string sec?: StringFilter | string pType?: StringFilter | string v0?: StringNullableFilter | string | null v1?: StringNullableFilter | string | null v2?: StringNullableFilter | string | null v3?: StringNullableFilter | string | null v4?: StringNullableFilter | string | null v5?: StringNullableFilter | string | null createdAt?: DateTimeNullableFilter | Date | string | null updatedAt?: DateTimeNullableFilter | Date | string | null } export type CasbinModelOrderByWithRelationInput = { id?: SortOrder bizRealm?: SortOrder sec?: SortOrder pType?: SortOrder v0?: SortOrder v1?: SortOrder v2?: SortOrder v3?: SortOrder v4?: SortOrder v5?: SortOrder createdAt?: SortOrder updatedAt?: SortOrder } export type CasbinModelWhereUniqueInput = { id?: string } export type CasbinModelOrderByWithAggregationInput = { id?: SortOrder bizRealm?: SortOrder sec?: SortOrder pType?: SortOrder v0?: SortOrder v1?: SortOrder v2?: SortOrder v3?: SortOrder v4?: SortOrder v5?: SortOrder createdAt?: SortOrder updatedAt?: SortOrder _count?: CasbinModelCountOrderByAggregateInput _max?: CasbinModelMaxOrderByAggregateInput _min?: CasbinModelMinOrderByAggregateInput } export type CasbinModelScalarWhereWithAggregatesInput = { AND?: Enumerable OR?: Enumerable NOT?: Enumerable id?: StringWithAggregatesFilter | string bizRealm?: StringWithAggregatesFilter | string sec?: StringWithAggregatesFilter | string pType?: StringWithAggregatesFilter | string v0?: StringNullableWithAggregatesFilter | string | null v1?: StringNullableWithAggregatesFilter | string | null v2?: StringNullableWithAggregatesFilter | string | null v3?: StringNullableWithAggregatesFilter | string | null v4?: StringNullableWithAggregatesFilter | string | null v5?: StringNullableWithAggregatesFilter | string | null createdAt?: DateTimeNullableWithAggregatesFilter | Date | string | null updatedAt?: DateTimeNullableWithAggregatesFilter | Date | string | null } export type CasbinPolicyWhereInput = { AND?: Enumerable OR?: Enumerable NOT?: Enumerable id?: StringFilter | string bizRealm?: StringFilter | string sec?: StringFilter | string pType?: StringFilter | string v0?: StringNullableFilter | string | null v1?: StringNullableFilter | string | null v2?: StringNullableFilter | string | null v3?: StringNullableFilter | string | null v4?: StringNullableFilter | string | null v5?: StringNullableFilter | string | null createdAt?: DateTimeNullableFilter | Date | string | null updatedAt?: DateTimeNullableFilter | Date | string | null } export type CasbinPolicyOrderByWithRelationInput = { id?: SortOrder bizRealm?: SortOrder sec?: SortOrder pType?: SortOrder v0?: SortOrder v1?: SortOrder v2?: SortOrder v3?: SortOrder v4?: SortOrder v5?: SortOrder createdAt?: SortOrder updatedAt?: SortOrder } export type CasbinPolicyWhereUniqueInput = { id?: string } export type CasbinPolicyOrderByWithAggregationInput = { id?: SortOrder bizRealm?: SortOrder sec?: SortOrder pType?: SortOrder v0?: SortOrder v1?: SortOrder v2?: SortOrder v3?: SortOrder v4?: SortOrder v5?: SortOrder createdAt?: SortOrder updatedAt?: SortOrder _count?: CasbinPolicyCountOrderByAggregateInput _max?: CasbinPolicyMaxOrderByAggregateInput _min?: CasbinPolicyMinOrderByAggregateInput } export type CasbinPolicyScalarWhereWithAggregatesInput = { AND?: Enumerable OR?: Enumerable NOT?: Enumerable id?: StringWithAggregatesFilter | string bizRealm?: StringWithAggregatesFilter | string sec?: StringWithAggregatesFilter | string pType?: StringWithAggregatesFilter | string v0?: StringNullableWithAggregatesFilter | string | null v1?: StringNullableWithAggregatesFilter | string | null v2?: StringNullableWithAggregatesFilter | string | null v3?: StringNullableWithAggregatesFilter | string | null v4?: StringNullableWithAggregatesFilter | string | null v5?: StringNullableWithAggregatesFilter | string | null createdAt?: DateTimeNullableWithAggregatesFilter | Date | string | null updatedAt?: DateTimeNullableWithAggregatesFilter | Date | string | null } export type AccountCreateInput = { id?: string name: string userId: string roles?: AccountCreaterolesInput | Enumerable email: string salt: string password: string createdAt?: Date | string | null updatedAt?: Date | string | null lastSignedInAt?: Date | string | null inactive?: boolean inactiveAt?: Date | string | null } export type AccountUncheckedCreateInput = { id?: string name: string userId: string roles?: AccountCreaterolesInput | Enumerable email: string salt: string password: string createdAt?: Date | string | null updatedAt?: Date | string | null lastSignedInAt?: Date | string | null inactive?: boolean inactiveAt?: Date | string | null } export type AccountUpdateInput = { name?: StringFieldUpdateOperationsInput | string userId?: StringFieldUpdateOperationsInput | string roles?: AccountUpdaterolesInput | Enumerable email?: StringFieldUpdateOperationsInput | string salt?: StringFieldUpdateOperationsInput | string password?: StringFieldUpdateOperationsInput | string createdAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null updatedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null lastSignedInAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null inactive?: BoolFieldUpdateOperationsInput | boolean inactiveAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null } export type AccountUncheckedUpdateInput = { name?: StringFieldUpdateOperationsInput | string userId?: StringFieldUpdateOperationsInput | string roles?: AccountUpdaterolesInput | Enumerable email?: StringFieldUpdateOperationsInput | string salt?: StringFieldUpdateOperationsInput | string password?: StringFieldUpdateOperationsInput | string createdAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null updatedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null lastSignedInAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null inactive?: BoolFieldUpdateOperationsInput | boolean inactiveAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null } export type AccountCreateManyInput = { id?: string name: string userId: string roles?: AccountCreaterolesInput | Enumerable email: string salt: string password: string createdAt?: Date | string | null updatedAt?: Date | string | null lastSignedInAt?: Date | string | null inactive?: boolean inactiveAt?: Date | string | null } export type AccountUpdateManyMutationInput = { name?: StringFieldUpdateOperationsInput | string userId?: StringFieldUpdateOperationsInput | string roles?: AccountUpdaterolesInput | Enumerable email?: StringFieldUpdateOperationsInput | string salt?: StringFieldUpdateOperationsInput | string password?: StringFieldUpdateOperationsInput | string createdAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null updatedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null lastSignedInAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null inactive?: BoolFieldUpdateOperationsInput | boolean inactiveAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null } export type AccountUncheckedUpdateManyInput = { name?: StringFieldUpdateOperationsInput | string userId?: StringFieldUpdateOperationsInput | string roles?: AccountUpdaterolesInput | Enumerable email?: StringFieldUpdateOperationsInput | string salt?: StringFieldUpdateOperationsInput | string password?: StringFieldUpdateOperationsInput | string createdAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null updatedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null lastSignedInAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null inactive?: BoolFieldUpdateOperationsInput | boolean inactiveAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null } export type RoleCreateInput = { id?: string name: string roleId: string description: string createdAt?: Date | string | null updatedAt?: Date | string | null inactive?: boolean inactiveAt?: Date | string | null } export type RoleUncheckedCreateInput = { id?: string name: string roleId: string description: string createdAt?: Date | string | null updatedAt?: Date | string | null inactive?: boolean inactiveAt?: Date | string | null } export type RoleUpdateInput = { name?: StringFieldUpdateOperationsInput | string roleId?: StringFieldUpdateOperationsInput | string description?: StringFieldUpdateOperationsInput | string createdAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null updatedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null inactive?: BoolFieldUpdateOperationsInput | boolean inactiveAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null } export type RoleUncheckedUpdateInput = { name?: StringFieldUpdateOperationsInput | string roleId?: StringFieldUpdateOperationsInput | string description?: StringFieldUpdateOperationsInput | string createdAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null updatedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null inactive?: BoolFieldUpdateOperationsInput | boolean inactiveAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null } export type RoleCreateManyInput = { id?: string name: string roleId: string description: string createdAt?: Date | string | null updatedAt?: Date | string | null inactive?: boolean inactiveAt?: Date | string | null } export type RoleUpdateManyMutationInput = { name?: StringFieldUpdateOperationsInput | string roleId?: StringFieldUpdateOperationsInput | string description?: StringFieldUpdateOperationsInput | string createdAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null updatedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null inactive?: BoolFieldUpdateOperationsInput | boolean inactiveAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null } export type RoleUncheckedUpdateManyInput = { name?: StringFieldUpdateOperationsInput | string roleId?: StringFieldUpdateOperationsInput | string description?: StringFieldUpdateOperationsInput | string createdAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null updatedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null inactive?: BoolFieldUpdateOperationsInput | boolean inactiveAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null } export type CasbinModelCreateInput = { id?: string bizRealm: string sec: string pType: string v0?: string | null v1?: string | null v2?: string | null v3?: string | null v4?: string | null v5?: string | null createdAt?: Date | string | null updatedAt?: Date | string | null } export type CasbinModelUncheckedCreateInput = { id?: string bizRealm: string sec: string pType: string v0?: string | null v1?: string | null v2?: string | null v3?: string | null v4?: string | null v5?: string | null createdAt?: Date | string | null updatedAt?: Date | string | null } export type CasbinModelUpdateInput = { bizRealm?: StringFieldUpdateOperationsInput | string sec?: StringFieldUpdateOperationsInput | string pType?: StringFieldUpdateOperationsInput | string v0?: NullableStringFieldUpdateOperationsInput | string | null v1?: NullableStringFieldUpdateOperationsInput | string | null v2?: NullableStringFieldUpdateOperationsInput | string | null v3?: NullableStringFieldUpdateOperationsInput | string | null v4?: NullableStringFieldUpdateOperationsInput | string | null v5?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null updatedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null } export type CasbinModelUncheckedUpdateInput = { bizRealm?: StringFieldUpdateOperationsInput | string sec?: StringFieldUpdateOperationsInput | string pType?: StringFieldUpdateOperationsInput | string v0?: NullableStringFieldUpdateOperationsInput | string | null v1?: NullableStringFieldUpdateOperationsInput | string | null v2?: NullableStringFieldUpdateOperationsInput | string | null v3?: NullableStringFieldUpdateOperationsInput | string | null v4?: NullableStringFieldUpdateOperationsInput | string | null v5?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null updatedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null } export type CasbinModelCreateManyInput = { id?: string bizRealm: string sec: string pType: string v0?: string | null v1?: string | null v2?: string | null v3?: string | null v4?: string | null v5?: string | null createdAt?: Date | string | null updatedAt?: Date | string | null } export type CasbinModelUpdateManyMutationInput = { bizRealm?: StringFieldUpdateOperationsInput | string sec?: StringFieldUpdateOperationsInput | string pType?: StringFieldUpdateOperationsInput | string v0?: NullableStringFieldUpdateOperationsInput | string | null v1?: NullableStringFieldUpdateOperationsInput | string | null v2?: NullableStringFieldUpdateOperationsInput | string | null v3?: NullableStringFieldUpdateOperationsInput | string | null v4?: NullableStringFieldUpdateOperationsInput | string | null v5?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null updatedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null } export type CasbinModelUncheckedUpdateManyInput = { bizRealm?: StringFieldUpdateOperationsInput | string sec?: StringFieldUpdateOperationsInput | string pType?: StringFieldUpdateOperationsInput | string v0?: NullableStringFieldUpdateOperationsInput | string | null v1?: NullableStringFieldUpdateOperationsInput | string | null v2?: NullableStringFieldUpdateOperationsInput | string | null v3?: NullableStringFieldUpdateOperationsInput | string | null v4?: NullableStringFieldUpdateOperationsInput | string | null v5?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null updatedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null } export type CasbinPolicyCreateInput = { id?: string bizRealm: string sec: string pType: string v0?: string | null v1?: string | null v2?: string | null v3?: string | null v4?: string | null v5?: string | null createdAt?: Date | string | null updatedAt?: Date | string | null } export type CasbinPolicyUncheckedCreateInput = { id?: string bizRealm: string sec: string pType: string v0?: string | null v1?: string | null v2?: string | null v3?: string | null v4?: string | null v5?: string | null createdAt?: Date | string | null updatedAt?: Date | string | null } export type CasbinPolicyUpdateInput = { bizRealm?: StringFieldUpdateOperationsInput | string sec?: StringFieldUpdateOperationsInput | string pType?: StringFieldUpdateOperationsInput | string v0?: NullableStringFieldUpdateOperationsInput | string | null v1?: NullableStringFieldUpdateOperationsInput | string | null v2?: NullableStringFieldUpdateOperationsInput | string | null v3?: NullableStringFieldUpdateOperationsInput | string | null v4?: NullableStringFieldUpdateOperationsInput | string | null v5?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null updatedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null } export type CasbinPolicyUncheckedUpdateInput = { bizRealm?: StringFieldUpdateOperationsInput | string sec?: StringFieldUpdateOperationsInput | string pType?: StringFieldUpdateOperationsInput | string v0?: NullableStringFieldUpdateOperationsInput | string | null v1?: NullableStringFieldUpdateOperationsInput | string | null v2?: NullableStringFieldUpdateOperationsInput | string | null v3?: NullableStringFieldUpdateOperationsInput | string | null v4?: NullableStringFieldUpdateOperationsInput | string | null v5?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null updatedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null } export type CasbinPolicyCreateManyInput = { id?: string bizRealm: string sec: string pType: string v0?: string | null v1?: string | null v2?: string | null v3?: string | null v4?: string | null v5?: string | null createdAt?: Date | string | null updatedAt?: Date | string | null } export type CasbinPolicyUpdateManyMutationInput = { bizRealm?: StringFieldUpdateOperationsInput | string sec?: StringFieldUpdateOperationsInput | string pType?: StringFieldUpdateOperationsInput | string v0?: NullableStringFieldUpdateOperationsInput | string | null v1?: NullableStringFieldUpdateOperationsInput | string | null v2?: NullableStringFieldUpdateOperationsInput | string | null v3?: NullableStringFieldUpdateOperationsInput | string | null v4?: NullableStringFieldUpdateOperationsInput | string | null v5?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null updatedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null } export type CasbinPolicyUncheckedUpdateManyInput = { bizRealm?: StringFieldUpdateOperationsInput | string sec?: StringFieldUpdateOperationsInput | string pType?: StringFieldUpdateOperationsInput | string v0?: NullableStringFieldUpdateOperationsInput | string | null v1?: NullableStringFieldUpdateOperationsInput | string | null v2?: NullableStringFieldUpdateOperationsInput | string | null v3?: NullableStringFieldUpdateOperationsInput | string | null v4?: NullableStringFieldUpdateOperationsInput | string | null v5?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null updatedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null } export type StringFilter = { equals?: string in?: Enumerable | string notIn?: Enumerable | string lt?: string lte?: string gt?: string gte?: string contains?: string startsWith?: string endsWith?: string mode?: QueryMode not?: NestedStringFilter | string } export type StringNullableListFilter = { equals?: Enumerable | null has?: string | null hasEvery?: Enumerable hasSome?: Enumerable isEmpty?: boolean } export type DateTimeNullableFilter = { equals?: Date | string | null in?: Enumerable | Enumerable | Date | string | null notIn?: Enumerable | Enumerable | Date | string | null lt?: Date | string lte?: Date | string gt?: Date | string gte?: Date | string not?: NestedDateTimeNullableFilter | Date | string | null isSet?: boolean } export type BoolFilter = { equals?: boolean not?: NestedBoolFilter | boolean } export type AccountCountOrderByAggregateInput = { id?: SortOrder name?: SortOrder userId?: SortOrder roles?: SortOrder email?: SortOrder salt?: SortOrder password?: SortOrder createdAt?: SortOrder updatedAt?: SortOrder lastSignedInAt?: SortOrder inactive?: SortOrder inactiveAt?: SortOrder } export type AccountMaxOrderByAggregateInput = { id?: SortOrder name?: SortOrder userId?: SortOrder email?: SortOrder salt?: SortOrder password?: SortOrder createdAt?: SortOrder updatedAt?: SortOrder lastSignedInAt?: SortOrder inactive?: SortOrder inactiveAt?: SortOrder } export type AccountMinOrderByAggregateInput = { id?: SortOrder name?: SortOrder userId?: SortOrder email?: SortOrder salt?: SortOrder password?: SortOrder createdAt?: SortOrder updatedAt?: SortOrder lastSignedInAt?: SortOrder inactive?: SortOrder inactiveAt?: SortOrder } export type StringWithAggregatesFilter = { equals?: string in?: Enumerable | string notIn?: Enumerable | string lt?: string lte?: string gt?: string gte?: string contains?: string startsWith?: string endsWith?: string mode?: QueryMode not?: NestedStringWithAggregatesFilter | string _count?: NestedIntFilter _min?: NestedStringFilter _max?: NestedStringFilter } export type DateTimeNullableWithAggregatesFilter = { equals?: Date | string | null in?: Enumerable | Enumerable | Date | string | null notIn?: Enumerable | Enumerable | Date | string | null lt?: Date | string lte?: Date | string gt?: Date | string gte?: Date | string not?: NestedDateTimeNullableWithAggregatesFilter | Date | string | null _count?: NestedIntNullableFilter _min?: NestedDateTimeNullableFilter _max?: NestedDateTimeNullableFilter isSet?: boolean } export type BoolWithAggregatesFilter = { equals?: boolean not?: NestedBoolWithAggregatesFilter | boolean _count?: NestedIntFilter _min?: NestedBoolFilter _max?: NestedBoolFilter } export type RoleCountOrderByAggregateInput = { id?: SortOrder name?: SortOrder roleId?: SortOrder description?: SortOrder createdAt?: SortOrder updatedAt?: SortOrder inactive?: SortOrder inactiveAt?: SortOrder } export type RoleMaxOrderByAggregateInput = { id?: SortOrder name?: SortOrder roleId?: SortOrder description?: SortOrder createdAt?: SortOrder updatedAt?: SortOrder inactive?: SortOrder inactiveAt?: SortOrder } export type RoleMinOrderByAggregateInput = { id?: SortOrder name?: SortOrder roleId?: SortOrder description?: SortOrder createdAt?: SortOrder updatedAt?: SortOrder inactive?: SortOrder inactiveAt?: SortOrder } export type StringNullableFilter = { equals?: string | null in?: Enumerable | string | null notIn?: Enumerable | string | null lt?: string lte?: string gt?: string gte?: string contains?: string startsWith?: string endsWith?: string mode?: QueryMode not?: NestedStringNullableFilter | string | null isSet?: boolean } export type CasbinModelCountOrderByAggregateInput = { id?: SortOrder bizRealm?: SortOrder sec?: SortOrder pType?: SortOrder v0?: SortOrder v1?: SortOrder v2?: SortOrder v3?: SortOrder v4?: SortOrder v5?: SortOrder createdAt?: SortOrder updatedAt?: SortOrder } export type CasbinModelMaxOrderByAggregateInput = { id?: SortOrder bizRealm?: SortOrder sec?: SortOrder pType?: SortOrder v0?: SortOrder v1?: SortOrder v2?: SortOrder v3?: SortOrder v4?: SortOrder v5?: SortOrder createdAt?: SortOrder updatedAt?: SortOrder } export type CasbinModelMinOrderByAggregateInput = { id?: SortOrder bizRealm?: SortOrder sec?: SortOrder pType?: SortOrder v0?: SortOrder v1?: SortOrder v2?: SortOrder v3?: SortOrder v4?: SortOrder v5?: SortOrder createdAt?: SortOrder updatedAt?: SortOrder } export type StringNullableWithAggregatesFilter = { equals?: string | null in?: Enumerable | string | null notIn?: Enumerable | string | null lt?: string lte?: string gt?: string gte?: string contains?: string startsWith?: string endsWith?: string mode?: QueryMode not?: NestedStringNullableWithAggregatesFilter | string | null _count?: NestedIntNullableFilter _min?: NestedStringNullableFilter _max?: NestedStringNullableFilter isSet?: boolean } export type CasbinPolicyCountOrderByAggregateInput = { id?: SortOrder bizRealm?: SortOrder sec?: SortOrder pType?: SortOrder v0?: SortOrder v1?: SortOrder v2?: SortOrder v3?: SortOrder v4?: SortOrder v5?: SortOrder createdAt?: SortOrder updatedAt?: SortOrder } export type CasbinPolicyMaxOrderByAggregateInput = { id?: SortOrder bizRealm?: SortOrder sec?: SortOrder pType?: SortOrder v0?: SortOrder v1?: SortOrder v2?: SortOrder v3?: SortOrder v4?: SortOrder v5?: SortOrder createdAt?: SortOrder updatedAt?: SortOrder } export type CasbinPolicyMinOrderByAggregateInput = { id?: SortOrder bizRealm?: SortOrder sec?: SortOrder pType?: SortOrder v0?: SortOrder v1?: SortOrder v2?: SortOrder v3?: SortOrder v4?: SortOrder v5?: SortOrder createdAt?: SortOrder updatedAt?: SortOrder } export type AccountCreaterolesInput = { set: Enumerable } export type StringFieldUpdateOperationsInput = { set?: string } export type AccountUpdaterolesInput = { set?: Enumerable push?: string | Enumerable } export type NullableDateTimeFieldUpdateOperationsInput = { set?: Date | string | null unset?: boolean } export type BoolFieldUpdateOperationsInput = { set?: boolean } export type NullableStringFieldUpdateOperationsInput = { set?: string | null unset?: boolean } export type NestedStringFilter = { equals?: string in?: Enumerable | string notIn?: Enumerable | string lt?: string lte?: string gt?: string gte?: string contains?: string startsWith?: string endsWith?: string not?: NestedStringFilter | string } export type NestedDateTimeNullableFilter = { equals?: Date | string | null in?: Enumerable | Enumerable | Date | string | null notIn?: Enumerable | Enumerable | Date | string | null lt?: Date | string lte?: Date | string gt?: Date | string gte?: Date | string not?: NestedDateTimeNullableFilter | Date | string | null isSet?: boolean } export type NestedBoolFilter = { equals?: boolean not?: NestedBoolFilter | boolean } export type NestedStringWithAggregatesFilter = { equals?: string in?: Enumerable | string notIn?: Enumerable | string lt?: string lte?: string gt?: string gte?: string contains?: string startsWith?: string endsWith?: string not?: NestedStringWithAggregatesFilter | string _count?: NestedIntFilter _min?: NestedStringFilter _max?: NestedStringFilter } export type NestedIntFilter = { equals?: number in?: Enumerable | number notIn?: Enumerable | number lt?: number lte?: number gt?: number gte?: number not?: NestedIntFilter | number } export type NestedDateTimeNullableWithAggregatesFilter = { equals?: Date | string | null in?: Enumerable | Enumerable | Date | string | null notIn?: Enumerable | Enumerable | Date | string | null lt?: Date | string lte?: Date | string gt?: Date | string gte?: Date | string not?: NestedDateTimeNullableWithAggregatesFilter | Date | string | null _count?: NestedIntNullableFilter _min?: NestedDateTimeNullableFilter _max?: NestedDateTimeNullableFilter isSet?: boolean } export type NestedIntNullableFilter = { equals?: number | null in?: Enumerable | number | null notIn?: Enumerable | number | null lt?: number lte?: number gt?: number gte?: number not?: NestedIntNullableFilter | number | null isSet?: boolean } export type NestedBoolWithAggregatesFilter = { equals?: boolean not?: NestedBoolWithAggregatesFilter | boolean _count?: NestedIntFilter _min?: NestedBoolFilter _max?: NestedBoolFilter } export type NestedStringNullableFilter = { equals?: string | null in?: Enumerable | string | null notIn?: Enumerable | string | null lt?: string lte?: string gt?: string gte?: string contains?: string startsWith?: string endsWith?: string not?: NestedStringNullableFilter | string | null isSet?: boolean } export type NestedStringNullableWithAggregatesFilter = { equals?: string | null in?: Enumerable | string | null notIn?: Enumerable | string | null lt?: string lte?: string gt?: string gte?: string contains?: string startsWith?: string endsWith?: string not?: NestedStringNullableWithAggregatesFilter | string | null _count?: NestedIntNullableFilter _min?: NestedStringNullableFilter _max?: NestedStringNullableFilter isSet?: boolean } /** * Batch Payload for updateMany & deleteMany & createMany */ export type BatchPayload = { count: number } /** * DMMF */ export const dmmf: runtime.BaseDMMF }