@nymbalhq/platform 1.1.0 → 1.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (36) hide show
  1. package/dist/chunk-UBEGSSFI.js +5332 -0
  2. package/dist/chunk-UBEGSSFI.js.map +1 -0
  3. package/dist/{chunk-PW6ILJF7.js → chunk-XVUH34US.js} +138 -10
  4. package/dist/chunk-XVUH34US.js.map +1 -0
  5. package/dist/db/schema/index.d.ts +3717 -2105
  6. package/dist/db/schema/index.js +1 -2
  7. package/dist/index.d.ts +408 -21
  8. package/dist/index.js +1563 -1867
  9. package/dist/index.js.map +1 -1
  10. package/dist/register-NHG3TIRQ.js +8 -0
  11. package/migrations/postgres/0008_event_correlation.sql +6 -0
  12. package/migrations/postgres/0009_settings.sql +13 -0
  13. package/migrations/postgres/0010_catch_up_index.sql +2 -0
  14. package/migrations/postgres/0011_audit_entries.sql +27 -0
  15. package/migrations/postgres/meta/0008_snapshot.json +1625 -0
  16. package/migrations/postgres/meta/0009_snapshot.json +1705 -0
  17. package/migrations/postgres/meta/0010_snapshot.json +1732 -0
  18. package/migrations/postgres/meta/0011_snapshot.json +1887 -0
  19. package/migrations/postgres/meta/_journal.json +28 -0
  20. package/migrations/sqlite/0008_event_correlation.sql +7 -0
  21. package/migrations/sqlite/0009_settings.sql +13 -0
  22. package/migrations/sqlite/0010_catch_up_index.sql +2 -0
  23. package/migrations/sqlite/0011_audit_entries.sql +26 -0
  24. package/migrations/sqlite/meta/0008_snapshot.json +1485 -0
  25. package/migrations/sqlite/meta/0009_snapshot.json +1571 -0
  26. package/migrations/sqlite/meta/0010_snapshot.json +1580 -0
  27. package/migrations/sqlite/meta/0011_snapshot.json +1705 -0
  28. package/migrations/sqlite/meta/_journal.json +28 -0
  29. package/package.json +29 -23
  30. package/dist/chunk-2GFZHF5W.js +0 -2647
  31. package/dist/chunk-2GFZHF5W.js.map +0 -1
  32. package/dist/chunk-PW6ILJF7.js.map +0 -1
  33. package/dist/chunk-PZ5AY32C.js +0 -10
  34. package/dist/register-FJA7YJV3.js +0 -8
  35. package/dist/register-FJA7YJV3.js.map +0 -1
  36. /package/dist/{chunk-PZ5AY32C.js.map → register-NHG3TIRQ.js.map} +0 -0
@@ -0,0 +1,1705 @@
1
+ {
2
+ "version": "6",
3
+ "dialect": "sqlite",
4
+ "id": "0a78ea00-6236-4b0f-abc8-f0758d3a4e78",
5
+ "prevId": "2327646a-a596-4c20-8e22-9d06a0e7a47a",
6
+ "tables": {
7
+ "audit_entries": {
8
+ "name": "audit_entries",
9
+ "columns": {
10
+ "id": {
11
+ "name": "id",
12
+ "type": "text",
13
+ "primaryKey": true,
14
+ "notNull": true,
15
+ "autoincrement": false
16
+ },
17
+ "at": {
18
+ "name": "at",
19
+ "type": "text",
20
+ "primaryKey": false,
21
+ "notNull": true,
22
+ "autoincrement": false
23
+ },
24
+ "actor_kind": {
25
+ "name": "actor_kind",
26
+ "type": "text",
27
+ "primaryKey": false,
28
+ "notNull": true,
29
+ "autoincrement": false
30
+ },
31
+ "actor_id": {
32
+ "name": "actor_id",
33
+ "type": "text",
34
+ "primaryKey": false,
35
+ "notNull": true,
36
+ "autoincrement": false
37
+ },
38
+ "command": {
39
+ "name": "command",
40
+ "type": "text",
41
+ "primaryKey": false,
42
+ "notNull": true,
43
+ "autoincrement": false
44
+ },
45
+ "subjects": {
46
+ "name": "subjects",
47
+ "type": "text",
48
+ "primaryKey": false,
49
+ "notNull": true,
50
+ "autoincrement": false
51
+ },
52
+ "correlation_id": {
53
+ "name": "correlation_id",
54
+ "type": "text",
55
+ "primaryKey": false,
56
+ "notNull": false,
57
+ "autoincrement": false
58
+ },
59
+ "idempotency_key": {
60
+ "name": "idempotency_key",
61
+ "type": "text",
62
+ "primaryKey": false,
63
+ "notNull": false,
64
+ "autoincrement": false
65
+ },
66
+ "request_hash": {
67
+ "name": "request_hash",
68
+ "type": "text",
69
+ "primaryKey": false,
70
+ "notNull": false,
71
+ "autoincrement": false
72
+ },
73
+ "outcome": {
74
+ "name": "outcome",
75
+ "type": "text",
76
+ "primaryKey": false,
77
+ "notNull": true,
78
+ "autoincrement": false
79
+ },
80
+ "response_status": {
81
+ "name": "response_status",
82
+ "type": "integer",
83
+ "primaryKey": false,
84
+ "notNull": false,
85
+ "autoincrement": false
86
+ },
87
+ "response_body": {
88
+ "name": "response_body",
89
+ "type": "text",
90
+ "primaryKey": false,
91
+ "notNull": false,
92
+ "autoincrement": false
93
+ }
94
+ },
95
+ "indexes": {
96
+ "audit_entries_applied_key_unique": {
97
+ "name": "audit_entries_applied_key_unique",
98
+ "columns": [
99
+ "actor_id",
100
+ "command",
101
+ "idempotency_key"
102
+ ],
103
+ "isUnique": true,
104
+ "where": "\"audit_entries\".\"outcome\" = 'applied' AND \"audit_entries\".\"idempotency_key\" IS NOT NULL"
105
+ },
106
+ "audit_entries_at_idx": {
107
+ "name": "audit_entries_at_idx",
108
+ "columns": [
109
+ "at",
110
+ "id"
111
+ ],
112
+ "isUnique": false
113
+ },
114
+ "audit_entries_correlation_idx": {
115
+ "name": "audit_entries_correlation_idx",
116
+ "columns": [
117
+ "correlation_id"
118
+ ],
119
+ "isUnique": false
120
+ }
121
+ },
122
+ "foreignKeys": {},
123
+ "compositePrimaryKeys": {},
124
+ "uniqueConstraints": {},
125
+ "checkConstraints": {
126
+ "audit_entries_outcome": {
127
+ "name": "audit_entries_outcome",
128
+ "value": "\"audit_entries\".\"outcome\" IN ('applied', 'refused', 'replayed')"
129
+ }
130
+ }
131
+ },
132
+ "carts": {
133
+ "name": "carts",
134
+ "columns": {
135
+ "token": {
136
+ "name": "token",
137
+ "type": "text",
138
+ "primaryKey": true,
139
+ "notNull": true,
140
+ "autoincrement": false
141
+ },
142
+ "customer_id": {
143
+ "name": "customer_id",
144
+ "type": "text",
145
+ "primaryKey": false,
146
+ "notNull": false,
147
+ "autoincrement": false
148
+ },
149
+ "currency": {
150
+ "name": "currency",
151
+ "type": "text",
152
+ "primaryKey": false,
153
+ "notNull": true,
154
+ "autoincrement": false
155
+ },
156
+ "items": {
157
+ "name": "items",
158
+ "type": "text",
159
+ "primaryKey": false,
160
+ "notNull": true,
161
+ "autoincrement": false,
162
+ "default": "'[]'"
163
+ },
164
+ "line_count": {
165
+ "name": "line_count",
166
+ "type": "integer",
167
+ "primaryKey": false,
168
+ "notNull": true,
169
+ "autoincrement": false,
170
+ "default": 0
171
+ },
172
+ "subtotal_minor": {
173
+ "name": "subtotal_minor",
174
+ "type": "integer",
175
+ "primaryKey": false,
176
+ "notNull": true,
177
+ "autoincrement": false,
178
+ "default": 0
179
+ },
180
+ "expires_at": {
181
+ "name": "expires_at",
182
+ "type": "text",
183
+ "primaryKey": false,
184
+ "notNull": true,
185
+ "autoincrement": false
186
+ },
187
+ "created_at": {
188
+ "name": "created_at",
189
+ "type": "text",
190
+ "primaryKey": false,
191
+ "notNull": true,
192
+ "autoincrement": false
193
+ },
194
+ "updated_at": {
195
+ "name": "updated_at",
196
+ "type": "text",
197
+ "primaryKey": false,
198
+ "notNull": true,
199
+ "autoincrement": false
200
+ },
201
+ "abandoned_notified_at": {
202
+ "name": "abandoned_notified_at",
203
+ "type": "text",
204
+ "primaryKey": false,
205
+ "notNull": false,
206
+ "autoincrement": false
207
+ }
208
+ },
209
+ "indexes": {
210
+ "carts_expires_idx": {
211
+ "name": "carts_expires_idx",
212
+ "columns": [
213
+ "expires_at"
214
+ ],
215
+ "isUnique": false
216
+ },
217
+ "carts_updated_idx": {
218
+ "name": "carts_updated_idx",
219
+ "columns": [
220
+ "updated_at"
221
+ ],
222
+ "isUnique": false
223
+ }
224
+ },
225
+ "foreignKeys": {},
226
+ "compositePrimaryKeys": {},
227
+ "uniqueConstraints": {},
228
+ "checkConstraints": {}
229
+ },
230
+ "categories": {
231
+ "name": "categories",
232
+ "columns": {
233
+ "id": {
234
+ "name": "id",
235
+ "type": "text",
236
+ "primaryKey": true,
237
+ "notNull": true,
238
+ "autoincrement": false
239
+ },
240
+ "parent_id": {
241
+ "name": "parent_id",
242
+ "type": "text",
243
+ "primaryKey": false,
244
+ "notNull": false,
245
+ "autoincrement": false
246
+ },
247
+ "slug": {
248
+ "name": "slug",
249
+ "type": "text",
250
+ "primaryKey": false,
251
+ "notNull": true,
252
+ "autoincrement": false
253
+ },
254
+ "name": {
255
+ "name": "name",
256
+ "type": "text",
257
+ "primaryKey": false,
258
+ "notNull": true,
259
+ "autoincrement": false
260
+ },
261
+ "description": {
262
+ "name": "description",
263
+ "type": "text",
264
+ "primaryKey": false,
265
+ "notNull": true,
266
+ "autoincrement": false,
267
+ "default": "''"
268
+ },
269
+ "position": {
270
+ "name": "position",
271
+ "type": "integer",
272
+ "primaryKey": false,
273
+ "notNull": true,
274
+ "autoincrement": false,
275
+ "default": 0
276
+ },
277
+ "created_at": {
278
+ "name": "created_at",
279
+ "type": "text",
280
+ "primaryKey": false,
281
+ "notNull": true,
282
+ "autoincrement": false
283
+ }
284
+ },
285
+ "indexes": {
286
+ "categories_slug_unique": {
287
+ "name": "categories_slug_unique",
288
+ "columns": [
289
+ "slug"
290
+ ],
291
+ "isUnique": true
292
+ },
293
+ "categories_parent_idx": {
294
+ "name": "categories_parent_idx",
295
+ "columns": [
296
+ "parent_id"
297
+ ],
298
+ "isUnique": false
299
+ }
300
+ },
301
+ "foreignKeys": {},
302
+ "compositePrimaryKeys": {},
303
+ "uniqueConstraints": {},
304
+ "checkConstraints": {}
305
+ },
306
+ "customers": {
307
+ "name": "customers",
308
+ "columns": {
309
+ "id": {
310
+ "name": "id",
311
+ "type": "text",
312
+ "primaryKey": true,
313
+ "notNull": true,
314
+ "autoincrement": false
315
+ },
316
+ "email": {
317
+ "name": "email",
318
+ "type": "text",
319
+ "primaryKey": false,
320
+ "notNull": true,
321
+ "autoincrement": false
322
+ },
323
+ "password_hash": {
324
+ "name": "password_hash",
325
+ "type": "text",
326
+ "primaryKey": false,
327
+ "notNull": true,
328
+ "autoincrement": false
329
+ },
330
+ "first_name": {
331
+ "name": "first_name",
332
+ "type": "text",
333
+ "primaryKey": false,
334
+ "notNull": true,
335
+ "autoincrement": false,
336
+ "default": "''"
337
+ },
338
+ "last_name": {
339
+ "name": "last_name",
340
+ "type": "text",
341
+ "primaryKey": false,
342
+ "notNull": true,
343
+ "autoincrement": false,
344
+ "default": "''"
345
+ },
346
+ "phone": {
347
+ "name": "phone",
348
+ "type": "text",
349
+ "primaryKey": false,
350
+ "notNull": true,
351
+ "autoincrement": false,
352
+ "default": "''"
353
+ },
354
+ "addresses": {
355
+ "name": "addresses",
356
+ "type": "text",
357
+ "primaryKey": false,
358
+ "notNull": true,
359
+ "autoincrement": false,
360
+ "default": "'[]'"
361
+ },
362
+ "order_count": {
363
+ "name": "order_count",
364
+ "type": "integer",
365
+ "primaryKey": false,
366
+ "notNull": true,
367
+ "autoincrement": false,
368
+ "default": 0
369
+ },
370
+ "total_spent_minor": {
371
+ "name": "total_spent_minor",
372
+ "type": "integer",
373
+ "primaryKey": false,
374
+ "notNull": true,
375
+ "autoincrement": false,
376
+ "default": 0
377
+ },
378
+ "metadata": {
379
+ "name": "metadata",
380
+ "type": "text",
381
+ "primaryKey": false,
382
+ "notNull": true,
383
+ "autoincrement": false,
384
+ "default": "'{}'"
385
+ },
386
+ "roles": {
387
+ "name": "roles",
388
+ "type": "text",
389
+ "primaryKey": false,
390
+ "notNull": true,
391
+ "autoincrement": false,
392
+ "default": "'[\"customer\"]'"
393
+ },
394
+ "requires_password_reset": {
395
+ "name": "requires_password_reset",
396
+ "type": "integer",
397
+ "primaryKey": false,
398
+ "notNull": true,
399
+ "autoincrement": false,
400
+ "default": false
401
+ },
402
+ "created_at": {
403
+ "name": "created_at",
404
+ "type": "text",
405
+ "primaryKey": false,
406
+ "notNull": true,
407
+ "autoincrement": false
408
+ },
409
+ "updated_at": {
410
+ "name": "updated_at",
411
+ "type": "text",
412
+ "primaryKey": false,
413
+ "notNull": true,
414
+ "autoincrement": false
415
+ }
416
+ },
417
+ "indexes": {
418
+ "customers_email_unique": {
419
+ "name": "customers_email_unique",
420
+ "columns": [
421
+ "email"
422
+ ],
423
+ "isUnique": true
424
+ }
425
+ },
426
+ "foreignKeys": {},
427
+ "compositePrimaryKeys": {},
428
+ "uniqueConstraints": {},
429
+ "checkConstraints": {}
430
+ },
431
+ "events": {
432
+ "name": "events",
433
+ "columns": {
434
+ "seq": {
435
+ "name": "seq",
436
+ "type": "integer",
437
+ "primaryKey": true,
438
+ "notNull": true,
439
+ "autoincrement": true
440
+ },
441
+ "id": {
442
+ "name": "id",
443
+ "type": "text",
444
+ "primaryKey": false,
445
+ "notNull": true,
446
+ "autoincrement": false
447
+ },
448
+ "type": {
449
+ "name": "type",
450
+ "type": "text",
451
+ "primaryKey": false,
452
+ "notNull": true,
453
+ "autoincrement": false
454
+ },
455
+ "envelope": {
456
+ "name": "envelope",
457
+ "type": "text",
458
+ "primaryKey": false,
459
+ "notNull": true,
460
+ "autoincrement": false
461
+ },
462
+ "correlation_id": {
463
+ "name": "correlation_id",
464
+ "type": "text",
465
+ "primaryKey": false,
466
+ "notNull": true,
467
+ "autoincrement": false
468
+ },
469
+ "created_at": {
470
+ "name": "created_at",
471
+ "type": "text",
472
+ "primaryKey": false,
473
+ "notNull": true,
474
+ "autoincrement": false
475
+ },
476
+ "delivered_at": {
477
+ "name": "delivered_at",
478
+ "type": "text",
479
+ "primaryKey": false,
480
+ "notNull": false,
481
+ "autoincrement": false
482
+ },
483
+ "attempts": {
484
+ "name": "attempts",
485
+ "type": "integer",
486
+ "primaryKey": false,
487
+ "notNull": true,
488
+ "autoincrement": false,
489
+ "default": 0
490
+ },
491
+ "dead_at": {
492
+ "name": "dead_at",
493
+ "type": "text",
494
+ "primaryKey": false,
495
+ "notNull": false,
496
+ "autoincrement": false
497
+ }
498
+ },
499
+ "indexes": {
500
+ "events_id_unique": {
501
+ "name": "events_id_unique",
502
+ "columns": [
503
+ "id"
504
+ ],
505
+ "isUnique": true
506
+ },
507
+ "events_undelivered_idx": {
508
+ "name": "events_undelivered_idx",
509
+ "columns": [
510
+ "delivered_at",
511
+ "seq"
512
+ ],
513
+ "isUnique": false
514
+ },
515
+ "events_correlation_idx": {
516
+ "name": "events_correlation_idx",
517
+ "columns": [
518
+ "correlation_id",
519
+ "seq"
520
+ ],
521
+ "isUnique": false
522
+ },
523
+ "events_catch_up_idx": {
524
+ "name": "events_catch_up_idx",
525
+ "columns": [
526
+ "dead_at",
527
+ "delivered_at",
528
+ "seq"
529
+ ],
530
+ "isUnique": false
531
+ }
532
+ },
533
+ "foreignKeys": {},
534
+ "compositePrimaryKeys": {},
535
+ "uniqueConstraints": {},
536
+ "checkConstraints": {}
537
+ },
538
+ "inventory_reservations": {
539
+ "name": "inventory_reservations",
540
+ "columns": {
541
+ "reservation_id": {
542
+ "name": "reservation_id",
543
+ "type": "text",
544
+ "primaryKey": true,
545
+ "notNull": true,
546
+ "autoincrement": false
547
+ },
548
+ "variant_id": {
549
+ "name": "variant_id",
550
+ "type": "text",
551
+ "primaryKey": false,
552
+ "notNull": true,
553
+ "autoincrement": false
554
+ },
555
+ "qty": {
556
+ "name": "qty",
557
+ "type": "integer",
558
+ "primaryKey": false,
559
+ "notNull": true,
560
+ "autoincrement": false
561
+ },
562
+ "order_ref": {
563
+ "name": "order_ref",
564
+ "type": "text",
565
+ "primaryKey": false,
566
+ "notNull": false,
567
+ "autoincrement": false
568
+ },
569
+ "expires_at": {
570
+ "name": "expires_at",
571
+ "type": "text",
572
+ "primaryKey": false,
573
+ "notNull": true,
574
+ "autoincrement": false
575
+ },
576
+ "created_at": {
577
+ "name": "created_at",
578
+ "type": "text",
579
+ "primaryKey": false,
580
+ "notNull": true,
581
+ "autoincrement": false
582
+ }
583
+ },
584
+ "indexes": {
585
+ "inv_reservations_variant_idx": {
586
+ "name": "inv_reservations_variant_idx",
587
+ "columns": [
588
+ "variant_id"
589
+ ],
590
+ "isUnique": false
591
+ },
592
+ "inv_reservations_expires_idx": {
593
+ "name": "inv_reservations_expires_idx",
594
+ "columns": [
595
+ "expires_at"
596
+ ],
597
+ "isUnique": false
598
+ }
599
+ },
600
+ "foreignKeys": {},
601
+ "compositePrimaryKeys": {},
602
+ "uniqueConstraints": {},
603
+ "checkConstraints": {}
604
+ },
605
+ "order_history": {
606
+ "name": "order_history",
607
+ "columns": {
608
+ "id": {
609
+ "name": "id",
610
+ "type": "text",
611
+ "primaryKey": true,
612
+ "notNull": true,
613
+ "autoincrement": false
614
+ },
615
+ "order_id": {
616
+ "name": "order_id",
617
+ "type": "text",
618
+ "primaryKey": false,
619
+ "notNull": true,
620
+ "autoincrement": false
621
+ },
622
+ "from_status": {
623
+ "name": "from_status",
624
+ "type": "text",
625
+ "primaryKey": false,
626
+ "notNull": false,
627
+ "autoincrement": false
628
+ },
629
+ "to_status": {
630
+ "name": "to_status",
631
+ "type": "text",
632
+ "primaryKey": false,
633
+ "notNull": true,
634
+ "autoincrement": false
635
+ },
636
+ "actor": {
637
+ "name": "actor",
638
+ "type": "text",
639
+ "primaryKey": false,
640
+ "notNull": true,
641
+ "autoincrement": false
642
+ },
643
+ "note": {
644
+ "name": "note",
645
+ "type": "text",
646
+ "primaryKey": false,
647
+ "notNull": true,
648
+ "autoincrement": false,
649
+ "default": "''"
650
+ },
651
+ "timestamp": {
652
+ "name": "timestamp",
653
+ "type": "text",
654
+ "primaryKey": false,
655
+ "notNull": true,
656
+ "autoincrement": false
657
+ }
658
+ },
659
+ "indexes": {
660
+ "order_history_order_idx": {
661
+ "name": "order_history_order_idx",
662
+ "columns": [
663
+ "order_id"
664
+ ],
665
+ "isUnique": false
666
+ }
667
+ },
668
+ "foreignKeys": {},
669
+ "compositePrimaryKeys": {},
670
+ "uniqueConstraints": {},
671
+ "checkConstraints": {}
672
+ },
673
+ "order_refunds": {
674
+ "name": "order_refunds",
675
+ "columns": {
676
+ "id": {
677
+ "name": "id",
678
+ "type": "text",
679
+ "primaryKey": true,
680
+ "notNull": true,
681
+ "autoincrement": false
682
+ },
683
+ "order_id": {
684
+ "name": "order_id",
685
+ "type": "text",
686
+ "primaryKey": false,
687
+ "notNull": true,
688
+ "autoincrement": false
689
+ },
690
+ "amount_minor": {
691
+ "name": "amount_minor",
692
+ "type": "integer",
693
+ "primaryKey": false,
694
+ "notNull": true,
695
+ "autoincrement": false
696
+ },
697
+ "currency": {
698
+ "name": "currency",
699
+ "type": "text",
700
+ "primaryKey": false,
701
+ "notNull": true,
702
+ "autoincrement": false
703
+ },
704
+ "provider_refund_id": {
705
+ "name": "provider_refund_id",
706
+ "type": "text",
707
+ "primaryKey": false,
708
+ "notNull": false,
709
+ "autoincrement": false
710
+ },
711
+ "status": {
712
+ "name": "status",
713
+ "type": "text",
714
+ "primaryKey": false,
715
+ "notNull": true,
716
+ "autoincrement": false,
717
+ "default": "'pending'"
718
+ },
719
+ "reason": {
720
+ "name": "reason",
721
+ "type": "text",
722
+ "primaryKey": false,
723
+ "notNull": false,
724
+ "autoincrement": false
725
+ },
726
+ "actor": {
727
+ "name": "actor",
728
+ "type": "text",
729
+ "primaryKey": false,
730
+ "notNull": true,
731
+ "autoincrement": false
732
+ },
733
+ "created_at": {
734
+ "name": "created_at",
735
+ "type": "text",
736
+ "primaryKey": false,
737
+ "notNull": true,
738
+ "autoincrement": false
739
+ },
740
+ "request_id": {
741
+ "name": "request_id",
742
+ "type": "text",
743
+ "primaryKey": false,
744
+ "notNull": false,
745
+ "autoincrement": false
746
+ }
747
+ },
748
+ "indexes": {
749
+ "order_refunds_order_idx": {
750
+ "name": "order_refunds_order_idx",
751
+ "columns": [
752
+ "order_id"
753
+ ],
754
+ "isUnique": false
755
+ },
756
+ "order_refunds_order_request_idx": {
757
+ "name": "order_refunds_order_request_idx",
758
+ "columns": [
759
+ "order_id",
760
+ "request_id"
761
+ ],
762
+ "isUnique": true
763
+ }
764
+ },
765
+ "foreignKeys": {},
766
+ "compositePrimaryKeys": {},
767
+ "uniqueConstraints": {},
768
+ "checkConstraints": {}
769
+ },
770
+ "order_sequences": {
771
+ "name": "order_sequences",
772
+ "columns": {
773
+ "id": {
774
+ "name": "id",
775
+ "type": "integer",
776
+ "primaryKey": true,
777
+ "notNull": true,
778
+ "autoincrement": false
779
+ },
780
+ "next_value": {
781
+ "name": "next_value",
782
+ "type": "integer",
783
+ "primaryKey": false,
784
+ "notNull": true,
785
+ "autoincrement": false
786
+ }
787
+ },
788
+ "indexes": {},
789
+ "foreignKeys": {},
790
+ "compositePrimaryKeys": {},
791
+ "uniqueConstraints": {},
792
+ "checkConstraints": {}
793
+ },
794
+ "orders": {
795
+ "name": "orders",
796
+ "columns": {
797
+ "id": {
798
+ "name": "id",
799
+ "type": "text",
800
+ "primaryKey": true,
801
+ "notNull": true,
802
+ "autoincrement": false
803
+ },
804
+ "order_number": {
805
+ "name": "order_number",
806
+ "type": "text",
807
+ "primaryKey": false,
808
+ "notNull": true,
809
+ "autoincrement": false
810
+ },
811
+ "sequence": {
812
+ "name": "sequence",
813
+ "type": "integer",
814
+ "primaryKey": false,
815
+ "notNull": true,
816
+ "autoincrement": false
817
+ },
818
+ "customer_id": {
819
+ "name": "customer_id",
820
+ "type": "text",
821
+ "primaryKey": false,
822
+ "notNull": false,
823
+ "autoincrement": false
824
+ },
825
+ "status": {
826
+ "name": "status",
827
+ "type": "text",
828
+ "primaryKey": false,
829
+ "notNull": true,
830
+ "autoincrement": false,
831
+ "default": "'pending'"
832
+ },
833
+ "email": {
834
+ "name": "email",
835
+ "type": "text",
836
+ "primaryKey": false,
837
+ "notNull": true,
838
+ "autoincrement": false
839
+ },
840
+ "billing_address": {
841
+ "name": "billing_address",
842
+ "type": "text",
843
+ "primaryKey": false,
844
+ "notNull": true,
845
+ "autoincrement": false
846
+ },
847
+ "shipping_address": {
848
+ "name": "shipping_address",
849
+ "type": "text",
850
+ "primaryKey": false,
851
+ "notNull": true,
852
+ "autoincrement": false
853
+ },
854
+ "line_items": {
855
+ "name": "line_items",
856
+ "type": "text",
857
+ "primaryKey": false,
858
+ "notNull": true,
859
+ "autoincrement": false
860
+ },
861
+ "subtotal_minor": {
862
+ "name": "subtotal_minor",
863
+ "type": "integer",
864
+ "primaryKey": false,
865
+ "notNull": true,
866
+ "autoincrement": false
867
+ },
868
+ "tax_total_minor": {
869
+ "name": "tax_total_minor",
870
+ "type": "integer",
871
+ "primaryKey": false,
872
+ "notNull": true,
873
+ "autoincrement": false,
874
+ "default": 0
875
+ },
876
+ "shipping_total_minor": {
877
+ "name": "shipping_total_minor",
878
+ "type": "integer",
879
+ "primaryKey": false,
880
+ "notNull": true,
881
+ "autoincrement": false,
882
+ "default": 0
883
+ },
884
+ "discount_total_minor": {
885
+ "name": "discount_total_minor",
886
+ "type": "integer",
887
+ "primaryKey": false,
888
+ "notNull": true,
889
+ "autoincrement": false,
890
+ "default": 0
891
+ },
892
+ "total_minor": {
893
+ "name": "total_minor",
894
+ "type": "integer",
895
+ "primaryKey": false,
896
+ "notNull": true,
897
+ "autoincrement": false
898
+ },
899
+ "currency": {
900
+ "name": "currency",
901
+ "type": "text",
902
+ "primaryKey": false,
903
+ "notNull": true,
904
+ "autoincrement": false
905
+ },
906
+ "notes": {
907
+ "name": "notes",
908
+ "type": "text",
909
+ "primaryKey": false,
910
+ "notNull": true,
911
+ "autoincrement": false,
912
+ "default": "''"
913
+ },
914
+ "metadata": {
915
+ "name": "metadata",
916
+ "type": "text",
917
+ "primaryKey": false,
918
+ "notNull": true,
919
+ "autoincrement": false,
920
+ "default": "'{}'"
921
+ },
922
+ "payment_intent_id": {
923
+ "name": "payment_intent_id",
924
+ "type": "text",
925
+ "primaryKey": false,
926
+ "notNull": false,
927
+ "autoincrement": false
928
+ },
929
+ "cart_token": {
930
+ "name": "cart_token",
931
+ "type": "text",
932
+ "primaryKey": false,
933
+ "notNull": false,
934
+ "autoincrement": false
935
+ },
936
+ "captured_minor": {
937
+ "name": "captured_minor",
938
+ "type": "integer",
939
+ "primaryKey": false,
940
+ "notNull": true,
941
+ "autoincrement": false,
942
+ "default": 0
943
+ },
944
+ "captured_at": {
945
+ "name": "captured_at",
946
+ "type": "text",
947
+ "primaryKey": false,
948
+ "notNull": false,
949
+ "autoincrement": false
950
+ },
951
+ "refunded_minor": {
952
+ "name": "refunded_minor",
953
+ "type": "integer",
954
+ "primaryKey": false,
955
+ "notNull": true,
956
+ "autoincrement": false,
957
+ "default": 0
958
+ },
959
+ "capture_method": {
960
+ "name": "capture_method",
961
+ "type": "text",
962
+ "primaryKey": false,
963
+ "notNull": false,
964
+ "autoincrement": false
965
+ },
966
+ "created_at": {
967
+ "name": "created_at",
968
+ "type": "text",
969
+ "primaryKey": false,
970
+ "notNull": true,
971
+ "autoincrement": false
972
+ },
973
+ "updated_at": {
974
+ "name": "updated_at",
975
+ "type": "text",
976
+ "primaryKey": false,
977
+ "notNull": true,
978
+ "autoincrement": false
979
+ }
980
+ },
981
+ "indexes": {
982
+ "orders_number_unique": {
983
+ "name": "orders_number_unique",
984
+ "columns": [
985
+ "order_number"
986
+ ],
987
+ "isUnique": true
988
+ },
989
+ "orders_sequence_unique": {
990
+ "name": "orders_sequence_unique",
991
+ "columns": [
992
+ "sequence"
993
+ ],
994
+ "isUnique": true
995
+ },
996
+ "orders_customer_idx": {
997
+ "name": "orders_customer_idx",
998
+ "columns": [
999
+ "customer_id"
1000
+ ],
1001
+ "isUnique": false
1002
+ },
1003
+ "orders_status_idx": {
1004
+ "name": "orders_status_idx",
1005
+ "columns": [
1006
+ "status"
1007
+ ],
1008
+ "isUnique": false
1009
+ },
1010
+ "orders_payment_intent_idx": {
1011
+ "name": "orders_payment_intent_idx",
1012
+ "columns": [
1013
+ "payment_intent_id"
1014
+ ],
1015
+ "isUnique": false
1016
+ },
1017
+ "orders_pending_cart_unique": {
1018
+ "name": "orders_pending_cart_unique",
1019
+ "columns": [
1020
+ "cart_token"
1021
+ ],
1022
+ "isUnique": true,
1023
+ "where": "status = 'pending'"
1024
+ }
1025
+ },
1026
+ "foreignKeys": {},
1027
+ "compositePrimaryKeys": {},
1028
+ "uniqueConstraints": {},
1029
+ "checkConstraints": {}
1030
+ },
1031
+ "processed_events": {
1032
+ "name": "processed_events",
1033
+ "columns": {
1034
+ "handler_name": {
1035
+ "name": "handler_name",
1036
+ "type": "text",
1037
+ "primaryKey": false,
1038
+ "notNull": true,
1039
+ "autoincrement": false
1040
+ },
1041
+ "event_id": {
1042
+ "name": "event_id",
1043
+ "type": "text",
1044
+ "primaryKey": false,
1045
+ "notNull": true,
1046
+ "autoincrement": false
1047
+ },
1048
+ "processed_at": {
1049
+ "name": "processed_at",
1050
+ "type": "text",
1051
+ "primaryKey": false,
1052
+ "notNull": true,
1053
+ "autoincrement": false
1054
+ }
1055
+ },
1056
+ "indexes": {},
1057
+ "foreignKeys": {},
1058
+ "compositePrimaryKeys": {
1059
+ "processed_events_handler_name_event_id_pk": {
1060
+ "columns": [
1061
+ "handler_name",
1062
+ "event_id"
1063
+ ],
1064
+ "name": "processed_events_handler_name_event_id_pk"
1065
+ }
1066
+ },
1067
+ "uniqueConstraints": {},
1068
+ "checkConstraints": {}
1069
+ },
1070
+ "product_categories": {
1071
+ "name": "product_categories",
1072
+ "columns": {
1073
+ "product_id": {
1074
+ "name": "product_id",
1075
+ "type": "text",
1076
+ "primaryKey": false,
1077
+ "notNull": true,
1078
+ "autoincrement": false
1079
+ },
1080
+ "category_id": {
1081
+ "name": "category_id",
1082
+ "type": "text",
1083
+ "primaryKey": false,
1084
+ "notNull": true,
1085
+ "autoincrement": false
1086
+ }
1087
+ },
1088
+ "indexes": {
1089
+ "product_categories_category_idx": {
1090
+ "name": "product_categories_category_idx",
1091
+ "columns": [
1092
+ "category_id"
1093
+ ],
1094
+ "isUnique": false
1095
+ }
1096
+ },
1097
+ "foreignKeys": {},
1098
+ "compositePrimaryKeys": {
1099
+ "product_categories_product_id_category_id_pk": {
1100
+ "columns": [
1101
+ "product_id",
1102
+ "category_id"
1103
+ ],
1104
+ "name": "product_categories_product_id_category_id_pk"
1105
+ }
1106
+ },
1107
+ "uniqueConstraints": {},
1108
+ "checkConstraints": {}
1109
+ },
1110
+ "products": {
1111
+ "name": "products",
1112
+ "columns": {
1113
+ "id": {
1114
+ "name": "id",
1115
+ "type": "text",
1116
+ "primaryKey": true,
1117
+ "notNull": true,
1118
+ "autoincrement": false
1119
+ },
1120
+ "slug": {
1121
+ "name": "slug",
1122
+ "type": "text",
1123
+ "primaryKey": false,
1124
+ "notNull": true,
1125
+ "autoincrement": false
1126
+ },
1127
+ "name": {
1128
+ "name": "name",
1129
+ "type": "text",
1130
+ "primaryKey": false,
1131
+ "notNull": true,
1132
+ "autoincrement": false
1133
+ },
1134
+ "description": {
1135
+ "name": "description",
1136
+ "type": "text",
1137
+ "primaryKey": false,
1138
+ "notNull": true,
1139
+ "autoincrement": false,
1140
+ "default": "''"
1141
+ },
1142
+ "short_description": {
1143
+ "name": "short_description",
1144
+ "type": "text",
1145
+ "primaryKey": false,
1146
+ "notNull": true,
1147
+ "autoincrement": false,
1148
+ "default": "''"
1149
+ },
1150
+ "status": {
1151
+ "name": "status",
1152
+ "type": "text",
1153
+ "primaryKey": false,
1154
+ "notNull": true,
1155
+ "autoincrement": false,
1156
+ "default": "'draft'"
1157
+ },
1158
+ "type": {
1159
+ "name": "type",
1160
+ "type": "text",
1161
+ "primaryKey": false,
1162
+ "notNull": true,
1163
+ "autoincrement": false,
1164
+ "default": "'simple'"
1165
+ },
1166
+ "seo_title": {
1167
+ "name": "seo_title",
1168
+ "type": "text",
1169
+ "primaryKey": false,
1170
+ "notNull": true,
1171
+ "autoincrement": false,
1172
+ "default": "''"
1173
+ },
1174
+ "seo_description": {
1175
+ "name": "seo_description",
1176
+ "type": "text",
1177
+ "primaryKey": false,
1178
+ "notNull": true,
1179
+ "autoincrement": false,
1180
+ "default": "''"
1181
+ },
1182
+ "media": {
1183
+ "name": "media",
1184
+ "type": "text",
1185
+ "primaryKey": false,
1186
+ "notNull": true,
1187
+ "autoincrement": false,
1188
+ "default": "'[]'"
1189
+ },
1190
+ "metadata": {
1191
+ "name": "metadata",
1192
+ "type": "text",
1193
+ "primaryKey": false,
1194
+ "notNull": true,
1195
+ "autoincrement": false,
1196
+ "default": "'{}'"
1197
+ },
1198
+ "created_at": {
1199
+ "name": "created_at",
1200
+ "type": "text",
1201
+ "primaryKey": false,
1202
+ "notNull": true,
1203
+ "autoincrement": false
1204
+ },
1205
+ "updated_at": {
1206
+ "name": "updated_at",
1207
+ "type": "text",
1208
+ "primaryKey": false,
1209
+ "notNull": true,
1210
+ "autoincrement": false
1211
+ }
1212
+ },
1213
+ "indexes": {
1214
+ "products_slug_unique": {
1215
+ "name": "products_slug_unique",
1216
+ "columns": [
1217
+ "slug"
1218
+ ],
1219
+ "isUnique": true
1220
+ },
1221
+ "products_status_idx": {
1222
+ "name": "products_status_idx",
1223
+ "columns": [
1224
+ "status"
1225
+ ],
1226
+ "isUnique": false
1227
+ }
1228
+ },
1229
+ "foreignKeys": {},
1230
+ "compositePrimaryKeys": {},
1231
+ "uniqueConstraints": {},
1232
+ "checkConstraints": {}
1233
+ },
1234
+ "refresh_tokens": {
1235
+ "name": "refresh_tokens",
1236
+ "columns": {
1237
+ "id": {
1238
+ "name": "id",
1239
+ "type": "text",
1240
+ "primaryKey": true,
1241
+ "notNull": true,
1242
+ "autoincrement": false
1243
+ },
1244
+ "customer_id": {
1245
+ "name": "customer_id",
1246
+ "type": "text",
1247
+ "primaryKey": false,
1248
+ "notNull": true,
1249
+ "autoincrement": false
1250
+ },
1251
+ "token_hash": {
1252
+ "name": "token_hash",
1253
+ "type": "text",
1254
+ "primaryKey": false,
1255
+ "notNull": true,
1256
+ "autoincrement": false
1257
+ },
1258
+ "revoked_at": {
1259
+ "name": "revoked_at",
1260
+ "type": "text",
1261
+ "primaryKey": false,
1262
+ "notNull": false,
1263
+ "autoincrement": false
1264
+ },
1265
+ "replaced_by_jti": {
1266
+ "name": "replaced_by_jti",
1267
+ "type": "text",
1268
+ "primaryKey": false,
1269
+ "notNull": false,
1270
+ "autoincrement": false
1271
+ },
1272
+ "expires_at": {
1273
+ "name": "expires_at",
1274
+ "type": "text",
1275
+ "primaryKey": false,
1276
+ "notNull": true,
1277
+ "autoincrement": false
1278
+ },
1279
+ "created_at": {
1280
+ "name": "created_at",
1281
+ "type": "text",
1282
+ "primaryKey": false,
1283
+ "notNull": true,
1284
+ "autoincrement": false
1285
+ }
1286
+ },
1287
+ "indexes": {
1288
+ "refresh_tokens_customer_idx": {
1289
+ "name": "refresh_tokens_customer_idx",
1290
+ "columns": [
1291
+ "customer_id"
1292
+ ],
1293
+ "isUnique": false
1294
+ }
1295
+ },
1296
+ "foreignKeys": {},
1297
+ "compositePrimaryKeys": {},
1298
+ "uniqueConstraints": {},
1299
+ "checkConstraints": {}
1300
+ },
1301
+ "reviews": {
1302
+ "name": "reviews",
1303
+ "columns": {
1304
+ "id": {
1305
+ "name": "id",
1306
+ "type": "text",
1307
+ "primaryKey": true,
1308
+ "notNull": true,
1309
+ "autoincrement": false
1310
+ },
1311
+ "product_id": {
1312
+ "name": "product_id",
1313
+ "type": "text",
1314
+ "primaryKey": false,
1315
+ "notNull": true,
1316
+ "autoincrement": false
1317
+ },
1318
+ "customer_id": {
1319
+ "name": "customer_id",
1320
+ "type": "text",
1321
+ "primaryKey": false,
1322
+ "notNull": false,
1323
+ "autoincrement": false
1324
+ },
1325
+ "order_id": {
1326
+ "name": "order_id",
1327
+ "type": "text",
1328
+ "primaryKey": false,
1329
+ "notNull": false,
1330
+ "autoincrement": false
1331
+ },
1332
+ "rating": {
1333
+ "name": "rating",
1334
+ "type": "integer",
1335
+ "primaryKey": false,
1336
+ "notNull": true,
1337
+ "autoincrement": false
1338
+ },
1339
+ "title": {
1340
+ "name": "title",
1341
+ "type": "text",
1342
+ "primaryKey": false,
1343
+ "notNull": true,
1344
+ "autoincrement": false,
1345
+ "default": "''"
1346
+ },
1347
+ "body": {
1348
+ "name": "body",
1349
+ "type": "text",
1350
+ "primaryKey": false,
1351
+ "notNull": true,
1352
+ "autoincrement": false,
1353
+ "default": "''"
1354
+ },
1355
+ "moderation_status": {
1356
+ "name": "moderation_status",
1357
+ "type": "text",
1358
+ "primaryKey": false,
1359
+ "notNull": true,
1360
+ "autoincrement": false,
1361
+ "default": "'pending'"
1362
+ },
1363
+ "submitted_at": {
1364
+ "name": "submitted_at",
1365
+ "type": "text",
1366
+ "primaryKey": false,
1367
+ "notNull": true,
1368
+ "autoincrement": false
1369
+ },
1370
+ "moderated_at": {
1371
+ "name": "moderated_at",
1372
+ "type": "text",
1373
+ "primaryKey": false,
1374
+ "notNull": false,
1375
+ "autoincrement": false
1376
+ },
1377
+ "moderated_by": {
1378
+ "name": "moderated_by",
1379
+ "type": "text",
1380
+ "primaryKey": false,
1381
+ "notNull": false,
1382
+ "autoincrement": false
1383
+ }
1384
+ },
1385
+ "indexes": {
1386
+ "reviews_product_idx": {
1387
+ "name": "reviews_product_idx",
1388
+ "columns": [
1389
+ "product_id"
1390
+ ],
1391
+ "isUnique": false
1392
+ },
1393
+ "reviews_status_idx": {
1394
+ "name": "reviews_status_idx",
1395
+ "columns": [
1396
+ "moderation_status"
1397
+ ],
1398
+ "isUnique": false
1399
+ }
1400
+ },
1401
+ "foreignKeys": {},
1402
+ "compositePrimaryKeys": {},
1403
+ "uniqueConstraints": {},
1404
+ "checkConstraints": {}
1405
+ },
1406
+ "settings": {
1407
+ "name": "settings",
1408
+ "columns": {
1409
+ "slot": {
1410
+ "name": "slot",
1411
+ "type": "text",
1412
+ "primaryKey": false,
1413
+ "notNull": true,
1414
+ "autoincrement": false
1415
+ },
1416
+ "path": {
1417
+ "name": "path",
1418
+ "type": "text",
1419
+ "primaryKey": false,
1420
+ "notNull": true,
1421
+ "autoincrement": false
1422
+ },
1423
+ "ciphertext": {
1424
+ "name": "ciphertext",
1425
+ "type": "blob",
1426
+ "primaryKey": false,
1427
+ "notNull": false,
1428
+ "autoincrement": false
1429
+ },
1430
+ "plain": {
1431
+ "name": "plain",
1432
+ "type": "text",
1433
+ "primaryKey": false,
1434
+ "notNull": false,
1435
+ "autoincrement": false
1436
+ },
1437
+ "iv": {
1438
+ "name": "iv",
1439
+ "type": "blob",
1440
+ "primaryKey": false,
1441
+ "notNull": false,
1442
+ "autoincrement": false
1443
+ },
1444
+ "tag": {
1445
+ "name": "tag",
1446
+ "type": "blob",
1447
+ "primaryKey": false,
1448
+ "notNull": false,
1449
+ "autoincrement": false
1450
+ },
1451
+ "key_id": {
1452
+ "name": "key_id",
1453
+ "type": "text",
1454
+ "primaryKey": false,
1455
+ "notNull": false,
1456
+ "autoincrement": false
1457
+ },
1458
+ "updated_at": {
1459
+ "name": "updated_at",
1460
+ "type": "text",
1461
+ "primaryKey": false,
1462
+ "notNull": true,
1463
+ "autoincrement": false
1464
+ },
1465
+ "updated_by": {
1466
+ "name": "updated_by",
1467
+ "type": "text",
1468
+ "primaryKey": false,
1469
+ "notNull": false,
1470
+ "autoincrement": false
1471
+ }
1472
+ },
1473
+ "indexes": {},
1474
+ "foreignKeys": {},
1475
+ "compositePrimaryKeys": {
1476
+ "settings_slot_path_pk": {
1477
+ "columns": [
1478
+ "slot",
1479
+ "path"
1480
+ ],
1481
+ "name": "settings_slot_path_pk"
1482
+ }
1483
+ },
1484
+ "uniqueConstraints": {},
1485
+ "checkConstraints": {
1486
+ "settings_one_value": {
1487
+ "name": "settings_one_value",
1488
+ "value": "(\"settings\".\"ciphertext\" IS NULL) <> (\"settings\".\"plain\" IS NULL) AND (\"settings\".\"ciphertext\" IS NULL OR (\"settings\".\"iv\" IS NOT NULL AND \"settings\".\"tag\" IS NOT NULL AND \"settings\".\"key_id\" IS NOT NULL))"
1489
+ }
1490
+ }
1491
+ },
1492
+ "stock_adjustments": {
1493
+ "name": "stock_adjustments",
1494
+ "columns": {
1495
+ "id": {
1496
+ "name": "id",
1497
+ "type": "text",
1498
+ "primaryKey": true,
1499
+ "notNull": true,
1500
+ "autoincrement": false
1501
+ },
1502
+ "variant_id": {
1503
+ "name": "variant_id",
1504
+ "type": "text",
1505
+ "primaryKey": false,
1506
+ "notNull": true,
1507
+ "autoincrement": false
1508
+ },
1509
+ "adjustment": {
1510
+ "name": "adjustment",
1511
+ "type": "integer",
1512
+ "primaryKey": false,
1513
+ "notNull": true,
1514
+ "autoincrement": false
1515
+ },
1516
+ "reason": {
1517
+ "name": "reason",
1518
+ "type": "text",
1519
+ "primaryKey": false,
1520
+ "notNull": true,
1521
+ "autoincrement": false
1522
+ },
1523
+ "actor": {
1524
+ "name": "actor",
1525
+ "type": "text",
1526
+ "primaryKey": false,
1527
+ "notNull": true,
1528
+ "autoincrement": false
1529
+ },
1530
+ "previous_qty": {
1531
+ "name": "previous_qty",
1532
+ "type": "integer",
1533
+ "primaryKey": false,
1534
+ "notNull": true,
1535
+ "autoincrement": false
1536
+ },
1537
+ "new_qty": {
1538
+ "name": "new_qty",
1539
+ "type": "integer",
1540
+ "primaryKey": false,
1541
+ "notNull": true,
1542
+ "autoincrement": false
1543
+ },
1544
+ "timestamp": {
1545
+ "name": "timestamp",
1546
+ "type": "text",
1547
+ "primaryKey": false,
1548
+ "notNull": true,
1549
+ "autoincrement": false
1550
+ }
1551
+ },
1552
+ "indexes": {
1553
+ "stock_adjustments_variant_idx": {
1554
+ "name": "stock_adjustments_variant_idx",
1555
+ "columns": [
1556
+ "variant_id"
1557
+ ],
1558
+ "isUnique": false
1559
+ }
1560
+ },
1561
+ "foreignKeys": {},
1562
+ "compositePrimaryKeys": {},
1563
+ "uniqueConstraints": {},
1564
+ "checkConstraints": {}
1565
+ },
1566
+ "variants": {
1567
+ "name": "variants",
1568
+ "columns": {
1569
+ "id": {
1570
+ "name": "id",
1571
+ "type": "text",
1572
+ "primaryKey": true,
1573
+ "notNull": true,
1574
+ "autoincrement": false
1575
+ },
1576
+ "product_id": {
1577
+ "name": "product_id",
1578
+ "type": "text",
1579
+ "primaryKey": false,
1580
+ "notNull": true,
1581
+ "autoincrement": false
1582
+ },
1583
+ "sku": {
1584
+ "name": "sku",
1585
+ "type": "text",
1586
+ "primaryKey": false,
1587
+ "notNull": true,
1588
+ "autoincrement": false
1589
+ },
1590
+ "name": {
1591
+ "name": "name",
1592
+ "type": "text",
1593
+ "primaryKey": false,
1594
+ "notNull": true,
1595
+ "autoincrement": false,
1596
+ "default": "''"
1597
+ },
1598
+ "price_minor": {
1599
+ "name": "price_minor",
1600
+ "type": "integer",
1601
+ "primaryKey": false,
1602
+ "notNull": true,
1603
+ "autoincrement": false
1604
+ },
1605
+ "compare_at_price_minor": {
1606
+ "name": "compare_at_price_minor",
1607
+ "type": "integer",
1608
+ "primaryKey": false,
1609
+ "notNull": false,
1610
+ "autoincrement": false
1611
+ },
1612
+ "weight_grams": {
1613
+ "name": "weight_grams",
1614
+ "type": "integer",
1615
+ "primaryKey": false,
1616
+ "notNull": false,
1617
+ "autoincrement": false
1618
+ },
1619
+ "dimensions": {
1620
+ "name": "dimensions",
1621
+ "type": "text",
1622
+ "primaryKey": false,
1623
+ "notNull": false,
1624
+ "autoincrement": false
1625
+ },
1626
+ "stock": {
1627
+ "name": "stock",
1628
+ "type": "integer",
1629
+ "primaryKey": false,
1630
+ "notNull": true,
1631
+ "autoincrement": false,
1632
+ "default": 0
1633
+ },
1634
+ "low_stock_threshold": {
1635
+ "name": "low_stock_threshold",
1636
+ "type": "integer",
1637
+ "primaryKey": false,
1638
+ "notNull": true,
1639
+ "autoincrement": false,
1640
+ "default": 0
1641
+ },
1642
+ "options": {
1643
+ "name": "options",
1644
+ "type": "text",
1645
+ "primaryKey": false,
1646
+ "notNull": true,
1647
+ "autoincrement": false,
1648
+ "default": "'[]'"
1649
+ },
1650
+ "status": {
1651
+ "name": "status",
1652
+ "type": "text",
1653
+ "primaryKey": false,
1654
+ "notNull": true,
1655
+ "autoincrement": false,
1656
+ "default": "'active'"
1657
+ },
1658
+ "created_at": {
1659
+ "name": "created_at",
1660
+ "type": "text",
1661
+ "primaryKey": false,
1662
+ "notNull": true,
1663
+ "autoincrement": false
1664
+ },
1665
+ "updated_at": {
1666
+ "name": "updated_at",
1667
+ "type": "text",
1668
+ "primaryKey": false,
1669
+ "notNull": true,
1670
+ "autoincrement": false
1671
+ }
1672
+ },
1673
+ "indexes": {
1674
+ "variants_sku_unique": {
1675
+ "name": "variants_sku_unique",
1676
+ "columns": [
1677
+ "sku"
1678
+ ],
1679
+ "isUnique": true
1680
+ },
1681
+ "variants_product_idx": {
1682
+ "name": "variants_product_idx",
1683
+ "columns": [
1684
+ "product_id"
1685
+ ],
1686
+ "isUnique": false
1687
+ }
1688
+ },
1689
+ "foreignKeys": {},
1690
+ "compositePrimaryKeys": {},
1691
+ "uniqueConstraints": {},
1692
+ "checkConstraints": {}
1693
+ }
1694
+ },
1695
+ "views": {},
1696
+ "enums": {},
1697
+ "_meta": {
1698
+ "schemas": {},
1699
+ "tables": {},
1700
+ "columns": {}
1701
+ },
1702
+ "internal": {
1703
+ "indexes": {}
1704
+ }
1705
+ }