auth-vir 1.3.1 → 2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (65) hide show
  1. package/README.md +27 -18
  2. package/dist/auth-client/backend-auth.client.d.ts +177 -0
  3. package/dist/auth-client/backend-auth.client.js +232 -0
  4. package/dist/auth-client/frontend-auth.client.d.ts +64 -0
  5. package/dist/auth-client/frontend-auth.client.js +107 -0
  6. package/dist/auth.d.ts +33 -47
  7. package/dist/auth.js +36 -36
  8. package/dist/cookie.d.ts +15 -4
  9. package/dist/cookie.js +17 -5
  10. package/dist/csrf-token.d.ts +113 -3
  11. package/dist/csrf-token.js +101 -5
  12. package/dist/generated/browser.d.ts +9 -0
  13. package/dist/generated/browser.js +16 -0
  14. package/dist/generated/client.d.ts +26 -0
  15. package/dist/generated/client.js +31 -0
  16. package/dist/generated/commonInputTypes.d.ts +122 -0
  17. package/dist/generated/enums.d.ts +1 -0
  18. package/dist/generated/enums.js +9 -0
  19. package/dist/generated/internal/class.d.ts +126 -0
  20. package/dist/generated/internal/class.js +84 -0
  21. package/dist/generated/internal/prismaNamespace.d.ts +544 -0
  22. package/dist/generated/internal/prismaNamespace.js +101 -0
  23. package/dist/generated/internal/prismaNamespaceBrowser.d.ts +75 -0
  24. package/dist/generated/internal/prismaNamespaceBrowser.js +69 -0
  25. package/dist/generated/models/User.d.ts +983 -0
  26. package/dist/generated/models/User.js +1 -0
  27. package/dist/generated/models.d.ts +2 -0
  28. package/dist/generated/models.js +1 -0
  29. package/dist/generated/shapes.gen.d.ts +8 -0
  30. package/dist/generated/shapes.gen.js +11 -0
  31. package/dist/headers.d.ts +20 -0
  32. package/dist/headers.js +33 -0
  33. package/dist/index.d.ts +5 -3
  34. package/dist/index.js +5 -3
  35. package/dist/jwt/jwt-keys.script.d.ts +1 -0
  36. package/dist/{jwt.d.ts → jwt/jwt.d.ts} +11 -2
  37. package/dist/{jwt.js → jwt/jwt.js} +14 -3
  38. package/dist/{user-jwt.d.ts → jwt/user-jwt.d.ts} +8 -8
  39. package/dist/{user-jwt.js → jwt/user-jwt.js} +12 -9
  40. package/package.json +17 -12
  41. package/src/auth-client/backend-auth.client.ts +500 -0
  42. package/src/auth-client/frontend-auth.client.ts +182 -0
  43. package/src/auth.ts +100 -78
  44. package/src/cookie.ts +20 -8
  45. package/src/csrf-token.ts +196 -5
  46. package/src/generated/browser.ts +23 -0
  47. package/src/generated/client.ts +47 -0
  48. package/src/generated/commonInputTypes.ts +147 -0
  49. package/src/generated/enums.ts +14 -0
  50. package/src/generated/internal/class.ts +236 -0
  51. package/src/generated/internal/prismaNamespace.ts +761 -0
  52. package/src/generated/internal/prismaNamespaceBrowser.ts +102 -0
  53. package/src/generated/models/User.ts +1135 -0
  54. package/src/generated/models.ts +11 -0
  55. package/src/generated/shapes.gen.ts +15 -0
  56. package/src/headers.ts +35 -0
  57. package/src/index.ts +5 -3
  58. package/src/{jwt.ts → jwt/jwt.ts} +34 -5
  59. package/src/{user-jwt.ts → jwt/user-jwt.ts} +22 -13
  60. /package/dist/{jwt-keys.script.d.ts → generated/commonInputTypes.js} +0 -0
  61. /package/dist/{jwt-keys.d.ts → jwt/jwt-keys.d.ts} +0 -0
  62. /package/dist/{jwt-keys.js → jwt/jwt-keys.js} +0 -0
  63. /package/dist/{jwt-keys.script.js → jwt/jwt-keys.script.js} +0 -0
  64. /package/src/{jwt-keys.script.ts → jwt/jwt-keys.script.ts} +0 -0
  65. /package/src/{jwt-keys.ts → jwt/jwt-keys.ts} +0 -0
@@ -0,0 +1,544 @@
1
+ import { type UtcIsoString } from 'date-vir';
2
+ import * as runtime from "@prisma/client/runtime/client";
3
+ import type * as Prisma from "../models.js";
4
+ import { type PrismaClient } from "./class.js";
5
+ export type * from '../models.js';
6
+ export type DMMF = typeof runtime.DMMF;
7
+ export type PrismaPromise<T> = runtime.Types.Public.PrismaPromise<T>;
8
+ /**
9
+ * Prisma Errors
10
+ */
11
+ export declare const PrismaClientKnownRequestError: typeof runtime.PrismaClientKnownRequestError;
12
+ export type PrismaClientKnownRequestError = runtime.PrismaClientKnownRequestError;
13
+ export declare const PrismaClientUnknownRequestError: typeof runtime.PrismaClientUnknownRequestError;
14
+ export type PrismaClientUnknownRequestError = runtime.PrismaClientUnknownRequestError;
15
+ export declare const PrismaClientRustPanicError: typeof runtime.PrismaClientRustPanicError;
16
+ export type PrismaClientRustPanicError = runtime.PrismaClientRustPanicError;
17
+ export declare const PrismaClientInitializationError: typeof runtime.PrismaClientInitializationError;
18
+ export type PrismaClientInitializationError = runtime.PrismaClientInitializationError;
19
+ export declare const PrismaClientValidationError: typeof runtime.PrismaClientValidationError;
20
+ export type PrismaClientValidationError = runtime.PrismaClientValidationError;
21
+ /**
22
+ * Re-export of sql-template-tag
23
+ */
24
+ export declare const sql: typeof runtime.sqltag;
25
+ export declare const empty: runtime.Sql;
26
+ export declare const join: typeof runtime.join;
27
+ export declare const raw: typeof runtime.raw;
28
+ export declare const Sql: typeof runtime.Sql;
29
+ export type Sql = runtime.Sql;
30
+ /**
31
+ * Prisma.skip
32
+ */
33
+ export declare const skip: runtime.Types.Skip;
34
+ /**
35
+ * Decimal.js
36
+ */
37
+ export declare const Decimal: typeof runtime.Decimal;
38
+ export type Decimal = runtime.Decimal;
39
+ export type DecimalJsLike = runtime.DecimalJsLike;
40
+ /**
41
+ * Metrics
42
+ */
43
+ export type Metrics = runtime.Metrics;
44
+ export type Metric<T> = runtime.Metric<T>;
45
+ export type MetricHistogram = runtime.MetricHistogram;
46
+ export type MetricHistogramBucket = runtime.MetricHistogramBucket;
47
+ /**
48
+ * Extensions
49
+ */
50
+ export type Extension = runtime.Types.Extensions.UserArgs;
51
+ export declare const getExtensionContext: typeof runtime.Extensions.getExtensionContext;
52
+ export type Args<T, F extends runtime.Operation> = runtime.Types.Public.Args<T, F>;
53
+ export type Payload<T, F extends runtime.Operation = never> = runtime.Types.Public.Payload<T, F>;
54
+ export type Result<T, A, F extends runtime.Operation> = runtime.Types.Public.Result<T, A, F>;
55
+ export type Exact<A, W> = runtime.Types.Public.Exact<A, W>;
56
+ export type PrismaVersion = {
57
+ client: string;
58
+ engine: string;
59
+ };
60
+ /**
61
+ * Prisma Client JS version: 6.17.1
62
+ * Query Engine version: 272a37d34178c2894197e17273bf937f25acdeac
63
+ */
64
+ export declare const prismaVersion: PrismaVersion;
65
+ /**
66
+ * Utility Types
67
+ */
68
+ export type JsonObject = runtime.JsonObject;
69
+ export type JsonArray = runtime.JsonArray;
70
+ export type JsonValue = runtime.JsonValue;
71
+ export type InputJsonObject = runtime.InputJsonObject;
72
+ export type InputJsonArray = runtime.InputJsonArray;
73
+ export type InputJsonValue = runtime.InputJsonValue;
74
+ export declare const NullTypes: {
75
+ DbNull: (new (secret: never) => typeof runtime.objectEnumValues.instances.DbNull);
76
+ JsonNull: (new (secret: never) => typeof runtime.objectEnumValues.instances.JsonNull);
77
+ AnyNull: (new (secret: never) => typeof runtime.objectEnumValues.instances.AnyNull);
78
+ };
79
+ /**
80
+ * Helper for filtering JSON entries that have `null` on the database (empty on the db)
81
+ *
82
+ * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field
83
+ */
84
+ export declare const DbNull: {
85
+ "__#private@#private": any;
86
+ _getNamespace(): string;
87
+ _getName(): string;
88
+ toString(): string;
89
+ };
90
+ /**
91
+ * Helper for filtering JSON entries that have JSON `null` values (not empty on the db)
92
+ *
93
+ * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field
94
+ */
95
+ export declare const JsonNull: {
96
+ "__#private@#private": any;
97
+ _getNamespace(): string;
98
+ _getName(): string;
99
+ toString(): string;
100
+ };
101
+ /**
102
+ * Helper for filtering JSON entries that are `Prisma.DbNull` or `Prisma.JsonNull`
103
+ *
104
+ * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field
105
+ */
106
+ export declare const AnyNull: {
107
+ "__#private@#private": any;
108
+ _getNamespace(): string;
109
+ _getName(): string;
110
+ toString(): string;
111
+ };
112
+ type SelectAndInclude = {
113
+ select: any;
114
+ include: any;
115
+ };
116
+ type SelectAndOmit = {
117
+ select: any;
118
+ omit: any;
119
+ };
120
+ /**
121
+ * From T, pick a set of properties whose keys are in the union K
122
+ */
123
+ type Prisma__Pick<T, K extends keyof T> = {
124
+ [P in K]: T[P];
125
+ };
126
+ export type Enumerable<T> = T | Array<T>;
127
+ /**
128
+ * Subset
129
+ * @desc From `T` pick properties that exist in `U`. Simple version of Intersection
130
+ */
131
+ export type Subset<T, U> = {
132
+ [key in keyof T]: key extends keyof U ? T[key] : never;
133
+ };
134
+ /**
135
+ * SelectSubset
136
+ * @desc From `T` pick properties that exist in `U`. Simple version of Intersection.
137
+ * Additionally, it validates, if both select and include are present. If the case, it errors.
138
+ */
139
+ export type SelectSubset<T, U> = {
140
+ [key in keyof T]: key extends keyof U ? T[key] : never;
141
+ } & (T extends SelectAndInclude ? 'Please either choose `select` or `include`.' : T extends SelectAndOmit ? 'Please either choose `select` or `omit`.' : {});
142
+ /**
143
+ * Subset + Intersection
144
+ * @desc From `T` pick properties that exist in `U` and intersect `K`
145
+ */
146
+ export type SubsetIntersection<T, U, K> = {
147
+ [key in keyof T]: key extends keyof U ? T[key] : never;
148
+ } & K;
149
+ type Without<T, U> = {
150
+ [P in Exclude<keyof T, keyof U>]?: never;
151
+ };
152
+ /**
153
+ * XOR is needed to have a real mutually exclusive union type
154
+ * https://stackoverflow.com/questions/42123407/does-typescript-support-mutually-exclusive-types
155
+ */
156
+ export type XOR<T, U> = T extends object ? U extends object ? (Without<T, U> & U) | (Without<U, T> & T) : U : T;
157
+ /**
158
+ * Is T a Record?
159
+ */
160
+ type IsObject<T extends any> = T extends Array<any> ? False : T extends UtcIsoString ? False : T extends Uint8Array ? False : T extends BigInt ? False : T extends object ? True : False;
161
+ /**
162
+ * If it's T[], return T
163
+ */
164
+ export type UnEnumerate<T extends unknown> = T extends Array<infer U> ? U : T;
165
+ /**
166
+ * From ts-toolbelt
167
+ */
168
+ type __Either<O extends object, K extends Key> = Omit<O, K> & {
169
+ [P in K]: Prisma__Pick<O, P & keyof O>;
170
+ }[K];
171
+ type EitherStrict<O extends object, K extends Key> = Strict<__Either<O, K>>;
172
+ type EitherLoose<O extends object, K extends Key> = ComputeRaw<__Either<O, K>>;
173
+ type _Either<O extends object, K extends Key, strict extends Boolean> = {
174
+ 1: EitherStrict<O, K>;
175
+ 0: EitherLoose<O, K>;
176
+ }[strict];
177
+ export type Either<O extends object, K extends Key, strict extends Boolean = 1> = O extends unknown ? _Either<O, K, strict> : never;
178
+ export type Union = any;
179
+ export type PatchUndefined<O extends object, O1 extends object> = {
180
+ [K in keyof O]: O[K] extends undefined ? At<O1, K> : O[K];
181
+ } & {};
182
+ /** Helper Types for "Merge" **/
183
+ export type IntersectOf<U extends Union> = (U extends unknown ? (k: U) => void : never) extends (k: infer I) => void ? I : never;
184
+ export type Overwrite<O extends object, O1 extends object> = {
185
+ [K in keyof O]: K extends keyof O1 ? O1[K] : O[K];
186
+ } & {};
187
+ type _Merge<U extends object> = IntersectOf<Overwrite<U, {
188
+ [K in keyof U]-?: At<U, K>;
189
+ }>>;
190
+ type Key = string | number | symbol;
191
+ type AtStrict<O extends object, K extends Key> = O[K & keyof O];
192
+ type AtLoose<O extends object, K extends Key> = O extends unknown ? AtStrict<O, K> : never;
193
+ export type At<O extends object, K extends Key, strict extends Boolean = 1> = {
194
+ 1: AtStrict<O, K>;
195
+ 0: AtLoose<O, K>;
196
+ }[strict];
197
+ export type ComputeRaw<A extends any> = A extends Function ? A : {
198
+ [K in keyof A]: A[K];
199
+ } & {};
200
+ export type OptionalFlat<O> = {
201
+ [K in keyof O]?: O[K];
202
+ } & {};
203
+ type _Record<K extends keyof any, T> = {
204
+ [P in K]: T;
205
+ };
206
+ type NoExpand<T> = T extends unknown ? T : never;
207
+ export type AtLeast<O extends object, K extends string> = NoExpand<O extends unknown ? (K extends keyof O ? {
208
+ [P in K]: O[P];
209
+ } & O : O) | {
210
+ [P in keyof O as P extends K ? P : never]-?: O[P];
211
+ } & O : never>;
212
+ type _Strict<U, _U = U> = U extends unknown ? U & OptionalFlat<_Record<Exclude<Keys<_U>, keyof U>, never>> : never;
213
+ export type Strict<U extends object> = ComputeRaw<_Strict<U>>;
214
+ /** End Helper Types for "Merge" **/
215
+ export type Merge<U extends object> = ComputeRaw<_Merge<Strict<U>>>;
216
+ export type Boolean = True | False;
217
+ export type True = 1;
218
+ export type False = 0;
219
+ export type Not<B extends Boolean> = {
220
+ 0: 1;
221
+ 1: 0;
222
+ }[B];
223
+ export type Extends<A1 extends any, A2 extends any> = [A1] extends [never] ? 0 : A1 extends A2 ? 1 : 0;
224
+ export type Has<U extends Union, U1 extends Union> = Not<Extends<Exclude<U1, U>, U1>>;
225
+ export type Or<B1 extends Boolean, B2 extends Boolean> = {
226
+ 0: {
227
+ 0: 0;
228
+ 1: 1;
229
+ };
230
+ 1: {
231
+ 0: 1;
232
+ 1: 1;
233
+ };
234
+ }[B1][B2];
235
+ export type Keys<U extends Union> = U extends unknown ? keyof U : never;
236
+ export type GetScalarType<T, O> = O extends object ? {
237
+ [P in keyof T]: P extends keyof O ? O[P] : never;
238
+ } : never;
239
+ type FieldPaths<T, U = Omit<T, '_avg' | '_sum' | '_count' | '_min' | '_max'>> = IsObject<T> extends True ? U : T;
240
+ export type GetHavingFields<T> = {
241
+ [K in keyof T]: Or<Or<Extends<'OR', K>, Extends<'AND', K>>, Extends<'NOT', K>> extends True ? T[K] extends infer TK ? GetHavingFields<UnEnumerate<TK> extends object ? Merge<UnEnumerate<TK>> : never> : never : {} extends FieldPaths<T[K]> ? never : K;
242
+ }[keyof T];
243
+ /**
244
+ * Convert tuple to union
245
+ */
246
+ type _TupleToUnion<T> = T extends (infer E)[] ? E : never;
247
+ type TupleToUnion<K extends readonly any[]> = _TupleToUnion<K>;
248
+ export type MaybeTupleToUnion<T> = T extends any[] ? TupleToUnion<T> : T;
249
+ /**
250
+ * Like `Pick`, but additionally can also accept an array of keys
251
+ */
252
+ export type PickEnumerable<T, K extends Enumerable<keyof T> | keyof T> = Prisma__Pick<T, MaybeTupleToUnion<K>>;
253
+ /**
254
+ * Exclude all keys with underscores
255
+ */
256
+ export type ExcludeUnderscoreKeys<T extends string> = T extends `_${string}` ? never : T;
257
+ export type FieldRef<Model, FieldType> = runtime.FieldRef<Model, FieldType>;
258
+ type FieldRefInputType<Model, FieldType> = Model extends never ? never : FieldRef<Model, FieldType>;
259
+ export declare const ModelName: {
260
+ readonly User: "User";
261
+ };
262
+ export type ModelName = (typeof ModelName)[keyof typeof ModelName];
263
+ export interface TypeMapCb<GlobalOmitOptions = {}> extends runtime.Types.Utils.Fn<{
264
+ extArgs: runtime.Types.Extensions.InternalArgs;
265
+ }, runtime.Types.Utils.Record<string, any>> {
266
+ returns: TypeMap<this['params']['extArgs'], GlobalOmitOptions>;
267
+ }
268
+ export type TypeMap<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs, GlobalOmitOptions = {}> = {
269
+ globalOmitOptions: {
270
+ omit: GlobalOmitOptions;
271
+ };
272
+ meta: {
273
+ modelProps: "user";
274
+ txIsolationLevel: TransactionIsolationLevel;
275
+ };
276
+ model: {
277
+ User: {
278
+ payload: Prisma.$UserPayload<ExtArgs>;
279
+ fields: Prisma.UserFieldRefs;
280
+ operations: {
281
+ findUnique: {
282
+ args: Prisma.UserFindUniqueArgs<ExtArgs>;
283
+ result: runtime.Types.Utils.PayloadToResult<Prisma.$UserPayload> | null;
284
+ };
285
+ findUniqueOrThrow: {
286
+ args: Prisma.UserFindUniqueOrThrowArgs<ExtArgs>;
287
+ result: runtime.Types.Utils.PayloadToResult<Prisma.$UserPayload>;
288
+ };
289
+ findFirst: {
290
+ args: Prisma.UserFindFirstArgs<ExtArgs>;
291
+ result: runtime.Types.Utils.PayloadToResult<Prisma.$UserPayload> | null;
292
+ };
293
+ findFirstOrThrow: {
294
+ args: Prisma.UserFindFirstOrThrowArgs<ExtArgs>;
295
+ result: runtime.Types.Utils.PayloadToResult<Prisma.$UserPayload>;
296
+ };
297
+ findMany: {
298
+ args: Prisma.UserFindManyArgs<ExtArgs>;
299
+ result: runtime.Types.Utils.PayloadToResult<Prisma.$UserPayload>[];
300
+ };
301
+ create: {
302
+ args: Prisma.UserCreateArgs<ExtArgs>;
303
+ result: runtime.Types.Utils.PayloadToResult<Prisma.$UserPayload>;
304
+ };
305
+ createMany: {
306
+ args: Prisma.UserCreateManyArgs<ExtArgs>;
307
+ result: BatchPayload;
308
+ };
309
+ createManyAndReturn: {
310
+ args: Prisma.UserCreateManyAndReturnArgs<ExtArgs>;
311
+ result: runtime.Types.Utils.PayloadToResult<Prisma.$UserPayload>[];
312
+ };
313
+ delete: {
314
+ args: Prisma.UserDeleteArgs<ExtArgs>;
315
+ result: runtime.Types.Utils.PayloadToResult<Prisma.$UserPayload>;
316
+ };
317
+ update: {
318
+ args: Prisma.UserUpdateArgs<ExtArgs>;
319
+ result: runtime.Types.Utils.PayloadToResult<Prisma.$UserPayload>;
320
+ };
321
+ deleteMany: {
322
+ args: Prisma.UserDeleteManyArgs<ExtArgs>;
323
+ result: BatchPayload;
324
+ };
325
+ updateMany: {
326
+ args: Prisma.UserUpdateManyArgs<ExtArgs>;
327
+ result: BatchPayload;
328
+ };
329
+ updateManyAndReturn: {
330
+ args: Prisma.UserUpdateManyAndReturnArgs<ExtArgs>;
331
+ result: runtime.Types.Utils.PayloadToResult<Prisma.$UserPayload>[];
332
+ };
333
+ upsert: {
334
+ args: Prisma.UserUpsertArgs<ExtArgs>;
335
+ result: runtime.Types.Utils.PayloadToResult<Prisma.$UserPayload>;
336
+ };
337
+ aggregate: {
338
+ args: Prisma.UserAggregateArgs<ExtArgs>;
339
+ result: runtime.Types.Utils.Optional<Prisma.AggregateUser>;
340
+ };
341
+ groupBy: {
342
+ args: Prisma.UserGroupByArgs<ExtArgs>;
343
+ result: runtime.Types.Utils.Optional<Prisma.UserGroupByOutputType>[];
344
+ };
345
+ count: {
346
+ args: Prisma.UserCountArgs<ExtArgs>;
347
+ result: runtime.Types.Utils.Optional<Prisma.UserCountAggregateOutputType> | number;
348
+ };
349
+ };
350
+ };
351
+ };
352
+ } & {
353
+ other: {
354
+ payload: any;
355
+ operations: {
356
+ $executeRaw: {
357
+ args: [query: TemplateStringsArray | Sql, ...values: any[]];
358
+ result: any;
359
+ };
360
+ $executeRawUnsafe: {
361
+ args: [query: string, ...values: any[]];
362
+ result: any;
363
+ };
364
+ $queryRaw: {
365
+ args: [query: TemplateStringsArray | Sql, ...values: any[]];
366
+ result: any;
367
+ };
368
+ $queryRawUnsafe: {
369
+ args: [query: string, ...values: any[]];
370
+ result: any;
371
+ };
372
+ };
373
+ };
374
+ };
375
+ /**
376
+ * Enums
377
+ */
378
+ export declare const TransactionIsolationLevel: {
379
+ readonly ReadUncommitted: "ReadUncommitted";
380
+ readonly ReadCommitted: "ReadCommitted";
381
+ readonly RepeatableRead: "RepeatableRead";
382
+ readonly Serializable: "Serializable";
383
+ };
384
+ export type TransactionIsolationLevel = (typeof TransactionIsolationLevel)[keyof typeof TransactionIsolationLevel];
385
+ export declare const UserScalarFieldEnum: {
386
+ readonly id: "id";
387
+ readonly createdAt: "createdAt";
388
+ readonly updatedAt: "updatedAt";
389
+ readonly name: "name";
390
+ };
391
+ export type UserScalarFieldEnum = (typeof UserScalarFieldEnum)[keyof typeof UserScalarFieldEnum];
392
+ export declare const RelationLoadStrategy: {
393
+ readonly query: "query";
394
+ readonly join: "join";
395
+ };
396
+ export type RelationLoadStrategy = (typeof RelationLoadStrategy)[keyof typeof RelationLoadStrategy];
397
+ export declare const SortOrder: {
398
+ readonly asc: "asc";
399
+ readonly desc: "desc";
400
+ };
401
+ export type SortOrder = (typeof SortOrder)[keyof typeof SortOrder];
402
+ export declare const QueryMode: {
403
+ readonly default: "default";
404
+ readonly insensitive: "insensitive";
405
+ };
406
+ export type QueryMode = (typeof QueryMode)[keyof typeof QueryMode];
407
+ /**
408
+ * Field references
409
+ */
410
+ /**
411
+ * Reference to a field of type 'String'
412
+ */
413
+ export type StringFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'String'>;
414
+ /**
415
+ * Reference to a field of type 'String[]'
416
+ */
417
+ export type ListStringFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'String[]'>;
418
+ /**
419
+ * Reference to a field of type 'DateTime'
420
+ */
421
+ export type DateTimeFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'DateTime'>;
422
+ /**
423
+ * Reference to a field of type 'DateTime[]'
424
+ */
425
+ export type ListDateTimeFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'DateTime[]'>;
426
+ /**
427
+ * Reference to a field of type 'Int'
428
+ */
429
+ export type IntFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'Int'>;
430
+ /**
431
+ * Reference to a field of type 'Int[]'
432
+ */
433
+ export type ListIntFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'Int[]'>;
434
+ /**
435
+ * Batch Payload for updateMany & deleteMany & createMany
436
+ */
437
+ export type BatchPayload = {
438
+ count: number;
439
+ };
440
+ export type Datasource = {
441
+ url?: string;
442
+ };
443
+ export type Datasources = {
444
+ db?: Datasource;
445
+ };
446
+ export declare const defineExtension: runtime.Types.Extensions.ExtendsHook<"define", TypeMapCb, runtime.Types.Extensions.DefaultArgs>;
447
+ export type DefaultPrismaClient = PrismaClient;
448
+ export type ErrorFormat = 'pretty' | 'colorless' | 'minimal';
449
+ export interface PrismaClientOptions {
450
+ /**
451
+ * Overwrites the datasource url from your schema.prisma file
452
+ */
453
+ datasources?: Datasources;
454
+ /**
455
+ * Overwrites the datasource url from your schema.prisma file
456
+ */
457
+ datasourceUrl?: string;
458
+ /**
459
+ * @default "colorless"
460
+ */
461
+ errorFormat?: ErrorFormat;
462
+ /**
463
+ * @example
464
+ * ```
465
+ * // Shorthand for `emit: 'stdout'`
466
+ * log: ['query', 'info', 'warn', 'error']
467
+ *
468
+ * // Emit as events only
469
+ * log: [
470
+ * { emit: 'event', level: 'query' },
471
+ * { emit: 'event', level: 'info' },
472
+ * { emit: 'event', level: 'warn' }
473
+ * { emit: 'event', level: 'error' }
474
+ * ]
475
+ *
476
+ * / Emit as events and log to stdout
477
+ * og: [
478
+ * { emit: 'stdout', level: 'query' },
479
+ * { emit: 'stdout', level: 'info' },
480
+ * { emit: 'stdout', level: 'warn' }
481
+ * { emit: 'stdout', level: 'error' }
482
+ *
483
+ * ```
484
+ * Read more in our [docs](https://www.prisma.io/docs/reference/tools-and-interfaces/prisma-client/logging#the-log-option).
485
+ */
486
+ log?: (LogLevel | LogDefinition)[];
487
+ /**
488
+ * The default values for transactionOptions
489
+ * maxWait ?= 2000
490
+ * timeout ?= 5000
491
+ */
492
+ transactionOptions?: {
493
+ maxWait?: number;
494
+ timeout?: number;
495
+ isolationLevel?: TransactionIsolationLevel;
496
+ };
497
+ /**
498
+ * Instance of a Driver Adapter, e.g., like one provided by `@prisma/adapter-planetscale`
499
+ */
500
+ adapter?: runtime.SqlDriverAdapterFactory | null;
501
+ /**
502
+ * Global configuration for omitting model fields by default.
503
+ *
504
+ * @example
505
+ * ```
506
+ * const prisma = new PrismaClient({
507
+ * omit: {
508
+ * user: {
509
+ * password: true
510
+ * }
511
+ * }
512
+ * })
513
+ * ```
514
+ */
515
+ omit?: GlobalOmitConfig;
516
+ }
517
+ export type GlobalOmitConfig = {
518
+ user?: Prisma.UserOmit;
519
+ };
520
+ export type LogLevel = 'info' | 'query' | 'warn' | 'error';
521
+ export type LogDefinition = {
522
+ level: LogLevel;
523
+ emit: 'stdout' | 'event';
524
+ };
525
+ export type CheckIsLogLevel<T> = T extends LogLevel ? T : never;
526
+ export type GetLogType<T> = CheckIsLogLevel<T extends LogDefinition ? T['level'] : T>;
527
+ export type GetEvents<T extends any[]> = T extends Array<LogLevel | LogDefinition> ? GetLogType<T[number]> : never;
528
+ export type QueryEvent = {
529
+ timestamp: UtcIsoString;
530
+ query: string;
531
+ params: string;
532
+ duration: number;
533
+ target: string;
534
+ };
535
+ export type LogEvent = {
536
+ timestamp: UtcIsoString;
537
+ message: string;
538
+ target: string;
539
+ };
540
+ export type PrismaAction = 'findUnique' | 'findUniqueOrThrow' | 'findMany' | 'findFirst' | 'findFirstOrThrow' | 'create' | 'createMany' | 'createManyAndReturn' | 'update' | 'updateMany' | 'updateManyAndReturn' | 'upsert' | 'delete' | 'deleteMany' | 'executeRaw' | 'queryRaw' | 'aggregate' | 'count' | 'runCommandRaw' | 'findRaw' | 'groupBy';
541
+ /**
542
+ * `PrismaClient` proxy available in interactive transactions.
543
+ */
544
+ export type TransactionClient = Omit<DefaultPrismaClient, runtime.ITXClientDenyList>;
@@ -0,0 +1,101 @@
1
+ /* !!! This is code generated by Prisma. Do not edit directly. !!! */
2
+ /* eslint-disable */
3
+ /*
4
+ * WARNING: This is an internal file that is subject to change!
5
+ *
6
+ * 🛑 Under no circumstances should you import this file directly! 🛑
7
+ *
8
+ * All exports from this file are wrapped under a `Prisma` namespace object in the client.ts file.
9
+ * While this enables partial backward compatibility, it is not part of the stable public API.
10
+ *
11
+ * If you are looking for your Models, Enums, and Input Types, please import them from the respective
12
+ * model files in the `model` directory!
13
+ */
14
+ import * as runtime from "@prisma/client/runtime/client";
15
+ /**
16
+ * Prisma Errors
17
+ */
18
+ export const PrismaClientKnownRequestError = runtime.PrismaClientKnownRequestError;
19
+ export const PrismaClientUnknownRequestError = runtime.PrismaClientUnknownRequestError;
20
+ export const PrismaClientRustPanicError = runtime.PrismaClientRustPanicError;
21
+ export const PrismaClientInitializationError = runtime.PrismaClientInitializationError;
22
+ export const PrismaClientValidationError = runtime.PrismaClientValidationError;
23
+ /**
24
+ * Re-export of sql-template-tag
25
+ */
26
+ export const sql = runtime.sqltag;
27
+ export const empty = runtime.empty;
28
+ export const join = runtime.join;
29
+ export const raw = runtime.raw;
30
+ export const Sql = runtime.Sql;
31
+ /**
32
+ * Prisma.skip
33
+ */
34
+ export const skip = runtime.skip;
35
+ /**
36
+ * Decimal.js
37
+ */
38
+ export const Decimal = runtime.Decimal;
39
+ export const getExtensionContext = runtime.Extensions.getExtensionContext;
40
+ /**
41
+ * Prisma Client JS version: 6.17.1
42
+ * Query Engine version: 272a37d34178c2894197e17273bf937f25acdeac
43
+ */
44
+ export const prismaVersion = {
45
+ client: "6.17.1",
46
+ engine: "272a37d34178c2894197e17273bf937f25acdeac"
47
+ };
48
+ export const NullTypes = {
49
+ DbNull: runtime.objectEnumValues.classes.DbNull,
50
+ JsonNull: runtime.objectEnumValues.classes.JsonNull,
51
+ AnyNull: runtime.objectEnumValues.classes.AnyNull,
52
+ };
53
+ /**
54
+ * Helper for filtering JSON entries that have `null` on the database (empty on the db)
55
+ *
56
+ * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field
57
+ */
58
+ export const DbNull = runtime.objectEnumValues.instances.DbNull;
59
+ /**
60
+ * Helper for filtering JSON entries that have JSON `null` values (not empty on the db)
61
+ *
62
+ * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field
63
+ */
64
+ export const JsonNull = runtime.objectEnumValues.instances.JsonNull;
65
+ /**
66
+ * Helper for filtering JSON entries that are `Prisma.DbNull` or `Prisma.JsonNull`
67
+ *
68
+ * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field
69
+ */
70
+ export const AnyNull = runtime.objectEnumValues.instances.AnyNull;
71
+ export const ModelName = {
72
+ User: 'User'
73
+ };
74
+ /**
75
+ * Enums
76
+ */
77
+ export const TransactionIsolationLevel = runtime.makeStrictEnum({
78
+ ReadUncommitted: 'ReadUncommitted',
79
+ ReadCommitted: 'ReadCommitted',
80
+ RepeatableRead: 'RepeatableRead',
81
+ Serializable: 'Serializable'
82
+ });
83
+ export const UserScalarFieldEnum = {
84
+ id: 'id',
85
+ createdAt: 'createdAt',
86
+ updatedAt: 'updatedAt',
87
+ name: 'name'
88
+ };
89
+ export const RelationLoadStrategy = {
90
+ query: 'query',
91
+ join: 'join'
92
+ };
93
+ export const SortOrder = {
94
+ asc: 'asc',
95
+ desc: 'desc'
96
+ };
97
+ export const QueryMode = {
98
+ default: 'default',
99
+ insensitive: 'insensitive'
100
+ };
101
+ export const defineExtension = runtime.Extensions.defineExtension;