@explita/tunnel-server-plugin 0.0.0-stage → 0.1.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 (94) hide show
  1. package/CHANGELOG.md +44 -0
  2. package/LICENSE +21 -0
  3. package/README.md +63 -2
  4. package/bin/cli.js +100 -0
  5. package/dist/generated/prisma/browser.d.ts +25 -0
  6. package/dist/generated/prisma/browser.d.ts.map +1 -0
  7. package/dist/generated/prisma/browser.js +18 -0
  8. package/dist/generated/prisma/browser.js.map +1 -0
  9. package/dist/generated/prisma/client.d.ts +44 -0
  10. package/dist/generated/prisma/client.d.ts.map +1 -0
  11. package/dist/generated/prisma/client.js +35 -0
  12. package/dist/generated/prisma/client.js.map +1 -0
  13. package/dist/generated/prisma/commonInputTypes.d.ts +278 -0
  14. package/dist/generated/prisma/commonInputTypes.d.ts.map +1 -0
  15. package/dist/generated/prisma/commonInputTypes.js +11 -0
  16. package/dist/generated/prisma/commonInputTypes.js.map +1 -0
  17. package/dist/generated/prisma/enums.d.ts +2 -0
  18. package/dist/generated/prisma/enums.d.ts.map +1 -0
  19. package/dist/generated/prisma/enums.js +11 -0
  20. package/dist/generated/prisma/enums.js.map +1 -0
  21. package/dist/generated/prisma/internal/class.d.ts +166 -0
  22. package/dist/generated/prisma/internal/class.d.ts.map +1 -0
  23. package/dist/generated/prisma/internal/class.js +50 -0
  24. package/dist/generated/prisma/internal/class.js.map +1 -0
  25. package/dist/generated/prisma/internal/prismaNamespace.d.ts +867 -0
  26. package/dist/generated/prisma/internal/prismaNamespace.d.ts.map +1 -0
  27. package/dist/generated/prisma/internal/prismaNamespace.js +128 -0
  28. package/dist/generated/prisma/internal/prismaNamespace.js.map +1 -0
  29. package/dist/generated/prisma/internal/prismaNamespaceBrowser.d.ts +92 -0
  30. package/dist/generated/prisma/internal/prismaNamespaceBrowser.d.ts.map +1 -0
  31. package/dist/generated/prisma/internal/prismaNamespaceBrowser.js +99 -0
  32. package/dist/generated/prisma/internal/prismaNamespaceBrowser.js.map +1 -0
  33. package/dist/generated/prisma/models/DailyMetric.d.ts +1152 -0
  34. package/dist/generated/prisma/models/DailyMetric.d.ts.map +1 -0
  35. package/dist/generated/prisma/models/DailyMetric.js +2 -0
  36. package/dist/generated/prisma/models/DailyMetric.js.map +1 -0
  37. package/dist/generated/prisma/models/Developer.d.ts +1134 -0
  38. package/dist/generated/prisma/models/Developer.d.ts.map +1 -0
  39. package/dist/generated/prisma/models/Developer.js +2 -0
  40. package/dist/generated/prisma/models/Developer.js.map +1 -0
  41. package/dist/generated/prisma/models/SystemMetric.d.ts +1048 -0
  42. package/dist/generated/prisma/models/SystemMetric.d.ts.map +1 -0
  43. package/dist/generated/prisma/models/SystemMetric.js +2 -0
  44. package/dist/generated/prisma/models/SystemMetric.js.map +1 -0
  45. package/dist/generated/prisma/models/Token.d.ts +1214 -0
  46. package/dist/generated/prisma/models/Token.d.ts.map +1 -0
  47. package/dist/generated/prisma/models/Token.js +2 -0
  48. package/dist/generated/prisma/models/Token.js.map +1 -0
  49. package/dist/generated/prisma/models.d.ts +6 -0
  50. package/dist/generated/prisma/models.d.ts.map +1 -0
  51. package/dist/generated/prisma/models.js +2 -0
  52. package/dist/generated/prisma/models.js.map +1 -0
  53. package/dist/index.d.ts +21 -0
  54. package/dist/index.d.ts.map +1 -0
  55. package/dist/index.js +45 -0
  56. package/dist/index.js.map +1 -0
  57. package/dist/issue.d.ts +3 -0
  58. package/dist/issue.d.ts.map +1 -0
  59. package/dist/issue.js +102 -0
  60. package/dist/issue.js.map +1 -0
  61. package/dist/lib/cache.d.ts +2 -0
  62. package/dist/lib/cache.d.ts.map +1 -0
  63. package/dist/lib/cache.js +6 -0
  64. package/dist/lib/cache.js.map +1 -0
  65. package/dist/lib/mailer.d.ts +28 -0
  66. package/dist/lib/mailer.d.ts.map +1 -0
  67. package/dist/lib/mailer.js +116 -0
  68. package/dist/lib/mailer.js.map +1 -0
  69. package/dist/lib/metrics.d.ts +27 -0
  70. package/dist/lib/metrics.d.ts.map +1 -0
  71. package/dist/lib/metrics.js +93 -0
  72. package/dist/lib/metrics.js.map +1 -0
  73. package/dist/lib/prisma.d.ts +3 -0
  74. package/dist/lib/prisma.d.ts.map +1 -0
  75. package/dist/lib/prisma.js +20 -0
  76. package/dist/lib/prisma.js.map +1 -0
  77. package/dist/lib/utils.d.ts +2 -0
  78. package/dist/lib/utils.d.ts.map +1 -0
  79. package/dist/lib/utils.js +5 -0
  80. package/dist/lib/utils.js.map +1 -0
  81. package/dist/request.d.ts +4 -0
  82. package/dist/request.d.ts.map +1 -0
  83. package/dist/request.js +29 -0
  84. package/dist/request.js.map +1 -0
  85. package/dist/validate.d.ts +2 -0
  86. package/dist/validate.d.ts.map +1 -0
  87. package/dist/validate.js +48 -0
  88. package/dist/validate.js.map +1 -0
  89. package/dist/verify.d.ts +3 -0
  90. package/dist/verify.d.ts.map +1 -0
  91. package/dist/verify.js +53 -0
  92. package/dist/verify.js.map +1 -0
  93. package/package.json +52 -4
  94. package/prisma/schema.prisma +62 -0
@@ -0,0 +1,1214 @@
1
+ import type * as runtime from "@prisma/client/runtime/client";
2
+ import type * as Prisma from "../internal/prismaNamespace.js";
3
+ /**
4
+ * Model Token
5
+ *
6
+ */
7
+ export type TokenModel = runtime.Types.Result.DefaultSelection<Prisma.$TokenPayload>;
8
+ export type AggregateToken = {
9
+ _count: TokenCountAggregateOutputType | null;
10
+ _min: TokenMinAggregateOutputType | null;
11
+ _max: TokenMaxAggregateOutputType | null;
12
+ };
13
+ export type TokenMinAggregateOutputType = {
14
+ id: string | null;
15
+ developerId: string | null;
16
+ token: string | null;
17
+ createdAt: Date | null;
18
+ lastUsedAt: Date | null;
19
+ revokedAt: Date | null;
20
+ };
21
+ export type TokenMaxAggregateOutputType = {
22
+ id: string | null;
23
+ developerId: string | null;
24
+ token: string | null;
25
+ createdAt: Date | null;
26
+ lastUsedAt: Date | null;
27
+ revokedAt: Date | null;
28
+ };
29
+ export type TokenCountAggregateOutputType = {
30
+ id: number;
31
+ developerId: number;
32
+ token: number;
33
+ createdAt: number;
34
+ lastUsedAt: number;
35
+ revokedAt: number;
36
+ _all: number;
37
+ };
38
+ export type TokenMinAggregateInputType = {
39
+ id?: true;
40
+ developerId?: true;
41
+ token?: true;
42
+ createdAt?: true;
43
+ lastUsedAt?: true;
44
+ revokedAt?: true;
45
+ };
46
+ export type TokenMaxAggregateInputType = {
47
+ id?: true;
48
+ developerId?: true;
49
+ token?: true;
50
+ createdAt?: true;
51
+ lastUsedAt?: true;
52
+ revokedAt?: true;
53
+ };
54
+ export type TokenCountAggregateInputType = {
55
+ id?: true;
56
+ developerId?: true;
57
+ token?: true;
58
+ createdAt?: true;
59
+ lastUsedAt?: true;
60
+ revokedAt?: true;
61
+ _all?: true;
62
+ };
63
+ export type TokenAggregateArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
64
+ /**
65
+ * Filter which Token to aggregate.
66
+ */
67
+ where?: Prisma.TokenWhereInput;
68
+ /**
69
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
70
+ *
71
+ * Determine the order of Tokens to fetch.
72
+ */
73
+ orderBy?: Prisma.TokenOrderByWithRelationInput | Prisma.TokenOrderByWithRelationInput[];
74
+ /**
75
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
76
+ *
77
+ * Sets the start position
78
+ */
79
+ cursor?: Prisma.TokenWhereUniqueInput;
80
+ /**
81
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
82
+ *
83
+ * Take `±n` Tokens from the position of the cursor.
84
+ */
85
+ take?: number;
86
+ /**
87
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
88
+ *
89
+ * Skip the first `n` Tokens.
90
+ */
91
+ skip?: number;
92
+ /**
93
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
94
+ *
95
+ * Count returned Tokens
96
+ **/
97
+ _count?: true | TokenCountAggregateInputType;
98
+ /**
99
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
100
+ *
101
+ * Select which fields to find the minimum value
102
+ **/
103
+ _min?: TokenMinAggregateInputType;
104
+ /**
105
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
106
+ *
107
+ * Select which fields to find the maximum value
108
+ **/
109
+ _max?: TokenMaxAggregateInputType;
110
+ };
111
+ export type GetTokenAggregateType<T extends TokenAggregateArgs> = {
112
+ [P in keyof T & keyof AggregateToken]: P extends '_count' | 'count' ? T[P] extends true ? number : Prisma.GetScalarType<T[P], AggregateToken[P]> : Prisma.GetScalarType<T[P], AggregateToken[P]>;
113
+ };
114
+ export type TokenGroupByArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
115
+ where?: Prisma.TokenWhereInput;
116
+ orderBy?: Prisma.TokenOrderByWithAggregationInput | Prisma.TokenOrderByWithAggregationInput[];
117
+ by: Prisma.TokenScalarFieldEnum[] | Prisma.TokenScalarFieldEnum;
118
+ having?: Prisma.TokenScalarWhereWithAggregatesInput;
119
+ take?: number;
120
+ skip?: number;
121
+ _count?: TokenCountAggregateInputType | true;
122
+ _min?: TokenMinAggregateInputType;
123
+ _max?: TokenMaxAggregateInputType;
124
+ };
125
+ export type TokenGroupByOutputType = {
126
+ id: string;
127
+ developerId: string;
128
+ token: string;
129
+ createdAt: Date;
130
+ lastUsedAt: Date | null;
131
+ revokedAt: Date | null;
132
+ _count: TokenCountAggregateOutputType | null;
133
+ _min: TokenMinAggregateOutputType | null;
134
+ _max: TokenMaxAggregateOutputType | null;
135
+ };
136
+ export type GetTokenGroupByPayload<T extends TokenGroupByArgs> = Prisma.PrismaPromise<Array<Prisma.PickEnumerable<TokenGroupByOutputType, T['by']> & {
137
+ [P in ((keyof T) & (keyof TokenGroupByOutputType))]: P extends '_count' ? T[P] extends boolean ? number : Prisma.GetScalarType<T[P], TokenGroupByOutputType[P]> : Prisma.GetScalarType<T[P], TokenGroupByOutputType[P]>;
138
+ }>>;
139
+ export type TokenWhereInput = {
140
+ AND?: Prisma.TokenWhereInput | Prisma.TokenWhereInput[];
141
+ OR?: Prisma.TokenWhereInput[];
142
+ NOT?: Prisma.TokenWhereInput | Prisma.TokenWhereInput[];
143
+ id?: Prisma.StringFilter<"Token"> | string;
144
+ developerId?: Prisma.StringFilter<"Token"> | string;
145
+ token?: Prisma.StringFilter<"Token"> | string;
146
+ createdAt?: Prisma.DateTimeFilter<"Token"> | Date | string;
147
+ lastUsedAt?: Prisma.DateTimeNullableFilter<"Token"> | Date | string | null;
148
+ revokedAt?: Prisma.DateTimeNullableFilter<"Token"> | Date | string | null;
149
+ developer?: Prisma.XOR<Prisma.DeveloperScalarRelationFilter, Prisma.DeveloperWhereInput>;
150
+ };
151
+ export type TokenOrderByWithRelationInput = {
152
+ id?: Prisma.SortOrder;
153
+ developerId?: Prisma.SortOrder;
154
+ token?: Prisma.SortOrder;
155
+ createdAt?: Prisma.SortOrder;
156
+ lastUsedAt?: Prisma.SortOrderInput | Prisma.SortOrder;
157
+ revokedAt?: Prisma.SortOrderInput | Prisma.SortOrder;
158
+ developer?: Prisma.DeveloperOrderByWithRelationInput;
159
+ };
160
+ export type TokenWhereUniqueInput = Prisma.AtLeast<{
161
+ id?: string;
162
+ token?: string;
163
+ AND?: Prisma.TokenWhereInput | Prisma.TokenWhereInput[];
164
+ OR?: Prisma.TokenWhereInput[];
165
+ NOT?: Prisma.TokenWhereInput | Prisma.TokenWhereInput[];
166
+ developerId?: Prisma.StringFilter<"Token"> | string;
167
+ createdAt?: Prisma.DateTimeFilter<"Token"> | Date | string;
168
+ lastUsedAt?: Prisma.DateTimeNullableFilter<"Token"> | Date | string | null;
169
+ revokedAt?: Prisma.DateTimeNullableFilter<"Token"> | Date | string | null;
170
+ developer?: Prisma.XOR<Prisma.DeveloperScalarRelationFilter, Prisma.DeveloperWhereInput>;
171
+ }, "id" | "token">;
172
+ export type TokenOrderByWithAggregationInput = {
173
+ id?: Prisma.SortOrder;
174
+ developerId?: Prisma.SortOrder;
175
+ token?: Prisma.SortOrder;
176
+ createdAt?: Prisma.SortOrder;
177
+ lastUsedAt?: Prisma.SortOrderInput | Prisma.SortOrder;
178
+ revokedAt?: Prisma.SortOrderInput | Prisma.SortOrder;
179
+ _count?: Prisma.TokenCountOrderByAggregateInput;
180
+ _max?: Prisma.TokenMaxOrderByAggregateInput;
181
+ _min?: Prisma.TokenMinOrderByAggregateInput;
182
+ };
183
+ export type TokenScalarWhereWithAggregatesInput = {
184
+ AND?: Prisma.TokenScalarWhereWithAggregatesInput | Prisma.TokenScalarWhereWithAggregatesInput[];
185
+ OR?: Prisma.TokenScalarWhereWithAggregatesInput[];
186
+ NOT?: Prisma.TokenScalarWhereWithAggregatesInput | Prisma.TokenScalarWhereWithAggregatesInput[];
187
+ id?: Prisma.StringWithAggregatesFilter<"Token"> | string;
188
+ developerId?: Prisma.StringWithAggregatesFilter<"Token"> | string;
189
+ token?: Prisma.StringWithAggregatesFilter<"Token"> | string;
190
+ createdAt?: Prisma.DateTimeWithAggregatesFilter<"Token"> | Date | string;
191
+ lastUsedAt?: Prisma.DateTimeNullableWithAggregatesFilter<"Token"> | Date | string | null;
192
+ revokedAt?: Prisma.DateTimeNullableWithAggregatesFilter<"Token"> | Date | string | null;
193
+ };
194
+ export type TokenCreateInput = {
195
+ id?: string;
196
+ token: string;
197
+ createdAt?: Date | string;
198
+ lastUsedAt?: Date | string | null;
199
+ revokedAt?: Date | string | null;
200
+ developer: Prisma.DeveloperCreateNestedOneWithoutTokensInput;
201
+ };
202
+ export type TokenUncheckedCreateInput = {
203
+ id?: string;
204
+ developerId: string;
205
+ token: string;
206
+ createdAt?: Date | string;
207
+ lastUsedAt?: Date | string | null;
208
+ revokedAt?: Date | string | null;
209
+ };
210
+ export type TokenUpdateInput = {
211
+ id?: Prisma.StringFieldUpdateOperationsInput | string;
212
+ token?: Prisma.StringFieldUpdateOperationsInput | string;
213
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string;
214
+ lastUsedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null;
215
+ revokedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null;
216
+ developer?: Prisma.DeveloperUpdateOneRequiredWithoutTokensNestedInput;
217
+ };
218
+ export type TokenUncheckedUpdateInput = {
219
+ id?: Prisma.StringFieldUpdateOperationsInput | string;
220
+ developerId?: Prisma.StringFieldUpdateOperationsInput | string;
221
+ token?: Prisma.StringFieldUpdateOperationsInput | string;
222
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string;
223
+ lastUsedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null;
224
+ revokedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null;
225
+ };
226
+ export type TokenCreateManyInput = {
227
+ id?: string;
228
+ developerId: string;
229
+ token: string;
230
+ createdAt?: Date | string;
231
+ lastUsedAt?: Date | string | null;
232
+ revokedAt?: Date | string | null;
233
+ };
234
+ export type TokenUpdateManyMutationInput = {
235
+ id?: Prisma.StringFieldUpdateOperationsInput | string;
236
+ token?: Prisma.StringFieldUpdateOperationsInput | string;
237
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string;
238
+ lastUsedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null;
239
+ revokedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null;
240
+ };
241
+ export type TokenUncheckedUpdateManyInput = {
242
+ id?: Prisma.StringFieldUpdateOperationsInput | string;
243
+ developerId?: Prisma.StringFieldUpdateOperationsInput | string;
244
+ token?: Prisma.StringFieldUpdateOperationsInput | string;
245
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string;
246
+ lastUsedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null;
247
+ revokedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null;
248
+ };
249
+ export type TokenListRelationFilter = {
250
+ every?: Prisma.TokenWhereInput;
251
+ some?: Prisma.TokenWhereInput;
252
+ none?: Prisma.TokenWhereInput;
253
+ };
254
+ export type TokenOrderByRelationAggregateInput = {
255
+ _count?: Prisma.SortOrder;
256
+ };
257
+ export type TokenCountOrderByAggregateInput = {
258
+ id?: Prisma.SortOrder;
259
+ developerId?: Prisma.SortOrder;
260
+ token?: Prisma.SortOrder;
261
+ createdAt?: Prisma.SortOrder;
262
+ lastUsedAt?: Prisma.SortOrder;
263
+ revokedAt?: Prisma.SortOrder;
264
+ };
265
+ export type TokenMaxOrderByAggregateInput = {
266
+ id?: Prisma.SortOrder;
267
+ developerId?: Prisma.SortOrder;
268
+ token?: Prisma.SortOrder;
269
+ createdAt?: Prisma.SortOrder;
270
+ lastUsedAt?: Prisma.SortOrder;
271
+ revokedAt?: Prisma.SortOrder;
272
+ };
273
+ export type TokenMinOrderByAggregateInput = {
274
+ id?: Prisma.SortOrder;
275
+ developerId?: Prisma.SortOrder;
276
+ token?: Prisma.SortOrder;
277
+ createdAt?: Prisma.SortOrder;
278
+ lastUsedAt?: Prisma.SortOrder;
279
+ revokedAt?: Prisma.SortOrder;
280
+ };
281
+ export type TokenCreateNestedManyWithoutDeveloperInput = {
282
+ create?: Prisma.XOR<Prisma.TokenCreateWithoutDeveloperInput, Prisma.TokenUncheckedCreateWithoutDeveloperInput> | Prisma.TokenCreateWithoutDeveloperInput[] | Prisma.TokenUncheckedCreateWithoutDeveloperInput[];
283
+ connectOrCreate?: Prisma.TokenCreateOrConnectWithoutDeveloperInput | Prisma.TokenCreateOrConnectWithoutDeveloperInput[];
284
+ createMany?: Prisma.TokenCreateManyDeveloperInputEnvelope;
285
+ connect?: Prisma.TokenWhereUniqueInput | Prisma.TokenWhereUniqueInput[];
286
+ };
287
+ export type TokenUncheckedCreateNestedManyWithoutDeveloperInput = {
288
+ create?: Prisma.XOR<Prisma.TokenCreateWithoutDeveloperInput, Prisma.TokenUncheckedCreateWithoutDeveloperInput> | Prisma.TokenCreateWithoutDeveloperInput[] | Prisma.TokenUncheckedCreateWithoutDeveloperInput[];
289
+ connectOrCreate?: Prisma.TokenCreateOrConnectWithoutDeveloperInput | Prisma.TokenCreateOrConnectWithoutDeveloperInput[];
290
+ createMany?: Prisma.TokenCreateManyDeveloperInputEnvelope;
291
+ connect?: Prisma.TokenWhereUniqueInput | Prisma.TokenWhereUniqueInput[];
292
+ };
293
+ export type TokenUpdateManyWithoutDeveloperNestedInput = {
294
+ create?: Prisma.XOR<Prisma.TokenCreateWithoutDeveloperInput, Prisma.TokenUncheckedCreateWithoutDeveloperInput> | Prisma.TokenCreateWithoutDeveloperInput[] | Prisma.TokenUncheckedCreateWithoutDeveloperInput[];
295
+ connectOrCreate?: Prisma.TokenCreateOrConnectWithoutDeveloperInput | Prisma.TokenCreateOrConnectWithoutDeveloperInput[];
296
+ upsert?: Prisma.TokenUpsertWithWhereUniqueWithoutDeveloperInput | Prisma.TokenUpsertWithWhereUniqueWithoutDeveloperInput[];
297
+ createMany?: Prisma.TokenCreateManyDeveloperInputEnvelope;
298
+ set?: Prisma.TokenWhereUniqueInput | Prisma.TokenWhereUniqueInput[];
299
+ disconnect?: Prisma.TokenWhereUniqueInput | Prisma.TokenWhereUniqueInput[];
300
+ delete?: Prisma.TokenWhereUniqueInput | Prisma.TokenWhereUniqueInput[];
301
+ connect?: Prisma.TokenWhereUniqueInput | Prisma.TokenWhereUniqueInput[];
302
+ update?: Prisma.TokenUpdateWithWhereUniqueWithoutDeveloperInput | Prisma.TokenUpdateWithWhereUniqueWithoutDeveloperInput[];
303
+ updateMany?: Prisma.TokenUpdateManyWithWhereWithoutDeveloperInput | Prisma.TokenUpdateManyWithWhereWithoutDeveloperInput[];
304
+ deleteMany?: Prisma.TokenScalarWhereInput | Prisma.TokenScalarWhereInput[];
305
+ };
306
+ export type TokenUncheckedUpdateManyWithoutDeveloperNestedInput = {
307
+ create?: Prisma.XOR<Prisma.TokenCreateWithoutDeveloperInput, Prisma.TokenUncheckedCreateWithoutDeveloperInput> | Prisma.TokenCreateWithoutDeveloperInput[] | Prisma.TokenUncheckedCreateWithoutDeveloperInput[];
308
+ connectOrCreate?: Prisma.TokenCreateOrConnectWithoutDeveloperInput | Prisma.TokenCreateOrConnectWithoutDeveloperInput[];
309
+ upsert?: Prisma.TokenUpsertWithWhereUniqueWithoutDeveloperInput | Prisma.TokenUpsertWithWhereUniqueWithoutDeveloperInput[];
310
+ createMany?: Prisma.TokenCreateManyDeveloperInputEnvelope;
311
+ set?: Prisma.TokenWhereUniqueInput | Prisma.TokenWhereUniqueInput[];
312
+ disconnect?: Prisma.TokenWhereUniqueInput | Prisma.TokenWhereUniqueInput[];
313
+ delete?: Prisma.TokenWhereUniqueInput | Prisma.TokenWhereUniqueInput[];
314
+ connect?: Prisma.TokenWhereUniqueInput | Prisma.TokenWhereUniqueInput[];
315
+ update?: Prisma.TokenUpdateWithWhereUniqueWithoutDeveloperInput | Prisma.TokenUpdateWithWhereUniqueWithoutDeveloperInput[];
316
+ updateMany?: Prisma.TokenUpdateManyWithWhereWithoutDeveloperInput | Prisma.TokenUpdateManyWithWhereWithoutDeveloperInput[];
317
+ deleteMany?: Prisma.TokenScalarWhereInput | Prisma.TokenScalarWhereInput[];
318
+ };
319
+ export type NullableDateTimeFieldUpdateOperationsInput = {
320
+ set?: Date | string | null;
321
+ };
322
+ export type TokenCreateWithoutDeveloperInput = {
323
+ id?: string;
324
+ token: string;
325
+ createdAt?: Date | string;
326
+ lastUsedAt?: Date | string | null;
327
+ revokedAt?: Date | string | null;
328
+ };
329
+ export type TokenUncheckedCreateWithoutDeveloperInput = {
330
+ id?: string;
331
+ token: string;
332
+ createdAt?: Date | string;
333
+ lastUsedAt?: Date | string | null;
334
+ revokedAt?: Date | string | null;
335
+ };
336
+ export type TokenCreateOrConnectWithoutDeveloperInput = {
337
+ where: Prisma.TokenWhereUniqueInput;
338
+ create: Prisma.XOR<Prisma.TokenCreateWithoutDeveloperInput, Prisma.TokenUncheckedCreateWithoutDeveloperInput>;
339
+ };
340
+ export type TokenCreateManyDeveloperInputEnvelope = {
341
+ data: Prisma.TokenCreateManyDeveloperInput | Prisma.TokenCreateManyDeveloperInput[];
342
+ skipDuplicates?: boolean;
343
+ };
344
+ export type TokenUpsertWithWhereUniqueWithoutDeveloperInput = {
345
+ where: Prisma.TokenWhereUniqueInput;
346
+ update: Prisma.XOR<Prisma.TokenUpdateWithoutDeveloperInput, Prisma.TokenUncheckedUpdateWithoutDeveloperInput>;
347
+ create: Prisma.XOR<Prisma.TokenCreateWithoutDeveloperInput, Prisma.TokenUncheckedCreateWithoutDeveloperInput>;
348
+ };
349
+ export type TokenUpdateWithWhereUniqueWithoutDeveloperInput = {
350
+ where: Prisma.TokenWhereUniqueInput;
351
+ data: Prisma.XOR<Prisma.TokenUpdateWithoutDeveloperInput, Prisma.TokenUncheckedUpdateWithoutDeveloperInput>;
352
+ };
353
+ export type TokenUpdateManyWithWhereWithoutDeveloperInput = {
354
+ where: Prisma.TokenScalarWhereInput;
355
+ data: Prisma.XOR<Prisma.TokenUpdateManyMutationInput, Prisma.TokenUncheckedUpdateManyWithoutDeveloperInput>;
356
+ };
357
+ export type TokenScalarWhereInput = {
358
+ AND?: Prisma.TokenScalarWhereInput | Prisma.TokenScalarWhereInput[];
359
+ OR?: Prisma.TokenScalarWhereInput[];
360
+ NOT?: Prisma.TokenScalarWhereInput | Prisma.TokenScalarWhereInput[];
361
+ id?: Prisma.StringFilter<"Token"> | string;
362
+ developerId?: Prisma.StringFilter<"Token"> | string;
363
+ token?: Prisma.StringFilter<"Token"> | string;
364
+ createdAt?: Prisma.DateTimeFilter<"Token"> | Date | string;
365
+ lastUsedAt?: Prisma.DateTimeNullableFilter<"Token"> | Date | string | null;
366
+ revokedAt?: Prisma.DateTimeNullableFilter<"Token"> | Date | string | null;
367
+ };
368
+ export type TokenCreateManyDeveloperInput = {
369
+ id?: string;
370
+ token: string;
371
+ createdAt?: Date | string;
372
+ lastUsedAt?: Date | string | null;
373
+ revokedAt?: Date | string | null;
374
+ };
375
+ export type TokenUpdateWithoutDeveloperInput = {
376
+ id?: Prisma.StringFieldUpdateOperationsInput | string;
377
+ token?: Prisma.StringFieldUpdateOperationsInput | string;
378
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string;
379
+ lastUsedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null;
380
+ revokedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null;
381
+ };
382
+ export type TokenUncheckedUpdateWithoutDeveloperInput = {
383
+ id?: Prisma.StringFieldUpdateOperationsInput | string;
384
+ token?: Prisma.StringFieldUpdateOperationsInput | string;
385
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string;
386
+ lastUsedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null;
387
+ revokedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null;
388
+ };
389
+ export type TokenUncheckedUpdateManyWithoutDeveloperInput = {
390
+ id?: Prisma.StringFieldUpdateOperationsInput | string;
391
+ token?: Prisma.StringFieldUpdateOperationsInput | string;
392
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string;
393
+ lastUsedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null;
394
+ revokedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null;
395
+ };
396
+ export type TokenSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
397
+ id?: boolean;
398
+ developerId?: boolean;
399
+ token?: boolean;
400
+ createdAt?: boolean;
401
+ lastUsedAt?: boolean;
402
+ revokedAt?: boolean;
403
+ developer?: boolean | Prisma.DeveloperDefaultArgs<ExtArgs>;
404
+ }, ExtArgs["result"]["token"]>;
405
+ export type TokenSelectCreateManyAndReturn<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
406
+ id?: boolean;
407
+ developerId?: boolean;
408
+ token?: boolean;
409
+ createdAt?: boolean;
410
+ lastUsedAt?: boolean;
411
+ revokedAt?: boolean;
412
+ developer?: boolean | Prisma.DeveloperDefaultArgs<ExtArgs>;
413
+ }, ExtArgs["result"]["token"]>;
414
+ export type TokenSelectUpdateManyAndReturn<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
415
+ id?: boolean;
416
+ developerId?: boolean;
417
+ token?: boolean;
418
+ createdAt?: boolean;
419
+ lastUsedAt?: boolean;
420
+ revokedAt?: boolean;
421
+ developer?: boolean | Prisma.DeveloperDefaultArgs<ExtArgs>;
422
+ }, ExtArgs["result"]["token"]>;
423
+ export type TokenSelectScalar = {
424
+ id?: boolean;
425
+ developerId?: boolean;
426
+ token?: boolean;
427
+ createdAt?: boolean;
428
+ lastUsedAt?: boolean;
429
+ revokedAt?: boolean;
430
+ };
431
+ export type TokenOmit<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetOmit<"id" | "developerId" | "token" | "createdAt" | "lastUsedAt" | "revokedAt", ExtArgs["result"]["token"]>;
432
+ export type TokenInclude<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
433
+ developer?: boolean | Prisma.DeveloperDefaultArgs<ExtArgs>;
434
+ };
435
+ export type TokenIncludeCreateManyAndReturn<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
436
+ developer?: boolean | Prisma.DeveloperDefaultArgs<ExtArgs>;
437
+ };
438
+ export type TokenIncludeUpdateManyAndReturn<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
439
+ developer?: boolean | Prisma.DeveloperDefaultArgs<ExtArgs>;
440
+ };
441
+ export type $TokenPayload<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
442
+ name: "Token";
443
+ objects: {
444
+ developer: Prisma.$DeveloperPayload<ExtArgs>;
445
+ };
446
+ scalars: runtime.Types.Extensions.GetPayloadResult<{
447
+ id: string;
448
+ developerId: string;
449
+ token: string;
450
+ createdAt: Date;
451
+ lastUsedAt: Date | null;
452
+ revokedAt: Date | null;
453
+ }, ExtArgs["result"]["token"]>;
454
+ composites: {};
455
+ };
456
+ export type TokenGetPayload<S extends boolean | null | undefined | TokenDefaultArgs> = runtime.Types.Result.GetResult<Prisma.$TokenPayload, S>;
457
+ export type TokenCountArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = Omit<TokenFindManyArgs, 'select' | 'include' | 'distinct' | 'omit'> & {
458
+ select?: TokenCountAggregateInputType | true;
459
+ };
460
+ export interface TokenDelegate<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs, GlobalOmitOptions = {}> {
461
+ [K: symbol]: {
462
+ types: Prisma.TypeMap<ExtArgs>['model']['Token'];
463
+ meta: {
464
+ name: 'Token';
465
+ };
466
+ };
467
+ /**
468
+ * Find zero or one Token that matches the filter.
469
+ * @param {TokenFindUniqueArgs} args - Arguments to find a Token
470
+ * @example
471
+ * // Get one Token
472
+ * const token = await prisma.token.findUnique({
473
+ * where: {
474
+ * // ... provide filter here
475
+ * }
476
+ * })
477
+ */
478
+ findUnique<T extends TokenFindUniqueArgs>(args: Prisma.SelectSubset<T, TokenFindUniqueArgs<ExtArgs>>): Prisma.Prisma__TokenClient<runtime.Types.Result.GetResult<Prisma.$TokenPayload<ExtArgs>, T, "findUnique", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>;
479
+ /**
480
+ * Find one Token that matches the filter or throw an error with `error.code='P2025'`
481
+ * if no matches were found.
482
+ * @param {TokenFindUniqueOrThrowArgs} args - Arguments to find a Token
483
+ * @example
484
+ * // Get one Token
485
+ * const token = await prisma.token.findUniqueOrThrow({
486
+ * where: {
487
+ * // ... provide filter here
488
+ * }
489
+ * })
490
+ */
491
+ findUniqueOrThrow<T extends TokenFindUniqueOrThrowArgs>(args: Prisma.SelectSubset<T, TokenFindUniqueOrThrowArgs<ExtArgs>>): Prisma.Prisma__TokenClient<runtime.Types.Result.GetResult<Prisma.$TokenPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>;
492
+ /**
493
+ * Find the first Token that matches the filter.
494
+ * Note, that providing `undefined` is treated as the value not being there.
495
+ * Read more here: https://pris.ly/d/null-undefined
496
+ * @param {TokenFindFirstArgs} args - Arguments to find a Token
497
+ * @example
498
+ * // Get one Token
499
+ * const token = await prisma.token.findFirst({
500
+ * where: {
501
+ * // ... provide filter here
502
+ * }
503
+ * })
504
+ */
505
+ findFirst<T extends TokenFindFirstArgs>(args?: Prisma.SelectSubset<T, TokenFindFirstArgs<ExtArgs>>): Prisma.Prisma__TokenClient<runtime.Types.Result.GetResult<Prisma.$TokenPayload<ExtArgs>, T, "findFirst", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>;
506
+ /**
507
+ * Find the first Token that matches the filter or
508
+ * throw `PrismaKnownClientError` with `P2025` code if no matches were found.
509
+ * Note, that providing `undefined` is treated as the value not being there.
510
+ * Read more here: https://pris.ly/d/null-undefined
511
+ * @param {TokenFindFirstOrThrowArgs} args - Arguments to find a Token
512
+ * @example
513
+ * // Get one Token
514
+ * const token = await prisma.token.findFirstOrThrow({
515
+ * where: {
516
+ * // ... provide filter here
517
+ * }
518
+ * })
519
+ */
520
+ findFirstOrThrow<T extends TokenFindFirstOrThrowArgs>(args?: Prisma.SelectSubset<T, TokenFindFirstOrThrowArgs<ExtArgs>>): Prisma.Prisma__TokenClient<runtime.Types.Result.GetResult<Prisma.$TokenPayload<ExtArgs>, T, "findFirstOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>;
521
+ /**
522
+ * Find zero or more Tokens that matches the filter.
523
+ * Note, that providing `undefined` is treated as the value not being there.
524
+ * Read more here: https://pris.ly/d/null-undefined
525
+ * @param {TokenFindManyArgs} args - Arguments to filter and select certain fields only.
526
+ * @example
527
+ * // Get all Tokens
528
+ * const tokens = await prisma.token.findMany()
529
+ *
530
+ * // Get first 10 Tokens
531
+ * const tokens = await prisma.token.findMany({ take: 10 })
532
+ *
533
+ * // Only select the `id`
534
+ * const tokenWithIdOnly = await prisma.token.findMany({ select: { id: true } })
535
+ *
536
+ */
537
+ findMany<T extends TokenFindManyArgs>(args?: Prisma.SelectSubset<T, TokenFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$TokenPayload<ExtArgs>, T, "findMany", GlobalOmitOptions>>;
538
+ /**
539
+ * Create a Token.
540
+ * @param {TokenCreateArgs} args - Arguments to create a Token.
541
+ * @example
542
+ * // Create one Token
543
+ * const Token = await prisma.token.create({
544
+ * data: {
545
+ * // ... data to create a Token
546
+ * }
547
+ * })
548
+ *
549
+ */
550
+ create<T extends TokenCreateArgs>(args: Prisma.SelectSubset<T, TokenCreateArgs<ExtArgs>>): Prisma.Prisma__TokenClient<runtime.Types.Result.GetResult<Prisma.$TokenPayload<ExtArgs>, T, "create", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>;
551
+ /**
552
+ * Create many Tokens.
553
+ * @param {TokenCreateManyArgs} args - Arguments to create many Tokens.
554
+ * @example
555
+ * // Create many Tokens
556
+ * const token = await prisma.token.createMany({
557
+ * data: [
558
+ * // ... provide data here
559
+ * ]
560
+ * })
561
+ *
562
+ */
563
+ createMany<T extends TokenCreateManyArgs>(args?: Prisma.SelectSubset<T, TokenCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<Prisma.BatchPayload>;
564
+ /**
565
+ * Create many Tokens and returns the data saved in the database.
566
+ * @param {TokenCreateManyAndReturnArgs} args - Arguments to create many Tokens.
567
+ * @example
568
+ * // Create many Tokens
569
+ * const token = await prisma.token.createManyAndReturn({
570
+ * data: [
571
+ * // ... provide data here
572
+ * ]
573
+ * })
574
+ *
575
+ * // Create many Tokens and only return the `id`
576
+ * const tokenWithIdOnly = await prisma.token.createManyAndReturn({
577
+ * select: { id: true },
578
+ * data: [
579
+ * // ... provide data here
580
+ * ]
581
+ * })
582
+ * Note, that providing `undefined` is treated as the value not being there.
583
+ * Read more here: https://pris.ly/d/null-undefined
584
+ *
585
+ */
586
+ createManyAndReturn<T extends TokenCreateManyAndReturnArgs>(args?: Prisma.SelectSubset<T, TokenCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$TokenPayload<ExtArgs>, T, "createManyAndReturn", GlobalOmitOptions>>;
587
+ /**
588
+ * Delete a Token.
589
+ * @param {TokenDeleteArgs} args - Arguments to delete one Token.
590
+ * @example
591
+ * // Delete one Token
592
+ * const Token = await prisma.token.delete({
593
+ * where: {
594
+ * // ... filter to delete one Token
595
+ * }
596
+ * })
597
+ *
598
+ */
599
+ delete<T extends TokenDeleteArgs>(args: Prisma.SelectSubset<T, TokenDeleteArgs<ExtArgs>>): Prisma.Prisma__TokenClient<runtime.Types.Result.GetResult<Prisma.$TokenPayload<ExtArgs>, T, "delete", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>;
600
+ /**
601
+ * Update one Token.
602
+ * @param {TokenUpdateArgs} args - Arguments to update one Token.
603
+ * @example
604
+ * // Update one Token
605
+ * const token = await prisma.token.update({
606
+ * where: {
607
+ * // ... provide filter here
608
+ * },
609
+ * data: {
610
+ * // ... provide data here
611
+ * }
612
+ * })
613
+ *
614
+ */
615
+ update<T extends TokenUpdateArgs>(args: Prisma.SelectSubset<T, TokenUpdateArgs<ExtArgs>>): Prisma.Prisma__TokenClient<runtime.Types.Result.GetResult<Prisma.$TokenPayload<ExtArgs>, T, "update", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>;
616
+ /**
617
+ * Delete zero or more Tokens.
618
+ * @param {TokenDeleteManyArgs} args - Arguments to filter Tokens to delete.
619
+ * @example
620
+ * // Delete a few Tokens
621
+ * const { count } = await prisma.token.deleteMany({
622
+ * where: {
623
+ * // ... provide filter here
624
+ * }
625
+ * })
626
+ *
627
+ */
628
+ deleteMany<T extends TokenDeleteManyArgs>(args?: Prisma.SelectSubset<T, TokenDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<Prisma.BatchPayload>;
629
+ /**
630
+ * Update zero or more Tokens.
631
+ * Note, that providing `undefined` is treated as the value not being there.
632
+ * Read more here: https://pris.ly/d/null-undefined
633
+ * @param {TokenUpdateManyArgs} args - Arguments to update one or more rows.
634
+ * @example
635
+ * // Update many Tokens
636
+ * const token = await prisma.token.updateMany({
637
+ * where: {
638
+ * // ... provide filter here
639
+ * },
640
+ * data: {
641
+ * // ... provide data here
642
+ * }
643
+ * })
644
+ *
645
+ */
646
+ updateMany<T extends TokenUpdateManyArgs>(args: Prisma.SelectSubset<T, TokenUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<Prisma.BatchPayload>;
647
+ /**
648
+ * Update zero or more Tokens and returns the data updated in the database.
649
+ * @param {TokenUpdateManyAndReturnArgs} args - Arguments to update many Tokens.
650
+ * @example
651
+ * // Update many Tokens
652
+ * const token = await prisma.token.updateManyAndReturn({
653
+ * where: {
654
+ * // ... provide filter here
655
+ * },
656
+ * data: [
657
+ * // ... provide data here
658
+ * ]
659
+ * })
660
+ *
661
+ * // Update zero or more Tokens and only return the `id`
662
+ * const tokenWithIdOnly = await prisma.token.updateManyAndReturn({
663
+ * select: { id: true },
664
+ * where: {
665
+ * // ... provide filter here
666
+ * },
667
+ * data: [
668
+ * // ... provide data here
669
+ * ]
670
+ * })
671
+ * Note, that providing `undefined` is treated as the value not being there.
672
+ * Read more here: https://pris.ly/d/null-undefined
673
+ *
674
+ */
675
+ updateManyAndReturn<T extends TokenUpdateManyAndReturnArgs>(args: Prisma.SelectSubset<T, TokenUpdateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$TokenPayload<ExtArgs>, T, "updateManyAndReturn", GlobalOmitOptions>>;
676
+ /**
677
+ * Create or update one Token.
678
+ * @param {TokenUpsertArgs} args - Arguments to update or create a Token.
679
+ * @example
680
+ * // Update or create a Token
681
+ * const token = await prisma.token.upsert({
682
+ * create: {
683
+ * // ... data to create a Token
684
+ * },
685
+ * update: {
686
+ * // ... in case it already exists, update
687
+ * },
688
+ * where: {
689
+ * // ... the filter for the Token we want to update
690
+ * }
691
+ * })
692
+ */
693
+ upsert<T extends TokenUpsertArgs>(args: Prisma.SelectSubset<T, TokenUpsertArgs<ExtArgs>>): Prisma.Prisma__TokenClient<runtime.Types.Result.GetResult<Prisma.$TokenPayload<ExtArgs>, T, "upsert", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>;
694
+ /**
695
+ * Count the number of Tokens.
696
+ * Note, that providing `undefined` is treated as the value not being there.
697
+ * Read more here: https://pris.ly/d/null-undefined
698
+ * @param {TokenCountArgs} args - Arguments to filter Tokens to count.
699
+ * @example
700
+ * // Count the number of Tokens
701
+ * const count = await prisma.token.count({
702
+ * where: {
703
+ * // ... the filter for the Tokens we want to count
704
+ * }
705
+ * })
706
+ **/
707
+ count<T extends TokenCountArgs>(args?: Prisma.Subset<T, TokenCountArgs>): Prisma.PrismaPromise<T extends runtime.Types.Utils.Record<'select', any> ? T['select'] extends true ? number : Prisma.GetScalarType<T['select'], TokenCountAggregateOutputType> : number>;
708
+ /**
709
+ * Allows you to perform aggregations operations on a Token.
710
+ * Note, that providing `undefined` is treated as the value not being there.
711
+ * Read more here: https://pris.ly/d/null-undefined
712
+ * @param {TokenAggregateArgs} args - Select which aggregations you would like to apply and on what fields.
713
+ * @example
714
+ * // Ordered by age ascending
715
+ * // Where email contains prisma.io
716
+ * // Limited to the 10 users
717
+ * const aggregations = await prisma.user.aggregate({
718
+ * _avg: {
719
+ * age: true,
720
+ * },
721
+ * where: {
722
+ * email: {
723
+ * contains: "prisma.io",
724
+ * },
725
+ * },
726
+ * orderBy: {
727
+ * age: "asc",
728
+ * },
729
+ * take: 10,
730
+ * })
731
+ **/
732
+ aggregate<T extends TokenAggregateArgs>(args: Prisma.Subset<T, TokenAggregateArgs>): Prisma.PrismaPromise<GetTokenAggregateType<T>>;
733
+ /**
734
+ * Group by Token.
735
+ * Note, that providing `undefined` is treated as the value not being there.
736
+ * Read more here: https://pris.ly/d/null-undefined
737
+ * @param {TokenGroupByArgs} args - Group by arguments.
738
+ * @example
739
+ * // Group by city, order by createdAt, get count
740
+ * const result = await prisma.user.groupBy({
741
+ * by: ['city', 'createdAt'],
742
+ * orderBy: {
743
+ * createdAt: true
744
+ * },
745
+ * _count: {
746
+ * _all: true
747
+ * },
748
+ * })
749
+ *
750
+ **/
751
+ groupBy<T extends TokenGroupByArgs, HasSelectOrTake extends Prisma.Or<Prisma.Extends<'skip', Prisma.Keys<T>>, Prisma.Extends<'take', Prisma.Keys<T>>>, OrderByArg extends Prisma.True extends HasSelectOrTake ? {
752
+ orderBy: TokenGroupByArgs['orderBy'];
753
+ } : {
754
+ orderBy?: TokenGroupByArgs['orderBy'];
755
+ }, OrderFields extends Prisma.ExcludeUnderscoreKeys<Prisma.Keys<Prisma.MaybeTupleToUnion<T['orderBy']>>>, ByFields extends Prisma.MaybeTupleToUnion<T['by']>, ByValid extends Prisma.Has<ByFields, OrderFields>, HavingFields extends Prisma.GetHavingFields<T['having']>, HavingValid extends Prisma.Has<ByFields, HavingFields>, ByEmpty extends T['by'] extends never[] ? Prisma.True : Prisma.False, InputErrors extends ByEmpty extends Prisma.True ? `Error: "by" must not be empty.` : HavingValid extends Prisma.False ? {
756
+ [P in HavingFields]: P extends ByFields ? never : P extends string ? `Error: Field "${P}" used in "having" needs to be provided in "by".` : [
757
+ Error,
758
+ 'Field ',
759
+ P,
760
+ ` in "having" needs to be provided in "by"`
761
+ ];
762
+ }[HavingFields] : 'take' extends Prisma.Keys<T> ? 'orderBy' extends Prisma.Keys<T> ? ByValid extends Prisma.True ? {} : {
763
+ [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`;
764
+ }[OrderFields] : 'Error: If you provide "take", you also need to provide "orderBy"' : 'skip' extends Prisma.Keys<T> ? 'orderBy' extends Prisma.Keys<T> ? ByValid extends Prisma.True ? {} : {
765
+ [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`;
766
+ }[OrderFields] : 'Error: If you provide "skip", you also need to provide "orderBy"' : ByValid extends Prisma.True ? {} : {
767
+ [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`;
768
+ }[OrderFields]>(args: Prisma.SubsetIntersection<T, TokenGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetTokenGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>;
769
+ /**
770
+ * Fields of the Token model
771
+ */
772
+ readonly fields: TokenFieldRefs;
773
+ }
774
+ /**
775
+ * The delegate class that acts as a "Promise-like" for Token.
776
+ * Why is this prefixed with `Prisma__`?
777
+ * Because we want to prevent naming conflicts as mentioned in
778
+ * https://github.com/prisma/prisma-client-js/issues/707
779
+ */
780
+ export interface Prisma__TokenClient<T, Null = never, ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs, GlobalOmitOptions = {}> extends Prisma.PrismaPromise<T> {
781
+ readonly [Symbol.toStringTag]: "PrismaPromise";
782
+ developer<T extends Prisma.DeveloperDefaultArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.DeveloperDefaultArgs<ExtArgs>>): Prisma.Prisma__DeveloperClient<runtime.Types.Result.GetResult<Prisma.$DeveloperPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | Null, Null, ExtArgs, GlobalOmitOptions>;
783
+ /**
784
+ * Attaches callbacks for the resolution and/or rejection of the Promise.
785
+ * @param onfulfilled The callback to execute when the Promise is resolved.
786
+ * @param onrejected The callback to execute when the Promise is rejected.
787
+ * @returns A Promise for the completion of which ever callback is executed.
788
+ */
789
+ then<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): runtime.Types.Utils.JsPromise<TResult1 | TResult2>;
790
+ /**
791
+ * Attaches a callback for only the rejection of the Promise.
792
+ * @param onrejected The callback to execute when the Promise is rejected.
793
+ * @returns A Promise for the completion of the callback.
794
+ */
795
+ catch<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): runtime.Types.Utils.JsPromise<T | TResult>;
796
+ /**
797
+ * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The
798
+ * resolved value cannot be modified from the callback.
799
+ * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected).
800
+ * @returns A Promise for the completion of the callback.
801
+ */
802
+ finally(onfinally?: (() => void) | undefined | null): runtime.Types.Utils.JsPromise<T>;
803
+ }
804
+ /**
805
+ * Fields of the Token model
806
+ */
807
+ export interface TokenFieldRefs {
808
+ readonly id: Prisma.FieldRef<"Token", 'String'>;
809
+ readonly developerId: Prisma.FieldRef<"Token", 'String'>;
810
+ readonly token: Prisma.FieldRef<"Token", 'String'>;
811
+ readonly createdAt: Prisma.FieldRef<"Token", 'DateTime'>;
812
+ readonly lastUsedAt: Prisma.FieldRef<"Token", 'DateTime'>;
813
+ readonly revokedAt: Prisma.FieldRef<"Token", 'DateTime'>;
814
+ }
815
+ /**
816
+ * Token findUnique
817
+ */
818
+ export type TokenFindUniqueArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
819
+ /**
820
+ * Select specific fields to fetch from the Token
821
+ */
822
+ select?: Prisma.TokenSelect<ExtArgs> | null;
823
+ /**
824
+ * Omit specific fields from the Token
825
+ */
826
+ omit?: Prisma.TokenOmit<ExtArgs> | null;
827
+ /**
828
+ * Choose, which related nodes to fetch as well
829
+ */
830
+ include?: Prisma.TokenInclude<ExtArgs> | null;
831
+ /**
832
+ * Filter, which Token to fetch.
833
+ */
834
+ where: Prisma.TokenWhereUniqueInput;
835
+ };
836
+ /**
837
+ * Token findUniqueOrThrow
838
+ */
839
+ export type TokenFindUniqueOrThrowArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
840
+ /**
841
+ * Select specific fields to fetch from the Token
842
+ */
843
+ select?: Prisma.TokenSelect<ExtArgs> | null;
844
+ /**
845
+ * Omit specific fields from the Token
846
+ */
847
+ omit?: Prisma.TokenOmit<ExtArgs> | null;
848
+ /**
849
+ * Choose, which related nodes to fetch as well
850
+ */
851
+ include?: Prisma.TokenInclude<ExtArgs> | null;
852
+ /**
853
+ * Filter, which Token to fetch.
854
+ */
855
+ where: Prisma.TokenWhereUniqueInput;
856
+ };
857
+ /**
858
+ * Token findFirst
859
+ */
860
+ export type TokenFindFirstArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
861
+ /**
862
+ * Select specific fields to fetch from the Token
863
+ */
864
+ select?: Prisma.TokenSelect<ExtArgs> | null;
865
+ /**
866
+ * Omit specific fields from the Token
867
+ */
868
+ omit?: Prisma.TokenOmit<ExtArgs> | null;
869
+ /**
870
+ * Choose, which related nodes to fetch as well
871
+ */
872
+ include?: Prisma.TokenInclude<ExtArgs> | null;
873
+ /**
874
+ * Filter, which Token to fetch.
875
+ */
876
+ where?: Prisma.TokenWhereInput;
877
+ /**
878
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
879
+ *
880
+ * Determine the order of Tokens to fetch.
881
+ */
882
+ orderBy?: Prisma.TokenOrderByWithRelationInput | Prisma.TokenOrderByWithRelationInput[];
883
+ /**
884
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
885
+ *
886
+ * Sets the position for searching for Tokens.
887
+ */
888
+ cursor?: Prisma.TokenWhereUniqueInput;
889
+ /**
890
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
891
+ *
892
+ * Take `±n` Tokens from the position of the cursor.
893
+ */
894
+ take?: number;
895
+ /**
896
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
897
+ *
898
+ * Skip the first `n` Tokens.
899
+ */
900
+ skip?: number;
901
+ /**
902
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
903
+ *
904
+ * Filter by unique combinations of Tokens.
905
+ */
906
+ distinct?: Prisma.TokenScalarFieldEnum | Prisma.TokenScalarFieldEnum[];
907
+ };
908
+ /**
909
+ * Token findFirstOrThrow
910
+ */
911
+ export type TokenFindFirstOrThrowArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
912
+ /**
913
+ * Select specific fields to fetch from the Token
914
+ */
915
+ select?: Prisma.TokenSelect<ExtArgs> | null;
916
+ /**
917
+ * Omit specific fields from the Token
918
+ */
919
+ omit?: Prisma.TokenOmit<ExtArgs> | null;
920
+ /**
921
+ * Choose, which related nodes to fetch as well
922
+ */
923
+ include?: Prisma.TokenInclude<ExtArgs> | null;
924
+ /**
925
+ * Filter, which Token to fetch.
926
+ */
927
+ where?: Prisma.TokenWhereInput;
928
+ /**
929
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
930
+ *
931
+ * Determine the order of Tokens to fetch.
932
+ */
933
+ orderBy?: Prisma.TokenOrderByWithRelationInput | Prisma.TokenOrderByWithRelationInput[];
934
+ /**
935
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
936
+ *
937
+ * Sets the position for searching for Tokens.
938
+ */
939
+ cursor?: Prisma.TokenWhereUniqueInput;
940
+ /**
941
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
942
+ *
943
+ * Take `±n` Tokens from the position of the cursor.
944
+ */
945
+ take?: number;
946
+ /**
947
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
948
+ *
949
+ * Skip the first `n` Tokens.
950
+ */
951
+ skip?: number;
952
+ /**
953
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
954
+ *
955
+ * Filter by unique combinations of Tokens.
956
+ */
957
+ distinct?: Prisma.TokenScalarFieldEnum | Prisma.TokenScalarFieldEnum[];
958
+ };
959
+ /**
960
+ * Token findMany
961
+ */
962
+ export type TokenFindManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
963
+ /**
964
+ * Select specific fields to fetch from the Token
965
+ */
966
+ select?: Prisma.TokenSelect<ExtArgs> | null;
967
+ /**
968
+ * Omit specific fields from the Token
969
+ */
970
+ omit?: Prisma.TokenOmit<ExtArgs> | null;
971
+ /**
972
+ * Choose, which related nodes to fetch as well
973
+ */
974
+ include?: Prisma.TokenInclude<ExtArgs> | null;
975
+ /**
976
+ * Filter, which Tokens to fetch.
977
+ */
978
+ where?: Prisma.TokenWhereInput;
979
+ /**
980
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
981
+ *
982
+ * Determine the order of Tokens to fetch.
983
+ */
984
+ orderBy?: Prisma.TokenOrderByWithRelationInput | Prisma.TokenOrderByWithRelationInput[];
985
+ /**
986
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
987
+ *
988
+ * Sets the position for listing Tokens.
989
+ */
990
+ cursor?: Prisma.TokenWhereUniqueInput;
991
+ /**
992
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
993
+ *
994
+ * Take `±n` Tokens from the position of the cursor.
995
+ */
996
+ take?: number;
997
+ /**
998
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
999
+ *
1000
+ * Skip the first `n` Tokens.
1001
+ */
1002
+ skip?: number;
1003
+ /**
1004
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
1005
+ *
1006
+ * Filter by unique combinations of Tokens.
1007
+ */
1008
+ distinct?: Prisma.TokenScalarFieldEnum | Prisma.TokenScalarFieldEnum[];
1009
+ };
1010
+ /**
1011
+ * Token create
1012
+ */
1013
+ export type TokenCreateArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1014
+ /**
1015
+ * Select specific fields to fetch from the Token
1016
+ */
1017
+ select?: Prisma.TokenSelect<ExtArgs> | null;
1018
+ /**
1019
+ * Omit specific fields from the Token
1020
+ */
1021
+ omit?: Prisma.TokenOmit<ExtArgs> | null;
1022
+ /**
1023
+ * Choose, which related nodes to fetch as well
1024
+ */
1025
+ include?: Prisma.TokenInclude<ExtArgs> | null;
1026
+ /**
1027
+ * The data needed to create a Token.
1028
+ */
1029
+ data: Prisma.XOR<Prisma.TokenCreateInput, Prisma.TokenUncheckedCreateInput>;
1030
+ };
1031
+ /**
1032
+ * Token createMany
1033
+ */
1034
+ export type TokenCreateManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1035
+ /**
1036
+ * The data used to create many Tokens.
1037
+ */
1038
+ data: Prisma.TokenCreateManyInput | Prisma.TokenCreateManyInput[];
1039
+ skipDuplicates?: boolean;
1040
+ };
1041
+ /**
1042
+ * Token createManyAndReturn
1043
+ */
1044
+ export type TokenCreateManyAndReturnArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1045
+ /**
1046
+ * Select specific fields to fetch from the Token
1047
+ */
1048
+ select?: Prisma.TokenSelectCreateManyAndReturn<ExtArgs> | null;
1049
+ /**
1050
+ * Omit specific fields from the Token
1051
+ */
1052
+ omit?: Prisma.TokenOmit<ExtArgs> | null;
1053
+ /**
1054
+ * The data used to create many Tokens.
1055
+ */
1056
+ data: Prisma.TokenCreateManyInput | Prisma.TokenCreateManyInput[];
1057
+ skipDuplicates?: boolean;
1058
+ /**
1059
+ * Choose, which related nodes to fetch as well
1060
+ */
1061
+ include?: Prisma.TokenIncludeCreateManyAndReturn<ExtArgs> | null;
1062
+ };
1063
+ /**
1064
+ * Token update
1065
+ */
1066
+ export type TokenUpdateArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1067
+ /**
1068
+ * Select specific fields to fetch from the Token
1069
+ */
1070
+ select?: Prisma.TokenSelect<ExtArgs> | null;
1071
+ /**
1072
+ * Omit specific fields from the Token
1073
+ */
1074
+ omit?: Prisma.TokenOmit<ExtArgs> | null;
1075
+ /**
1076
+ * Choose, which related nodes to fetch as well
1077
+ */
1078
+ include?: Prisma.TokenInclude<ExtArgs> | null;
1079
+ /**
1080
+ * The data needed to update a Token.
1081
+ */
1082
+ data: Prisma.XOR<Prisma.TokenUpdateInput, Prisma.TokenUncheckedUpdateInput>;
1083
+ /**
1084
+ * Choose, which Token to update.
1085
+ */
1086
+ where: Prisma.TokenWhereUniqueInput;
1087
+ };
1088
+ /**
1089
+ * Token updateMany
1090
+ */
1091
+ export type TokenUpdateManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1092
+ /**
1093
+ * The data used to update Tokens.
1094
+ */
1095
+ data: Prisma.XOR<Prisma.TokenUpdateManyMutationInput, Prisma.TokenUncheckedUpdateManyInput>;
1096
+ /**
1097
+ * Filter which Tokens to update
1098
+ */
1099
+ where?: Prisma.TokenWhereInput;
1100
+ /**
1101
+ * Limit how many Tokens to update.
1102
+ */
1103
+ limit?: number;
1104
+ };
1105
+ /**
1106
+ * Token updateManyAndReturn
1107
+ */
1108
+ export type TokenUpdateManyAndReturnArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1109
+ /**
1110
+ * Select specific fields to fetch from the Token
1111
+ */
1112
+ select?: Prisma.TokenSelectUpdateManyAndReturn<ExtArgs> | null;
1113
+ /**
1114
+ * Omit specific fields from the Token
1115
+ */
1116
+ omit?: Prisma.TokenOmit<ExtArgs> | null;
1117
+ /**
1118
+ * The data used to update Tokens.
1119
+ */
1120
+ data: Prisma.XOR<Prisma.TokenUpdateManyMutationInput, Prisma.TokenUncheckedUpdateManyInput>;
1121
+ /**
1122
+ * Filter which Tokens to update
1123
+ */
1124
+ where?: Prisma.TokenWhereInput;
1125
+ /**
1126
+ * Limit how many Tokens to update.
1127
+ */
1128
+ limit?: number;
1129
+ /**
1130
+ * Choose, which related nodes to fetch as well
1131
+ */
1132
+ include?: Prisma.TokenIncludeUpdateManyAndReturn<ExtArgs> | null;
1133
+ };
1134
+ /**
1135
+ * Token upsert
1136
+ */
1137
+ export type TokenUpsertArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1138
+ /**
1139
+ * Select specific fields to fetch from the Token
1140
+ */
1141
+ select?: Prisma.TokenSelect<ExtArgs> | null;
1142
+ /**
1143
+ * Omit specific fields from the Token
1144
+ */
1145
+ omit?: Prisma.TokenOmit<ExtArgs> | null;
1146
+ /**
1147
+ * Choose, which related nodes to fetch as well
1148
+ */
1149
+ include?: Prisma.TokenInclude<ExtArgs> | null;
1150
+ /**
1151
+ * The filter to search for the Token to update in case it exists.
1152
+ */
1153
+ where: Prisma.TokenWhereUniqueInput;
1154
+ /**
1155
+ * In case the Token found by the `where` argument doesn't exist, create a new Token with this data.
1156
+ */
1157
+ create: Prisma.XOR<Prisma.TokenCreateInput, Prisma.TokenUncheckedCreateInput>;
1158
+ /**
1159
+ * In case the Token was found with the provided `where` argument, update it with this data.
1160
+ */
1161
+ update: Prisma.XOR<Prisma.TokenUpdateInput, Prisma.TokenUncheckedUpdateInput>;
1162
+ };
1163
+ /**
1164
+ * Token delete
1165
+ */
1166
+ export type TokenDeleteArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1167
+ /**
1168
+ * Select specific fields to fetch from the Token
1169
+ */
1170
+ select?: Prisma.TokenSelect<ExtArgs> | null;
1171
+ /**
1172
+ * Omit specific fields from the Token
1173
+ */
1174
+ omit?: Prisma.TokenOmit<ExtArgs> | null;
1175
+ /**
1176
+ * Choose, which related nodes to fetch as well
1177
+ */
1178
+ include?: Prisma.TokenInclude<ExtArgs> | null;
1179
+ /**
1180
+ * Filter which Token to delete.
1181
+ */
1182
+ where: Prisma.TokenWhereUniqueInput;
1183
+ };
1184
+ /**
1185
+ * Token deleteMany
1186
+ */
1187
+ export type TokenDeleteManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1188
+ /**
1189
+ * Filter which Tokens to delete
1190
+ */
1191
+ where?: Prisma.TokenWhereInput;
1192
+ /**
1193
+ * Limit how many Tokens to delete.
1194
+ */
1195
+ limit?: number;
1196
+ };
1197
+ /**
1198
+ * Token without action
1199
+ */
1200
+ export type TokenDefaultArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1201
+ /**
1202
+ * Select specific fields to fetch from the Token
1203
+ */
1204
+ select?: Prisma.TokenSelect<ExtArgs> | null;
1205
+ /**
1206
+ * Omit specific fields from the Token
1207
+ */
1208
+ omit?: Prisma.TokenOmit<ExtArgs> | null;
1209
+ /**
1210
+ * Choose, which related nodes to fetch as well
1211
+ */
1212
+ include?: Prisma.TokenInclude<ExtArgs> | null;
1213
+ };
1214
+ //# sourceMappingURL=Token.d.ts.map