bitsnap-react 1.4.15 → 1.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,592 @@
1
+ import * as z from 'zod';
2
+
3
+ declare namespace BitsnapModels {
4
+ const BaselinkerFieldsSchema: z.ZodObject<{
5
+ storageID: z.ZodOptional<z.ZodString>;
6
+ }, z.core.$strip>;
7
+ type BaselinkerFields = z.infer<typeof BaselinkerFieldsSchema>;
8
+ const MetadataSchema: z.ZodRecord<z.ZodString, z.ZodAny>;
9
+ const ProductPricingSchema: z.ZodObject<{
10
+ regularPrice: z.ZodNumber;
11
+ effectivePrice: z.ZodNumber;
12
+ currency: z.ZodString;
13
+ discount: z.ZodOptional<z.ZodObject<{
14
+ id: z.ZodString;
15
+ type: z.ZodEnum<{
16
+ FIXED: "FIXED";
17
+ PERCENTAGE: "PERCENTAGE";
18
+ }>;
19
+ value: z.ZodNumber;
20
+ status: z.ZodEnum<{
21
+ ACTIVE: "ACTIVE";
22
+ SCHEDULED: "SCHEDULED";
23
+ EXPIRED: "EXPIRED";
24
+ DISABLED: "DISABLED";
25
+ }>;
26
+ startsAt: z.ZodOptional<z.ZodNumber>;
27
+ endsAt: z.ZodOptional<z.ZodNumber>;
28
+ }, z.core.$strip>>;
29
+ referencePrice: z.ZodObject<{
30
+ amount: z.ZodOptional<z.ZodNumber>;
31
+ windowDays: z.ZodLiteral<30>;
32
+ asOf: z.ZodNumber;
33
+ basis: z.ZodLiteral<"observed-history">;
34
+ historyAvailable: z.ZodBoolean;
35
+ }, z.core.$strip>;
36
+ priceVersion: z.ZodString;
37
+ nextPriceChangeAt: z.ZodOptional<z.ZodNumber>;
38
+ }, z.core.$strip>;
39
+ type ProductPricing = z.infer<typeof ProductPricingSchema>;
40
+ const VariantSchema: z.ZodObject<{
41
+ id: z.ZodString;
42
+ name: z.ZodString;
43
+ price: z.ZodNumber;
44
+ currency: z.ZodString;
45
+ metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
46
+ images: z.ZodArray<z.ZodString>;
47
+ availableQuantity: z.ZodOptional<z.ZodNumber>;
48
+ isDeliverable: z.ZodOptional<z.ZodBoolean>;
49
+ estimatedDeliveryAt: z.ZodOptional<z.ZodNumber>;
50
+ pricing: z.ZodOptional<z.ZodObject<{
51
+ regularPrice: z.ZodNumber;
52
+ effectivePrice: z.ZodNumber;
53
+ currency: z.ZodString;
54
+ discount: z.ZodOptional<z.ZodObject<{
55
+ id: z.ZodString;
56
+ type: z.ZodEnum<{
57
+ FIXED: "FIXED";
58
+ PERCENTAGE: "PERCENTAGE";
59
+ }>;
60
+ value: z.ZodNumber;
61
+ status: z.ZodEnum<{
62
+ ACTIVE: "ACTIVE";
63
+ SCHEDULED: "SCHEDULED";
64
+ EXPIRED: "EXPIRED";
65
+ DISABLED: "DISABLED";
66
+ }>;
67
+ startsAt: z.ZodOptional<z.ZodNumber>;
68
+ endsAt: z.ZodOptional<z.ZodNumber>;
69
+ }, z.core.$strip>>;
70
+ referencePrice: z.ZodObject<{
71
+ amount: z.ZodOptional<z.ZodNumber>;
72
+ windowDays: z.ZodLiteral<30>;
73
+ asOf: z.ZodNumber;
74
+ basis: z.ZodLiteral<"observed-history">;
75
+ historyAvailable: z.ZodBoolean;
76
+ }, z.core.$strip>;
77
+ priceVersion: z.ZodString;
78
+ nextPriceChangeAt: z.ZodOptional<z.ZodNumber>;
79
+ }, z.core.$strip>>;
80
+ }, z.core.$strip>;
81
+ type Variant = z.infer<typeof VariantSchema>;
82
+ const AdditionalSchema: z.ZodObject<{
83
+ sku: z.ZodOptional<z.ZodString>;
84
+ baselinkerFields: z.ZodOptional<z.ZodObject<{
85
+ storageID: z.ZodOptional<z.ZodString>;
86
+ }, z.core.$strip>>;
87
+ isPresale: z.ZodOptional<z.ZodBoolean>;
88
+ }, z.core.$strip>;
89
+ type Additional = z.infer<typeof AdditionalSchema>;
90
+ const ItemSchema: z.ZodObject<{
91
+ id: z.ZodString;
92
+ ownerID: z.ZodOptional<z.ZodString>;
93
+ name: z.ZodString;
94
+ description: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNull]>>;
95
+ createdAt: z.ZodOptional<z.ZodNumber>;
96
+ updatedAt: z.ZodOptional<z.ZodNumber>;
97
+ price: z.ZodNumber;
98
+ currency: z.ZodString;
99
+ metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
100
+ image_url: z.ZodString;
101
+ images: z.ZodArray<z.ZodString>;
102
+ isDeliverable: z.ZodOptional<z.ZodBoolean>;
103
+ availableQuantity: z.ZodOptional<z.ZodNumber>;
104
+ additional: z.ZodOptional<z.ZodObject<{
105
+ sku: z.ZodOptional<z.ZodString>;
106
+ baselinkerFields: z.ZodOptional<z.ZodObject<{
107
+ storageID: z.ZodOptional<z.ZodString>;
108
+ }, z.core.$strip>>;
109
+ isPresale: z.ZodOptional<z.ZodBoolean>;
110
+ }, z.core.$strip>>;
111
+ variants: z.ZodOptional<z.ZodArray<z.ZodObject<{
112
+ id: z.ZodString;
113
+ name: z.ZodString;
114
+ price: z.ZodNumber;
115
+ currency: z.ZodString;
116
+ metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
117
+ images: z.ZodArray<z.ZodString>;
118
+ availableQuantity: z.ZodOptional<z.ZodNumber>;
119
+ isDeliverable: z.ZodOptional<z.ZodBoolean>;
120
+ estimatedDeliveryAt: z.ZodOptional<z.ZodNumber>;
121
+ pricing: z.ZodOptional<z.ZodObject<{
122
+ regularPrice: z.ZodNumber;
123
+ effectivePrice: z.ZodNumber;
124
+ currency: z.ZodString;
125
+ discount: z.ZodOptional<z.ZodObject<{
126
+ id: z.ZodString;
127
+ type: z.ZodEnum<{
128
+ FIXED: "FIXED";
129
+ PERCENTAGE: "PERCENTAGE";
130
+ }>;
131
+ value: z.ZodNumber;
132
+ status: z.ZodEnum<{
133
+ ACTIVE: "ACTIVE";
134
+ SCHEDULED: "SCHEDULED";
135
+ EXPIRED: "EXPIRED";
136
+ DISABLED: "DISABLED";
137
+ }>;
138
+ startsAt: z.ZodOptional<z.ZodNumber>;
139
+ endsAt: z.ZodOptional<z.ZodNumber>;
140
+ }, z.core.$strip>>;
141
+ referencePrice: z.ZodObject<{
142
+ amount: z.ZodOptional<z.ZodNumber>;
143
+ windowDays: z.ZodLiteral<30>;
144
+ asOf: z.ZodNumber;
145
+ basis: z.ZodLiteral<"observed-history">;
146
+ historyAvailable: z.ZodBoolean;
147
+ }, z.core.$strip>;
148
+ priceVersion: z.ZodString;
149
+ nextPriceChangeAt: z.ZodOptional<z.ZodNumber>;
150
+ }, z.core.$strip>>;
151
+ }, z.core.$strip>>>;
152
+ estimatedDeliveryAt: z.ZodOptional<z.ZodNumber>;
153
+ pricing: z.ZodOptional<z.ZodObject<{
154
+ regularPrice: z.ZodNumber;
155
+ effectivePrice: z.ZodNumber;
156
+ currency: z.ZodString;
157
+ discount: z.ZodOptional<z.ZodObject<{
158
+ id: z.ZodString;
159
+ type: z.ZodEnum<{
160
+ FIXED: "FIXED";
161
+ PERCENTAGE: "PERCENTAGE";
162
+ }>;
163
+ value: z.ZodNumber;
164
+ status: z.ZodEnum<{
165
+ ACTIVE: "ACTIVE";
166
+ SCHEDULED: "SCHEDULED";
167
+ EXPIRED: "EXPIRED";
168
+ DISABLED: "DISABLED";
169
+ }>;
170
+ startsAt: z.ZodOptional<z.ZodNumber>;
171
+ endsAt: z.ZodOptional<z.ZodNumber>;
172
+ }, z.core.$strip>>;
173
+ referencePrice: z.ZodObject<{
174
+ amount: z.ZodOptional<z.ZodNumber>;
175
+ windowDays: z.ZodLiteral<30>;
176
+ asOf: z.ZodNumber;
177
+ basis: z.ZodLiteral<"observed-history">;
178
+ historyAvailable: z.ZodBoolean;
179
+ }, z.core.$strip>;
180
+ priceVersion: z.ZodString;
181
+ nextPriceChangeAt: z.ZodOptional<z.ZodNumber>;
182
+ }, z.core.$strip>>;
183
+ }, z.core.$strip>;
184
+ type Item = z.infer<typeof ItemSchema>;
185
+ const DataSchema: z.ZodObject<{
186
+ success: z.ZodBoolean;
187
+ result: z.ZodArray<z.ZodObject<{
188
+ id: z.ZodString;
189
+ ownerID: z.ZodOptional<z.ZodString>;
190
+ name: z.ZodString;
191
+ description: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNull]>>;
192
+ createdAt: z.ZodOptional<z.ZodNumber>;
193
+ updatedAt: z.ZodOptional<z.ZodNumber>;
194
+ price: z.ZodNumber;
195
+ currency: z.ZodString;
196
+ metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
197
+ image_url: z.ZodString;
198
+ images: z.ZodArray<z.ZodString>;
199
+ isDeliverable: z.ZodOptional<z.ZodBoolean>;
200
+ availableQuantity: z.ZodOptional<z.ZodNumber>;
201
+ additional: z.ZodOptional<z.ZodObject<{
202
+ sku: z.ZodOptional<z.ZodString>;
203
+ baselinkerFields: z.ZodOptional<z.ZodObject<{
204
+ storageID: z.ZodOptional<z.ZodString>;
205
+ }, z.core.$strip>>;
206
+ isPresale: z.ZodOptional<z.ZodBoolean>;
207
+ }, z.core.$strip>>;
208
+ variants: z.ZodOptional<z.ZodArray<z.ZodObject<{
209
+ id: z.ZodString;
210
+ name: z.ZodString;
211
+ price: z.ZodNumber;
212
+ currency: z.ZodString;
213
+ metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
214
+ images: z.ZodArray<z.ZodString>;
215
+ availableQuantity: z.ZodOptional<z.ZodNumber>;
216
+ isDeliverable: z.ZodOptional<z.ZodBoolean>;
217
+ estimatedDeliveryAt: z.ZodOptional<z.ZodNumber>;
218
+ pricing: z.ZodOptional<z.ZodObject<{
219
+ regularPrice: z.ZodNumber;
220
+ effectivePrice: z.ZodNumber;
221
+ currency: z.ZodString;
222
+ discount: z.ZodOptional<z.ZodObject<{
223
+ id: z.ZodString;
224
+ type: z.ZodEnum<{
225
+ FIXED: "FIXED";
226
+ PERCENTAGE: "PERCENTAGE";
227
+ }>;
228
+ value: z.ZodNumber;
229
+ status: z.ZodEnum<{
230
+ ACTIVE: "ACTIVE";
231
+ SCHEDULED: "SCHEDULED";
232
+ EXPIRED: "EXPIRED";
233
+ DISABLED: "DISABLED";
234
+ }>;
235
+ startsAt: z.ZodOptional<z.ZodNumber>;
236
+ endsAt: z.ZodOptional<z.ZodNumber>;
237
+ }, z.core.$strip>>;
238
+ referencePrice: z.ZodObject<{
239
+ amount: z.ZodOptional<z.ZodNumber>;
240
+ windowDays: z.ZodLiteral<30>;
241
+ asOf: z.ZodNumber;
242
+ basis: z.ZodLiteral<"observed-history">;
243
+ historyAvailable: z.ZodBoolean;
244
+ }, z.core.$strip>;
245
+ priceVersion: z.ZodString;
246
+ nextPriceChangeAt: z.ZodOptional<z.ZodNumber>;
247
+ }, z.core.$strip>>;
248
+ }, z.core.$strip>>>;
249
+ estimatedDeliveryAt: z.ZodOptional<z.ZodNumber>;
250
+ pricing: z.ZodOptional<z.ZodObject<{
251
+ regularPrice: z.ZodNumber;
252
+ effectivePrice: z.ZodNumber;
253
+ currency: z.ZodString;
254
+ discount: z.ZodOptional<z.ZodObject<{
255
+ id: z.ZodString;
256
+ type: z.ZodEnum<{
257
+ FIXED: "FIXED";
258
+ PERCENTAGE: "PERCENTAGE";
259
+ }>;
260
+ value: z.ZodNumber;
261
+ status: z.ZodEnum<{
262
+ ACTIVE: "ACTIVE";
263
+ SCHEDULED: "SCHEDULED";
264
+ EXPIRED: "EXPIRED";
265
+ DISABLED: "DISABLED";
266
+ }>;
267
+ startsAt: z.ZodOptional<z.ZodNumber>;
268
+ endsAt: z.ZodOptional<z.ZodNumber>;
269
+ }, z.core.$strip>>;
270
+ referencePrice: z.ZodObject<{
271
+ amount: z.ZodOptional<z.ZodNumber>;
272
+ windowDays: z.ZodLiteral<30>;
273
+ asOf: z.ZodNumber;
274
+ basis: z.ZodLiteral<"observed-history">;
275
+ historyAvailable: z.ZodBoolean;
276
+ }, z.core.$strip>;
277
+ priceVersion: z.ZodString;
278
+ nextPriceChangeAt: z.ZodOptional<z.ZodNumber>;
279
+ }, z.core.$strip>>;
280
+ }, z.core.$strip>>;
281
+ totalCount: z.ZodNumber;
282
+ }, z.core.$strip>;
283
+ type Data = z.infer<typeof DataSchema>;
284
+ const ProductsResultResultSchema: z.ZodObject<{
285
+ data: z.ZodObject<{
286
+ success: z.ZodBoolean;
287
+ result: z.ZodArray<z.ZodObject<{
288
+ id: z.ZodString;
289
+ ownerID: z.ZodOptional<z.ZodString>;
290
+ name: z.ZodString;
291
+ description: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNull]>>;
292
+ createdAt: z.ZodOptional<z.ZodNumber>;
293
+ updatedAt: z.ZodOptional<z.ZodNumber>;
294
+ price: z.ZodNumber;
295
+ currency: z.ZodString;
296
+ metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
297
+ image_url: z.ZodString;
298
+ images: z.ZodArray<z.ZodString>;
299
+ isDeliverable: z.ZodOptional<z.ZodBoolean>;
300
+ availableQuantity: z.ZodOptional<z.ZodNumber>;
301
+ additional: z.ZodOptional<z.ZodObject<{
302
+ sku: z.ZodOptional<z.ZodString>;
303
+ baselinkerFields: z.ZodOptional<z.ZodObject<{
304
+ storageID: z.ZodOptional<z.ZodString>;
305
+ }, z.core.$strip>>;
306
+ isPresale: z.ZodOptional<z.ZodBoolean>;
307
+ }, z.core.$strip>>;
308
+ variants: z.ZodOptional<z.ZodArray<z.ZodObject<{
309
+ id: z.ZodString;
310
+ name: z.ZodString;
311
+ price: z.ZodNumber;
312
+ currency: z.ZodString;
313
+ metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
314
+ images: z.ZodArray<z.ZodString>;
315
+ availableQuantity: z.ZodOptional<z.ZodNumber>;
316
+ isDeliverable: z.ZodOptional<z.ZodBoolean>;
317
+ estimatedDeliveryAt: z.ZodOptional<z.ZodNumber>;
318
+ pricing: z.ZodOptional<z.ZodObject<{
319
+ regularPrice: z.ZodNumber;
320
+ effectivePrice: z.ZodNumber;
321
+ currency: z.ZodString;
322
+ discount: z.ZodOptional<z.ZodObject<{
323
+ id: z.ZodString;
324
+ type: z.ZodEnum<{
325
+ FIXED: "FIXED";
326
+ PERCENTAGE: "PERCENTAGE";
327
+ }>;
328
+ value: z.ZodNumber;
329
+ status: z.ZodEnum<{
330
+ ACTIVE: "ACTIVE";
331
+ SCHEDULED: "SCHEDULED";
332
+ EXPIRED: "EXPIRED";
333
+ DISABLED: "DISABLED";
334
+ }>;
335
+ startsAt: z.ZodOptional<z.ZodNumber>;
336
+ endsAt: z.ZodOptional<z.ZodNumber>;
337
+ }, z.core.$strip>>;
338
+ referencePrice: z.ZodObject<{
339
+ amount: z.ZodOptional<z.ZodNumber>;
340
+ windowDays: z.ZodLiteral<30>;
341
+ asOf: z.ZodNumber;
342
+ basis: z.ZodLiteral<"observed-history">;
343
+ historyAvailable: z.ZodBoolean;
344
+ }, z.core.$strip>;
345
+ priceVersion: z.ZodString;
346
+ nextPriceChangeAt: z.ZodOptional<z.ZodNumber>;
347
+ }, z.core.$strip>>;
348
+ }, z.core.$strip>>>;
349
+ estimatedDeliveryAt: z.ZodOptional<z.ZodNumber>;
350
+ pricing: z.ZodOptional<z.ZodObject<{
351
+ regularPrice: z.ZodNumber;
352
+ effectivePrice: z.ZodNumber;
353
+ currency: z.ZodString;
354
+ discount: z.ZodOptional<z.ZodObject<{
355
+ id: z.ZodString;
356
+ type: z.ZodEnum<{
357
+ FIXED: "FIXED";
358
+ PERCENTAGE: "PERCENTAGE";
359
+ }>;
360
+ value: z.ZodNumber;
361
+ status: z.ZodEnum<{
362
+ ACTIVE: "ACTIVE";
363
+ SCHEDULED: "SCHEDULED";
364
+ EXPIRED: "EXPIRED";
365
+ DISABLED: "DISABLED";
366
+ }>;
367
+ startsAt: z.ZodOptional<z.ZodNumber>;
368
+ endsAt: z.ZodOptional<z.ZodNumber>;
369
+ }, z.core.$strip>>;
370
+ referencePrice: z.ZodObject<{
371
+ amount: z.ZodOptional<z.ZodNumber>;
372
+ windowDays: z.ZodLiteral<30>;
373
+ asOf: z.ZodNumber;
374
+ basis: z.ZodLiteral<"observed-history">;
375
+ historyAvailable: z.ZodBoolean;
376
+ }, z.core.$strip>;
377
+ priceVersion: z.ZodString;
378
+ nextPriceChangeAt: z.ZodOptional<z.ZodNumber>;
379
+ }, z.core.$strip>>;
380
+ }, z.core.$strip>>;
381
+ totalCount: z.ZodNumber;
382
+ }, z.core.$strip>;
383
+ }, z.core.$strip>;
384
+ type ProductsResultResult = z.infer<typeof ProductsResultResultSchema>;
385
+ const ProductsResultElementSchema: z.ZodArray<z.ZodObject<{
386
+ result: z.ZodObject<{
387
+ data: z.ZodObject<{
388
+ success: z.ZodBoolean;
389
+ result: z.ZodArray<z.ZodObject<{
390
+ id: z.ZodString;
391
+ ownerID: z.ZodOptional<z.ZodString>;
392
+ name: z.ZodString;
393
+ description: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNull]>>;
394
+ createdAt: z.ZodOptional<z.ZodNumber>;
395
+ updatedAt: z.ZodOptional<z.ZodNumber>;
396
+ price: z.ZodNumber;
397
+ currency: z.ZodString;
398
+ metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
399
+ image_url: z.ZodString;
400
+ images: z.ZodArray<z.ZodString>;
401
+ isDeliverable: z.ZodOptional<z.ZodBoolean>;
402
+ availableQuantity: z.ZodOptional<z.ZodNumber>;
403
+ additional: z.ZodOptional<z.ZodObject<{
404
+ sku: z.ZodOptional<z.ZodString>;
405
+ baselinkerFields: z.ZodOptional<z.ZodObject<{
406
+ storageID: z.ZodOptional<z.ZodString>;
407
+ }, z.core.$strip>>;
408
+ isPresale: z.ZodOptional<z.ZodBoolean>;
409
+ }, z.core.$strip>>;
410
+ variants: z.ZodOptional<z.ZodArray<z.ZodObject<{
411
+ id: z.ZodString;
412
+ name: z.ZodString;
413
+ price: z.ZodNumber;
414
+ currency: z.ZodString;
415
+ metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
416
+ images: z.ZodArray<z.ZodString>;
417
+ availableQuantity: z.ZodOptional<z.ZodNumber>;
418
+ isDeliverable: z.ZodOptional<z.ZodBoolean>;
419
+ estimatedDeliveryAt: z.ZodOptional<z.ZodNumber>;
420
+ pricing: z.ZodOptional<z.ZodObject<{
421
+ regularPrice: z.ZodNumber;
422
+ effectivePrice: z.ZodNumber;
423
+ currency: z.ZodString;
424
+ discount: z.ZodOptional<z.ZodObject<{
425
+ id: z.ZodString;
426
+ type: z.ZodEnum<{
427
+ FIXED: "FIXED";
428
+ PERCENTAGE: "PERCENTAGE";
429
+ }>;
430
+ value: z.ZodNumber;
431
+ status: z.ZodEnum<{
432
+ ACTIVE: "ACTIVE";
433
+ SCHEDULED: "SCHEDULED";
434
+ EXPIRED: "EXPIRED";
435
+ DISABLED: "DISABLED";
436
+ }>;
437
+ startsAt: z.ZodOptional<z.ZodNumber>;
438
+ endsAt: z.ZodOptional<z.ZodNumber>;
439
+ }, z.core.$strip>>;
440
+ referencePrice: z.ZodObject<{
441
+ amount: z.ZodOptional<z.ZodNumber>;
442
+ windowDays: z.ZodLiteral<30>;
443
+ asOf: z.ZodNumber;
444
+ basis: z.ZodLiteral<"observed-history">;
445
+ historyAvailable: z.ZodBoolean;
446
+ }, z.core.$strip>;
447
+ priceVersion: z.ZodString;
448
+ nextPriceChangeAt: z.ZodOptional<z.ZodNumber>;
449
+ }, z.core.$strip>>;
450
+ }, z.core.$strip>>>;
451
+ estimatedDeliveryAt: z.ZodOptional<z.ZodNumber>;
452
+ pricing: z.ZodOptional<z.ZodObject<{
453
+ regularPrice: z.ZodNumber;
454
+ effectivePrice: z.ZodNumber;
455
+ currency: z.ZodString;
456
+ discount: z.ZodOptional<z.ZodObject<{
457
+ id: z.ZodString;
458
+ type: z.ZodEnum<{
459
+ FIXED: "FIXED";
460
+ PERCENTAGE: "PERCENTAGE";
461
+ }>;
462
+ value: z.ZodNumber;
463
+ status: z.ZodEnum<{
464
+ ACTIVE: "ACTIVE";
465
+ SCHEDULED: "SCHEDULED";
466
+ EXPIRED: "EXPIRED";
467
+ DISABLED: "DISABLED";
468
+ }>;
469
+ startsAt: z.ZodOptional<z.ZodNumber>;
470
+ endsAt: z.ZodOptional<z.ZodNumber>;
471
+ }, z.core.$strip>>;
472
+ referencePrice: z.ZodObject<{
473
+ amount: z.ZodOptional<z.ZodNumber>;
474
+ windowDays: z.ZodLiteral<30>;
475
+ asOf: z.ZodNumber;
476
+ basis: z.ZodLiteral<"observed-history">;
477
+ historyAvailable: z.ZodBoolean;
478
+ }, z.core.$strip>;
479
+ priceVersion: z.ZodString;
480
+ nextPriceChangeAt: z.ZodOptional<z.ZodNumber>;
481
+ }, z.core.$strip>>;
482
+ }, z.core.$strip>>;
483
+ totalCount: z.ZodNumber;
484
+ }, z.core.$strip>;
485
+ }, z.core.$strip>;
486
+ }, z.core.$strip>>;
487
+ type ProductsResultElement = z.infer<typeof ProductsResultElementSchema>;
488
+ const ProductResultSchema: z.ZodArray<z.ZodObject<{
489
+ result: z.ZodObject<{
490
+ data: z.ZodObject<{
491
+ success: z.ZodBoolean;
492
+ message: z.ZodOptional<z.ZodString>;
493
+ result: z.ZodOptional<z.ZodObject<{
494
+ id: z.ZodString;
495
+ ownerID: z.ZodOptional<z.ZodString>;
496
+ name: z.ZodString;
497
+ description: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNull]>>;
498
+ createdAt: z.ZodOptional<z.ZodNumber>;
499
+ updatedAt: z.ZodOptional<z.ZodNumber>;
500
+ price: z.ZodNumber;
501
+ currency: z.ZodString;
502
+ metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
503
+ image_url: z.ZodString;
504
+ images: z.ZodArray<z.ZodString>;
505
+ isDeliverable: z.ZodOptional<z.ZodBoolean>;
506
+ availableQuantity: z.ZodOptional<z.ZodNumber>;
507
+ additional: z.ZodOptional<z.ZodObject<{
508
+ sku: z.ZodOptional<z.ZodString>;
509
+ baselinkerFields: z.ZodOptional<z.ZodObject<{
510
+ storageID: z.ZodOptional<z.ZodString>;
511
+ }, z.core.$strip>>;
512
+ isPresale: z.ZodOptional<z.ZodBoolean>;
513
+ }, z.core.$strip>>;
514
+ variants: z.ZodOptional<z.ZodArray<z.ZodObject<{
515
+ id: z.ZodString;
516
+ name: z.ZodString;
517
+ price: z.ZodNumber;
518
+ currency: z.ZodString;
519
+ metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
520
+ images: z.ZodArray<z.ZodString>;
521
+ availableQuantity: z.ZodOptional<z.ZodNumber>;
522
+ isDeliverable: z.ZodOptional<z.ZodBoolean>;
523
+ estimatedDeliveryAt: z.ZodOptional<z.ZodNumber>;
524
+ pricing: z.ZodOptional<z.ZodObject<{
525
+ regularPrice: z.ZodNumber;
526
+ effectivePrice: z.ZodNumber;
527
+ currency: z.ZodString;
528
+ discount: z.ZodOptional<z.ZodObject<{
529
+ id: z.ZodString;
530
+ type: z.ZodEnum<{
531
+ FIXED: "FIXED";
532
+ PERCENTAGE: "PERCENTAGE";
533
+ }>;
534
+ value: z.ZodNumber;
535
+ status: z.ZodEnum<{
536
+ ACTIVE: "ACTIVE";
537
+ SCHEDULED: "SCHEDULED";
538
+ EXPIRED: "EXPIRED";
539
+ DISABLED: "DISABLED";
540
+ }>;
541
+ startsAt: z.ZodOptional<z.ZodNumber>;
542
+ endsAt: z.ZodOptional<z.ZodNumber>;
543
+ }, z.core.$strip>>;
544
+ referencePrice: z.ZodObject<{
545
+ amount: z.ZodOptional<z.ZodNumber>;
546
+ windowDays: z.ZodLiteral<30>;
547
+ asOf: z.ZodNumber;
548
+ basis: z.ZodLiteral<"observed-history">;
549
+ historyAvailable: z.ZodBoolean;
550
+ }, z.core.$strip>;
551
+ priceVersion: z.ZodString;
552
+ nextPriceChangeAt: z.ZodOptional<z.ZodNumber>;
553
+ }, z.core.$strip>>;
554
+ }, z.core.$strip>>>;
555
+ estimatedDeliveryAt: z.ZodOptional<z.ZodNumber>;
556
+ pricing: z.ZodOptional<z.ZodObject<{
557
+ regularPrice: z.ZodNumber;
558
+ effectivePrice: z.ZodNumber;
559
+ currency: z.ZodString;
560
+ discount: z.ZodOptional<z.ZodObject<{
561
+ id: z.ZodString;
562
+ type: z.ZodEnum<{
563
+ FIXED: "FIXED";
564
+ PERCENTAGE: "PERCENTAGE";
565
+ }>;
566
+ value: z.ZodNumber;
567
+ status: z.ZodEnum<{
568
+ ACTIVE: "ACTIVE";
569
+ SCHEDULED: "SCHEDULED";
570
+ EXPIRED: "EXPIRED";
571
+ DISABLED: "DISABLED";
572
+ }>;
573
+ startsAt: z.ZodOptional<z.ZodNumber>;
574
+ endsAt: z.ZodOptional<z.ZodNumber>;
575
+ }, z.core.$strip>>;
576
+ referencePrice: z.ZodObject<{
577
+ amount: z.ZodOptional<z.ZodNumber>;
578
+ windowDays: z.ZodLiteral<30>;
579
+ asOf: z.ZodNumber;
580
+ basis: z.ZodLiteral<"observed-history">;
581
+ historyAvailable: z.ZodBoolean;
582
+ }, z.core.$strip>;
583
+ priceVersion: z.ZodString;
584
+ nextPriceChangeAt: z.ZodOptional<z.ZodNumber>;
585
+ }, z.core.$strip>>;
586
+ }, z.core.$strip>>;
587
+ }, z.core.$strip>;
588
+ }, z.core.$strip>;
589
+ }, z.core.$strip>>;
590
+ }
591
+
592
+ export { BitsnapModels };
package/dist/models.js CHANGED
@@ -1,2 +1,2 @@
1
- "use strict";var p=Object.create;var z=Object.defineProperty;var s=Object.getOwnPropertyDescriptor;var b=Object.getOwnPropertyNames;var y=Object.getPrototypeOf,g=Object.prototype.hasOwnProperty;var x=(r,a)=>{for(var o in a)z(r,o,{get:a[o],enumerable:!0})},l=(r,a,o,i)=>{if(a&&typeof a=="object"||typeof a=="function")for(let n of b(a))!g.call(r,n)&&n!==o&&z(r,n,{get:()=>a[n],enumerable:!(i=s(a,n))||i.enumerable});return r};var h=(r,a,o)=>(o=r!=null?p(y(r)):{},l(a||!r||!r.__esModule?z(o,"default",{value:r,enumerable:!0}):o,r)),S=r=>l(z({},"__esModule",{value:!0}),r);var f={};x(f,{BitsnapModels:()=>c});module.exports=S(f);var e=h(require("zod")),c;(t=>(t.BaselinkerFieldsSchema=e.object({storageID:e.string().optional()}),t.MetadataSchema=e.record(e.string(),e.any()),t.VariantSchema=e.object({id:e.string(),name:e.string(),price:e.number(),currency:e.string(),metadata:t.MetadataSchema.optional(),images:e.array(e.string()),availableQuantity:e.number().optional(),isDeliverable:e.boolean().optional(),estimatedDeliveryAt:e.number().optional()}),t.AdditionalSchema=e.object({sku:e.string().optional(),baselinkerFields:t.BaselinkerFieldsSchema.optional(),isPresale:e.boolean().optional()}),t.ItemSchema=e.object({id:e.string(),ownerID:e.string().optional(),name:e.string(),description:e.union([e.string(),e.null()]).optional(),createdAt:e.number().optional(),updatedAt:e.number().optional(),price:e.number(),currency:e.string(),metadata:t.MetadataSchema.optional(),image_url:e.string(),images:e.array(e.string()),isDeliverable:e.boolean().optional(),availableQuantity:e.number().optional(),additional:t.AdditionalSchema.optional(),variants:e.array(t.VariantSchema).optional(),estimatedDeliveryAt:e.number().optional()}),t.DataSchema=e.object({success:e.boolean(),result:e.array(t.ItemSchema),totalCount:e.number()}),t.ProductsResultResultSchema=e.object({data:t.DataSchema}),t.ProductsResultElementSchema=e.array(e.object({result:t.ProductsResultResultSchema})),t.ProductResultSchema=e.array(e.object({result:e.object({data:e.object({success:e.boolean(),message:e.string().optional(),result:t.ItemSchema.optional()})})}))))(c||(c={}));
1
+ "use strict";var s=Object.create;var c=Object.defineProperty;var b=Object.getOwnPropertyDescriptor;var y=Object.getOwnPropertyNames;var g=Object.getPrototypeOf,f=Object.prototype.hasOwnProperty;var h=(r,o)=>{for(var a in o)c(r,a,{get:o[a],enumerable:!0})},l=(r,o,a,i)=>{if(o&&typeof o=="object"||typeof o=="function")for(let n of y(o))!f.call(r,n)&&n!==a&&c(r,n,{get:()=>o[n],enumerable:!(i=b(o,n))||i.enumerable});return r};var d=(r,o,a)=>(a=r!=null?s(g(r)):{},l(o||!r||!r.__esModule?c(a,"default",{value:r,enumerable:!0}):a,r)),x=r=>l(c({},"__esModule",{value:!0}),r);var P={};h(P,{BitsnapModels:()=>u});module.exports=x(P);var e=d(require("zod")),u;(t=>(t.BaselinkerFieldsSchema=e.object({storageID:e.string().optional()}),t.MetadataSchema=e.record(e.string(),e.any()),t.ProductPricingSchema=e.object({regularPrice:e.number(),effectivePrice:e.number(),currency:e.string(),discount:e.object({id:e.string(),type:e.enum(["FIXED","PERCENTAGE"]),value:e.number(),status:e.enum(["ACTIVE","SCHEDULED","EXPIRED","DISABLED"]),startsAt:e.number().optional(),endsAt:e.number().optional()}).optional(),referencePrice:e.object({amount:e.number().optional(),windowDays:e.literal(30),asOf:e.number(),basis:e.literal("observed-history"),historyAvailable:e.boolean()}),priceVersion:e.string(),nextPriceChangeAt:e.number().optional()}),t.VariantSchema=e.object({id:e.string(),name:e.string(),price:e.number(),currency:e.string(),metadata:t.MetadataSchema.optional(),images:e.array(e.string()),availableQuantity:e.number().optional(),isDeliverable:e.boolean().optional(),estimatedDeliveryAt:e.number().optional(),pricing:t.ProductPricingSchema.optional()}),t.AdditionalSchema=e.object({sku:e.string().optional(),baselinkerFields:t.BaselinkerFieldsSchema.optional(),isPresale:e.boolean().optional()}),t.ItemSchema=e.object({id:e.string(),ownerID:e.string().optional(),name:e.string(),description:e.union([e.string(),e.null()]).optional(),createdAt:e.number().optional(),updatedAt:e.number().optional(),price:e.number(),currency:e.string(),metadata:t.MetadataSchema.optional(),image_url:e.string(),images:e.array(e.string()),isDeliverable:e.boolean().optional(),availableQuantity:e.number().optional(),additional:t.AdditionalSchema.optional(),variants:e.array(t.VariantSchema).optional(),estimatedDeliveryAt:e.number().optional(),pricing:t.ProductPricingSchema.optional()}),t.DataSchema=e.object({success:e.boolean(),result:e.array(t.ItemSchema),totalCount:e.number()}),t.ProductsResultResultSchema=e.object({data:t.DataSchema}),t.ProductsResultElementSchema=e.array(e.object({result:t.ProductsResultResultSchema})),t.ProductResultSchema=e.array(e.object({result:e.object({data:e.object({success:e.boolean(),message:e.string().optional(),result:t.ItemSchema.optional()})})}))))(u||={});
2
2
  //# sourceMappingURL=models.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/models.ts"],"sourcesContent":["import * as z from \"zod\";\n\nexport namespace BitsnapModels {\n export const BaselinkerFieldsSchema = z.object({\n storageID: z.string().optional(),\n });\n export type BaselinkerFields = z.infer<typeof BaselinkerFieldsSchema>;\n\n export const MetadataSchema = z.record(z.string(), z.any());\n\n export const VariantSchema = z.object({\n id: z.string(),\n name: z.string(),\n price: z.number(),\n currency: z.string(),\n metadata: MetadataSchema.optional(),\n images: z.array(z.string()),\n availableQuantity: z.number().optional(),\n isDeliverable: z.boolean().optional(),\n estimatedDeliveryAt: z.number().optional(),\n });\n export type Variant = z.infer<typeof VariantSchema>;\n\n export const AdditionalSchema = z.object({\n sku: z.string().optional(),\n baselinkerFields: BaselinkerFieldsSchema.optional(),\n isPresale: z.boolean().optional(),\n });\n export type Additional = z.infer<typeof AdditionalSchema>;\n\n export const ItemSchema = z.object({\n id: z.string(),\n ownerID: z.string().optional(),\n name: z.string(),\n description: z.union([z.string(), z.null()]).optional(),\n createdAt: z.number().optional(),\n updatedAt: z.number().optional(),\n price: z.number(),\n currency: z.string(),\n metadata: MetadataSchema.optional(),\n image_url: z.string(),\n images: z.array(z.string()),\n isDeliverable: z.boolean().optional(),\n availableQuantity: z.number().optional(),\n additional: AdditionalSchema.optional(),\n variants: z.array(VariantSchema).optional(),\n estimatedDeliveryAt: z.number().optional(),\n });\n export type Item = z.infer<typeof ItemSchema>;\n\n export const DataSchema = z.object({\n success: z.boolean(),\n result: z.array(ItemSchema),\n totalCount: z.number(),\n });\n export type Data = z.infer<typeof DataSchema>;\n\n export const ProductsResultResultSchema = z.object({\n data: DataSchema,\n });\n export type ProductsResultResult = z.infer<typeof ProductsResultResultSchema>;\n\n export const ProductsResultElementSchema = z.array(\n z.object({\n result: ProductsResultResultSchema,\n }),\n );\n export type ProductsResultElement = z.infer<\n typeof ProductsResultElementSchema\n >;\n\n export const ProductResultSchema = z.array(\n z.object({\n result: z.object({\n data: z.object({\n success: z.boolean(),\n message: z.string().optional(),\n result: ItemSchema.optional(),\n }),\n }),\n }),\n );\n}\n"],"mappings":"0jBAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,mBAAAE,IAAA,eAAAC,EAAAH,GAAA,IAAAI,EAAmB,kBAEFF,OACFA,EAAA,uBAA2B,SAAO,CAC7C,UAAa,SAAO,EAAE,SAAS,CACjC,CAAC,EAGYA,EAAA,eAAmB,SAAS,SAAO,EAAK,MAAI,CAAC,EAE7CA,EAAA,cAAkB,SAAO,CACpC,GAAM,SAAO,EACb,KAAQ,SAAO,EACf,MAAS,SAAO,EAChB,SAAY,SAAO,EACnB,SAAUA,EAAA,eAAe,SAAS,EAClC,OAAU,QAAQ,SAAO,CAAC,EAC1B,kBAAqB,SAAO,EAAE,SAAS,EACvC,cAAiB,UAAQ,EAAE,SAAS,EACpC,oBAAuB,SAAO,EAAE,SAAS,CAC3C,CAAC,EAGYA,EAAA,iBAAqB,SAAO,CACvC,IAAO,SAAO,EAAE,SAAS,EACzB,iBAAkBA,EAAA,uBAAuB,SAAS,EAClD,UAAa,UAAQ,EAAE,SAAS,CAClC,CAAC,EAGYA,EAAA,WAAe,SAAO,CACjC,GAAM,SAAO,EACb,QAAW,SAAO,EAAE,SAAS,EAC7B,KAAQ,SAAO,EACf,YAAe,QAAM,CAAG,SAAO,EAAK,OAAK,CAAC,CAAC,EAAE,SAAS,EACtD,UAAa,SAAO,EAAE,SAAS,EAC/B,UAAa,SAAO,EAAE,SAAS,EAC/B,MAAS,SAAO,EAChB,SAAY,SAAO,EACnB,SAAUA,EAAA,eAAe,SAAS,EAClC,UAAa,SAAO,EACpB,OAAU,QAAQ,SAAO,CAAC,EAC1B,cAAiB,UAAQ,EAAE,SAAS,EACpC,kBAAqB,SAAO,EAAE,SAAS,EACvC,WAAYA,EAAA,iBAAiB,SAAS,EACtC,SAAY,QAAMA,EAAA,aAAa,EAAE,SAAS,EAC1C,oBAAuB,SAAO,EAAE,SAAS,CAC3C,CAAC,EAGYA,EAAA,WAAe,SAAO,CACjC,QAAW,UAAQ,EACnB,OAAU,QAAMA,EAAA,UAAU,EAC1B,WAAc,SAAO,CACvB,CAAC,EAGYA,EAAA,2BAA+B,SAAO,CACjD,KAAMA,EAAA,UACR,CAAC,EAGYA,EAAA,4BAAgC,QACzC,SAAO,CACP,OAAQA,EAAA,0BACV,CAAC,CACH,EAKaA,EAAA,oBAAwB,QACjC,SAAO,CACP,OAAU,SAAO,CACf,KAAQ,SAAO,CACb,QAAW,UAAQ,EACnB,QAAW,SAAO,EAAE,SAAS,EAC7B,OAAQA,EAAA,WAAW,SAAS,CAC9B,CAAC,CACH,CAAC,CACH,CAAC,CACH,IA/EeA,MAAA","names":["models_exports","__export","BitsnapModels","__toCommonJS","z"]}
1
+ {"version":3,"sources":["../src/models.ts"],"sourcesContent":["import * as z from \"zod\";\n\nexport namespace BitsnapModels {\n export const BaselinkerFieldsSchema = z.object({\n storageID: z.string().optional(),\n });\n export type BaselinkerFields = z.infer<typeof BaselinkerFieldsSchema>;\n\n export const MetadataSchema = z.record(z.string(), z.any());\n\n export const ProductPricingSchema = z.object({\n regularPrice: z.number(),\n effectivePrice: z.number(),\n currency: z.string(),\n discount: z.object({\n id: z.string(),\n type: z.enum([\"FIXED\", \"PERCENTAGE\"]),\n value: z.number(),\n status: z.enum([\"ACTIVE\", \"SCHEDULED\", \"EXPIRED\", \"DISABLED\"]),\n startsAt: z.number().optional(),\n endsAt: z.number().optional(),\n }).optional(),\n referencePrice: z.object({\n amount: z.number().optional(),\n windowDays: z.literal(30),\n asOf: z.number(),\n basis: z.literal(\"observed-history\"),\n historyAvailable: z.boolean(),\n }),\n priceVersion: z.string(),\n nextPriceChangeAt: z.number().optional(),\n });\n export type ProductPricing = z.infer<typeof ProductPricingSchema>;\n\n export const VariantSchema = z.object({\n id: z.string(),\n name: z.string(),\n price: z.number(),\n currency: z.string(),\n metadata: MetadataSchema.optional(),\n images: z.array(z.string()),\n availableQuantity: z.number().optional(),\n isDeliverable: z.boolean().optional(),\n estimatedDeliveryAt: z.number().optional(),\n pricing: ProductPricingSchema.optional(),\n });\n export type Variant = z.infer<typeof VariantSchema>;\n\n export const AdditionalSchema = z.object({\n sku: z.string().optional(),\n baselinkerFields: BaselinkerFieldsSchema.optional(),\n isPresale: z.boolean().optional(),\n });\n export type Additional = z.infer<typeof AdditionalSchema>;\n\n export const ItemSchema = z.object({\n id: z.string(),\n ownerID: z.string().optional(),\n name: z.string(),\n description: z.union([z.string(), z.null()]).optional(),\n createdAt: z.number().optional(),\n updatedAt: z.number().optional(),\n price: z.number(),\n currency: z.string(),\n metadata: MetadataSchema.optional(),\n image_url: z.string(),\n images: z.array(z.string()),\n isDeliverable: z.boolean().optional(),\n availableQuantity: z.number().optional(),\n additional: AdditionalSchema.optional(),\n variants: z.array(VariantSchema).optional(),\n estimatedDeliveryAt: z.number().optional(),\n pricing: ProductPricingSchema.optional(),\n });\n export type Item = z.infer<typeof ItemSchema>;\n\n export const DataSchema = z.object({\n success: z.boolean(),\n result: z.array(ItemSchema),\n totalCount: z.number(),\n });\n export type Data = z.infer<typeof DataSchema>;\n\n export const ProductsResultResultSchema = z.object({\n data: DataSchema,\n });\n export type ProductsResultResult = z.infer<typeof ProductsResultResultSchema>;\n\n export const ProductsResultElementSchema = z.array(\n z.object({\n result: ProductsResultResultSchema,\n }),\n );\n export type ProductsResultElement = z.infer<\n typeof ProductsResultElementSchema\n >;\n\n export const ProductResultSchema = z.array(\n z.object({\n result: z.object({\n data: z.object({\n success: z.boolean(),\n message: z.string().optional(),\n result: ItemSchema.optional(),\n }),\n }),\n }),\n );\n}\n"],"mappings":"0jBAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,mBAAAE,IAAA,eAAAC,EAAAH,GAAA,IAAAI,EAAmB,kBAEFF,OACFA,EAAA,uBAA2B,SAAO,CAC7C,UAAa,SAAO,EAAE,SAAS,CACjC,CAAC,EAGYA,EAAA,eAAmB,SAAS,SAAO,EAAK,MAAI,CAAC,EAE7CA,EAAA,qBAAyB,SAAO,CAC3C,aAAgB,SAAO,EACvB,eAAkB,SAAO,EACzB,SAAY,SAAO,EACnB,SAAY,SAAO,CACjB,GAAM,SAAO,EACb,KAAQ,OAAK,CAAC,QAAS,YAAY,CAAC,EACpC,MAAS,SAAO,EAChB,OAAU,OAAK,CAAC,SAAU,YAAa,UAAW,UAAU,CAAC,EAC7D,SAAY,SAAO,EAAE,SAAS,EAC9B,OAAU,SAAO,EAAE,SAAS,CAC9B,CAAC,EAAE,SAAS,EACZ,eAAkB,SAAO,CACvB,OAAU,SAAO,EAAE,SAAS,EAC5B,WAAc,UAAQ,EAAE,EACxB,KAAQ,SAAO,EACf,MAAS,UAAQ,kBAAkB,EACnC,iBAAoB,UAAQ,CAC9B,CAAC,EACD,aAAgB,SAAO,EACvB,kBAAqB,SAAO,EAAE,SAAS,CACzC,CAAC,EAGYA,EAAA,cAAkB,SAAO,CACpC,GAAM,SAAO,EACb,KAAQ,SAAO,EACf,MAAS,SAAO,EAChB,SAAY,SAAO,EACnB,SAAUA,EAAA,eAAe,SAAS,EAClC,OAAU,QAAQ,SAAO,CAAC,EAC1B,kBAAqB,SAAO,EAAE,SAAS,EACvC,cAAiB,UAAQ,EAAE,SAAS,EACpC,oBAAuB,SAAO,EAAE,SAAS,EACzC,QAASA,EAAA,qBAAqB,SAAS,CACzC,CAAC,EAGYA,EAAA,iBAAqB,SAAO,CACvC,IAAO,SAAO,EAAE,SAAS,EACzB,iBAAkBA,EAAA,uBAAuB,SAAS,EAClD,UAAa,UAAQ,EAAE,SAAS,CAClC,CAAC,EAGYA,EAAA,WAAe,SAAO,CACjC,GAAM,SAAO,EACb,QAAW,SAAO,EAAE,SAAS,EAC7B,KAAQ,SAAO,EACf,YAAe,QAAM,CAAG,SAAO,EAAK,OAAK,CAAC,CAAC,EAAE,SAAS,EACtD,UAAa,SAAO,EAAE,SAAS,EAC/B,UAAa,SAAO,EAAE,SAAS,EAC/B,MAAS,SAAO,EAChB,SAAY,SAAO,EACnB,SAAUA,EAAA,eAAe,SAAS,EAClC,UAAa,SAAO,EACpB,OAAU,QAAQ,SAAO,CAAC,EAC1B,cAAiB,UAAQ,EAAE,SAAS,EACpC,kBAAqB,SAAO,EAAE,SAAS,EACvC,WAAYA,EAAA,iBAAiB,SAAS,EACtC,SAAY,QAAMA,EAAA,aAAa,EAAE,SAAS,EAC1C,oBAAuB,SAAO,EAAE,SAAS,EACzC,QAASA,EAAA,qBAAqB,SAAS,CACzC,CAAC,EAGYA,EAAA,WAAe,SAAO,CACjC,QAAW,UAAQ,EACnB,OAAU,QAAMA,EAAA,UAAU,EAC1B,WAAc,SAAO,CACvB,CAAC,EAGYA,EAAA,2BAA+B,SAAO,CACjD,KAAMA,EAAA,UACR,CAAC,EAGYA,EAAA,4BAAgC,QACzC,SAAO,CACP,OAAQA,EAAA,0BACV,CAAC,CACH,EAKaA,EAAA,oBAAwB,QACjC,SAAO,CACP,OAAU,SAAO,CACf,KAAQ,SAAO,CACb,QAAW,UAAQ,EACnB,QAAW,SAAO,EAAE,SAAS,EAC7B,OAAQA,EAAA,WAAW,SAAS,CAC9B,CAAC,CACH,CAAC,CACH,CAAC,CACH,IAzGeA,IAAA","names":["models_exports","__export","BitsnapModels","__toCommonJS","z"]}
package/dist/models.mjs CHANGED
@@ -1,2 +1,2 @@
1
- import"./chunk-43KBVYBT.mjs";import*as e from"zod";var o;(t=>(t.BaselinkerFieldsSchema=e.object({storageID:e.string().optional()}),t.MetadataSchema=e.record(e.string(),e.any()),t.VariantSchema=e.object({id:e.string(),name:e.string(),price:e.number(),currency:e.string(),metadata:t.MetadataSchema.optional(),images:e.array(e.string()),availableQuantity:e.number().optional(),isDeliverable:e.boolean().optional(),estimatedDeliveryAt:e.number().optional()}),t.AdditionalSchema=e.object({sku:e.string().optional(),baselinkerFields:t.BaselinkerFieldsSchema.optional(),isPresale:e.boolean().optional()}),t.ItemSchema=e.object({id:e.string(),ownerID:e.string().optional(),name:e.string(),description:e.union([e.string(),e.null()]).optional(),createdAt:e.number().optional(),updatedAt:e.number().optional(),price:e.number(),currency:e.string(),metadata:t.MetadataSchema.optional(),image_url:e.string(),images:e.array(e.string()),isDeliverable:e.boolean().optional(),availableQuantity:e.number().optional(),additional:t.AdditionalSchema.optional(),variants:e.array(t.VariantSchema).optional(),estimatedDeliveryAt:e.number().optional()}),t.DataSchema=e.object({success:e.boolean(),result:e.array(t.ItemSchema),totalCount:e.number()}),t.ProductsResultResultSchema=e.object({data:t.DataSchema}),t.ProductsResultElementSchema=e.array(e.object({result:t.ProductsResultResultSchema})),t.ProductResultSchema=e.array(e.object({result:e.object({data:e.object({success:e.boolean(),message:e.string().optional(),result:t.ItemSchema.optional()})})}))))(o||(o={}));export{o as BitsnapModels};
1
+ import"./chunk-U6FLIRIV.mjs";import*as e from"zod";var u;(t=>(t.BaselinkerFieldsSchema=e.object({storageID:e.string().optional()}),t.MetadataSchema=e.record(e.string(),e.any()),t.ProductPricingSchema=e.object({regularPrice:e.number(),effectivePrice:e.number(),currency:e.string(),discount:e.object({id:e.string(),type:e.enum(["FIXED","PERCENTAGE"]),value:e.number(),status:e.enum(["ACTIVE","SCHEDULED","EXPIRED","DISABLED"]),startsAt:e.number().optional(),endsAt:e.number().optional()}).optional(),referencePrice:e.object({amount:e.number().optional(),windowDays:e.literal(30),asOf:e.number(),basis:e.literal("observed-history"),historyAvailable:e.boolean()}),priceVersion:e.string(),nextPriceChangeAt:e.number().optional()}),t.VariantSchema=e.object({id:e.string(),name:e.string(),price:e.number(),currency:e.string(),metadata:t.MetadataSchema.optional(),images:e.array(e.string()),availableQuantity:e.number().optional(),isDeliverable:e.boolean().optional(),estimatedDeliveryAt:e.number().optional(),pricing:t.ProductPricingSchema.optional()}),t.AdditionalSchema=e.object({sku:e.string().optional(),baselinkerFields:t.BaselinkerFieldsSchema.optional(),isPresale:e.boolean().optional()}),t.ItemSchema=e.object({id:e.string(),ownerID:e.string().optional(),name:e.string(),description:e.union([e.string(),e.null()]).optional(),createdAt:e.number().optional(),updatedAt:e.number().optional(),price:e.number(),currency:e.string(),metadata:t.MetadataSchema.optional(),image_url:e.string(),images:e.array(e.string()),isDeliverable:e.boolean().optional(),availableQuantity:e.number().optional(),additional:t.AdditionalSchema.optional(),variants:e.array(t.VariantSchema).optional(),estimatedDeliveryAt:e.number().optional(),pricing:t.ProductPricingSchema.optional()}),t.DataSchema=e.object({success:e.boolean(),result:e.array(t.ItemSchema),totalCount:e.number()}),t.ProductsResultResultSchema=e.object({data:t.DataSchema}),t.ProductsResultElementSchema=e.array(e.object({result:t.ProductsResultResultSchema})),t.ProductResultSchema=e.array(e.object({result:e.object({data:e.object({success:e.boolean(),message:e.string().optional(),result:t.ItemSchema.optional()})})}))))(u||={});export{u as BitsnapModels};
2
2
  //# sourceMappingURL=models.mjs.map