@mars-stack/cli 0.2.0 → 1.0.2

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 (175) hide show
  1. package/dist/index.js +137 -12
  2. package/dist/index.js.map +1 -1
  3. package/package.json +4 -3
  4. package/template/.cursor/rules/composition-patterns.mdc +186 -0
  5. package/template/.cursor/rules/data-access.mdc +29 -0
  6. package/template/.cursor/rules/project-structure.mdc +34 -0
  7. package/template/.cursor/rules/security.mdc +25 -0
  8. package/template/.cursor/rules/testing.mdc +24 -0
  9. package/template/.cursor/rules/ui-conventions.mdc +29 -0
  10. package/template/.cursor/skills/add-api-route/SKILL.md +122 -0
  11. package/template/.cursor/skills/add-audit-log/SKILL.md +375 -0
  12. package/template/.cursor/skills/add-blog/SKILL.md +447 -0
  13. package/template/.cursor/skills/add-command-palette/SKILL.md +438 -0
  14. package/template/.cursor/skills/add-component/SKILL.md +158 -0
  15. package/template/.cursor/skills/add-crud-routes/SKILL.md +221 -0
  16. package/template/.cursor/skills/add-e2e-test/SKILL.md +227 -0
  17. package/template/.cursor/skills/add-error-boundary/SKILL.md +472 -0
  18. package/template/.cursor/skills/add-feature/SKILL.md +174 -0
  19. package/template/.cursor/skills/add-middleware/SKILL.md +135 -0
  20. package/template/.cursor/skills/add-page/SKILL.md +151 -0
  21. package/template/.cursor/skills/add-prisma-model/SKILL.md +148 -0
  22. package/template/.cursor/skills/add-protected-resource/SKILL.md +192 -0
  23. package/template/.cursor/skills/add-role/SKILL.md +156 -0
  24. package/template/.cursor/skills/add-server-action/SKILL.md +167 -0
  25. package/template/.cursor/skills/add-webhook/SKILL.md +192 -0
  26. package/template/.cursor/skills/build-complete-feature/SKILL.md +227 -0
  27. package/template/.cursor/skills/build-dashboard/SKILL.md +211 -0
  28. package/template/.cursor/skills/build-data-table/SKILL.md +283 -0
  29. package/template/.cursor/skills/build-form/SKILL.md +231 -0
  30. package/template/.cursor/skills/build-landing-page/SKILL.md +248 -0
  31. package/template/.cursor/skills/configure-ai/SKILL.md +617 -0
  32. package/template/.cursor/skills/configure-analytics/SKILL.md +413 -0
  33. package/template/.cursor/skills/configure-dark-mode/SKILL.md +309 -0
  34. package/template/.cursor/skills/configure-email/SKILL.md +170 -0
  35. package/template/.cursor/skills/configure-email-verification/SKILL.md +333 -0
  36. package/template/.cursor/skills/configure-feature-flags/SKILL.md +361 -0
  37. package/template/.cursor/skills/configure-i18n/SKILL.md +518 -0
  38. package/template/.cursor/skills/configure-jobs/SKILL.md +500 -0
  39. package/template/.cursor/skills/configure-magic-links/SKILL.md +385 -0
  40. package/template/.cursor/skills/configure-multi-tenancy/SKILL.md +611 -0
  41. package/template/.cursor/skills/configure-notifications/SKILL.md +569 -0
  42. package/template/.cursor/skills/configure-oauth/SKILL.md +217 -0
  43. package/template/.cursor/skills/configure-onboarding/SKILL.md +483 -0
  44. package/template/.cursor/skills/configure-payments/SKILL.md +243 -0
  45. package/template/.cursor/skills/configure-realtime/SKILL.md +733 -0
  46. package/template/.cursor/skills/configure-search/SKILL.md +581 -0
  47. package/template/.cursor/skills/configure-storage/SKILL.md +273 -0
  48. package/template/.cursor/skills/configure-two-factor/SKILL.md +518 -0
  49. package/template/.cursor/skills/create-execution-plan/SKILL.md +204 -0
  50. package/template/.cursor/skills/create-seed/SKILL.md +191 -0
  51. package/template/.cursor/skills/deploy-to-vercel/SKILL.md +300 -0
  52. package/template/.cursor/skills/design-tokens/SKILL.md +138 -0
  53. package/template/.cursor/skills/mars-capture-conversation-context/SKILL.md +119 -0
  54. package/template/.cursor/skills/setup-billing/SKILL.md +322 -0
  55. package/template/.cursor/skills/setup-project/SKILL.md +104 -0
  56. package/template/.cursor/skills/setup-teams/SKILL.md +682 -0
  57. package/template/.cursor/skills/test-api-route/SKILL.md +219 -0
  58. package/template/.cursor/skills/update-architecture-docs/SKILL.md +99 -0
  59. package/template/AGENTS.md +104 -0
  60. package/template/ARCHITECTURE.md +102 -0
  61. package/template/docs/QUALITY_SCORE.md +20 -0
  62. package/template/docs/design-docs/conversation-as-system-record.md +70 -0
  63. package/template/docs/design-docs/core-beliefs.md +43 -0
  64. package/template/docs/design-docs/index.md +8 -0
  65. package/template/docs/exec-plans/active/.gitkeep +0 -0
  66. package/template/docs/exec-plans/completed/.gitkeep +0 -0
  67. package/template/docs/exec-plans/tech-debt.md +7 -0
  68. package/template/docs/generated/.gitkeep +0 -0
  69. package/template/docs/product-specs/index.md +7 -0
  70. package/template/docs/references/index.md +18 -0
  71. package/template/e2e/api.spec.ts +20 -0
  72. package/template/e2e/auth.spec.ts +24 -0
  73. package/template/e2e/public.spec.ts +25 -0
  74. package/template/eslint.config.mjs +24 -0
  75. package/template/next-env.d.ts +6 -0
  76. package/template/next.config.ts +45 -0
  77. package/template/package.json +80 -0
  78. package/template/playwright.config.ts +31 -0
  79. package/template/postcss.config.mjs +8 -0
  80. package/template/prisma/generated/prisma/browser.ts +49 -0
  81. package/template/prisma/generated/prisma/client.ts +73 -0
  82. package/template/prisma/generated/prisma/commonInputTypes.ts +406 -0
  83. package/template/prisma/generated/prisma/enums.ts +15 -0
  84. package/template/prisma/generated/prisma/internal/class.ts +254 -0
  85. package/template/prisma/generated/prisma/internal/prismaNamespace.ts +1240 -0
  86. package/template/prisma/generated/prisma/internal/prismaNamespaceBrowser.ts +190 -0
  87. package/template/prisma/generated/prisma/models/Account.ts +1543 -0
  88. package/template/prisma/generated/prisma/models/File.ts +1529 -0
  89. package/template/prisma/generated/prisma/models/Session.ts +1415 -0
  90. package/template/prisma/generated/prisma/models/Subscription.ts +1455 -0
  91. package/template/prisma/generated/prisma/models/User.ts +2235 -0
  92. package/template/prisma/generated/prisma/models/VerificationToken.ts +1099 -0
  93. package/template/prisma/generated/prisma/models.ts +17 -0
  94. package/template/prisma/schema/auth.prisma +69 -0
  95. package/template/prisma/schema/base.prisma +8 -0
  96. package/template/prisma/schema/file.prisma +15 -0
  97. package/template/prisma/schema/subscription.prisma +17 -0
  98. package/template/prisma.config.ts +13 -0
  99. package/template/scripts/check-architecture.ts +221 -0
  100. package/template/scripts/check-doc-freshness.ts +242 -0
  101. package/template/scripts/ensure-db.mjs +291 -0
  102. package/template/scripts/generate-docs.ts +143 -0
  103. package/template/scripts/generate-env-example.ts +89 -0
  104. package/template/scripts/seed.ts +56 -0
  105. package/template/scripts/update-quality-score.ts +263 -0
  106. package/template/src/__tests__/architecture.test.ts +114 -0
  107. package/template/src/app/(auth)/forgotten-password/page.tsx +92 -0
  108. package/template/src/app/(auth)/layout.tsx +11 -0
  109. package/template/src/app/(auth)/register/page.tsx +162 -0
  110. package/template/src/app/(auth)/reset-password/page.tsx +109 -0
  111. package/template/src/app/(auth)/sign-in/page.tsx +122 -0
  112. package/template/src/app/(auth)/verify/[token]/page.tsx +87 -0
  113. package/template/src/app/(auth)/verify/page.tsx +56 -0
  114. package/template/src/app/(protected)/admin/page.tsx +108 -0
  115. package/template/src/app/(protected)/dashboard/loading.tsx +20 -0
  116. package/template/src/app/(protected)/dashboard/page.tsx +22 -0
  117. package/template/src/app/(protected)/layout.tsx +262 -0
  118. package/template/src/app/(protected)/settings/page.tsx +370 -0
  119. package/template/src/app/api/auth/forgot/route.ts +63 -0
  120. package/template/src/app/api/auth/login/route.ts +121 -0
  121. package/template/src/app/api/auth/logout/route.ts +19 -0
  122. package/template/src/app/api/auth/me/route.ts +30 -0
  123. package/template/src/app/api/auth/reset/route.ts +45 -0
  124. package/template/src/app/api/auth/signup/route.ts +85 -0
  125. package/template/src/app/api/auth/verify/route.ts +46 -0
  126. package/template/src/app/api/csrf/route.ts +12 -0
  127. package/template/src/app/api/health/route.ts +10 -0
  128. package/template/src/app/api/protected/admin/users/route.ts +24 -0
  129. package/template/src/app/api/protected/billing/checkout/route.ts +83 -0
  130. package/template/src/app/api/protected/billing/portal/route.ts +39 -0
  131. package/template/src/app/api/protected/files/[fileId]/route.ts +86 -0
  132. package/template/src/app/api/protected/files/upload/route.ts +64 -0
  133. package/template/src/app/api/protected/user/password/route.ts +63 -0
  134. package/template/src/app/api/protected/user/profile/route.ts +35 -0
  135. package/template/src/app/api/protected/user/sessions/[sessionId]/route.ts +33 -0
  136. package/template/src/app/api/protected/user/sessions/route.ts +22 -0
  137. package/template/src/app/api/readiness/route.ts +15 -0
  138. package/template/src/app/api/webhooks/stripe/route.ts +166 -0
  139. package/template/src/app/error.tsx +33 -0
  140. package/template/src/app/layout.tsx +29 -0
  141. package/template/src/app/not-found.tsx +20 -0
  142. package/template/src/app/page.tsx +136 -0
  143. package/template/src/app/privacy/page.tsx +178 -0
  144. package/template/src/app/providers.tsx +8 -0
  145. package/template/src/app/terms/page.tsx +139 -0
  146. package/template/src/config/app.config.ts +70 -0
  147. package/template/src/config/routes.ts +17 -0
  148. package/template/src/features/admin/index.ts +11 -0
  149. package/template/src/features/admin/permissions.ts +64 -0
  150. package/template/src/features/auth/context/AuthContext.tsx +96 -0
  151. package/template/src/features/auth/context/index.ts +2 -0
  152. package/template/src/features/auth/index.ts +3 -0
  153. package/template/src/features/auth/server/consent.ts +66 -0
  154. package/template/src/features/auth/server/session-revocation.ts +20 -0
  155. package/template/src/features/auth/server/sessions.ts +66 -0
  156. package/template/src/features/auth/server/user.ts +166 -0
  157. package/template/src/features/auth/types.ts +19 -0
  158. package/template/src/features/auth/validators.ts +29 -0
  159. package/template/src/features/billing/server/index.ts +66 -0
  160. package/template/src/features/billing/types.ts +43 -0
  161. package/template/src/features/uploads/server/index.ts +49 -0
  162. package/template/src/features/uploads/types.ts +26 -0
  163. package/template/src/lib/core/email/templates/base-layout.ts +122 -0
  164. package/template/src/lib/core/email/templates/index.ts +4 -0
  165. package/template/src/lib/core/email/templates/password-reset-email.ts +42 -0
  166. package/template/src/lib/core/email/templates/verification-email.ts +41 -0
  167. package/template/src/lib/core/email/templates/welcome-email.ts +40 -0
  168. package/template/src/lib/mars.ts +56 -0
  169. package/template/src/lib/prisma.ts +19 -0
  170. package/template/src/proxy.ts +92 -0
  171. package/template/src/styles/brand.css +15 -0
  172. package/template/src/styles/globals.css +7 -0
  173. package/template/tsconfig.json +59 -0
  174. package/template/vitest.config.ts +41 -0
  175. package/template/vitest.setup.ts +24 -0
@@ -0,0 +1,1455 @@
1
+
2
+ /* !!! This is code generated by Prisma. Do not edit directly. !!! */
3
+ /* eslint-disable */
4
+ // biome-ignore-all lint: generated file
5
+ // @ts-nocheck
6
+ /*
7
+ * This file exports the `Subscription` model and its related types.
8
+ *
9
+ * 🟢 You can import this file directly.
10
+ */
11
+ import type * as runtime from "@prisma/client/runtime/client"
12
+ import type * as $Enums from "../enums"
13
+ import type * as Prisma from "../internal/prismaNamespace"
14
+
15
+ /**
16
+ * Model Subscription
17
+ *
18
+ */
19
+ export type SubscriptionModel = runtime.Types.Result.DefaultSelection<Prisma.$SubscriptionPayload>
20
+
21
+ export type AggregateSubscription = {
22
+ _count: SubscriptionCountAggregateOutputType | null
23
+ _min: SubscriptionMinAggregateOutputType | null
24
+ _max: SubscriptionMaxAggregateOutputType | null
25
+ }
26
+
27
+ export type SubscriptionMinAggregateOutputType = {
28
+ id: string | null
29
+ userId: string | null
30
+ stripeCustomerId: string | null
31
+ stripePriceId: string | null
32
+ stripeSubscriptionId: string | null
33
+ status: string | null
34
+ currentPeriodEnd: Date | null
35
+ cancelAtPeriodEnd: boolean | null
36
+ createdAt: Date | null
37
+ updatedAt: Date | null
38
+ }
39
+
40
+ export type SubscriptionMaxAggregateOutputType = {
41
+ id: string | null
42
+ userId: string | null
43
+ stripeCustomerId: string | null
44
+ stripePriceId: string | null
45
+ stripeSubscriptionId: string | null
46
+ status: string | null
47
+ currentPeriodEnd: Date | null
48
+ cancelAtPeriodEnd: boolean | null
49
+ createdAt: Date | null
50
+ updatedAt: Date | null
51
+ }
52
+
53
+ export type SubscriptionCountAggregateOutputType = {
54
+ id: number
55
+ userId: number
56
+ stripeCustomerId: number
57
+ stripePriceId: number
58
+ stripeSubscriptionId: number
59
+ status: number
60
+ currentPeriodEnd: number
61
+ cancelAtPeriodEnd: number
62
+ createdAt: number
63
+ updatedAt: number
64
+ _all: number
65
+ }
66
+
67
+
68
+ export type SubscriptionMinAggregateInputType = {
69
+ id?: true
70
+ userId?: true
71
+ stripeCustomerId?: true
72
+ stripePriceId?: true
73
+ stripeSubscriptionId?: true
74
+ status?: true
75
+ currentPeriodEnd?: true
76
+ cancelAtPeriodEnd?: true
77
+ createdAt?: true
78
+ updatedAt?: true
79
+ }
80
+
81
+ export type SubscriptionMaxAggregateInputType = {
82
+ id?: true
83
+ userId?: true
84
+ stripeCustomerId?: true
85
+ stripePriceId?: true
86
+ stripeSubscriptionId?: true
87
+ status?: true
88
+ currentPeriodEnd?: true
89
+ cancelAtPeriodEnd?: true
90
+ createdAt?: true
91
+ updatedAt?: true
92
+ }
93
+
94
+ export type SubscriptionCountAggregateInputType = {
95
+ id?: true
96
+ userId?: true
97
+ stripeCustomerId?: true
98
+ stripePriceId?: true
99
+ stripeSubscriptionId?: true
100
+ status?: true
101
+ currentPeriodEnd?: true
102
+ cancelAtPeriodEnd?: true
103
+ createdAt?: true
104
+ updatedAt?: true
105
+ _all?: true
106
+ }
107
+
108
+ export type SubscriptionAggregateArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
109
+ /**
110
+ * Filter which Subscription to aggregate.
111
+ */
112
+ where?: Prisma.SubscriptionWhereInput
113
+ /**
114
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
115
+ *
116
+ * Determine the order of Subscriptions to fetch.
117
+ */
118
+ orderBy?: Prisma.SubscriptionOrderByWithRelationInput | Prisma.SubscriptionOrderByWithRelationInput[]
119
+ /**
120
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
121
+ *
122
+ * Sets the start position
123
+ */
124
+ cursor?: Prisma.SubscriptionWhereUniqueInput
125
+ /**
126
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
127
+ *
128
+ * Take `±n` Subscriptions from the position of the cursor.
129
+ */
130
+ take?: number
131
+ /**
132
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
133
+ *
134
+ * Skip the first `n` Subscriptions.
135
+ */
136
+ skip?: number
137
+ /**
138
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
139
+ *
140
+ * Count returned Subscriptions
141
+ **/
142
+ _count?: true | SubscriptionCountAggregateInputType
143
+ /**
144
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
145
+ *
146
+ * Select which fields to find the minimum value
147
+ **/
148
+ _min?: SubscriptionMinAggregateInputType
149
+ /**
150
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
151
+ *
152
+ * Select which fields to find the maximum value
153
+ **/
154
+ _max?: SubscriptionMaxAggregateInputType
155
+ }
156
+
157
+ export type GetSubscriptionAggregateType<T extends SubscriptionAggregateArgs> = {
158
+ [P in keyof T & keyof AggregateSubscription]: P extends '_count' | 'count'
159
+ ? T[P] extends true
160
+ ? number
161
+ : Prisma.GetScalarType<T[P], AggregateSubscription[P]>
162
+ : Prisma.GetScalarType<T[P], AggregateSubscription[P]>
163
+ }
164
+
165
+
166
+
167
+
168
+ export type SubscriptionGroupByArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
169
+ where?: Prisma.SubscriptionWhereInput
170
+ orderBy?: Prisma.SubscriptionOrderByWithAggregationInput | Prisma.SubscriptionOrderByWithAggregationInput[]
171
+ by: Prisma.SubscriptionScalarFieldEnum[] | Prisma.SubscriptionScalarFieldEnum
172
+ having?: Prisma.SubscriptionScalarWhereWithAggregatesInput
173
+ take?: number
174
+ skip?: number
175
+ _count?: SubscriptionCountAggregateInputType | true
176
+ _min?: SubscriptionMinAggregateInputType
177
+ _max?: SubscriptionMaxAggregateInputType
178
+ }
179
+
180
+ export type SubscriptionGroupByOutputType = {
181
+ id: string
182
+ userId: string
183
+ stripeCustomerId: string
184
+ stripePriceId: string | null
185
+ stripeSubscriptionId: string | null
186
+ status: string
187
+ currentPeriodEnd: Date | null
188
+ cancelAtPeriodEnd: boolean
189
+ createdAt: Date
190
+ updatedAt: Date
191
+ _count: SubscriptionCountAggregateOutputType | null
192
+ _min: SubscriptionMinAggregateOutputType | null
193
+ _max: SubscriptionMaxAggregateOutputType | null
194
+ }
195
+
196
+ type GetSubscriptionGroupByPayload<T extends SubscriptionGroupByArgs> = Prisma.PrismaPromise<
197
+ Array<
198
+ Prisma.PickEnumerable<SubscriptionGroupByOutputType, T['by']> &
199
+ {
200
+ [P in ((keyof T) & (keyof SubscriptionGroupByOutputType))]: P extends '_count'
201
+ ? T[P] extends boolean
202
+ ? number
203
+ : Prisma.GetScalarType<T[P], SubscriptionGroupByOutputType[P]>
204
+ : Prisma.GetScalarType<T[P], SubscriptionGroupByOutputType[P]>
205
+ }
206
+ >
207
+ >
208
+
209
+
210
+
211
+ export type SubscriptionWhereInput = {
212
+ AND?: Prisma.SubscriptionWhereInput | Prisma.SubscriptionWhereInput[]
213
+ OR?: Prisma.SubscriptionWhereInput[]
214
+ NOT?: Prisma.SubscriptionWhereInput | Prisma.SubscriptionWhereInput[]
215
+ id?: Prisma.StringFilter<"Subscription"> | string
216
+ userId?: Prisma.StringFilter<"Subscription"> | string
217
+ stripeCustomerId?: Prisma.StringFilter<"Subscription"> | string
218
+ stripePriceId?: Prisma.StringNullableFilter<"Subscription"> | string | null
219
+ stripeSubscriptionId?: Prisma.StringNullableFilter<"Subscription"> | string | null
220
+ status?: Prisma.StringFilter<"Subscription"> | string
221
+ currentPeriodEnd?: Prisma.DateTimeNullableFilter<"Subscription"> | Date | string | null
222
+ cancelAtPeriodEnd?: Prisma.BoolFilter<"Subscription"> | boolean
223
+ createdAt?: Prisma.DateTimeFilter<"Subscription"> | Date | string
224
+ updatedAt?: Prisma.DateTimeFilter<"Subscription"> | Date | string
225
+ user?: Prisma.XOR<Prisma.UserScalarRelationFilter, Prisma.UserWhereInput>
226
+ }
227
+
228
+ export type SubscriptionOrderByWithRelationInput = {
229
+ id?: Prisma.SortOrder
230
+ userId?: Prisma.SortOrder
231
+ stripeCustomerId?: Prisma.SortOrder
232
+ stripePriceId?: Prisma.SortOrderInput | Prisma.SortOrder
233
+ stripeSubscriptionId?: Prisma.SortOrderInput | Prisma.SortOrder
234
+ status?: Prisma.SortOrder
235
+ currentPeriodEnd?: Prisma.SortOrderInput | Prisma.SortOrder
236
+ cancelAtPeriodEnd?: Prisma.SortOrder
237
+ createdAt?: Prisma.SortOrder
238
+ updatedAt?: Prisma.SortOrder
239
+ user?: Prisma.UserOrderByWithRelationInput
240
+ }
241
+
242
+ export type SubscriptionWhereUniqueInput = Prisma.AtLeast<{
243
+ id?: string
244
+ userId?: string
245
+ stripeCustomerId?: string
246
+ stripeSubscriptionId?: string
247
+ AND?: Prisma.SubscriptionWhereInput | Prisma.SubscriptionWhereInput[]
248
+ OR?: Prisma.SubscriptionWhereInput[]
249
+ NOT?: Prisma.SubscriptionWhereInput | Prisma.SubscriptionWhereInput[]
250
+ stripePriceId?: Prisma.StringNullableFilter<"Subscription"> | string | null
251
+ status?: Prisma.StringFilter<"Subscription"> | string
252
+ currentPeriodEnd?: Prisma.DateTimeNullableFilter<"Subscription"> | Date | string | null
253
+ cancelAtPeriodEnd?: Prisma.BoolFilter<"Subscription"> | boolean
254
+ createdAt?: Prisma.DateTimeFilter<"Subscription"> | Date | string
255
+ updatedAt?: Prisma.DateTimeFilter<"Subscription"> | Date | string
256
+ user?: Prisma.XOR<Prisma.UserScalarRelationFilter, Prisma.UserWhereInput>
257
+ }, "id" | "userId" | "stripeCustomerId" | "stripeSubscriptionId">
258
+
259
+ export type SubscriptionOrderByWithAggregationInput = {
260
+ id?: Prisma.SortOrder
261
+ userId?: Prisma.SortOrder
262
+ stripeCustomerId?: Prisma.SortOrder
263
+ stripePriceId?: Prisma.SortOrderInput | Prisma.SortOrder
264
+ stripeSubscriptionId?: Prisma.SortOrderInput | Prisma.SortOrder
265
+ status?: Prisma.SortOrder
266
+ currentPeriodEnd?: Prisma.SortOrderInput | Prisma.SortOrder
267
+ cancelAtPeriodEnd?: Prisma.SortOrder
268
+ createdAt?: Prisma.SortOrder
269
+ updatedAt?: Prisma.SortOrder
270
+ _count?: Prisma.SubscriptionCountOrderByAggregateInput
271
+ _max?: Prisma.SubscriptionMaxOrderByAggregateInput
272
+ _min?: Prisma.SubscriptionMinOrderByAggregateInput
273
+ }
274
+
275
+ export type SubscriptionScalarWhereWithAggregatesInput = {
276
+ AND?: Prisma.SubscriptionScalarWhereWithAggregatesInput | Prisma.SubscriptionScalarWhereWithAggregatesInput[]
277
+ OR?: Prisma.SubscriptionScalarWhereWithAggregatesInput[]
278
+ NOT?: Prisma.SubscriptionScalarWhereWithAggregatesInput | Prisma.SubscriptionScalarWhereWithAggregatesInput[]
279
+ id?: Prisma.StringWithAggregatesFilter<"Subscription"> | string
280
+ userId?: Prisma.StringWithAggregatesFilter<"Subscription"> | string
281
+ stripeCustomerId?: Prisma.StringWithAggregatesFilter<"Subscription"> | string
282
+ stripePriceId?: Prisma.StringNullableWithAggregatesFilter<"Subscription"> | string | null
283
+ stripeSubscriptionId?: Prisma.StringNullableWithAggregatesFilter<"Subscription"> | string | null
284
+ status?: Prisma.StringWithAggregatesFilter<"Subscription"> | string
285
+ currentPeriodEnd?: Prisma.DateTimeNullableWithAggregatesFilter<"Subscription"> | Date | string | null
286
+ cancelAtPeriodEnd?: Prisma.BoolWithAggregatesFilter<"Subscription"> | boolean
287
+ createdAt?: Prisma.DateTimeWithAggregatesFilter<"Subscription"> | Date | string
288
+ updatedAt?: Prisma.DateTimeWithAggregatesFilter<"Subscription"> | Date | string
289
+ }
290
+
291
+ export type SubscriptionCreateInput = {
292
+ id?: string
293
+ stripeCustomerId: string
294
+ stripePriceId?: string | null
295
+ stripeSubscriptionId?: string | null
296
+ status?: string
297
+ currentPeriodEnd?: Date | string | null
298
+ cancelAtPeriodEnd?: boolean
299
+ createdAt?: Date | string
300
+ updatedAt?: Date | string
301
+ user: Prisma.UserCreateNestedOneWithoutSubscriptionInput
302
+ }
303
+
304
+ export type SubscriptionUncheckedCreateInput = {
305
+ id?: string
306
+ userId: string
307
+ stripeCustomerId: string
308
+ stripePriceId?: string | null
309
+ stripeSubscriptionId?: string | null
310
+ status?: string
311
+ currentPeriodEnd?: Date | string | null
312
+ cancelAtPeriodEnd?: boolean
313
+ createdAt?: Date | string
314
+ updatedAt?: Date | string
315
+ }
316
+
317
+ export type SubscriptionUpdateInput = {
318
+ id?: Prisma.StringFieldUpdateOperationsInput | string
319
+ stripeCustomerId?: Prisma.StringFieldUpdateOperationsInput | string
320
+ stripePriceId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
321
+ stripeSubscriptionId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
322
+ status?: Prisma.StringFieldUpdateOperationsInput | string
323
+ currentPeriodEnd?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
324
+ cancelAtPeriodEnd?: Prisma.BoolFieldUpdateOperationsInput | boolean
325
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
326
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
327
+ user?: Prisma.UserUpdateOneRequiredWithoutSubscriptionNestedInput
328
+ }
329
+
330
+ export type SubscriptionUncheckedUpdateInput = {
331
+ id?: Prisma.StringFieldUpdateOperationsInput | string
332
+ userId?: Prisma.StringFieldUpdateOperationsInput | string
333
+ stripeCustomerId?: Prisma.StringFieldUpdateOperationsInput | string
334
+ stripePriceId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
335
+ stripeSubscriptionId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
336
+ status?: Prisma.StringFieldUpdateOperationsInput | string
337
+ currentPeriodEnd?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
338
+ cancelAtPeriodEnd?: Prisma.BoolFieldUpdateOperationsInput | boolean
339
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
340
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
341
+ }
342
+
343
+ export type SubscriptionCreateManyInput = {
344
+ id?: string
345
+ userId: string
346
+ stripeCustomerId: string
347
+ stripePriceId?: string | null
348
+ stripeSubscriptionId?: string | null
349
+ status?: string
350
+ currentPeriodEnd?: Date | string | null
351
+ cancelAtPeriodEnd?: boolean
352
+ createdAt?: Date | string
353
+ updatedAt?: Date | string
354
+ }
355
+
356
+ export type SubscriptionUpdateManyMutationInput = {
357
+ id?: Prisma.StringFieldUpdateOperationsInput | string
358
+ stripeCustomerId?: Prisma.StringFieldUpdateOperationsInput | string
359
+ stripePriceId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
360
+ stripeSubscriptionId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
361
+ status?: Prisma.StringFieldUpdateOperationsInput | string
362
+ currentPeriodEnd?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
363
+ cancelAtPeriodEnd?: Prisma.BoolFieldUpdateOperationsInput | boolean
364
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
365
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
366
+ }
367
+
368
+ export type SubscriptionUncheckedUpdateManyInput = {
369
+ id?: Prisma.StringFieldUpdateOperationsInput | string
370
+ userId?: Prisma.StringFieldUpdateOperationsInput | string
371
+ stripeCustomerId?: Prisma.StringFieldUpdateOperationsInput | string
372
+ stripePriceId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
373
+ stripeSubscriptionId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
374
+ status?: Prisma.StringFieldUpdateOperationsInput | string
375
+ currentPeriodEnd?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
376
+ cancelAtPeriodEnd?: Prisma.BoolFieldUpdateOperationsInput | boolean
377
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
378
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
379
+ }
380
+
381
+ export type SubscriptionNullableScalarRelationFilter = {
382
+ is?: Prisma.SubscriptionWhereInput | null
383
+ isNot?: Prisma.SubscriptionWhereInput | null
384
+ }
385
+
386
+ export type SubscriptionCountOrderByAggregateInput = {
387
+ id?: Prisma.SortOrder
388
+ userId?: Prisma.SortOrder
389
+ stripeCustomerId?: Prisma.SortOrder
390
+ stripePriceId?: Prisma.SortOrder
391
+ stripeSubscriptionId?: Prisma.SortOrder
392
+ status?: Prisma.SortOrder
393
+ currentPeriodEnd?: Prisma.SortOrder
394
+ cancelAtPeriodEnd?: Prisma.SortOrder
395
+ createdAt?: Prisma.SortOrder
396
+ updatedAt?: Prisma.SortOrder
397
+ }
398
+
399
+ export type SubscriptionMaxOrderByAggregateInput = {
400
+ id?: Prisma.SortOrder
401
+ userId?: Prisma.SortOrder
402
+ stripeCustomerId?: Prisma.SortOrder
403
+ stripePriceId?: Prisma.SortOrder
404
+ stripeSubscriptionId?: Prisma.SortOrder
405
+ status?: Prisma.SortOrder
406
+ currentPeriodEnd?: Prisma.SortOrder
407
+ cancelAtPeriodEnd?: Prisma.SortOrder
408
+ createdAt?: Prisma.SortOrder
409
+ updatedAt?: Prisma.SortOrder
410
+ }
411
+
412
+ export type SubscriptionMinOrderByAggregateInput = {
413
+ id?: Prisma.SortOrder
414
+ userId?: Prisma.SortOrder
415
+ stripeCustomerId?: Prisma.SortOrder
416
+ stripePriceId?: Prisma.SortOrder
417
+ stripeSubscriptionId?: Prisma.SortOrder
418
+ status?: Prisma.SortOrder
419
+ currentPeriodEnd?: Prisma.SortOrder
420
+ cancelAtPeriodEnd?: Prisma.SortOrder
421
+ createdAt?: Prisma.SortOrder
422
+ updatedAt?: Prisma.SortOrder
423
+ }
424
+
425
+ export type SubscriptionCreateNestedOneWithoutUserInput = {
426
+ create?: Prisma.XOR<Prisma.SubscriptionCreateWithoutUserInput, Prisma.SubscriptionUncheckedCreateWithoutUserInput>
427
+ connectOrCreate?: Prisma.SubscriptionCreateOrConnectWithoutUserInput
428
+ connect?: Prisma.SubscriptionWhereUniqueInput
429
+ }
430
+
431
+ export type SubscriptionUncheckedCreateNestedOneWithoutUserInput = {
432
+ create?: Prisma.XOR<Prisma.SubscriptionCreateWithoutUserInput, Prisma.SubscriptionUncheckedCreateWithoutUserInput>
433
+ connectOrCreate?: Prisma.SubscriptionCreateOrConnectWithoutUserInput
434
+ connect?: Prisma.SubscriptionWhereUniqueInput
435
+ }
436
+
437
+ export type SubscriptionUpdateOneWithoutUserNestedInput = {
438
+ create?: Prisma.XOR<Prisma.SubscriptionCreateWithoutUserInput, Prisma.SubscriptionUncheckedCreateWithoutUserInput>
439
+ connectOrCreate?: Prisma.SubscriptionCreateOrConnectWithoutUserInput
440
+ upsert?: Prisma.SubscriptionUpsertWithoutUserInput
441
+ disconnect?: Prisma.SubscriptionWhereInput | boolean
442
+ delete?: Prisma.SubscriptionWhereInput | boolean
443
+ connect?: Prisma.SubscriptionWhereUniqueInput
444
+ update?: Prisma.XOR<Prisma.XOR<Prisma.SubscriptionUpdateToOneWithWhereWithoutUserInput, Prisma.SubscriptionUpdateWithoutUserInput>, Prisma.SubscriptionUncheckedUpdateWithoutUserInput>
445
+ }
446
+
447
+ export type SubscriptionUncheckedUpdateOneWithoutUserNestedInput = {
448
+ create?: Prisma.XOR<Prisma.SubscriptionCreateWithoutUserInput, Prisma.SubscriptionUncheckedCreateWithoutUserInput>
449
+ connectOrCreate?: Prisma.SubscriptionCreateOrConnectWithoutUserInput
450
+ upsert?: Prisma.SubscriptionUpsertWithoutUserInput
451
+ disconnect?: Prisma.SubscriptionWhereInput | boolean
452
+ delete?: Prisma.SubscriptionWhereInput | boolean
453
+ connect?: Prisma.SubscriptionWhereUniqueInput
454
+ update?: Prisma.XOR<Prisma.XOR<Prisma.SubscriptionUpdateToOneWithWhereWithoutUserInput, Prisma.SubscriptionUpdateWithoutUserInput>, Prisma.SubscriptionUncheckedUpdateWithoutUserInput>
455
+ }
456
+
457
+ export type SubscriptionCreateWithoutUserInput = {
458
+ id?: string
459
+ stripeCustomerId: string
460
+ stripePriceId?: string | null
461
+ stripeSubscriptionId?: string | null
462
+ status?: string
463
+ currentPeriodEnd?: Date | string | null
464
+ cancelAtPeriodEnd?: boolean
465
+ createdAt?: Date | string
466
+ updatedAt?: Date | string
467
+ }
468
+
469
+ export type SubscriptionUncheckedCreateWithoutUserInput = {
470
+ id?: string
471
+ stripeCustomerId: string
472
+ stripePriceId?: string | null
473
+ stripeSubscriptionId?: string | null
474
+ status?: string
475
+ currentPeriodEnd?: Date | string | null
476
+ cancelAtPeriodEnd?: boolean
477
+ createdAt?: Date | string
478
+ updatedAt?: Date | string
479
+ }
480
+
481
+ export type SubscriptionCreateOrConnectWithoutUserInput = {
482
+ where: Prisma.SubscriptionWhereUniqueInput
483
+ create: Prisma.XOR<Prisma.SubscriptionCreateWithoutUserInput, Prisma.SubscriptionUncheckedCreateWithoutUserInput>
484
+ }
485
+
486
+ export type SubscriptionUpsertWithoutUserInput = {
487
+ update: Prisma.XOR<Prisma.SubscriptionUpdateWithoutUserInput, Prisma.SubscriptionUncheckedUpdateWithoutUserInput>
488
+ create: Prisma.XOR<Prisma.SubscriptionCreateWithoutUserInput, Prisma.SubscriptionUncheckedCreateWithoutUserInput>
489
+ where?: Prisma.SubscriptionWhereInput
490
+ }
491
+
492
+ export type SubscriptionUpdateToOneWithWhereWithoutUserInput = {
493
+ where?: Prisma.SubscriptionWhereInput
494
+ data: Prisma.XOR<Prisma.SubscriptionUpdateWithoutUserInput, Prisma.SubscriptionUncheckedUpdateWithoutUserInput>
495
+ }
496
+
497
+ export type SubscriptionUpdateWithoutUserInput = {
498
+ id?: Prisma.StringFieldUpdateOperationsInput | string
499
+ stripeCustomerId?: Prisma.StringFieldUpdateOperationsInput | string
500
+ stripePriceId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
501
+ stripeSubscriptionId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
502
+ status?: Prisma.StringFieldUpdateOperationsInput | string
503
+ currentPeriodEnd?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
504
+ cancelAtPeriodEnd?: Prisma.BoolFieldUpdateOperationsInput | boolean
505
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
506
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
507
+ }
508
+
509
+ export type SubscriptionUncheckedUpdateWithoutUserInput = {
510
+ id?: Prisma.StringFieldUpdateOperationsInput | string
511
+ stripeCustomerId?: Prisma.StringFieldUpdateOperationsInput | string
512
+ stripePriceId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
513
+ stripeSubscriptionId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
514
+ status?: Prisma.StringFieldUpdateOperationsInput | string
515
+ currentPeriodEnd?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
516
+ cancelAtPeriodEnd?: Prisma.BoolFieldUpdateOperationsInput | boolean
517
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
518
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
519
+ }
520
+
521
+
522
+
523
+ export type SubscriptionSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
524
+ id?: boolean
525
+ userId?: boolean
526
+ stripeCustomerId?: boolean
527
+ stripePriceId?: boolean
528
+ stripeSubscriptionId?: boolean
529
+ status?: boolean
530
+ currentPeriodEnd?: boolean
531
+ cancelAtPeriodEnd?: boolean
532
+ createdAt?: boolean
533
+ updatedAt?: boolean
534
+ user?: boolean | Prisma.UserDefaultArgs<ExtArgs>
535
+ }, ExtArgs["result"]["subscription"]>
536
+
537
+ export type SubscriptionSelectCreateManyAndReturn<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
538
+ id?: boolean
539
+ userId?: boolean
540
+ stripeCustomerId?: boolean
541
+ stripePriceId?: boolean
542
+ stripeSubscriptionId?: boolean
543
+ status?: boolean
544
+ currentPeriodEnd?: boolean
545
+ cancelAtPeriodEnd?: boolean
546
+ createdAt?: boolean
547
+ updatedAt?: boolean
548
+ user?: boolean | Prisma.UserDefaultArgs<ExtArgs>
549
+ }, ExtArgs["result"]["subscription"]>
550
+
551
+ export type SubscriptionSelectUpdateManyAndReturn<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
552
+ id?: boolean
553
+ userId?: boolean
554
+ stripeCustomerId?: boolean
555
+ stripePriceId?: boolean
556
+ stripeSubscriptionId?: boolean
557
+ status?: boolean
558
+ currentPeriodEnd?: boolean
559
+ cancelAtPeriodEnd?: boolean
560
+ createdAt?: boolean
561
+ updatedAt?: boolean
562
+ user?: boolean | Prisma.UserDefaultArgs<ExtArgs>
563
+ }, ExtArgs["result"]["subscription"]>
564
+
565
+ export type SubscriptionSelectScalar = {
566
+ id?: boolean
567
+ userId?: boolean
568
+ stripeCustomerId?: boolean
569
+ stripePriceId?: boolean
570
+ stripeSubscriptionId?: boolean
571
+ status?: boolean
572
+ currentPeriodEnd?: boolean
573
+ cancelAtPeriodEnd?: boolean
574
+ createdAt?: boolean
575
+ updatedAt?: boolean
576
+ }
577
+
578
+ export type SubscriptionOmit<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetOmit<"id" | "userId" | "stripeCustomerId" | "stripePriceId" | "stripeSubscriptionId" | "status" | "currentPeriodEnd" | "cancelAtPeriodEnd" | "createdAt" | "updatedAt", ExtArgs["result"]["subscription"]>
579
+ export type SubscriptionInclude<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
580
+ user?: boolean | Prisma.UserDefaultArgs<ExtArgs>
581
+ }
582
+ export type SubscriptionIncludeCreateManyAndReturn<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
583
+ user?: boolean | Prisma.UserDefaultArgs<ExtArgs>
584
+ }
585
+ export type SubscriptionIncludeUpdateManyAndReturn<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
586
+ user?: boolean | Prisma.UserDefaultArgs<ExtArgs>
587
+ }
588
+
589
+ export type $SubscriptionPayload<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
590
+ name: "Subscription"
591
+ objects: {
592
+ user: Prisma.$UserPayload<ExtArgs>
593
+ }
594
+ scalars: runtime.Types.Extensions.GetPayloadResult<{
595
+ id: string
596
+ userId: string
597
+ stripeCustomerId: string
598
+ stripePriceId: string | null
599
+ stripeSubscriptionId: string | null
600
+ status: string
601
+ currentPeriodEnd: Date | null
602
+ cancelAtPeriodEnd: boolean
603
+ createdAt: Date
604
+ updatedAt: Date
605
+ }, ExtArgs["result"]["subscription"]>
606
+ composites: {}
607
+ }
608
+
609
+ export type SubscriptionGetPayload<S extends boolean | null | undefined | SubscriptionDefaultArgs> = runtime.Types.Result.GetResult<Prisma.$SubscriptionPayload, S>
610
+
611
+ export type SubscriptionCountArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> =
612
+ Omit<SubscriptionFindManyArgs, 'select' | 'include' | 'distinct' | 'omit'> & {
613
+ select?: SubscriptionCountAggregateInputType | true
614
+ }
615
+
616
+ export interface SubscriptionDelegate<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs, GlobalOmitOptions = {}> {
617
+ [K: symbol]: { types: Prisma.TypeMap<ExtArgs>['model']['Subscription'], meta: { name: 'Subscription' } }
618
+ /**
619
+ * Find zero or one Subscription that matches the filter.
620
+ * @param {SubscriptionFindUniqueArgs} args - Arguments to find a Subscription
621
+ * @example
622
+ * // Get one Subscription
623
+ * const subscription = await prisma.subscription.findUnique({
624
+ * where: {
625
+ * // ... provide filter here
626
+ * }
627
+ * })
628
+ */
629
+ findUnique<T extends SubscriptionFindUniqueArgs>(args: Prisma.SelectSubset<T, SubscriptionFindUniqueArgs<ExtArgs>>): Prisma.Prisma__SubscriptionClient<runtime.Types.Result.GetResult<Prisma.$SubscriptionPayload<ExtArgs>, T, "findUnique", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>
630
+
631
+ /**
632
+ * Find one Subscription that matches the filter or throw an error with `error.code='P2025'`
633
+ * if no matches were found.
634
+ * @param {SubscriptionFindUniqueOrThrowArgs} args - Arguments to find a Subscription
635
+ * @example
636
+ * // Get one Subscription
637
+ * const subscription = await prisma.subscription.findUniqueOrThrow({
638
+ * where: {
639
+ * // ... provide filter here
640
+ * }
641
+ * })
642
+ */
643
+ findUniqueOrThrow<T extends SubscriptionFindUniqueOrThrowArgs>(args: Prisma.SelectSubset<T, SubscriptionFindUniqueOrThrowArgs<ExtArgs>>): Prisma.Prisma__SubscriptionClient<runtime.Types.Result.GetResult<Prisma.$SubscriptionPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>
644
+
645
+ /**
646
+ * Find the first Subscription that matches the filter.
647
+ * Note, that providing `undefined` is treated as the value not being there.
648
+ * Read more here: https://pris.ly/d/null-undefined
649
+ * @param {SubscriptionFindFirstArgs} args - Arguments to find a Subscription
650
+ * @example
651
+ * // Get one Subscription
652
+ * const subscription = await prisma.subscription.findFirst({
653
+ * where: {
654
+ * // ... provide filter here
655
+ * }
656
+ * })
657
+ */
658
+ findFirst<T extends SubscriptionFindFirstArgs>(args?: Prisma.SelectSubset<T, SubscriptionFindFirstArgs<ExtArgs>>): Prisma.Prisma__SubscriptionClient<runtime.Types.Result.GetResult<Prisma.$SubscriptionPayload<ExtArgs>, T, "findFirst", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>
659
+
660
+ /**
661
+ * Find the first Subscription that matches the filter or
662
+ * throw `PrismaKnownClientError` with `P2025` code if no matches were found.
663
+ * Note, that providing `undefined` is treated as the value not being there.
664
+ * Read more here: https://pris.ly/d/null-undefined
665
+ * @param {SubscriptionFindFirstOrThrowArgs} args - Arguments to find a Subscription
666
+ * @example
667
+ * // Get one Subscription
668
+ * const subscription = await prisma.subscription.findFirstOrThrow({
669
+ * where: {
670
+ * // ... provide filter here
671
+ * }
672
+ * })
673
+ */
674
+ findFirstOrThrow<T extends SubscriptionFindFirstOrThrowArgs>(args?: Prisma.SelectSubset<T, SubscriptionFindFirstOrThrowArgs<ExtArgs>>): Prisma.Prisma__SubscriptionClient<runtime.Types.Result.GetResult<Prisma.$SubscriptionPayload<ExtArgs>, T, "findFirstOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>
675
+
676
+ /**
677
+ * Find zero or more Subscriptions that matches the filter.
678
+ * Note, that providing `undefined` is treated as the value not being there.
679
+ * Read more here: https://pris.ly/d/null-undefined
680
+ * @param {SubscriptionFindManyArgs} args - Arguments to filter and select certain fields only.
681
+ * @example
682
+ * // Get all Subscriptions
683
+ * const subscriptions = await prisma.subscription.findMany()
684
+ *
685
+ * // Get first 10 Subscriptions
686
+ * const subscriptions = await prisma.subscription.findMany({ take: 10 })
687
+ *
688
+ * // Only select the `id`
689
+ * const subscriptionWithIdOnly = await prisma.subscription.findMany({ select: { id: true } })
690
+ *
691
+ */
692
+ findMany<T extends SubscriptionFindManyArgs>(args?: Prisma.SelectSubset<T, SubscriptionFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$SubscriptionPayload<ExtArgs>, T, "findMany", GlobalOmitOptions>>
693
+
694
+ /**
695
+ * Create a Subscription.
696
+ * @param {SubscriptionCreateArgs} args - Arguments to create a Subscription.
697
+ * @example
698
+ * // Create one Subscription
699
+ * const Subscription = await prisma.subscription.create({
700
+ * data: {
701
+ * // ... data to create a Subscription
702
+ * }
703
+ * })
704
+ *
705
+ */
706
+ create<T extends SubscriptionCreateArgs>(args: Prisma.SelectSubset<T, SubscriptionCreateArgs<ExtArgs>>): Prisma.Prisma__SubscriptionClient<runtime.Types.Result.GetResult<Prisma.$SubscriptionPayload<ExtArgs>, T, "create", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>
707
+
708
+ /**
709
+ * Create many Subscriptions.
710
+ * @param {SubscriptionCreateManyArgs} args - Arguments to create many Subscriptions.
711
+ * @example
712
+ * // Create many Subscriptions
713
+ * const subscription = await prisma.subscription.createMany({
714
+ * data: [
715
+ * // ... provide data here
716
+ * ]
717
+ * })
718
+ *
719
+ */
720
+ createMany<T extends SubscriptionCreateManyArgs>(args?: Prisma.SelectSubset<T, SubscriptionCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<Prisma.BatchPayload>
721
+
722
+ /**
723
+ * Create many Subscriptions and returns the data saved in the database.
724
+ * @param {SubscriptionCreateManyAndReturnArgs} args - Arguments to create many Subscriptions.
725
+ * @example
726
+ * // Create many Subscriptions
727
+ * const subscription = await prisma.subscription.createManyAndReturn({
728
+ * data: [
729
+ * // ... provide data here
730
+ * ]
731
+ * })
732
+ *
733
+ * // Create many Subscriptions and only return the `id`
734
+ * const subscriptionWithIdOnly = await prisma.subscription.createManyAndReturn({
735
+ * select: { id: true },
736
+ * data: [
737
+ * // ... provide data here
738
+ * ]
739
+ * })
740
+ * Note, that providing `undefined` is treated as the value not being there.
741
+ * Read more here: https://pris.ly/d/null-undefined
742
+ *
743
+ */
744
+ createManyAndReturn<T extends SubscriptionCreateManyAndReturnArgs>(args?: Prisma.SelectSubset<T, SubscriptionCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$SubscriptionPayload<ExtArgs>, T, "createManyAndReturn", GlobalOmitOptions>>
745
+
746
+ /**
747
+ * Delete a Subscription.
748
+ * @param {SubscriptionDeleteArgs} args - Arguments to delete one Subscription.
749
+ * @example
750
+ * // Delete one Subscription
751
+ * const Subscription = await prisma.subscription.delete({
752
+ * where: {
753
+ * // ... filter to delete one Subscription
754
+ * }
755
+ * })
756
+ *
757
+ */
758
+ delete<T extends SubscriptionDeleteArgs>(args: Prisma.SelectSubset<T, SubscriptionDeleteArgs<ExtArgs>>): Prisma.Prisma__SubscriptionClient<runtime.Types.Result.GetResult<Prisma.$SubscriptionPayload<ExtArgs>, T, "delete", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>
759
+
760
+ /**
761
+ * Update one Subscription.
762
+ * @param {SubscriptionUpdateArgs} args - Arguments to update one Subscription.
763
+ * @example
764
+ * // Update one Subscription
765
+ * const subscription = await prisma.subscription.update({
766
+ * where: {
767
+ * // ... provide filter here
768
+ * },
769
+ * data: {
770
+ * // ... provide data here
771
+ * }
772
+ * })
773
+ *
774
+ */
775
+ update<T extends SubscriptionUpdateArgs>(args: Prisma.SelectSubset<T, SubscriptionUpdateArgs<ExtArgs>>): Prisma.Prisma__SubscriptionClient<runtime.Types.Result.GetResult<Prisma.$SubscriptionPayload<ExtArgs>, T, "update", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>
776
+
777
+ /**
778
+ * Delete zero or more Subscriptions.
779
+ * @param {SubscriptionDeleteManyArgs} args - Arguments to filter Subscriptions to delete.
780
+ * @example
781
+ * // Delete a few Subscriptions
782
+ * const { count } = await prisma.subscription.deleteMany({
783
+ * where: {
784
+ * // ... provide filter here
785
+ * }
786
+ * })
787
+ *
788
+ */
789
+ deleteMany<T extends SubscriptionDeleteManyArgs>(args?: Prisma.SelectSubset<T, SubscriptionDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<Prisma.BatchPayload>
790
+
791
+ /**
792
+ * Update zero or more Subscriptions.
793
+ * Note, that providing `undefined` is treated as the value not being there.
794
+ * Read more here: https://pris.ly/d/null-undefined
795
+ * @param {SubscriptionUpdateManyArgs} args - Arguments to update one or more rows.
796
+ * @example
797
+ * // Update many Subscriptions
798
+ * const subscription = await prisma.subscription.updateMany({
799
+ * where: {
800
+ * // ... provide filter here
801
+ * },
802
+ * data: {
803
+ * // ... provide data here
804
+ * }
805
+ * })
806
+ *
807
+ */
808
+ updateMany<T extends SubscriptionUpdateManyArgs>(args: Prisma.SelectSubset<T, SubscriptionUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<Prisma.BatchPayload>
809
+
810
+ /**
811
+ * Update zero or more Subscriptions and returns the data updated in the database.
812
+ * @param {SubscriptionUpdateManyAndReturnArgs} args - Arguments to update many Subscriptions.
813
+ * @example
814
+ * // Update many Subscriptions
815
+ * const subscription = await prisma.subscription.updateManyAndReturn({
816
+ * where: {
817
+ * // ... provide filter here
818
+ * },
819
+ * data: [
820
+ * // ... provide data here
821
+ * ]
822
+ * })
823
+ *
824
+ * // Update zero or more Subscriptions and only return the `id`
825
+ * const subscriptionWithIdOnly = await prisma.subscription.updateManyAndReturn({
826
+ * select: { id: true },
827
+ * where: {
828
+ * // ... provide filter here
829
+ * },
830
+ * data: [
831
+ * // ... provide data here
832
+ * ]
833
+ * })
834
+ * Note, that providing `undefined` is treated as the value not being there.
835
+ * Read more here: https://pris.ly/d/null-undefined
836
+ *
837
+ */
838
+ updateManyAndReturn<T extends SubscriptionUpdateManyAndReturnArgs>(args: Prisma.SelectSubset<T, SubscriptionUpdateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$SubscriptionPayload<ExtArgs>, T, "updateManyAndReturn", GlobalOmitOptions>>
839
+
840
+ /**
841
+ * Create or update one Subscription.
842
+ * @param {SubscriptionUpsertArgs} args - Arguments to update or create a Subscription.
843
+ * @example
844
+ * // Update or create a Subscription
845
+ * const subscription = await prisma.subscription.upsert({
846
+ * create: {
847
+ * // ... data to create a Subscription
848
+ * },
849
+ * update: {
850
+ * // ... in case it already exists, update
851
+ * },
852
+ * where: {
853
+ * // ... the filter for the Subscription we want to update
854
+ * }
855
+ * })
856
+ */
857
+ upsert<T extends SubscriptionUpsertArgs>(args: Prisma.SelectSubset<T, SubscriptionUpsertArgs<ExtArgs>>): Prisma.Prisma__SubscriptionClient<runtime.Types.Result.GetResult<Prisma.$SubscriptionPayload<ExtArgs>, T, "upsert", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>
858
+
859
+
860
+ /**
861
+ * Count the number of Subscriptions.
862
+ * Note, that providing `undefined` is treated as the value not being there.
863
+ * Read more here: https://pris.ly/d/null-undefined
864
+ * @param {SubscriptionCountArgs} args - Arguments to filter Subscriptions to count.
865
+ * @example
866
+ * // Count the number of Subscriptions
867
+ * const count = await prisma.subscription.count({
868
+ * where: {
869
+ * // ... the filter for the Subscriptions we want to count
870
+ * }
871
+ * })
872
+ **/
873
+ count<T extends SubscriptionCountArgs>(
874
+ args?: Prisma.Subset<T, SubscriptionCountArgs>,
875
+ ): Prisma.PrismaPromise<
876
+ T extends runtime.Types.Utils.Record<'select', any>
877
+ ? T['select'] extends true
878
+ ? number
879
+ : Prisma.GetScalarType<T['select'], SubscriptionCountAggregateOutputType>
880
+ : number
881
+ >
882
+
883
+ /**
884
+ * Allows you to perform aggregations operations on a Subscription.
885
+ * Note, that providing `undefined` is treated as the value not being there.
886
+ * Read more here: https://pris.ly/d/null-undefined
887
+ * @param {SubscriptionAggregateArgs} args - Select which aggregations you would like to apply and on what fields.
888
+ * @example
889
+ * // Ordered by age ascending
890
+ * // Where email contains prisma.io
891
+ * // Limited to the 10 users
892
+ * const aggregations = await prisma.user.aggregate({
893
+ * _avg: {
894
+ * age: true,
895
+ * },
896
+ * where: {
897
+ * email: {
898
+ * contains: "prisma.io",
899
+ * },
900
+ * },
901
+ * orderBy: {
902
+ * age: "asc",
903
+ * },
904
+ * take: 10,
905
+ * })
906
+ **/
907
+ aggregate<T extends SubscriptionAggregateArgs>(args: Prisma.Subset<T, SubscriptionAggregateArgs>): Prisma.PrismaPromise<GetSubscriptionAggregateType<T>>
908
+
909
+ /**
910
+ * Group by Subscription.
911
+ * Note, that providing `undefined` is treated as the value not being there.
912
+ * Read more here: https://pris.ly/d/null-undefined
913
+ * @param {SubscriptionGroupByArgs} args - Group by arguments.
914
+ * @example
915
+ * // Group by city, order by createdAt, get count
916
+ * const result = await prisma.user.groupBy({
917
+ * by: ['city', 'createdAt'],
918
+ * orderBy: {
919
+ * createdAt: true
920
+ * },
921
+ * _count: {
922
+ * _all: true
923
+ * },
924
+ * })
925
+ *
926
+ **/
927
+ groupBy<
928
+ T extends SubscriptionGroupByArgs,
929
+ HasSelectOrTake extends Prisma.Or<
930
+ Prisma.Extends<'skip', Prisma.Keys<T>>,
931
+ Prisma.Extends<'take', Prisma.Keys<T>>
932
+ >,
933
+ OrderByArg extends Prisma.True extends HasSelectOrTake
934
+ ? { orderBy: SubscriptionGroupByArgs['orderBy'] }
935
+ : { orderBy?: SubscriptionGroupByArgs['orderBy'] },
936
+ OrderFields extends Prisma.ExcludeUnderscoreKeys<Prisma.Keys<Prisma.MaybeTupleToUnion<T['orderBy']>>>,
937
+ ByFields extends Prisma.MaybeTupleToUnion<T['by']>,
938
+ ByValid extends Prisma.Has<ByFields, OrderFields>,
939
+ HavingFields extends Prisma.GetHavingFields<T['having']>,
940
+ HavingValid extends Prisma.Has<ByFields, HavingFields>,
941
+ ByEmpty extends T['by'] extends never[] ? Prisma.True : Prisma.False,
942
+ InputErrors extends ByEmpty extends Prisma.True
943
+ ? `Error: "by" must not be empty.`
944
+ : HavingValid extends Prisma.False
945
+ ? {
946
+ [P in HavingFields]: P extends ByFields
947
+ ? never
948
+ : P extends string
949
+ ? `Error: Field "${P}" used in "having" needs to be provided in "by".`
950
+ : [
951
+ Error,
952
+ 'Field ',
953
+ P,
954
+ ` in "having" needs to be provided in "by"`,
955
+ ]
956
+ }[HavingFields]
957
+ : 'take' extends Prisma.Keys<T>
958
+ ? 'orderBy' extends Prisma.Keys<T>
959
+ ? ByValid extends Prisma.True
960
+ ? {}
961
+ : {
962
+ [P in OrderFields]: P extends ByFields
963
+ ? never
964
+ : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
965
+ }[OrderFields]
966
+ : 'Error: If you provide "take", you also need to provide "orderBy"'
967
+ : 'skip' extends Prisma.Keys<T>
968
+ ? 'orderBy' extends Prisma.Keys<T>
969
+ ? ByValid extends Prisma.True
970
+ ? {}
971
+ : {
972
+ [P in OrderFields]: P extends ByFields
973
+ ? never
974
+ : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
975
+ }[OrderFields]
976
+ : 'Error: If you provide "skip", you also need to provide "orderBy"'
977
+ : ByValid extends Prisma.True
978
+ ? {}
979
+ : {
980
+ [P in OrderFields]: P extends ByFields
981
+ ? never
982
+ : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
983
+ }[OrderFields]
984
+ >(args: Prisma.SubsetIntersection<T, SubscriptionGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetSubscriptionGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
985
+ /**
986
+ * Fields of the Subscription model
987
+ */
988
+ readonly fields: SubscriptionFieldRefs;
989
+ }
990
+
991
+ /**
992
+ * The delegate class that acts as a "Promise-like" for Subscription.
993
+ * Why is this prefixed with `Prisma__`?
994
+ * Because we want to prevent naming conflicts as mentioned in
995
+ * https://github.com/prisma/prisma-client-js/issues/707
996
+ */
997
+ export interface Prisma__SubscriptionClient<T, Null = never, ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs, GlobalOmitOptions = {}> extends Prisma.PrismaPromise<T> {
998
+ readonly [Symbol.toStringTag]: "PrismaPromise"
999
+ user<T extends Prisma.UserDefaultArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.UserDefaultArgs<ExtArgs>>): Prisma.Prisma__UserClient<runtime.Types.Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | Null, Null, ExtArgs, GlobalOmitOptions>
1000
+ /**
1001
+ * Attaches callbacks for the resolution and/or rejection of the Promise.
1002
+ * @param onfulfilled The callback to execute when the Promise is resolved.
1003
+ * @param onrejected The callback to execute when the Promise is rejected.
1004
+ * @returns A Promise for the completion of which ever callback is executed.
1005
+ */
1006
+ 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>
1007
+ /**
1008
+ * Attaches a callback for only the rejection of the Promise.
1009
+ * @param onrejected The callback to execute when the Promise is rejected.
1010
+ * @returns A Promise for the completion of the callback.
1011
+ */
1012
+ catch<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): runtime.Types.Utils.JsPromise<T | TResult>
1013
+ /**
1014
+ * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The
1015
+ * resolved value cannot be modified from the callback.
1016
+ * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected).
1017
+ * @returns A Promise for the completion of the callback.
1018
+ */
1019
+ finally(onfinally?: (() => void) | undefined | null): runtime.Types.Utils.JsPromise<T>
1020
+ }
1021
+
1022
+
1023
+
1024
+
1025
+ /**
1026
+ * Fields of the Subscription model
1027
+ */
1028
+ export interface SubscriptionFieldRefs {
1029
+ readonly id: Prisma.FieldRef<"Subscription", 'String'>
1030
+ readonly userId: Prisma.FieldRef<"Subscription", 'String'>
1031
+ readonly stripeCustomerId: Prisma.FieldRef<"Subscription", 'String'>
1032
+ readonly stripePriceId: Prisma.FieldRef<"Subscription", 'String'>
1033
+ readonly stripeSubscriptionId: Prisma.FieldRef<"Subscription", 'String'>
1034
+ readonly status: Prisma.FieldRef<"Subscription", 'String'>
1035
+ readonly currentPeriodEnd: Prisma.FieldRef<"Subscription", 'DateTime'>
1036
+ readonly cancelAtPeriodEnd: Prisma.FieldRef<"Subscription", 'Boolean'>
1037
+ readonly createdAt: Prisma.FieldRef<"Subscription", 'DateTime'>
1038
+ readonly updatedAt: Prisma.FieldRef<"Subscription", 'DateTime'>
1039
+ }
1040
+
1041
+
1042
+ // Custom InputTypes
1043
+ /**
1044
+ * Subscription findUnique
1045
+ */
1046
+ export type SubscriptionFindUniqueArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1047
+ /**
1048
+ * Select specific fields to fetch from the Subscription
1049
+ */
1050
+ select?: Prisma.SubscriptionSelect<ExtArgs> | null
1051
+ /**
1052
+ * Omit specific fields from the Subscription
1053
+ */
1054
+ omit?: Prisma.SubscriptionOmit<ExtArgs> | null
1055
+ /**
1056
+ * Choose, which related nodes to fetch as well
1057
+ */
1058
+ include?: Prisma.SubscriptionInclude<ExtArgs> | null
1059
+ /**
1060
+ * Filter, which Subscription to fetch.
1061
+ */
1062
+ where: Prisma.SubscriptionWhereUniqueInput
1063
+ }
1064
+
1065
+ /**
1066
+ * Subscription findUniqueOrThrow
1067
+ */
1068
+ export type SubscriptionFindUniqueOrThrowArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1069
+ /**
1070
+ * Select specific fields to fetch from the Subscription
1071
+ */
1072
+ select?: Prisma.SubscriptionSelect<ExtArgs> | null
1073
+ /**
1074
+ * Omit specific fields from the Subscription
1075
+ */
1076
+ omit?: Prisma.SubscriptionOmit<ExtArgs> | null
1077
+ /**
1078
+ * Choose, which related nodes to fetch as well
1079
+ */
1080
+ include?: Prisma.SubscriptionInclude<ExtArgs> | null
1081
+ /**
1082
+ * Filter, which Subscription to fetch.
1083
+ */
1084
+ where: Prisma.SubscriptionWhereUniqueInput
1085
+ }
1086
+
1087
+ /**
1088
+ * Subscription findFirst
1089
+ */
1090
+ export type SubscriptionFindFirstArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1091
+ /**
1092
+ * Select specific fields to fetch from the Subscription
1093
+ */
1094
+ select?: Prisma.SubscriptionSelect<ExtArgs> | null
1095
+ /**
1096
+ * Omit specific fields from the Subscription
1097
+ */
1098
+ omit?: Prisma.SubscriptionOmit<ExtArgs> | null
1099
+ /**
1100
+ * Choose, which related nodes to fetch as well
1101
+ */
1102
+ include?: Prisma.SubscriptionInclude<ExtArgs> | null
1103
+ /**
1104
+ * Filter, which Subscription to fetch.
1105
+ */
1106
+ where?: Prisma.SubscriptionWhereInput
1107
+ /**
1108
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
1109
+ *
1110
+ * Determine the order of Subscriptions to fetch.
1111
+ */
1112
+ orderBy?: Prisma.SubscriptionOrderByWithRelationInput | Prisma.SubscriptionOrderByWithRelationInput[]
1113
+ /**
1114
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
1115
+ *
1116
+ * Sets the position for searching for Subscriptions.
1117
+ */
1118
+ cursor?: Prisma.SubscriptionWhereUniqueInput
1119
+ /**
1120
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
1121
+ *
1122
+ * Take `±n` Subscriptions from the position of the cursor.
1123
+ */
1124
+ take?: number
1125
+ /**
1126
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
1127
+ *
1128
+ * Skip the first `n` Subscriptions.
1129
+ */
1130
+ skip?: number
1131
+ /**
1132
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
1133
+ *
1134
+ * Filter by unique combinations of Subscriptions.
1135
+ */
1136
+ distinct?: Prisma.SubscriptionScalarFieldEnum | Prisma.SubscriptionScalarFieldEnum[]
1137
+ }
1138
+
1139
+ /**
1140
+ * Subscription findFirstOrThrow
1141
+ */
1142
+ export type SubscriptionFindFirstOrThrowArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1143
+ /**
1144
+ * Select specific fields to fetch from the Subscription
1145
+ */
1146
+ select?: Prisma.SubscriptionSelect<ExtArgs> | null
1147
+ /**
1148
+ * Omit specific fields from the Subscription
1149
+ */
1150
+ omit?: Prisma.SubscriptionOmit<ExtArgs> | null
1151
+ /**
1152
+ * Choose, which related nodes to fetch as well
1153
+ */
1154
+ include?: Prisma.SubscriptionInclude<ExtArgs> | null
1155
+ /**
1156
+ * Filter, which Subscription to fetch.
1157
+ */
1158
+ where?: Prisma.SubscriptionWhereInput
1159
+ /**
1160
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
1161
+ *
1162
+ * Determine the order of Subscriptions to fetch.
1163
+ */
1164
+ orderBy?: Prisma.SubscriptionOrderByWithRelationInput | Prisma.SubscriptionOrderByWithRelationInput[]
1165
+ /**
1166
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
1167
+ *
1168
+ * Sets the position for searching for Subscriptions.
1169
+ */
1170
+ cursor?: Prisma.SubscriptionWhereUniqueInput
1171
+ /**
1172
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
1173
+ *
1174
+ * Take `±n` Subscriptions from the position of the cursor.
1175
+ */
1176
+ take?: number
1177
+ /**
1178
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
1179
+ *
1180
+ * Skip the first `n` Subscriptions.
1181
+ */
1182
+ skip?: number
1183
+ /**
1184
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
1185
+ *
1186
+ * Filter by unique combinations of Subscriptions.
1187
+ */
1188
+ distinct?: Prisma.SubscriptionScalarFieldEnum | Prisma.SubscriptionScalarFieldEnum[]
1189
+ }
1190
+
1191
+ /**
1192
+ * Subscription findMany
1193
+ */
1194
+ export type SubscriptionFindManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1195
+ /**
1196
+ * Select specific fields to fetch from the Subscription
1197
+ */
1198
+ select?: Prisma.SubscriptionSelect<ExtArgs> | null
1199
+ /**
1200
+ * Omit specific fields from the Subscription
1201
+ */
1202
+ omit?: Prisma.SubscriptionOmit<ExtArgs> | null
1203
+ /**
1204
+ * Choose, which related nodes to fetch as well
1205
+ */
1206
+ include?: Prisma.SubscriptionInclude<ExtArgs> | null
1207
+ /**
1208
+ * Filter, which Subscriptions to fetch.
1209
+ */
1210
+ where?: Prisma.SubscriptionWhereInput
1211
+ /**
1212
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
1213
+ *
1214
+ * Determine the order of Subscriptions to fetch.
1215
+ */
1216
+ orderBy?: Prisma.SubscriptionOrderByWithRelationInput | Prisma.SubscriptionOrderByWithRelationInput[]
1217
+ /**
1218
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
1219
+ *
1220
+ * Sets the position for listing Subscriptions.
1221
+ */
1222
+ cursor?: Prisma.SubscriptionWhereUniqueInput
1223
+ /**
1224
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
1225
+ *
1226
+ * Take `±n` Subscriptions from the position of the cursor.
1227
+ */
1228
+ take?: number
1229
+ /**
1230
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
1231
+ *
1232
+ * Skip the first `n` Subscriptions.
1233
+ */
1234
+ skip?: number
1235
+ /**
1236
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
1237
+ *
1238
+ * Filter by unique combinations of Subscriptions.
1239
+ */
1240
+ distinct?: Prisma.SubscriptionScalarFieldEnum | Prisma.SubscriptionScalarFieldEnum[]
1241
+ }
1242
+
1243
+ /**
1244
+ * Subscription create
1245
+ */
1246
+ export type SubscriptionCreateArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1247
+ /**
1248
+ * Select specific fields to fetch from the Subscription
1249
+ */
1250
+ select?: Prisma.SubscriptionSelect<ExtArgs> | null
1251
+ /**
1252
+ * Omit specific fields from the Subscription
1253
+ */
1254
+ omit?: Prisma.SubscriptionOmit<ExtArgs> | null
1255
+ /**
1256
+ * Choose, which related nodes to fetch as well
1257
+ */
1258
+ include?: Prisma.SubscriptionInclude<ExtArgs> | null
1259
+ /**
1260
+ * The data needed to create a Subscription.
1261
+ */
1262
+ data: Prisma.XOR<Prisma.SubscriptionCreateInput, Prisma.SubscriptionUncheckedCreateInput>
1263
+ }
1264
+
1265
+ /**
1266
+ * Subscription createMany
1267
+ */
1268
+ export type SubscriptionCreateManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1269
+ /**
1270
+ * The data used to create many Subscriptions.
1271
+ */
1272
+ data: Prisma.SubscriptionCreateManyInput | Prisma.SubscriptionCreateManyInput[]
1273
+ skipDuplicates?: boolean
1274
+ }
1275
+
1276
+ /**
1277
+ * Subscription createManyAndReturn
1278
+ */
1279
+ export type SubscriptionCreateManyAndReturnArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1280
+ /**
1281
+ * Select specific fields to fetch from the Subscription
1282
+ */
1283
+ select?: Prisma.SubscriptionSelectCreateManyAndReturn<ExtArgs> | null
1284
+ /**
1285
+ * Omit specific fields from the Subscription
1286
+ */
1287
+ omit?: Prisma.SubscriptionOmit<ExtArgs> | null
1288
+ /**
1289
+ * The data used to create many Subscriptions.
1290
+ */
1291
+ data: Prisma.SubscriptionCreateManyInput | Prisma.SubscriptionCreateManyInput[]
1292
+ skipDuplicates?: boolean
1293
+ /**
1294
+ * Choose, which related nodes to fetch as well
1295
+ */
1296
+ include?: Prisma.SubscriptionIncludeCreateManyAndReturn<ExtArgs> | null
1297
+ }
1298
+
1299
+ /**
1300
+ * Subscription update
1301
+ */
1302
+ export type SubscriptionUpdateArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1303
+ /**
1304
+ * Select specific fields to fetch from the Subscription
1305
+ */
1306
+ select?: Prisma.SubscriptionSelect<ExtArgs> | null
1307
+ /**
1308
+ * Omit specific fields from the Subscription
1309
+ */
1310
+ omit?: Prisma.SubscriptionOmit<ExtArgs> | null
1311
+ /**
1312
+ * Choose, which related nodes to fetch as well
1313
+ */
1314
+ include?: Prisma.SubscriptionInclude<ExtArgs> | null
1315
+ /**
1316
+ * The data needed to update a Subscription.
1317
+ */
1318
+ data: Prisma.XOR<Prisma.SubscriptionUpdateInput, Prisma.SubscriptionUncheckedUpdateInput>
1319
+ /**
1320
+ * Choose, which Subscription to update.
1321
+ */
1322
+ where: Prisma.SubscriptionWhereUniqueInput
1323
+ }
1324
+
1325
+ /**
1326
+ * Subscription updateMany
1327
+ */
1328
+ export type SubscriptionUpdateManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1329
+ /**
1330
+ * The data used to update Subscriptions.
1331
+ */
1332
+ data: Prisma.XOR<Prisma.SubscriptionUpdateManyMutationInput, Prisma.SubscriptionUncheckedUpdateManyInput>
1333
+ /**
1334
+ * Filter which Subscriptions to update
1335
+ */
1336
+ where?: Prisma.SubscriptionWhereInput
1337
+ /**
1338
+ * Limit how many Subscriptions to update.
1339
+ */
1340
+ limit?: number
1341
+ }
1342
+
1343
+ /**
1344
+ * Subscription updateManyAndReturn
1345
+ */
1346
+ export type SubscriptionUpdateManyAndReturnArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1347
+ /**
1348
+ * Select specific fields to fetch from the Subscription
1349
+ */
1350
+ select?: Prisma.SubscriptionSelectUpdateManyAndReturn<ExtArgs> | null
1351
+ /**
1352
+ * Omit specific fields from the Subscription
1353
+ */
1354
+ omit?: Prisma.SubscriptionOmit<ExtArgs> | null
1355
+ /**
1356
+ * The data used to update Subscriptions.
1357
+ */
1358
+ data: Prisma.XOR<Prisma.SubscriptionUpdateManyMutationInput, Prisma.SubscriptionUncheckedUpdateManyInput>
1359
+ /**
1360
+ * Filter which Subscriptions to update
1361
+ */
1362
+ where?: Prisma.SubscriptionWhereInput
1363
+ /**
1364
+ * Limit how many Subscriptions to update.
1365
+ */
1366
+ limit?: number
1367
+ /**
1368
+ * Choose, which related nodes to fetch as well
1369
+ */
1370
+ include?: Prisma.SubscriptionIncludeUpdateManyAndReturn<ExtArgs> | null
1371
+ }
1372
+
1373
+ /**
1374
+ * Subscription upsert
1375
+ */
1376
+ export type SubscriptionUpsertArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1377
+ /**
1378
+ * Select specific fields to fetch from the Subscription
1379
+ */
1380
+ select?: Prisma.SubscriptionSelect<ExtArgs> | null
1381
+ /**
1382
+ * Omit specific fields from the Subscription
1383
+ */
1384
+ omit?: Prisma.SubscriptionOmit<ExtArgs> | null
1385
+ /**
1386
+ * Choose, which related nodes to fetch as well
1387
+ */
1388
+ include?: Prisma.SubscriptionInclude<ExtArgs> | null
1389
+ /**
1390
+ * The filter to search for the Subscription to update in case it exists.
1391
+ */
1392
+ where: Prisma.SubscriptionWhereUniqueInput
1393
+ /**
1394
+ * In case the Subscription found by the `where` argument doesn't exist, create a new Subscription with this data.
1395
+ */
1396
+ create: Prisma.XOR<Prisma.SubscriptionCreateInput, Prisma.SubscriptionUncheckedCreateInput>
1397
+ /**
1398
+ * In case the Subscription was found with the provided `where` argument, update it with this data.
1399
+ */
1400
+ update: Prisma.XOR<Prisma.SubscriptionUpdateInput, Prisma.SubscriptionUncheckedUpdateInput>
1401
+ }
1402
+
1403
+ /**
1404
+ * Subscription delete
1405
+ */
1406
+ export type SubscriptionDeleteArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1407
+ /**
1408
+ * Select specific fields to fetch from the Subscription
1409
+ */
1410
+ select?: Prisma.SubscriptionSelect<ExtArgs> | null
1411
+ /**
1412
+ * Omit specific fields from the Subscription
1413
+ */
1414
+ omit?: Prisma.SubscriptionOmit<ExtArgs> | null
1415
+ /**
1416
+ * Choose, which related nodes to fetch as well
1417
+ */
1418
+ include?: Prisma.SubscriptionInclude<ExtArgs> | null
1419
+ /**
1420
+ * Filter which Subscription to delete.
1421
+ */
1422
+ where: Prisma.SubscriptionWhereUniqueInput
1423
+ }
1424
+
1425
+ /**
1426
+ * Subscription deleteMany
1427
+ */
1428
+ export type SubscriptionDeleteManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1429
+ /**
1430
+ * Filter which Subscriptions to delete
1431
+ */
1432
+ where?: Prisma.SubscriptionWhereInput
1433
+ /**
1434
+ * Limit how many Subscriptions to delete.
1435
+ */
1436
+ limit?: number
1437
+ }
1438
+
1439
+ /**
1440
+ * Subscription without action
1441
+ */
1442
+ export type SubscriptionDefaultArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1443
+ /**
1444
+ * Select specific fields to fetch from the Subscription
1445
+ */
1446
+ select?: Prisma.SubscriptionSelect<ExtArgs> | null
1447
+ /**
1448
+ * Omit specific fields from the Subscription
1449
+ */
1450
+ omit?: Prisma.SubscriptionOmit<ExtArgs> | null
1451
+ /**
1452
+ * Choose, which related nodes to fetch as well
1453
+ */
1454
+ include?: Prisma.SubscriptionInclude<ExtArgs> | null
1455
+ }