@purpleschool/multisite 0.0.21 → 0.0.22

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 (129) hide show
  1. package/api/controller/http/index.ts +2 -0
  2. package/api/controller/http/user-to-product.ts +7 -0
  3. package/api/controller/http/user-to-subscription.ts +8 -0
  4. package/api/routes.ts +18 -0
  5. package/build/api/controller/http/index.d.ts +2 -0
  6. package/build/api/controller/http/index.d.ts.map +1 -1
  7. package/build/api/controller/http/index.js +2 -0
  8. package/build/api/controller/http/user-to-product.d.ts +7 -0
  9. package/build/api/controller/http/user-to-product.d.ts.map +1 -0
  10. package/build/api/controller/http/user-to-product.js +9 -0
  11. package/build/api/controller/http/user-to-subscription.d.ts +8 -0
  12. package/build/api/controller/http/user-to-subscription.d.ts.map +1 -0
  13. package/build/api/controller/http/user-to-subscription.js +10 -0
  14. package/build/api/routes.d.ts +11 -0
  15. package/build/api/routes.d.ts.map +1 -1
  16. package/build/api/routes.js +11 -0
  17. package/build/commands/image-editor/execute-image-editor.command.d.ts +4 -4
  18. package/build/commands/image-editor/retry-image-editor-job.command.d.ts +4 -4
  19. package/build/commands/image-editor/set-reaction-to-image-editor-job.command.d.ts +4 -4
  20. package/build/commands/image-editor/update-image-editor-job-title.command.d.ts +4 -4
  21. package/build/commands/image-generation/execute-image-generation.command.d.ts +4 -4
  22. package/build/commands/image-generation/retry-image-generation-job.command.d.ts +4 -4
  23. package/build/commands/image-generation/set-reaction-to-image-generation-job.command.d.ts +4 -4
  24. package/build/commands/image-generation/update-image-generation-job-title.command.d.ts +4 -4
  25. package/build/commands/index.d.ts +2 -0
  26. package/build/commands/index.d.ts.map +1 -1
  27. package/build/commands/index.js +2 -0
  28. package/build/commands/page/create-page.command.d.ts +4 -4
  29. package/build/commands/page/find-page-by-alias.command.d.ts +12 -12
  30. package/build/commands/page/find-page-by-criteria.command.d.ts +4 -4
  31. package/build/commands/page/find-page.command.d.ts +8 -8
  32. package/build/commands/page/update-page.command.d.ts +4 -4
  33. package/build/commands/payment/cloud-payments.command.d.ts +2 -2
  34. package/build/commands/stt/execute-stt.command.d.ts +12 -12
  35. package/build/commands/stt/retry-stt-job.command.d.ts +12 -12
  36. package/build/commands/stt/set-reaction-to-stt-job.command.d.ts +12 -12
  37. package/build/commands/stt/update-stt-job-title.command.d.ts +12 -12
  38. package/build/commands/tts/execute-tts.command.d.ts +12 -12
  39. package/build/commands/tts/retry-tts-job.command.d.ts +12 -12
  40. package/build/commands/tts/set-reaction-to-tts-job.command.d.ts +12 -12
  41. package/build/commands/tts/update-tts-job-title.command.d.ts +12 -12
  42. package/build/commands/unregistered-user/upsert-unregistered-user.command.d.ts +4 -4
  43. package/build/commands/user-to-product/delete-user-to-product.command.d.ts +20 -0
  44. package/build/commands/user-to-product/delete-user-to-product.command.d.ts.map +1 -0
  45. package/build/commands/user-to-product/delete-user-to-product.command.js +13 -0
  46. package/build/commands/user-to-product/get-user-to-product-by-uuid.command.d.ts +75 -0
  47. package/build/commands/user-to-product/get-user-to-product-by-uuid.command.d.ts.map +1 -0
  48. package/build/commands/user-to-product/get-user-to-product-by-uuid.command.js +14 -0
  49. package/build/commands/user-to-product/index.d.ts +4 -0
  50. package/build/commands/user-to-product/index.d.ts.map +1 -0
  51. package/build/commands/user-to-product/index.js +19 -0
  52. package/build/commands/user-to-product/update-user-to-product.command.d.ts +93 -0
  53. package/build/commands/user-to-product/update-user-to-product.command.d.ts.map +1 -0
  54. package/build/commands/user-to-product/update-user-to-product.command.js +21 -0
  55. package/build/commands/user-to-subscription/admin-cancel-subscription.command.d.ts +14 -0
  56. package/build/commands/user-to-subscription/admin-cancel-subscription.command.d.ts.map +1 -0
  57. package/build/commands/user-to-subscription/admin-cancel-subscription.command.js +11 -0
  58. package/build/commands/user-to-subscription/delete-user-to-subscription.command.d.ts +20 -0
  59. package/build/commands/user-to-subscription/delete-user-to-subscription.command.d.ts.map +1 -0
  60. package/build/commands/user-to-subscription/delete-user-to-subscription.command.js +13 -0
  61. package/build/commands/user-to-subscription/get-user-to-subscription-by-uuid.command.d.ts +115 -0
  62. package/build/commands/user-to-subscription/get-user-to-subscription-by-uuid.command.d.ts.map +1 -0
  63. package/build/commands/user-to-subscription/get-user-to-subscription-by-uuid.command.js +14 -0
  64. package/build/commands/user-to-subscription/index.d.ts +5 -0
  65. package/build/commands/user-to-subscription/index.d.ts.map +1 -0
  66. package/build/commands/user-to-subscription/index.js +20 -0
  67. package/build/commands/user-to-subscription/update-user-to-subscription.command.d.ts +157 -0
  68. package/build/commands/user-to-subscription/update-user-to-subscription.command.d.ts.map +1 -0
  69. package/build/commands/user-to-subscription/update-user-to-subscription.command.js +29 -0
  70. package/build/constants/errors/errors.d.ts +60 -0
  71. package/build/constants/errors/errors.d.ts.map +1 -1
  72. package/build/constants/errors/errors.js +62 -0
  73. package/build/models/image-editor/image-editor-config.schema.d.ts +10 -10
  74. package/build/models/image-editor/image-editor-job.schema.d.ts +2 -2
  75. package/build/models/image-editor/image-editor-model.schema.d.ts +2 -2
  76. package/build/models/image-editor/image-editor-prompt-group.schema.d.ts +4 -4
  77. package/build/models/image-editor/image-editor-system-prompt.schema.d.ts +2 -2
  78. package/build/models/image-generation/image-generation-config.schema.d.ts +6 -6
  79. package/build/models/image-generation/image-generation-job.schema.d.ts +2 -2
  80. package/build/models/image-generation/image-generation-model.schema.d.ts +2 -2
  81. package/build/models/image-generation/image-generation-vendor.schema.d.ts +4 -4
  82. package/build/models/index.d.ts +2 -0
  83. package/build/models/index.d.ts.map +1 -1
  84. package/build/models/index.js +2 -0
  85. package/build/models/page.schema.d.ts +4 -4
  86. package/build/models/stt/stt-config.schema.d.ts +8 -8
  87. package/build/models/stt/stt-job.schema.d.ts +6 -6
  88. package/build/models/stt/stt-model.schema.d.ts +4 -4
  89. package/build/models/tts/tts-config.schema.d.ts +8 -8
  90. package/build/models/tts/tts-job.schema.d.ts +6 -6
  91. package/build/models/tts/tts-model.schema.d.ts +4 -4
  92. package/build/models/user-to-product.schema.d.ts +37 -0
  93. package/build/models/user-to-product.schema.d.ts.map +1 -0
  94. package/build/models/user-to-product.schema.js +17 -0
  95. package/build/models/user-to-subscription.schema.d.ts +61 -0
  96. package/build/models/user-to-subscription.schema.d.ts.map +1 -0
  97. package/build/models/user-to-subscription.schema.js +25 -0
  98. package/build/queries/image-editor/find-image-editor-jobs.command.d.ts +4 -4
  99. package/build/queries/image-editor/get-image-editor-config.command.d.ts +14 -14
  100. package/build/queries/image-editor/get-image-editor-job.command.d.ts +4 -4
  101. package/build/queries/image-generation/find-image-generation-jobs.command.d.ts +4 -4
  102. package/build/queries/image-generation/get-image-generation-config.command.d.ts +8 -8
  103. package/build/queries/image-generation/get-image-generation-job.command.d.ts +4 -4
  104. package/build/queries/payment/get-payment-history.command.d.ts +6 -6
  105. package/build/queries/stt/find-stt-jobs.command.d.ts +12 -12
  106. package/build/queries/stt/get-stt-config.command.d.ts +12 -12
  107. package/build/queries/stt/get-stt-job.command.d.ts +12 -12
  108. package/build/queries/subscription/get-subscriptions-summary.command.d.ts +16 -16
  109. package/build/queries/tts/find-tts-jobs.command.d.ts +12 -12
  110. package/build/queries/tts/get-tts-config.command.d.ts +12 -12
  111. package/build/queries/tts/get-tts-job.command.d.ts +12 -12
  112. package/build/queries/user/get-my-products.command.d.ts +8 -8
  113. package/build/queries/user/get-my-subscriptions.command.d.ts +12 -12
  114. package/build/queries/user/get-user-payments.command.d.ts +18 -18
  115. package/commands/index.ts +2 -0
  116. package/commands/user-to-product/delete-user-to-product.command.ts +13 -0
  117. package/commands/user-to-product/get-user-to-product-by-uuid.command.ts +14 -0
  118. package/commands/user-to-product/index.ts +3 -0
  119. package/commands/user-to-product/update-user-to-product.command.ts +23 -0
  120. package/commands/user-to-subscription/admin-cancel-subscription.command.ts +11 -0
  121. package/commands/user-to-subscription/delete-user-to-subscription.command.ts +13 -0
  122. package/commands/user-to-subscription/get-user-to-subscription-by-uuid.command.ts +14 -0
  123. package/commands/user-to-subscription/index.ts +4 -0
  124. package/commands/user-to-subscription/update-user-to-subscription.command.ts +31 -0
  125. package/constants/errors/errors.ts +64 -0
  126. package/models/index.ts +2 -0
  127. package/models/user-to-product.schema.ts +15 -0
  128. package/models/user-to-subscription.schema.ts +23 -0
  129. package/package.json +1 -1
@@ -100,9 +100,9 @@ export declare const ImageEditorJobSchema: z.ZodObject<{
100
100
  systemPromptId?: string | undefined;
101
101
  userHasActiveSubscriptionOrProduct?: boolean | undefined;
102
102
  };
103
- title: string;
104
103
  createdAt: string | Date;
105
104
  updatedAt: string | Date;
105
+ title: string;
106
106
  error: string | null;
107
107
  modelId: string;
108
108
  prompt: string;
@@ -137,9 +137,9 @@ export declare const ImageEditorJobSchema: z.ZodObject<{
137
137
  systemPromptId?: string | undefined;
138
138
  userHasActiveSubscriptionOrProduct?: boolean | undefined;
139
139
  };
140
- title: string;
141
140
  createdAt: string | Date;
142
141
  updatedAt: string | Date;
142
+ title: string;
143
143
  error: string | null;
144
144
  modelId: string;
145
145
  prompt: string;
@@ -161,9 +161,9 @@ export declare const ImageEditorModelSchema: z.ZodObject<{
161
161
  };
162
162
  };
163
163
  maxInputLength: number;
164
- statusCheckEndpoint?: string | null | undefined;
165
164
  createdAt?: string | Date | undefined;
166
165
  updatedAt?: string | Date | undefined;
166
+ statusCheckEndpoint?: string | null | undefined;
167
167
  }, {
168
168
  uuid: string;
169
169
  status: TOOL_MODEL_STATUS;
@@ -204,9 +204,9 @@ export declare const ImageEditorModelSchema: z.ZodObject<{
204
204
  };
205
205
  };
206
206
  maxInputLength: number;
207
- statusCheckEndpoint?: string | null | undefined;
208
207
  createdAt?: string | Date | undefined;
209
208
  updatedAt?: string | Date | undefined;
209
+ statusCheckEndpoint?: string | null | undefined;
210
210
  }>;
211
211
  export type ImageEditorModel = z.infer<typeof ImageEditorModelSchema>;
212
212
  //# sourceMappingURL=image-editor-model.schema.d.ts.map
@@ -66,9 +66,9 @@ export declare const ImageEditorPromptGroupSchema: z.ZodObject<{
66
66
  allowUserPrompt: boolean;
67
67
  groupId: string;
68
68
  params?: Record<string, any> | undefined;
69
- strategy?: import("../..").IMAGE_EDITING_STRATEGY | null | undefined;
70
69
  createdAt?: string | Date | undefined;
71
70
  updatedAt?: string | Date | undefined;
71
+ strategy?: import("../..").IMAGE_EDITING_STRATEGY | null | undefined;
72
72
  preview?: Record<string, any> | undefined;
73
73
  placeholder?: string | null | undefined;
74
74
  }, {
@@ -80,9 +80,9 @@ export declare const ImageEditorPromptGroupSchema: z.ZodObject<{
80
80
  allowUserPrompt: boolean;
81
81
  groupId: string;
82
82
  params?: Record<string, any> | undefined;
83
- strategy?: import("../..").IMAGE_EDITING_STRATEGY | null | undefined;
84
83
  createdAt?: string | Date | undefined;
85
84
  updatedAt?: string | Date | undefined;
85
+ strategy?: import("../..").IMAGE_EDITING_STRATEGY | null | undefined;
86
86
  preview?: Record<string, any> | undefined;
87
87
  placeholder?: string | null | undefined;
88
88
  }>, "many">;
@@ -109,9 +109,9 @@ export declare const ImageEditorPromptGroupSchema: z.ZodObject<{
109
109
  allowUserPrompt: boolean;
110
110
  groupId: string;
111
111
  params?: Record<string, any> | undefined;
112
- strategy?: import("../..").IMAGE_EDITING_STRATEGY | null | undefined;
113
112
  createdAt?: string | Date | undefined;
114
113
  updatedAt?: string | Date | undefined;
114
+ strategy?: import("../..").IMAGE_EDITING_STRATEGY | null | undefined;
115
115
  preview?: Record<string, any> | undefined;
116
116
  placeholder?: string | null | undefined;
117
117
  }[];
@@ -138,9 +138,9 @@ export declare const ImageEditorPromptGroupSchema: z.ZodObject<{
138
138
  allowUserPrompt: boolean;
139
139
  groupId: string;
140
140
  params?: Record<string, any> | undefined;
141
- strategy?: import("../..").IMAGE_EDITING_STRATEGY | null | undefined;
142
141
  createdAt?: string | Date | undefined;
143
142
  updatedAt?: string | Date | undefined;
143
+ strategy?: import("../..").IMAGE_EDITING_STRATEGY | null | undefined;
144
144
  preview?: Record<string, any> | undefined;
145
145
  placeholder?: string | null | undefined;
146
146
  }[];
@@ -23,9 +23,9 @@ export declare const ImageEditorSystemPromptSchema: z.ZodObject<{
23
23
  allowUserPrompt: boolean;
24
24
  groupId: string;
25
25
  params?: Record<string, any> | undefined;
26
- strategy?: IMAGE_EDITING_STRATEGY | null | undefined;
27
26
  createdAt?: string | Date | undefined;
28
27
  updatedAt?: string | Date | undefined;
28
+ strategy?: IMAGE_EDITING_STRATEGY | null | undefined;
29
29
  preview?: Record<string, any> | undefined;
30
30
  placeholder?: string | null | undefined;
31
31
  }, {
@@ -37,9 +37,9 @@ export declare const ImageEditorSystemPromptSchema: z.ZodObject<{
37
37
  allowUserPrompt: boolean;
38
38
  groupId: string;
39
39
  params?: Record<string, any> | undefined;
40
- strategy?: IMAGE_EDITING_STRATEGY | null | undefined;
41
40
  createdAt?: string | Date | undefined;
42
41
  updatedAt?: string | Date | undefined;
42
+ strategy?: IMAGE_EDITING_STRATEGY | null | undefined;
43
43
  preview?: Record<string, any> | undefined;
44
44
  placeholder?: string | null | undefined;
45
45
  }>;
@@ -208,9 +208,9 @@ export declare const ImageGenerationConfigSchema: z.ZodObject<{
208
208
  translatePrompt: boolean;
209
209
  order: number;
210
210
  vendorId: string;
211
- statusCheckEndpoint?: string | null | undefined;
212
211
  createdAt?: string | Date | undefined;
213
212
  updatedAt?: string | Date | undefined;
213
+ statusCheckEndpoint?: string | null | undefined;
214
214
  }, {
215
215
  price: number;
216
216
  uuid: string;
@@ -253,9 +253,9 @@ export declare const ImageGenerationConfigSchema: z.ZodObject<{
253
253
  translatePrompt: boolean;
254
254
  order: number;
255
255
  vendorId: string;
256
- statusCheckEndpoint?: string | null | undefined;
257
256
  createdAt?: string | Date | undefined;
258
257
  updatedAt?: string | Date | undefined;
258
+ statusCheckEndpoint?: string | null | undefined;
259
259
  }>, "many">;
260
260
  }, "strip", z.ZodTypeAny, {
261
261
  uuid: string;
@@ -313,9 +313,9 @@ export declare const ImageGenerationConfigSchema: z.ZodObject<{
313
313
  translatePrompt: boolean;
314
314
  order: number;
315
315
  vendorId: string;
316
- statusCheckEndpoint?: string | null | undefined;
317
316
  createdAt?: string | Date | undefined;
318
317
  updatedAt?: string | Date | undefined;
318
+ statusCheckEndpoint?: string | null | undefined;
319
319
  }[];
320
320
  }, {
321
321
  uuid: string;
@@ -373,9 +373,9 @@ export declare const ImageGenerationConfigSchema: z.ZodObject<{
373
373
  translatePrompt: boolean;
374
374
  order: number;
375
375
  vendorId: string;
376
- statusCheckEndpoint?: string | null | undefined;
377
376
  createdAt?: string | Date | undefined;
378
377
  updatedAt?: string | Date | undefined;
378
+ statusCheckEndpoint?: string | null | undefined;
379
379
  }[];
380
380
  }>, "many">;
381
381
  presets: z.ZodArray<z.ZodObject<{
@@ -451,9 +451,9 @@ export declare const ImageGenerationConfigSchema: z.ZodObject<{
451
451
  translatePrompt: boolean;
452
452
  order: number;
453
453
  vendorId: string;
454
- statusCheckEndpoint?: string | null | undefined;
455
454
  createdAt?: string | Date | undefined;
456
455
  updatedAt?: string | Date | undefined;
456
+ statusCheckEndpoint?: string | null | undefined;
457
457
  }[];
458
458
  }[];
459
459
  presets: {
@@ -519,9 +519,9 @@ export declare const ImageGenerationConfigSchema: z.ZodObject<{
519
519
  translatePrompt: boolean;
520
520
  order: number;
521
521
  vendorId: string;
522
- statusCheckEndpoint?: string | null | undefined;
523
522
  createdAt?: string | Date | undefined;
524
523
  updatedAt?: string | Date | undefined;
524
+ statusCheckEndpoint?: string | null | undefined;
525
525
  }[];
526
526
  }[];
527
527
  presets: {
@@ -128,11 +128,11 @@ export declare const ImageGenerationJobSchema: z.ZodObject<{
128
128
  origin: JOB_REQUEST_ORIGIN;
129
129
  isDeleted: boolean;
130
130
  internalError: string | null;
131
+ userId?: string | null | undefined;
131
132
  createdAt?: string | Date | undefined;
132
133
  updatedAt?: string | Date | undefined;
133
134
  error?: string | null | undefined;
134
135
  presetId?: string | null | undefined;
135
- userId?: string | null | undefined;
136
136
  unregisteredUserId?: string | null | undefined;
137
137
  tokenReservationId?: string | null | undefined;
138
138
  completedAt?: string | Date | null | undefined;
@@ -170,11 +170,11 @@ export declare const ImageGenerationJobSchema: z.ZodObject<{
170
170
  origin: JOB_REQUEST_ORIGIN;
171
171
  isDeleted: boolean;
172
172
  internalError: string | null;
173
+ userId?: string | null | undefined;
173
174
  createdAt?: string | Date | undefined;
174
175
  updatedAt?: string | Date | undefined;
175
176
  error?: string | null | undefined;
176
177
  presetId?: string | null | undefined;
177
- userId?: string | null | undefined;
178
178
  unregisteredUserId?: string | null | undefined;
179
179
  tokenReservationId?: string | null | undefined;
180
180
  completedAt?: string | Date | null | undefined;
@@ -163,9 +163,9 @@ export declare const ImageGenerationModelSchema: z.ZodObject<{
163
163
  translatePrompt: boolean;
164
164
  order: number;
165
165
  vendorId: string;
166
- statusCheckEndpoint?: string | null | undefined;
167
166
  createdAt?: string | Date | undefined;
168
167
  updatedAt?: string | Date | undefined;
168
+ statusCheckEndpoint?: string | null | undefined;
169
169
  }, {
170
170
  price: number;
171
171
  uuid: string;
@@ -208,8 +208,8 @@ export declare const ImageGenerationModelSchema: z.ZodObject<{
208
208
  translatePrompt: boolean;
209
209
  order: number;
210
210
  vendorId: string;
211
- statusCheckEndpoint?: string | null | undefined;
212
211
  createdAt?: string | Date | undefined;
213
212
  updatedAt?: string | Date | undefined;
213
+ statusCheckEndpoint?: string | null | undefined;
214
214
  }>;
215
215
  //# sourceMappingURL=image-generation-model.schema.d.ts.map
@@ -207,9 +207,9 @@ export declare const ImageGenerationVendorSchema: z.ZodObject<{
207
207
  translatePrompt: boolean;
208
208
  order: number;
209
209
  vendorId: string;
210
- statusCheckEndpoint?: string | null | undefined;
211
210
  createdAt?: string | Date | undefined;
212
211
  updatedAt?: string | Date | undefined;
212
+ statusCheckEndpoint?: string | null | undefined;
213
213
  }, {
214
214
  price: number;
215
215
  uuid: string;
@@ -252,9 +252,9 @@ export declare const ImageGenerationVendorSchema: z.ZodObject<{
252
252
  translatePrompt: boolean;
253
253
  order: number;
254
254
  vendorId: string;
255
- statusCheckEndpoint?: string | null | undefined;
256
255
  createdAt?: string | Date | undefined;
257
256
  updatedAt?: string | Date | undefined;
257
+ statusCheckEndpoint?: string | null | undefined;
258
258
  }>, "many">;
259
259
  }, "strip", z.ZodTypeAny, {
260
260
  uuid: string;
@@ -312,9 +312,9 @@ export declare const ImageGenerationVendorSchema: z.ZodObject<{
312
312
  translatePrompt: boolean;
313
313
  order: number;
314
314
  vendorId: string;
315
- statusCheckEndpoint?: string | null | undefined;
316
315
  createdAt?: string | Date | undefined;
317
316
  updatedAt?: string | Date | undefined;
317
+ statusCheckEndpoint?: string | null | undefined;
318
318
  }[];
319
319
  }, {
320
320
  uuid: string;
@@ -372,9 +372,9 @@ export declare const ImageGenerationVendorSchema: z.ZodObject<{
372
372
  translatePrompt: boolean;
373
373
  order: number;
374
374
  vendorId: string;
375
- statusCheckEndpoint?: string | null | undefined;
376
375
  createdAt?: string | Date | undefined;
377
376
  updatedAt?: string | Date | undefined;
377
+ statusCheckEndpoint?: string | null | undefined;
378
378
  }[];
379
379
  }>;
380
380
  export type ImageGenerationVendor = z.infer<typeof ImageGenerationVendorSchema>;
@@ -1,6 +1,8 @@
1
1
  export * from './user.schema';
2
2
  export * from './product.schema';
3
3
  export * from './subscription.schema';
4
+ export * from './user-to-product.schema';
5
+ export * from './user-to-subscription.schema';
4
6
  export * from './cloud-payments-widget.schema';
5
7
  export * from './cloud-payments-widget-data.schema';
6
8
  export * from './image-generation';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../models/index.ts"],"names":[],"mappings":"AAAA,cAAc,eAAe,CAAC;AAC9B,cAAc,kBAAkB,CAAC;AACjC,cAAc,uBAAuB,CAAC;AACtC,cAAc,gCAAgC,CAAC;AAC/C,cAAc,qCAAqC,CAAC;AACpD,cAAc,oBAAoB,CAAC;AACnC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,oBAAoB,CAAC;AACnC,cAAc,eAAe,CAAC;AAC9B,cAAc,UAAU,CAAC;AACzB,cAAc,SAAS,CAAC;AACxB,cAAc,eAAe,CAAC;AAC9B,cAAc,wBAAwB,CAAC;AACvC,cAAc,OAAO,CAAC;AACtB,cAAc,OAAO,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../models/index.ts"],"names":[],"mappings":"AAAA,cAAc,eAAe,CAAC;AAC9B,cAAc,kBAAkB,CAAC;AACjC,cAAc,uBAAuB,CAAC;AACtC,cAAc,0BAA0B,CAAC;AACzC,cAAc,+BAA+B,CAAC;AAC9C,cAAc,gCAAgC,CAAC;AAC/C,cAAc,qCAAqC,CAAC;AACpD,cAAc,oBAAoB,CAAC;AACnC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,oBAAoB,CAAC;AACnC,cAAc,eAAe,CAAC;AAC9B,cAAc,UAAU,CAAC;AACzB,cAAc,SAAS,CAAC;AACxB,cAAc,eAAe,CAAC;AAC9B,cAAc,wBAAwB,CAAC;AACvC,cAAc,OAAO,CAAC;AACtB,cAAc,OAAO,CAAC"}
@@ -17,6 +17,8 @@ Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./user.schema"), exports);
18
18
  __exportStar(require("./product.schema"), exports);
19
19
  __exportStar(require("./subscription.schema"), exports);
20
+ __exportStar(require("./user-to-product.schema"), exports);
21
+ __exportStar(require("./user-to-subscription.schema"), exports);
20
22
  __exportStar(require("./cloud-payments-widget.schema"), exports);
21
23
  __exportStar(require("./cloud-payments-widget-data.schema"), exports);
22
24
  __exportStar(require("./image-generation"), exports);
@@ -11,9 +11,9 @@ export declare const PageSchema: z.ZodObject<{
11
11
  updatedAt: z.ZodDate;
12
12
  }, "strip", z.ZodTypeAny, {
13
13
  uuid: string;
14
- title: string;
15
14
  createdAt: Date;
16
15
  updatedAt: Date;
16
+ title: string;
17
17
  metaTitle: string;
18
18
  metaDescription: string;
19
19
  subTitle: string;
@@ -21,9 +21,9 @@ export declare const PageSchema: z.ZodObject<{
21
21
  alias: string;
22
22
  }, {
23
23
  uuid: string;
24
- title: string;
25
24
  createdAt: Date;
26
25
  updatedAt: Date;
26
+ title: string;
27
27
  metaTitle: string;
28
28
  metaDescription: string;
29
29
  subTitle: string;
@@ -65,9 +65,9 @@ export declare const PageWithQuestionsSchema: z.ZodObject<{
65
65
  }>, "many">;
66
66
  }, "strip", z.ZodTypeAny, {
67
67
  uuid: string;
68
- title: string;
69
68
  createdAt: Date;
70
69
  updatedAt: Date;
70
+ title: string;
71
71
  metaTitle: string;
72
72
  metaDescription: string;
73
73
  subTitle: string;
@@ -83,9 +83,9 @@ export declare const PageWithQuestionsSchema: z.ZodObject<{
83
83
  }[];
84
84
  }, {
85
85
  uuid: string;
86
- title: string;
87
86
  createdAt: Date;
88
87
  updatedAt: Date;
88
+ title: string;
89
89
  metaTitle: string;
90
90
  metaDescription: string;
91
91
  subTitle: string;
@@ -60,11 +60,11 @@ export declare const STTConfigSchema: z.ZodObject<{
60
60
  siteId: string;
61
61
  status: import("../..").TOOL_MODEL_STATUS;
62
62
  description: string;
63
+ createdAt: Date;
64
+ updatedAt: Date;
63
65
  title: string;
64
66
  strategy: string;
65
67
  order: number;
66
- createdAt: Date;
67
- updatedAt: Date;
68
68
  aiModel: string;
69
69
  icons: {
70
70
  light: {
@@ -85,11 +85,11 @@ export declare const STTConfigSchema: z.ZodObject<{
85
85
  siteId: string;
86
86
  status: import("../..").TOOL_MODEL_STATUS;
87
87
  description: string;
88
+ createdAt: Date;
89
+ updatedAt: Date;
88
90
  title: string;
89
91
  strategy: string;
90
92
  order: number;
91
- createdAt: Date;
92
- updatedAt: Date;
93
93
  aiModel: string;
94
94
  icons: {
95
95
  light: {
@@ -112,11 +112,11 @@ export declare const STTConfigSchema: z.ZodObject<{
112
112
  siteId: string;
113
113
  status: import("../..").TOOL_MODEL_STATUS;
114
114
  description: string;
115
+ createdAt: Date;
116
+ updatedAt: Date;
115
117
  title: string;
116
118
  strategy: string;
117
119
  order: number;
118
- createdAt: Date;
119
- updatedAt: Date;
120
120
  aiModel: string;
121
121
  icons: {
122
122
  light: {
@@ -139,11 +139,11 @@ export declare const STTConfigSchema: z.ZodObject<{
139
139
  siteId: string;
140
140
  status: import("../..").TOOL_MODEL_STATUS;
141
141
  description: string;
142
+ createdAt: Date;
143
+ updatedAt: Date;
142
144
  title: string;
143
145
  strategy: string;
144
146
  order: number;
145
- createdAt: Date;
146
- updatedAt: Date;
147
147
  aiModel: string;
148
148
  icons: {
149
149
  light: {
@@ -59,10 +59,11 @@ export declare const STTJobSchema: z.ZodObject<{
59
59
  uuid: string;
60
60
  siteId: string;
61
61
  status: JOB_STATUS;
62
- duration: number;
63
- title: string;
62
+ userId: string | null;
64
63
  createdAt: Date;
65
64
  updatedAt: Date;
65
+ duration: number;
66
+ title: string;
66
67
  error: string | null;
67
68
  modelId: string;
68
69
  reaction: USER_REACTION | null;
@@ -73,7 +74,6 @@ export declare const STTJobSchema: z.ZodObject<{
73
74
  timestamp: string;
74
75
  error?: string | null | undefined;
75
76
  }[];
76
- userId: string | null;
77
77
  unregisteredUserId: string | null;
78
78
  isDeleted: boolean;
79
79
  completedAt: Date | null;
@@ -93,15 +93,15 @@ export declare const STTJobSchema: z.ZodObject<{
93
93
  uuid: string;
94
94
  siteId: string;
95
95
  status: JOB_STATUS;
96
- duration: number;
97
- title: string;
96
+ userId: string | null;
98
97
  createdAt: Date;
99
98
  updatedAt: Date;
99
+ duration: number;
100
+ title: string;
100
101
  error: string | null;
101
102
  modelId: string;
102
103
  reaction: USER_REACTION | null;
103
104
  dislikeReason: string | null;
104
- userId: string | null;
105
105
  unregisteredUserId: string | null;
106
106
  isDeleted: boolean;
107
107
  completedAt: Date | null;
@@ -60,11 +60,11 @@ export declare const STTModelSchema: z.ZodObject<{
60
60
  siteId: string;
61
61
  status: TOOL_MODEL_STATUS;
62
62
  description: string;
63
+ createdAt: Date;
64
+ updatedAt: Date;
63
65
  title: string;
64
66
  strategy: string;
65
67
  order: number;
66
- createdAt: Date;
67
- updatedAt: Date;
68
68
  aiModel: string;
69
69
  icons: {
70
70
  light: {
@@ -85,11 +85,11 @@ export declare const STTModelSchema: z.ZodObject<{
85
85
  siteId: string;
86
86
  status: TOOL_MODEL_STATUS;
87
87
  description: string;
88
+ createdAt: Date;
89
+ updatedAt: Date;
88
90
  title: string;
89
91
  strategy: string;
90
92
  order: number;
91
- createdAt: Date;
92
- updatedAt: Date;
93
93
  aiModel: string;
94
94
  icons: {
95
95
  light: {
@@ -710,11 +710,11 @@ export declare const TTSConfigSchema: z.ZodObject<{
710
710
  } | undefined;
711
711
  };
712
712
  description: string;
713
+ createdAt: Date;
714
+ updatedAt: Date;
713
715
  title: string;
714
716
  strategy: string;
715
717
  order: number;
716
- createdAt: Date;
717
- updatedAt: Date;
718
718
  aiModel: string;
719
719
  icons: {
720
720
  light: {
@@ -831,11 +831,11 @@ export declare const TTSConfigSchema: z.ZodObject<{
831
831
  } | undefined;
832
832
  };
833
833
  description: string;
834
+ createdAt: Date;
835
+ updatedAt: Date;
834
836
  title: string;
835
837
  strategy: string;
836
838
  order: number;
837
- createdAt: Date;
838
- updatedAt: Date;
839
839
  aiModel: string;
840
840
  icons: {
841
841
  light: {
@@ -954,11 +954,11 @@ export declare const TTSConfigSchema: z.ZodObject<{
954
954
  } | undefined;
955
955
  };
956
956
  description: string;
957
+ createdAt: Date;
958
+ updatedAt: Date;
957
959
  title: string;
958
960
  strategy: string;
959
961
  order: number;
960
- createdAt: Date;
961
- updatedAt: Date;
962
962
  aiModel: string;
963
963
  icons: {
964
964
  light: {
@@ -1077,11 +1077,11 @@ export declare const TTSConfigSchema: z.ZodObject<{
1077
1077
  } | undefined;
1078
1078
  };
1079
1079
  description: string;
1080
+ createdAt: Date;
1081
+ updatedAt: Date;
1080
1082
  title: string;
1081
1083
  strategy: string;
1082
1084
  order: number;
1083
- createdAt: Date;
1084
- updatedAt: Date;
1085
1085
  aiModel: string;
1086
1086
  icons: {
1087
1087
  light: {
@@ -69,10 +69,11 @@ export declare const TTSJobSchema: z.ZodObject<{
69
69
  style?: number | undefined;
70
70
  language?: string | undefined;
71
71
  };
72
- duration: number;
73
- title: string;
72
+ userId: string | null;
74
73
  createdAt: Date;
75
74
  updatedAt: Date;
75
+ duration: number;
76
+ title: string;
76
77
  error: string | null;
77
78
  modelId: string;
78
79
  reaction: USER_REACTION | null;
@@ -83,7 +84,6 @@ export declare const TTSJobSchema: z.ZodObject<{
83
84
  timestamp: string;
84
85
  error?: string | null | undefined;
85
86
  }[];
86
- userId: string | null;
87
87
  unregisteredUserId: string | null;
88
88
  isDeleted: boolean;
89
89
  completedAt: Date | null;
@@ -104,15 +104,15 @@ export declare const TTSJobSchema: z.ZodObject<{
104
104
  style?: number | undefined;
105
105
  language?: string | undefined;
106
106
  };
107
- duration: number;
108
- title: string;
107
+ userId: string | null;
109
108
  createdAt: Date;
110
109
  updatedAt: Date;
110
+ duration: number;
111
+ title: string;
111
112
  error: string | null;
112
113
  modelId: string;
113
114
  reaction: USER_REACTION | null;
114
115
  dislikeReason: string | null;
115
- userId: string | null;
116
116
  unregisteredUserId: string | null;
117
117
  isDeleted: boolean;
118
118
  completedAt: Date | null;
@@ -1370,11 +1370,11 @@ export declare const TTSModelSchema: z.ZodObject<{
1370
1370
  } | undefined;
1371
1371
  };
1372
1372
  description: string;
1373
+ createdAt: Date;
1374
+ updatedAt: Date;
1373
1375
  title: string;
1374
1376
  strategy: string;
1375
1377
  order: number;
1376
- createdAt: Date;
1377
- updatedAt: Date;
1378
1378
  aiModel: string;
1379
1379
  icons: {
1380
1380
  light: {
@@ -1491,11 +1491,11 @@ export declare const TTSModelSchema: z.ZodObject<{
1491
1491
  } | undefined;
1492
1492
  };
1493
1493
  description: string;
1494
+ createdAt: Date;
1495
+ updatedAt: Date;
1494
1496
  title: string;
1495
1497
  strategy: string;
1496
1498
  order: number;
1497
- createdAt: Date;
1498
- updatedAt: Date;
1499
1499
  aiModel: string;
1500
1500
  icons: {
1501
1501
  light: {
@@ -0,0 +1,37 @@
1
+ import { z } from 'zod';
2
+ import { USER_TO_PRODUCT_STATUS } from '../constants';
3
+ export declare const UserToProductSchema: z.ZodObject<{
4
+ uuid: z.ZodString;
5
+ siteId: z.ZodString;
6
+ userId: z.ZodString;
7
+ productId: z.ZodString;
8
+ orderId: z.ZodNullable<z.ZodString>;
9
+ initTokenBalance: z.ZodNumber;
10
+ tokenBalance: z.ZodNumber;
11
+ status: z.ZodNativeEnum<typeof USER_TO_PRODUCT_STATUS>;
12
+ createdAt: z.ZodDate;
13
+ updatedAt: z.ZodDate;
14
+ }, "strip", z.ZodTypeAny, {
15
+ uuid: string;
16
+ siteId: string;
17
+ status: USER_TO_PRODUCT_STATUS;
18
+ userId: string;
19
+ productId: string;
20
+ orderId: string | null;
21
+ initTokenBalance: number;
22
+ tokenBalance: number;
23
+ createdAt: Date;
24
+ updatedAt: Date;
25
+ }, {
26
+ uuid: string;
27
+ siteId: string;
28
+ status: USER_TO_PRODUCT_STATUS;
29
+ userId: string;
30
+ productId: string;
31
+ orderId: string | null;
32
+ initTokenBalance: number;
33
+ tokenBalance: number;
34
+ createdAt: Date;
35
+ updatedAt: Date;
36
+ }>;
37
+ //# sourceMappingURL=user-to-product.schema.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"user-to-product.schema.d.ts","sourceRoot":"","sources":["../../models/user-to-product.schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,sBAAsB,EAAE,MAAM,cAAc,CAAC;AAEtD,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAW9B,CAAC"}
@@ -0,0 +1,17 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.UserToProductSchema = void 0;
4
+ const zod_1 = require("zod");
5
+ const constants_1 = require("../constants");
6
+ exports.UserToProductSchema = zod_1.z.object({
7
+ uuid: zod_1.z.string().uuid(),
8
+ siteId: zod_1.z.string().uuid(),
9
+ userId: zod_1.z.string().uuid(),
10
+ productId: zod_1.z.string().uuid(),
11
+ orderId: zod_1.z.string().uuid().nullable(),
12
+ initTokenBalance: zod_1.z.number().int().min(0),
13
+ tokenBalance: zod_1.z.number().int().min(0),
14
+ status: zod_1.z.nativeEnum(constants_1.USER_TO_PRODUCT_STATUS),
15
+ createdAt: zod_1.z.date(),
16
+ updatedAt: zod_1.z.date(),
17
+ });