@manablox/db 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,2115 @@
1
+ {
2
+ "id": "2df3e48d-5ef8-41ac-bc3a-b49809510b4e",
3
+ "prevId": "53fb727f-2718-48d0-8b5b-ee603c1d7276",
4
+ "version": "7",
5
+ "dialect": "postgresql",
6
+ "tables": {
7
+ "public.accounts": {
8
+ "name": "accounts",
9
+ "schema": "",
10
+ "columns": {
11
+ "id": {
12
+ "name": "id",
13
+ "type": "uuid",
14
+ "primaryKey": true,
15
+ "notNull": true,
16
+ "default": "gen_random_uuid()"
17
+ },
18
+ "user_id": {
19
+ "name": "user_id",
20
+ "type": "uuid",
21
+ "primaryKey": false,
22
+ "notNull": true
23
+ },
24
+ "account_id": {
25
+ "name": "account_id",
26
+ "type": "text",
27
+ "primaryKey": false,
28
+ "notNull": true
29
+ },
30
+ "provider_id": {
31
+ "name": "provider_id",
32
+ "type": "text",
33
+ "primaryKey": false,
34
+ "notNull": true
35
+ },
36
+ "issuer": {
37
+ "name": "issuer",
38
+ "type": "text",
39
+ "primaryKey": false,
40
+ "notNull": true,
41
+ "default": "''"
42
+ },
43
+ "access_token": {
44
+ "name": "access_token",
45
+ "type": "text",
46
+ "primaryKey": false,
47
+ "notNull": false
48
+ },
49
+ "refresh_token": {
50
+ "name": "refresh_token",
51
+ "type": "text",
52
+ "primaryKey": false,
53
+ "notNull": false
54
+ },
55
+ "access_token_expires_at": {
56
+ "name": "access_token_expires_at",
57
+ "type": "timestamp with time zone",
58
+ "primaryKey": false,
59
+ "notNull": false
60
+ },
61
+ "refresh_token_expires_at": {
62
+ "name": "refresh_token_expires_at",
63
+ "type": "timestamp with time zone",
64
+ "primaryKey": false,
65
+ "notNull": false
66
+ },
67
+ "scope": {
68
+ "name": "scope",
69
+ "type": "text",
70
+ "primaryKey": false,
71
+ "notNull": false
72
+ },
73
+ "id_token": {
74
+ "name": "id_token",
75
+ "type": "text",
76
+ "primaryKey": false,
77
+ "notNull": false
78
+ },
79
+ "password": {
80
+ "name": "password",
81
+ "type": "text",
82
+ "primaryKey": false,
83
+ "notNull": false
84
+ },
85
+ "created_at": {
86
+ "name": "created_at",
87
+ "type": "timestamp with time zone",
88
+ "primaryKey": false,
89
+ "notNull": true,
90
+ "default": "now()"
91
+ },
92
+ "updated_at": {
93
+ "name": "updated_at",
94
+ "type": "timestamp with time zone",
95
+ "primaryKey": false,
96
+ "notNull": true,
97
+ "default": "now()"
98
+ }
99
+ },
100
+ "indexes": {
101
+ "accounts_provider_account_key": {
102
+ "name": "accounts_provider_account_key",
103
+ "columns": [
104
+ {
105
+ "expression": "provider_id",
106
+ "isExpression": false,
107
+ "asc": true,
108
+ "nulls": "last"
109
+ },
110
+ {
111
+ "expression": "account_id",
112
+ "isExpression": false,
113
+ "asc": true,
114
+ "nulls": "last"
115
+ }
116
+ ],
117
+ "isUnique": true,
118
+ "concurrently": false,
119
+ "method": "btree",
120
+ "with": {}
121
+ }
122
+ },
123
+ "foreignKeys": {
124
+ "accounts_user_id_users_id_fk": {
125
+ "name": "accounts_user_id_users_id_fk",
126
+ "tableFrom": "accounts",
127
+ "tableTo": "users",
128
+ "columnsFrom": ["user_id"],
129
+ "columnsTo": ["id"],
130
+ "onDelete": "cascade",
131
+ "onUpdate": "no action"
132
+ }
133
+ },
134
+ "compositePrimaryKeys": {},
135
+ "uniqueConstraints": {},
136
+ "policies": {},
137
+ "checkConstraints": {},
138
+ "isRLSEnabled": false
139
+ },
140
+ "public.apikeys": {
141
+ "name": "apikeys",
142
+ "schema": "",
143
+ "columns": {
144
+ "id": {
145
+ "name": "id",
146
+ "type": "uuid",
147
+ "primaryKey": true,
148
+ "notNull": true,
149
+ "default": "gen_random_uuid()"
150
+ },
151
+ "name": {
152
+ "name": "name",
153
+ "type": "text",
154
+ "primaryKey": false,
155
+ "notNull": false
156
+ },
157
+ "start": {
158
+ "name": "start",
159
+ "type": "text",
160
+ "primaryKey": false,
161
+ "notNull": false
162
+ },
163
+ "prefix": {
164
+ "name": "prefix",
165
+ "type": "text",
166
+ "primaryKey": false,
167
+ "notNull": false
168
+ },
169
+ "key": {
170
+ "name": "key",
171
+ "type": "text",
172
+ "primaryKey": false,
173
+ "notNull": true
174
+ },
175
+ "user_id": {
176
+ "name": "user_id",
177
+ "type": "uuid",
178
+ "primaryKey": false,
179
+ "notNull": true
180
+ },
181
+ "enabled": {
182
+ "name": "enabled",
183
+ "type": "boolean",
184
+ "primaryKey": false,
185
+ "notNull": true,
186
+ "default": true
187
+ },
188
+ "expires_at": {
189
+ "name": "expires_at",
190
+ "type": "timestamp with time zone",
191
+ "primaryKey": false,
192
+ "notNull": false
193
+ },
194
+ "last_request": {
195
+ "name": "last_request",
196
+ "type": "timestamp with time zone",
197
+ "primaryKey": false,
198
+ "notNull": false
199
+ },
200
+ "permissions": {
201
+ "name": "permissions",
202
+ "type": "text",
203
+ "primaryKey": false,
204
+ "notNull": false
205
+ },
206
+ "metadata": {
207
+ "name": "metadata",
208
+ "type": "text",
209
+ "primaryKey": false,
210
+ "notNull": false
211
+ },
212
+ "created_at": {
213
+ "name": "created_at",
214
+ "type": "timestamp with time zone",
215
+ "primaryKey": false,
216
+ "notNull": true,
217
+ "default": "now()"
218
+ },
219
+ "updated_at": {
220
+ "name": "updated_at",
221
+ "type": "timestamp with time zone",
222
+ "primaryKey": false,
223
+ "notNull": true,
224
+ "default": "now()"
225
+ }
226
+ },
227
+ "indexes": {
228
+ "apikeys_user_idx": {
229
+ "name": "apikeys_user_idx",
230
+ "columns": [
231
+ {
232
+ "expression": "user_id",
233
+ "isExpression": false,
234
+ "asc": true,
235
+ "nulls": "last"
236
+ }
237
+ ],
238
+ "isUnique": false,
239
+ "concurrently": false,
240
+ "method": "btree",
241
+ "with": {}
242
+ }
243
+ },
244
+ "foreignKeys": {
245
+ "apikeys_user_id_users_id_fk": {
246
+ "name": "apikeys_user_id_users_id_fk",
247
+ "tableFrom": "apikeys",
248
+ "tableTo": "users",
249
+ "columnsFrom": ["user_id"],
250
+ "columnsTo": ["id"],
251
+ "onDelete": "cascade",
252
+ "onUpdate": "no action"
253
+ }
254
+ },
255
+ "compositePrimaryKeys": {},
256
+ "uniqueConstraints": {},
257
+ "policies": {},
258
+ "checkConstraints": {},
259
+ "isRLSEnabled": false
260
+ },
261
+ "public.asset_variants": {
262
+ "name": "asset_variants",
263
+ "schema": "",
264
+ "columns": {
265
+ "id": {
266
+ "name": "id",
267
+ "type": "uuid",
268
+ "primaryKey": true,
269
+ "notNull": true,
270
+ "default": "gen_random_uuid()"
271
+ },
272
+ "asset_id": {
273
+ "name": "asset_id",
274
+ "type": "uuid",
275
+ "primaryKey": false,
276
+ "notNull": true
277
+ },
278
+ "preset": {
279
+ "name": "preset",
280
+ "type": "text",
281
+ "primaryKey": false,
282
+ "notNull": true
283
+ },
284
+ "format": {
285
+ "name": "format",
286
+ "type": "text",
287
+ "primaryKey": false,
288
+ "notNull": true
289
+ },
290
+ "key": {
291
+ "name": "key",
292
+ "type": "text",
293
+ "primaryKey": false,
294
+ "notNull": true
295
+ },
296
+ "width": {
297
+ "name": "width",
298
+ "type": "integer",
299
+ "primaryKey": false,
300
+ "notNull": false
301
+ },
302
+ "height": {
303
+ "name": "height",
304
+ "type": "integer",
305
+ "primaryKey": false,
306
+ "notNull": false
307
+ },
308
+ "size": {
309
+ "name": "size",
310
+ "type": "integer",
311
+ "primaryKey": false,
312
+ "notNull": true
313
+ },
314
+ "created_at": {
315
+ "name": "created_at",
316
+ "type": "timestamp with time zone",
317
+ "primaryKey": false,
318
+ "notNull": true,
319
+ "default": "now()"
320
+ }
321
+ },
322
+ "indexes": {
323
+ "asset_variants_asset_preset_format_key": {
324
+ "name": "asset_variants_asset_preset_format_key",
325
+ "columns": [
326
+ {
327
+ "expression": "asset_id",
328
+ "isExpression": false,
329
+ "asc": true,
330
+ "nulls": "last"
331
+ },
332
+ {
333
+ "expression": "preset",
334
+ "isExpression": false,
335
+ "asc": true,
336
+ "nulls": "last"
337
+ },
338
+ {
339
+ "expression": "format",
340
+ "isExpression": false,
341
+ "asc": true,
342
+ "nulls": "last"
343
+ }
344
+ ],
345
+ "isUnique": true,
346
+ "concurrently": false,
347
+ "method": "btree",
348
+ "with": {}
349
+ }
350
+ },
351
+ "foreignKeys": {
352
+ "asset_variants_asset_id_assets_id_fk": {
353
+ "name": "asset_variants_asset_id_assets_id_fk",
354
+ "tableFrom": "asset_variants",
355
+ "tableTo": "assets",
356
+ "columnsFrom": ["asset_id"],
357
+ "columnsTo": ["id"],
358
+ "onDelete": "cascade",
359
+ "onUpdate": "no action"
360
+ }
361
+ },
362
+ "compositePrimaryKeys": {},
363
+ "uniqueConstraints": {},
364
+ "policies": {},
365
+ "checkConstraints": {},
366
+ "isRLSEnabled": false
367
+ },
368
+ "public.assets": {
369
+ "name": "assets",
370
+ "schema": "",
371
+ "columns": {
372
+ "id": {
373
+ "name": "id",
374
+ "type": "uuid",
375
+ "primaryKey": true,
376
+ "notNull": true,
377
+ "default": "gen_random_uuid()"
378
+ },
379
+ "space_id": {
380
+ "name": "space_id",
381
+ "type": "uuid",
382
+ "primaryKey": false,
383
+ "notNull": true
384
+ },
385
+ "driver": {
386
+ "name": "driver",
387
+ "type": "text",
388
+ "primaryKey": false,
389
+ "notNull": true,
390
+ "default": "'local'"
391
+ },
392
+ "key": {
393
+ "name": "key",
394
+ "type": "text",
395
+ "primaryKey": false,
396
+ "notNull": true
397
+ },
398
+ "filename": {
399
+ "name": "filename",
400
+ "type": "text",
401
+ "primaryKey": false,
402
+ "notNull": true
403
+ },
404
+ "name": {
405
+ "name": "name",
406
+ "type": "text",
407
+ "primaryKey": false,
408
+ "notNull": true
409
+ },
410
+ "mime_type": {
411
+ "name": "mime_type",
412
+ "type": "text",
413
+ "primaryKey": false,
414
+ "notNull": true
415
+ },
416
+ "size": {
417
+ "name": "size",
418
+ "type": "integer",
419
+ "primaryKey": false,
420
+ "notNull": true
421
+ },
422
+ "width": {
423
+ "name": "width",
424
+ "type": "integer",
425
+ "primaryKey": false,
426
+ "notNull": false
427
+ },
428
+ "height": {
429
+ "name": "height",
430
+ "type": "integer",
431
+ "primaryKey": false,
432
+ "notNull": false
433
+ },
434
+ "duration": {
435
+ "name": "duration",
436
+ "type": "integer",
437
+ "primaryKey": false,
438
+ "notNull": false
439
+ },
440
+ "checksum": {
441
+ "name": "checksum",
442
+ "type": "text",
443
+ "primaryKey": false,
444
+ "notNull": false
445
+ },
446
+ "alt": {
447
+ "name": "alt",
448
+ "type": "text",
449
+ "primaryKey": false,
450
+ "notNull": false
451
+ },
452
+ "title": {
453
+ "name": "title",
454
+ "type": "text",
455
+ "primaryKey": false,
456
+ "notNull": false
457
+ },
458
+ "meta": {
459
+ "name": "meta",
460
+ "type": "jsonb",
461
+ "primaryKey": false,
462
+ "notNull": true,
463
+ "default": "'{}'::jsonb"
464
+ },
465
+ "created_at": {
466
+ "name": "created_at",
467
+ "type": "timestamp with time zone",
468
+ "primaryKey": false,
469
+ "notNull": true,
470
+ "default": "now()"
471
+ },
472
+ "updated_at": {
473
+ "name": "updated_at",
474
+ "type": "timestamp with time zone",
475
+ "primaryKey": false,
476
+ "notNull": true,
477
+ "default": "now()"
478
+ },
479
+ "created_by": {
480
+ "name": "created_by",
481
+ "type": "uuid",
482
+ "primaryKey": false,
483
+ "notNull": false
484
+ }
485
+ },
486
+ "indexes": {
487
+ "assets_driver_key_key": {
488
+ "name": "assets_driver_key_key",
489
+ "columns": [
490
+ {
491
+ "expression": "driver",
492
+ "isExpression": false,
493
+ "asc": true,
494
+ "nulls": "last"
495
+ },
496
+ {
497
+ "expression": "key",
498
+ "isExpression": false,
499
+ "asc": true,
500
+ "nulls": "last"
501
+ }
502
+ ],
503
+ "isUnique": true,
504
+ "concurrently": false,
505
+ "method": "btree",
506
+ "with": {}
507
+ },
508
+ "assets_space_idx": {
509
+ "name": "assets_space_idx",
510
+ "columns": [
511
+ {
512
+ "expression": "space_id",
513
+ "isExpression": false,
514
+ "asc": true,
515
+ "nulls": "last"
516
+ },
517
+ {
518
+ "expression": "created_at",
519
+ "isExpression": false,
520
+ "asc": true,
521
+ "nulls": "last"
522
+ }
523
+ ],
524
+ "isUnique": false,
525
+ "concurrently": false,
526
+ "method": "btree",
527
+ "with": {}
528
+ },
529
+ "assets_checksum_idx": {
530
+ "name": "assets_checksum_idx",
531
+ "columns": [
532
+ {
533
+ "expression": "space_id",
534
+ "isExpression": false,
535
+ "asc": true,
536
+ "nulls": "last"
537
+ },
538
+ {
539
+ "expression": "checksum",
540
+ "isExpression": false,
541
+ "asc": true,
542
+ "nulls": "last"
543
+ }
544
+ ],
545
+ "isUnique": false,
546
+ "concurrently": false,
547
+ "method": "btree",
548
+ "with": {}
549
+ },
550
+ "assets_mime_idx": {
551
+ "name": "assets_mime_idx",
552
+ "columns": [
553
+ {
554
+ "expression": "space_id",
555
+ "isExpression": false,
556
+ "asc": true,
557
+ "nulls": "last"
558
+ },
559
+ {
560
+ "expression": "mime_type",
561
+ "isExpression": false,
562
+ "asc": true,
563
+ "nulls": "last"
564
+ }
565
+ ],
566
+ "isUnique": false,
567
+ "concurrently": false,
568
+ "method": "btree",
569
+ "with": {}
570
+ }
571
+ },
572
+ "foreignKeys": {
573
+ "assets_space_id_spaces_id_fk": {
574
+ "name": "assets_space_id_spaces_id_fk",
575
+ "tableFrom": "assets",
576
+ "tableTo": "spaces",
577
+ "columnsFrom": ["space_id"],
578
+ "columnsTo": ["id"],
579
+ "onDelete": "cascade",
580
+ "onUpdate": "no action"
581
+ }
582
+ },
583
+ "compositePrimaryKeys": {},
584
+ "uniqueConstraints": {},
585
+ "policies": {},
586
+ "checkConstraints": {},
587
+ "isRLSEnabled": false
588
+ },
589
+ "public.content_types": {
590
+ "name": "content_types",
591
+ "schema": "",
592
+ "columns": {
593
+ "id": {
594
+ "name": "id",
595
+ "type": "uuid",
596
+ "primaryKey": true,
597
+ "notNull": true,
598
+ "default": "gen_random_uuid()"
599
+ },
600
+ "space_id": {
601
+ "name": "space_id",
602
+ "type": "uuid",
603
+ "primaryKey": false,
604
+ "notNull": false
605
+ },
606
+ "name": {
607
+ "name": "name",
608
+ "type": "text",
609
+ "primaryKey": false,
610
+ "notNull": true
611
+ },
612
+ "label": {
613
+ "name": "label",
614
+ "type": "text",
615
+ "primaryKey": false,
616
+ "notNull": true
617
+ },
618
+ "description": {
619
+ "name": "description",
620
+ "type": "text",
621
+ "primaryKey": false,
622
+ "notNull": false
623
+ },
624
+ "icon": {
625
+ "name": "icon",
626
+ "type": "text",
627
+ "primaryKey": false,
628
+ "notNull": false
629
+ },
630
+ "kind": {
631
+ "name": "kind",
632
+ "type": "text",
633
+ "primaryKey": false,
634
+ "notNull": true,
635
+ "default": "'content'"
636
+ },
637
+ "has_slug": {
638
+ "name": "has_slug",
639
+ "type": "boolean",
640
+ "primaryKey": false,
641
+ "notNull": true,
642
+ "default": true
643
+ },
644
+ "is_publishable": {
645
+ "name": "is_publishable",
646
+ "type": "boolean",
647
+ "primaryKey": false,
648
+ "notNull": true,
649
+ "default": true
650
+ },
651
+ "is_visible_in_tree": {
652
+ "name": "is_visible_in_tree",
653
+ "type": "boolean",
654
+ "primaryKey": false,
655
+ "notNull": true,
656
+ "default": true
657
+ },
658
+ "can_be_visible_in_menu": {
659
+ "name": "can_be_visible_in_menu",
660
+ "type": "boolean",
661
+ "primaryKey": false,
662
+ "notNull": true,
663
+ "default": true
664
+ },
665
+ "fields": {
666
+ "name": "fields",
667
+ "type": "jsonb",
668
+ "primaryKey": false,
669
+ "notNull": true,
670
+ "default": "'[]'::jsonb"
671
+ },
672
+ "created_at": {
673
+ "name": "created_at",
674
+ "type": "timestamp with time zone",
675
+ "primaryKey": false,
676
+ "notNull": true,
677
+ "default": "now()"
678
+ },
679
+ "updated_at": {
680
+ "name": "updated_at",
681
+ "type": "timestamp with time zone",
682
+ "primaryKey": false,
683
+ "notNull": true,
684
+ "default": "now()"
685
+ }
686
+ },
687
+ "indexes": {
688
+ "content_types_space_idx": {
689
+ "name": "content_types_space_idx",
690
+ "columns": [
691
+ {
692
+ "expression": "space_id",
693
+ "isExpression": false,
694
+ "asc": true,
695
+ "nulls": "last"
696
+ }
697
+ ],
698
+ "isUnique": false,
699
+ "concurrently": false,
700
+ "method": "btree",
701
+ "with": {}
702
+ }
703
+ },
704
+ "foreignKeys": {
705
+ "content_types_space_id_spaces_id_fk": {
706
+ "name": "content_types_space_id_spaces_id_fk",
707
+ "tableFrom": "content_types",
708
+ "tableTo": "spaces",
709
+ "columnsFrom": ["space_id"],
710
+ "columnsTo": ["id"],
711
+ "onDelete": "cascade",
712
+ "onUpdate": "no action"
713
+ }
714
+ },
715
+ "compositePrimaryKeys": {},
716
+ "uniqueConstraints": {
717
+ "content_types_space_name_key": {
718
+ "name": "content_types_space_name_key",
719
+ "nullsNotDistinct": true,
720
+ "columns": ["space_id", "name"]
721
+ }
722
+ },
723
+ "policies": {},
724
+ "checkConstraints": {},
725
+ "isRLSEnabled": false
726
+ },
727
+ "public.content_versions": {
728
+ "name": "content_versions",
729
+ "schema": "",
730
+ "columns": {
731
+ "id": {
732
+ "name": "id",
733
+ "type": "uuid",
734
+ "primaryKey": true,
735
+ "notNull": true,
736
+ "default": "gen_random_uuid()"
737
+ },
738
+ "content_id": {
739
+ "name": "content_id",
740
+ "type": "uuid",
741
+ "primaryKey": false,
742
+ "notNull": true
743
+ },
744
+ "version": {
745
+ "name": "version",
746
+ "type": "integer",
747
+ "primaryKey": false,
748
+ "notNull": true
749
+ },
750
+ "label": {
751
+ "name": "label",
752
+ "type": "text",
753
+ "primaryKey": false,
754
+ "notNull": false
755
+ },
756
+ "snapshot": {
757
+ "name": "snapshot",
758
+ "type": "jsonb",
759
+ "primaryKey": false,
760
+ "notNull": true
761
+ },
762
+ "created_at": {
763
+ "name": "created_at",
764
+ "type": "timestamp with time zone",
765
+ "primaryKey": false,
766
+ "notNull": true,
767
+ "default": "now()"
768
+ },
769
+ "created_by": {
770
+ "name": "created_by",
771
+ "type": "uuid",
772
+ "primaryKey": false,
773
+ "notNull": false
774
+ }
775
+ },
776
+ "indexes": {
777
+ "content_versions_content_version_key": {
778
+ "name": "content_versions_content_version_key",
779
+ "columns": [
780
+ {
781
+ "expression": "content_id",
782
+ "isExpression": false,
783
+ "asc": true,
784
+ "nulls": "last"
785
+ },
786
+ {
787
+ "expression": "version",
788
+ "isExpression": false,
789
+ "asc": true,
790
+ "nulls": "last"
791
+ }
792
+ ],
793
+ "isUnique": true,
794
+ "concurrently": false,
795
+ "method": "btree",
796
+ "with": {}
797
+ },
798
+ "content_versions_content_idx": {
799
+ "name": "content_versions_content_idx",
800
+ "columns": [
801
+ {
802
+ "expression": "content_id",
803
+ "isExpression": false,
804
+ "asc": true,
805
+ "nulls": "last"
806
+ },
807
+ {
808
+ "expression": "created_at",
809
+ "isExpression": false,
810
+ "asc": true,
811
+ "nulls": "last"
812
+ }
813
+ ],
814
+ "isUnique": false,
815
+ "concurrently": false,
816
+ "method": "btree",
817
+ "with": {}
818
+ }
819
+ },
820
+ "foreignKeys": {},
821
+ "compositePrimaryKeys": {},
822
+ "uniqueConstraints": {},
823
+ "policies": {},
824
+ "checkConstraints": {},
825
+ "isRLSEnabled": false
826
+ },
827
+ "public.contents": {
828
+ "name": "contents",
829
+ "schema": "",
830
+ "columns": {
831
+ "id": {
832
+ "name": "id",
833
+ "type": "uuid",
834
+ "primaryKey": true,
835
+ "notNull": true,
836
+ "default": "gen_random_uuid()"
837
+ },
838
+ "space_id": {
839
+ "name": "space_id",
840
+ "type": "uuid",
841
+ "primaryKey": false,
842
+ "notNull": true
843
+ },
844
+ "type_id": {
845
+ "name": "type_id",
846
+ "type": "uuid",
847
+ "primaryKey": false,
848
+ "notNull": true
849
+ },
850
+ "locale": {
851
+ "name": "locale",
852
+ "type": "text",
853
+ "primaryKey": false,
854
+ "notNull": true
855
+ },
856
+ "localization_id": {
857
+ "name": "localization_id",
858
+ "type": "uuid",
859
+ "primaryKey": false,
860
+ "notNull": true
861
+ },
862
+ "parent_id": {
863
+ "name": "parent_id",
864
+ "type": "uuid",
865
+ "primaryKey": false,
866
+ "notNull": false
867
+ },
868
+ "title": {
869
+ "name": "title",
870
+ "type": "text",
871
+ "primaryKey": false,
872
+ "notNull": true
873
+ },
874
+ "slug": {
875
+ "name": "slug",
876
+ "type": "text",
877
+ "primaryKey": false,
878
+ "notNull": true
879
+ },
880
+ "path": {
881
+ "name": "path",
882
+ "type": "ltree",
883
+ "primaryKey": false,
884
+ "notNull": true
885
+ },
886
+ "permalink": {
887
+ "name": "permalink",
888
+ "type": "text",
889
+ "primaryKey": false,
890
+ "notNull": false
891
+ },
892
+ "permalink_path": {
893
+ "name": "permalink_path",
894
+ "type": "text",
895
+ "primaryKey": false,
896
+ "notNull": true,
897
+ "default": "''"
898
+ },
899
+ "permalink_segment": {
900
+ "name": "permalink_segment",
901
+ "type": "text",
902
+ "primaryKey": false,
903
+ "notNull": false
904
+ },
905
+ "status": {
906
+ "name": "status",
907
+ "type": "text",
908
+ "primaryKey": false,
909
+ "notNull": true,
910
+ "default": "'draft'"
911
+ },
912
+ "visible_in_menu": {
913
+ "name": "visible_in_menu",
914
+ "type": "boolean",
915
+ "primaryKey": false,
916
+ "notNull": true,
917
+ "default": false
918
+ },
919
+ "position": {
920
+ "name": "position",
921
+ "type": "integer",
922
+ "primaryKey": false,
923
+ "notNull": true,
924
+ "default": 0
925
+ },
926
+ "fields": {
927
+ "name": "fields",
928
+ "type": "jsonb",
929
+ "primaryKey": false,
930
+ "notNull": true,
931
+ "default": "'{}'::jsonb"
932
+ },
933
+ "search_text": {
934
+ "name": "search_text",
935
+ "type": "text",
936
+ "primaryKey": false,
937
+ "notNull": true,
938
+ "default": "''"
939
+ },
940
+ "version": {
941
+ "name": "version",
942
+ "type": "integer",
943
+ "primaryKey": false,
944
+ "notNull": true,
945
+ "default": 1
946
+ },
947
+ "created_at": {
948
+ "name": "created_at",
949
+ "type": "timestamp with time zone",
950
+ "primaryKey": false,
951
+ "notNull": true,
952
+ "default": "now()"
953
+ },
954
+ "updated_at": {
955
+ "name": "updated_at",
956
+ "type": "timestamp with time zone",
957
+ "primaryKey": false,
958
+ "notNull": true,
959
+ "default": "now()"
960
+ },
961
+ "created_by": {
962
+ "name": "created_by",
963
+ "type": "uuid",
964
+ "primaryKey": false,
965
+ "notNull": false
966
+ },
967
+ "updated_by": {
968
+ "name": "updated_by",
969
+ "type": "uuid",
970
+ "primaryKey": false,
971
+ "notNull": false
972
+ },
973
+ "published_at": {
974
+ "name": "published_at",
975
+ "type": "timestamp with time zone",
976
+ "primaryKey": false,
977
+ "notNull": false
978
+ },
979
+ "search": {
980
+ "name": "search",
981
+ "type": "tsvector",
982
+ "primaryKey": false,
983
+ "notNull": false,
984
+ "generated": {
985
+ "as": "to_tsvector('simple', coalesce(title, '') || ' ' || coalesce(search_text, ''))",
986
+ "type": "stored"
987
+ }
988
+ }
989
+ },
990
+ "indexes": {
991
+ "contents_path_gist_idx": {
992
+ "name": "contents_path_gist_idx",
993
+ "columns": [
994
+ {
995
+ "expression": "path",
996
+ "isExpression": false,
997
+ "asc": true,
998
+ "nulls": "last"
999
+ }
1000
+ ],
1001
+ "isUnique": false,
1002
+ "concurrently": false,
1003
+ "method": "gist",
1004
+ "with": {}
1005
+ },
1006
+ "contents_parent_idx": {
1007
+ "name": "contents_parent_idx",
1008
+ "columns": [
1009
+ {
1010
+ "expression": "parent_id",
1011
+ "isExpression": false,
1012
+ "asc": true,
1013
+ "nulls": "last"
1014
+ }
1015
+ ],
1016
+ "isUnique": false,
1017
+ "concurrently": false,
1018
+ "method": "btree",
1019
+ "with": {}
1020
+ },
1021
+ "contents_space_type_idx": {
1022
+ "name": "contents_space_type_idx",
1023
+ "columns": [
1024
+ {
1025
+ "expression": "space_id",
1026
+ "isExpression": false,
1027
+ "asc": true,
1028
+ "nulls": "last"
1029
+ },
1030
+ {
1031
+ "expression": "type_id",
1032
+ "isExpression": false,
1033
+ "asc": true,
1034
+ "nulls": "last"
1035
+ }
1036
+ ],
1037
+ "isUnique": false,
1038
+ "concurrently": false,
1039
+ "method": "btree",
1040
+ "with": {}
1041
+ },
1042
+ "contents_localization_idx": {
1043
+ "name": "contents_localization_idx",
1044
+ "columns": [
1045
+ {
1046
+ "expression": "localization_id",
1047
+ "isExpression": false,
1048
+ "asc": true,
1049
+ "nulls": "last"
1050
+ }
1051
+ ],
1052
+ "isUnique": false,
1053
+ "concurrently": false,
1054
+ "method": "btree",
1055
+ "with": {}
1056
+ },
1057
+ "contents_status_idx": {
1058
+ "name": "contents_status_idx",
1059
+ "columns": [
1060
+ {
1061
+ "expression": "space_id",
1062
+ "isExpression": false,
1063
+ "asc": true,
1064
+ "nulls": "last"
1065
+ },
1066
+ {
1067
+ "expression": "status",
1068
+ "isExpression": false,
1069
+ "asc": true,
1070
+ "nulls": "last"
1071
+ }
1072
+ ],
1073
+ "isUnique": false,
1074
+ "concurrently": false,
1075
+ "method": "btree",
1076
+ "with": {}
1077
+ },
1078
+ "contents_fields_gin_idx": {
1079
+ "name": "contents_fields_gin_idx",
1080
+ "columns": [
1081
+ {
1082
+ "expression": "\"fields\" jsonb_path_ops",
1083
+ "asc": true,
1084
+ "isExpression": true,
1085
+ "nulls": "last"
1086
+ }
1087
+ ],
1088
+ "isUnique": false,
1089
+ "concurrently": false,
1090
+ "method": "gin",
1091
+ "with": {}
1092
+ },
1093
+ "contents_search_gin_idx": {
1094
+ "name": "contents_search_gin_idx",
1095
+ "columns": [
1096
+ {
1097
+ "expression": "search",
1098
+ "isExpression": false,
1099
+ "asc": true,
1100
+ "nulls": "last"
1101
+ }
1102
+ ],
1103
+ "isUnique": false,
1104
+ "concurrently": false,
1105
+ "method": "gin",
1106
+ "with": {}
1107
+ },
1108
+ "contents_permalink_key": {
1109
+ "name": "contents_permalink_key",
1110
+ "columns": [
1111
+ {
1112
+ "expression": "space_id",
1113
+ "isExpression": false,
1114
+ "asc": true,
1115
+ "nulls": "last"
1116
+ },
1117
+ {
1118
+ "expression": "locale",
1119
+ "isExpression": false,
1120
+ "asc": true,
1121
+ "nulls": "last"
1122
+ },
1123
+ {
1124
+ "expression": "permalink",
1125
+ "isExpression": false,
1126
+ "asc": true,
1127
+ "nulls": "last"
1128
+ }
1129
+ ],
1130
+ "isUnique": true,
1131
+ "where": "permalink is not null",
1132
+ "concurrently": false,
1133
+ "method": "btree",
1134
+ "with": {}
1135
+ }
1136
+ },
1137
+ "foreignKeys": {
1138
+ "contents_space_id_spaces_id_fk": {
1139
+ "name": "contents_space_id_spaces_id_fk",
1140
+ "tableFrom": "contents",
1141
+ "tableTo": "spaces",
1142
+ "columnsFrom": ["space_id"],
1143
+ "columnsTo": ["id"],
1144
+ "onDelete": "cascade",
1145
+ "onUpdate": "no action"
1146
+ }
1147
+ },
1148
+ "compositePrimaryKeys": {},
1149
+ "uniqueConstraints": {
1150
+ "contents_sibling_slug_key": {
1151
+ "name": "contents_sibling_slug_key",
1152
+ "nullsNotDistinct": true,
1153
+ "columns": ["space_id", "parent_id", "locale", "slug"]
1154
+ }
1155
+ },
1156
+ "policies": {},
1157
+ "checkConstraints": {},
1158
+ "isRLSEnabled": false
1159
+ },
1160
+ "public.memberships": {
1161
+ "name": "memberships",
1162
+ "schema": "",
1163
+ "columns": {
1164
+ "user_id": {
1165
+ "name": "user_id",
1166
+ "type": "uuid",
1167
+ "primaryKey": false,
1168
+ "notNull": true
1169
+ },
1170
+ "space_id": {
1171
+ "name": "space_id",
1172
+ "type": "uuid",
1173
+ "primaryKey": false,
1174
+ "notNull": true
1175
+ },
1176
+ "role": {
1177
+ "name": "role",
1178
+ "type": "text",
1179
+ "primaryKey": false,
1180
+ "notNull": true,
1181
+ "default": "'editor'"
1182
+ },
1183
+ "created_at": {
1184
+ "name": "created_at",
1185
+ "type": "timestamp with time zone",
1186
+ "primaryKey": false,
1187
+ "notNull": true,
1188
+ "default": "now()"
1189
+ }
1190
+ },
1191
+ "indexes": {
1192
+ "memberships_space_idx": {
1193
+ "name": "memberships_space_idx",
1194
+ "columns": [
1195
+ {
1196
+ "expression": "space_id",
1197
+ "isExpression": false,
1198
+ "asc": true,
1199
+ "nulls": "last"
1200
+ }
1201
+ ],
1202
+ "isUnique": false,
1203
+ "concurrently": false,
1204
+ "method": "btree",
1205
+ "with": {}
1206
+ }
1207
+ },
1208
+ "foreignKeys": {
1209
+ "memberships_user_id_users_id_fk": {
1210
+ "name": "memberships_user_id_users_id_fk",
1211
+ "tableFrom": "memberships",
1212
+ "tableTo": "users",
1213
+ "columnsFrom": ["user_id"],
1214
+ "columnsTo": ["id"],
1215
+ "onDelete": "cascade",
1216
+ "onUpdate": "no action"
1217
+ },
1218
+ "memberships_space_id_spaces_id_fk": {
1219
+ "name": "memberships_space_id_spaces_id_fk",
1220
+ "tableFrom": "memberships",
1221
+ "tableTo": "spaces",
1222
+ "columnsFrom": ["space_id"],
1223
+ "columnsTo": ["id"],
1224
+ "onDelete": "cascade",
1225
+ "onUpdate": "no action"
1226
+ }
1227
+ },
1228
+ "compositePrimaryKeys": {
1229
+ "memberships_user_id_space_id_pk": {
1230
+ "name": "memberships_user_id_space_id_pk",
1231
+ "columns": ["user_id", "space_id"]
1232
+ }
1233
+ },
1234
+ "uniqueConstraints": {},
1235
+ "policies": {},
1236
+ "checkConstraints": {},
1237
+ "isRLSEnabled": false
1238
+ },
1239
+ "public.published_contents": {
1240
+ "name": "published_contents",
1241
+ "schema": "",
1242
+ "columns": {
1243
+ "id": {
1244
+ "name": "id",
1245
+ "type": "uuid",
1246
+ "primaryKey": true,
1247
+ "notNull": true,
1248
+ "default": "gen_random_uuid()"
1249
+ },
1250
+ "space_id": {
1251
+ "name": "space_id",
1252
+ "type": "uuid",
1253
+ "primaryKey": false,
1254
+ "notNull": true
1255
+ },
1256
+ "type_id": {
1257
+ "name": "type_id",
1258
+ "type": "uuid",
1259
+ "primaryKey": false,
1260
+ "notNull": true
1261
+ },
1262
+ "locale": {
1263
+ "name": "locale",
1264
+ "type": "text",
1265
+ "primaryKey": false,
1266
+ "notNull": true
1267
+ },
1268
+ "localization_id": {
1269
+ "name": "localization_id",
1270
+ "type": "uuid",
1271
+ "primaryKey": false,
1272
+ "notNull": true
1273
+ },
1274
+ "parent_id": {
1275
+ "name": "parent_id",
1276
+ "type": "uuid",
1277
+ "primaryKey": false,
1278
+ "notNull": false
1279
+ },
1280
+ "title": {
1281
+ "name": "title",
1282
+ "type": "text",
1283
+ "primaryKey": false,
1284
+ "notNull": true
1285
+ },
1286
+ "slug": {
1287
+ "name": "slug",
1288
+ "type": "text",
1289
+ "primaryKey": false,
1290
+ "notNull": true
1291
+ },
1292
+ "path": {
1293
+ "name": "path",
1294
+ "type": "ltree",
1295
+ "primaryKey": false,
1296
+ "notNull": true
1297
+ },
1298
+ "permalink": {
1299
+ "name": "permalink",
1300
+ "type": "text",
1301
+ "primaryKey": false,
1302
+ "notNull": false
1303
+ },
1304
+ "permalink_path": {
1305
+ "name": "permalink_path",
1306
+ "type": "text",
1307
+ "primaryKey": false,
1308
+ "notNull": true,
1309
+ "default": "''"
1310
+ },
1311
+ "permalink_segment": {
1312
+ "name": "permalink_segment",
1313
+ "type": "text",
1314
+ "primaryKey": false,
1315
+ "notNull": false
1316
+ },
1317
+ "status": {
1318
+ "name": "status",
1319
+ "type": "text",
1320
+ "primaryKey": false,
1321
+ "notNull": true,
1322
+ "default": "'draft'"
1323
+ },
1324
+ "visible_in_menu": {
1325
+ "name": "visible_in_menu",
1326
+ "type": "boolean",
1327
+ "primaryKey": false,
1328
+ "notNull": true,
1329
+ "default": false
1330
+ },
1331
+ "position": {
1332
+ "name": "position",
1333
+ "type": "integer",
1334
+ "primaryKey": false,
1335
+ "notNull": true,
1336
+ "default": 0
1337
+ },
1338
+ "fields": {
1339
+ "name": "fields",
1340
+ "type": "jsonb",
1341
+ "primaryKey": false,
1342
+ "notNull": true,
1343
+ "default": "'{}'::jsonb"
1344
+ },
1345
+ "search_text": {
1346
+ "name": "search_text",
1347
+ "type": "text",
1348
+ "primaryKey": false,
1349
+ "notNull": true,
1350
+ "default": "''"
1351
+ },
1352
+ "version": {
1353
+ "name": "version",
1354
+ "type": "integer",
1355
+ "primaryKey": false,
1356
+ "notNull": true,
1357
+ "default": 1
1358
+ },
1359
+ "created_at": {
1360
+ "name": "created_at",
1361
+ "type": "timestamp with time zone",
1362
+ "primaryKey": false,
1363
+ "notNull": true,
1364
+ "default": "now()"
1365
+ },
1366
+ "updated_at": {
1367
+ "name": "updated_at",
1368
+ "type": "timestamp with time zone",
1369
+ "primaryKey": false,
1370
+ "notNull": true,
1371
+ "default": "now()"
1372
+ },
1373
+ "created_by": {
1374
+ "name": "created_by",
1375
+ "type": "uuid",
1376
+ "primaryKey": false,
1377
+ "notNull": false
1378
+ },
1379
+ "updated_by": {
1380
+ "name": "updated_by",
1381
+ "type": "uuid",
1382
+ "primaryKey": false,
1383
+ "notNull": false
1384
+ },
1385
+ "published_at": {
1386
+ "name": "published_at",
1387
+ "type": "timestamp with time zone",
1388
+ "primaryKey": false,
1389
+ "notNull": false
1390
+ },
1391
+ "source_version": {
1392
+ "name": "source_version",
1393
+ "type": "integer",
1394
+ "primaryKey": false,
1395
+ "notNull": true,
1396
+ "default": 1
1397
+ },
1398
+ "search": {
1399
+ "name": "search",
1400
+ "type": "tsvector",
1401
+ "primaryKey": false,
1402
+ "notNull": false,
1403
+ "generated": {
1404
+ "as": "to_tsvector('simple', coalesce(title, '') || ' ' || coalesce(search_text, ''))",
1405
+ "type": "stored"
1406
+ }
1407
+ }
1408
+ },
1409
+ "indexes": {
1410
+ "published_contents_path_gist_idx": {
1411
+ "name": "published_contents_path_gist_idx",
1412
+ "columns": [
1413
+ {
1414
+ "expression": "path",
1415
+ "isExpression": false,
1416
+ "asc": true,
1417
+ "nulls": "last"
1418
+ }
1419
+ ],
1420
+ "isUnique": false,
1421
+ "concurrently": false,
1422
+ "method": "gist",
1423
+ "with": {}
1424
+ },
1425
+ "published_contents_parent_idx": {
1426
+ "name": "published_contents_parent_idx",
1427
+ "columns": [
1428
+ {
1429
+ "expression": "parent_id",
1430
+ "isExpression": false,
1431
+ "asc": true,
1432
+ "nulls": "last"
1433
+ }
1434
+ ],
1435
+ "isUnique": false,
1436
+ "concurrently": false,
1437
+ "method": "btree",
1438
+ "with": {}
1439
+ },
1440
+ "published_contents_space_type_idx": {
1441
+ "name": "published_contents_space_type_idx",
1442
+ "columns": [
1443
+ {
1444
+ "expression": "space_id",
1445
+ "isExpression": false,
1446
+ "asc": true,
1447
+ "nulls": "last"
1448
+ },
1449
+ {
1450
+ "expression": "type_id",
1451
+ "isExpression": false,
1452
+ "asc": true,
1453
+ "nulls": "last"
1454
+ }
1455
+ ],
1456
+ "isUnique": false,
1457
+ "concurrently": false,
1458
+ "method": "btree",
1459
+ "with": {}
1460
+ },
1461
+ "published_contents_fields_gin_idx": {
1462
+ "name": "published_contents_fields_gin_idx",
1463
+ "columns": [
1464
+ {
1465
+ "expression": "\"fields\" jsonb_path_ops",
1466
+ "asc": true,
1467
+ "isExpression": true,
1468
+ "nulls": "last"
1469
+ }
1470
+ ],
1471
+ "isUnique": false,
1472
+ "concurrently": false,
1473
+ "method": "gin",
1474
+ "with": {}
1475
+ },
1476
+ "published_contents_search_gin_idx": {
1477
+ "name": "published_contents_search_gin_idx",
1478
+ "columns": [
1479
+ {
1480
+ "expression": "search",
1481
+ "isExpression": false,
1482
+ "asc": true,
1483
+ "nulls": "last"
1484
+ }
1485
+ ],
1486
+ "isUnique": false,
1487
+ "concurrently": false,
1488
+ "method": "gin",
1489
+ "with": {}
1490
+ },
1491
+ "published_contents_permalink_key": {
1492
+ "name": "published_contents_permalink_key",
1493
+ "columns": [
1494
+ {
1495
+ "expression": "space_id",
1496
+ "isExpression": false,
1497
+ "asc": true,
1498
+ "nulls": "last"
1499
+ },
1500
+ {
1501
+ "expression": "locale",
1502
+ "isExpression": false,
1503
+ "asc": true,
1504
+ "nulls": "last"
1505
+ },
1506
+ {
1507
+ "expression": "permalink",
1508
+ "isExpression": false,
1509
+ "asc": true,
1510
+ "nulls": "last"
1511
+ }
1512
+ ],
1513
+ "isUnique": true,
1514
+ "where": "permalink is not null",
1515
+ "concurrently": false,
1516
+ "method": "btree",
1517
+ "with": {}
1518
+ }
1519
+ },
1520
+ "foreignKeys": {
1521
+ "published_contents_space_id_spaces_id_fk": {
1522
+ "name": "published_contents_space_id_spaces_id_fk",
1523
+ "tableFrom": "published_contents",
1524
+ "tableTo": "spaces",
1525
+ "columnsFrom": ["space_id"],
1526
+ "columnsTo": ["id"],
1527
+ "onDelete": "cascade",
1528
+ "onUpdate": "no action"
1529
+ }
1530
+ },
1531
+ "compositePrimaryKeys": {},
1532
+ "uniqueConstraints": {},
1533
+ "policies": {},
1534
+ "checkConstraints": {},
1535
+ "isRLSEnabled": false
1536
+ },
1537
+ "public.sessions": {
1538
+ "name": "sessions",
1539
+ "schema": "",
1540
+ "columns": {
1541
+ "id": {
1542
+ "name": "id",
1543
+ "type": "uuid",
1544
+ "primaryKey": true,
1545
+ "notNull": true,
1546
+ "default": "gen_random_uuid()"
1547
+ },
1548
+ "user_id": {
1549
+ "name": "user_id",
1550
+ "type": "uuid",
1551
+ "primaryKey": false,
1552
+ "notNull": true
1553
+ },
1554
+ "token": {
1555
+ "name": "token",
1556
+ "type": "text",
1557
+ "primaryKey": false,
1558
+ "notNull": true
1559
+ },
1560
+ "expires_at": {
1561
+ "name": "expires_at",
1562
+ "type": "timestamp with time zone",
1563
+ "primaryKey": false,
1564
+ "notNull": true
1565
+ },
1566
+ "ip_address": {
1567
+ "name": "ip_address",
1568
+ "type": "text",
1569
+ "primaryKey": false,
1570
+ "notNull": false
1571
+ },
1572
+ "user_agent": {
1573
+ "name": "user_agent",
1574
+ "type": "text",
1575
+ "primaryKey": false,
1576
+ "notNull": false
1577
+ },
1578
+ "created_at": {
1579
+ "name": "created_at",
1580
+ "type": "timestamp with time zone",
1581
+ "primaryKey": false,
1582
+ "notNull": true,
1583
+ "default": "now()"
1584
+ },
1585
+ "updated_at": {
1586
+ "name": "updated_at",
1587
+ "type": "timestamp with time zone",
1588
+ "primaryKey": false,
1589
+ "notNull": true,
1590
+ "default": "now()"
1591
+ }
1592
+ },
1593
+ "indexes": {
1594
+ "sessions_token_key": {
1595
+ "name": "sessions_token_key",
1596
+ "columns": [
1597
+ {
1598
+ "expression": "token",
1599
+ "isExpression": false,
1600
+ "asc": true,
1601
+ "nulls": "last"
1602
+ }
1603
+ ],
1604
+ "isUnique": true,
1605
+ "concurrently": false,
1606
+ "method": "btree",
1607
+ "with": {}
1608
+ },
1609
+ "sessions_user_idx": {
1610
+ "name": "sessions_user_idx",
1611
+ "columns": [
1612
+ {
1613
+ "expression": "user_id",
1614
+ "isExpression": false,
1615
+ "asc": true,
1616
+ "nulls": "last"
1617
+ }
1618
+ ],
1619
+ "isUnique": false,
1620
+ "concurrently": false,
1621
+ "method": "btree",
1622
+ "with": {}
1623
+ },
1624
+ "sessions_expires_idx": {
1625
+ "name": "sessions_expires_idx",
1626
+ "columns": [
1627
+ {
1628
+ "expression": "expires_at",
1629
+ "isExpression": false,
1630
+ "asc": true,
1631
+ "nulls": "last"
1632
+ }
1633
+ ],
1634
+ "isUnique": false,
1635
+ "concurrently": false,
1636
+ "method": "btree",
1637
+ "with": {}
1638
+ }
1639
+ },
1640
+ "foreignKeys": {
1641
+ "sessions_user_id_users_id_fk": {
1642
+ "name": "sessions_user_id_users_id_fk",
1643
+ "tableFrom": "sessions",
1644
+ "tableTo": "users",
1645
+ "columnsFrom": ["user_id"],
1646
+ "columnsTo": ["id"],
1647
+ "onDelete": "cascade",
1648
+ "onUpdate": "no action"
1649
+ }
1650
+ },
1651
+ "compositePrimaryKeys": {},
1652
+ "uniqueConstraints": {},
1653
+ "policies": {},
1654
+ "checkConstraints": {},
1655
+ "isRLSEnabled": false
1656
+ },
1657
+ "public.spaces": {
1658
+ "name": "spaces",
1659
+ "schema": "",
1660
+ "columns": {
1661
+ "id": {
1662
+ "name": "id",
1663
+ "type": "uuid",
1664
+ "primaryKey": true,
1665
+ "notNull": true,
1666
+ "default": "gen_random_uuid()"
1667
+ },
1668
+ "name": {
1669
+ "name": "name",
1670
+ "type": "text",
1671
+ "primaryKey": false,
1672
+ "notNull": true
1673
+ },
1674
+ "machine_name": {
1675
+ "name": "machine_name",
1676
+ "type": "text",
1677
+ "primaryKey": false,
1678
+ "notNull": true
1679
+ },
1680
+ "description": {
1681
+ "name": "description",
1682
+ "type": "text",
1683
+ "primaryKey": false,
1684
+ "notNull": false
1685
+ },
1686
+ "url": {
1687
+ "name": "url",
1688
+ "type": "text",
1689
+ "primaryKey": false,
1690
+ "notNull": true
1691
+ },
1692
+ "default_locale": {
1693
+ "name": "default_locale",
1694
+ "type": "text",
1695
+ "primaryKey": false,
1696
+ "notNull": true,
1697
+ "default": "'en'"
1698
+ },
1699
+ "locales": {
1700
+ "name": "locales",
1701
+ "type": "jsonb",
1702
+ "primaryKey": false,
1703
+ "notNull": true,
1704
+ "default": "'[\"en\"]'::jsonb"
1705
+ },
1706
+ "settings": {
1707
+ "name": "settings",
1708
+ "type": "jsonb",
1709
+ "primaryKey": false,
1710
+ "notNull": true,
1711
+ "default": "'{}'::jsonb"
1712
+ },
1713
+ "created_at": {
1714
+ "name": "created_at",
1715
+ "type": "timestamp with time zone",
1716
+ "primaryKey": false,
1717
+ "notNull": true,
1718
+ "default": "now()"
1719
+ },
1720
+ "updated_at": {
1721
+ "name": "updated_at",
1722
+ "type": "timestamp with time zone",
1723
+ "primaryKey": false,
1724
+ "notNull": true,
1725
+ "default": "now()"
1726
+ }
1727
+ },
1728
+ "indexes": {
1729
+ "spaces_machine_name_key": {
1730
+ "name": "spaces_machine_name_key",
1731
+ "columns": [
1732
+ {
1733
+ "expression": "machine_name",
1734
+ "isExpression": false,
1735
+ "asc": true,
1736
+ "nulls": "last"
1737
+ }
1738
+ ],
1739
+ "isUnique": true,
1740
+ "concurrently": false,
1741
+ "method": "btree",
1742
+ "with": {}
1743
+ }
1744
+ },
1745
+ "foreignKeys": {},
1746
+ "compositePrimaryKeys": {},
1747
+ "uniqueConstraints": {},
1748
+ "policies": {},
1749
+ "checkConstraints": {},
1750
+ "isRLSEnabled": false
1751
+ },
1752
+ "public.users": {
1753
+ "name": "users",
1754
+ "schema": "",
1755
+ "columns": {
1756
+ "id": {
1757
+ "name": "id",
1758
+ "type": "uuid",
1759
+ "primaryKey": true,
1760
+ "notNull": true,
1761
+ "default": "gen_random_uuid()"
1762
+ },
1763
+ "name": {
1764
+ "name": "name",
1765
+ "type": "text",
1766
+ "primaryKey": false,
1767
+ "notNull": true,
1768
+ "default": "''"
1769
+ },
1770
+ "email": {
1771
+ "name": "email",
1772
+ "type": "text",
1773
+ "primaryKey": false,
1774
+ "notNull": true
1775
+ },
1776
+ "email_verified": {
1777
+ "name": "email_verified",
1778
+ "type": "boolean",
1779
+ "primaryKey": false,
1780
+ "notNull": true,
1781
+ "default": false
1782
+ },
1783
+ "image": {
1784
+ "name": "image",
1785
+ "type": "text",
1786
+ "primaryKey": false,
1787
+ "notNull": false
1788
+ },
1789
+ "role": {
1790
+ "name": "role",
1791
+ "type": "text",
1792
+ "primaryKey": false,
1793
+ "notNull": true,
1794
+ "default": "'editor'"
1795
+ },
1796
+ "banned": {
1797
+ "name": "banned",
1798
+ "type": "boolean",
1799
+ "primaryKey": false,
1800
+ "notNull": true,
1801
+ "default": false
1802
+ },
1803
+ "ban_reason": {
1804
+ "name": "ban_reason",
1805
+ "type": "text",
1806
+ "primaryKey": false,
1807
+ "notNull": false
1808
+ },
1809
+ "created_at": {
1810
+ "name": "created_at",
1811
+ "type": "timestamp with time zone",
1812
+ "primaryKey": false,
1813
+ "notNull": true,
1814
+ "default": "now()"
1815
+ },
1816
+ "updated_at": {
1817
+ "name": "updated_at",
1818
+ "type": "timestamp with time zone",
1819
+ "primaryKey": false,
1820
+ "notNull": true,
1821
+ "default": "now()"
1822
+ }
1823
+ },
1824
+ "indexes": {
1825
+ "users_email_key": {
1826
+ "name": "users_email_key",
1827
+ "columns": [
1828
+ {
1829
+ "expression": "email",
1830
+ "isExpression": false,
1831
+ "asc": true,
1832
+ "nulls": "last"
1833
+ }
1834
+ ],
1835
+ "isUnique": true,
1836
+ "concurrently": false,
1837
+ "method": "btree",
1838
+ "with": {}
1839
+ }
1840
+ },
1841
+ "foreignKeys": {},
1842
+ "compositePrimaryKeys": {},
1843
+ "uniqueConstraints": {},
1844
+ "policies": {},
1845
+ "checkConstraints": {},
1846
+ "isRLSEnabled": false
1847
+ },
1848
+ "public.verifications": {
1849
+ "name": "verifications",
1850
+ "schema": "",
1851
+ "columns": {
1852
+ "id": {
1853
+ "name": "id",
1854
+ "type": "uuid",
1855
+ "primaryKey": true,
1856
+ "notNull": true,
1857
+ "default": "gen_random_uuid()"
1858
+ },
1859
+ "identifier": {
1860
+ "name": "identifier",
1861
+ "type": "text",
1862
+ "primaryKey": false,
1863
+ "notNull": true
1864
+ },
1865
+ "value": {
1866
+ "name": "value",
1867
+ "type": "text",
1868
+ "primaryKey": false,
1869
+ "notNull": true
1870
+ },
1871
+ "expires_at": {
1872
+ "name": "expires_at",
1873
+ "type": "timestamp with time zone",
1874
+ "primaryKey": false,
1875
+ "notNull": true
1876
+ },
1877
+ "created_at": {
1878
+ "name": "created_at",
1879
+ "type": "timestamp with time zone",
1880
+ "primaryKey": false,
1881
+ "notNull": true,
1882
+ "default": "now()"
1883
+ },
1884
+ "updated_at": {
1885
+ "name": "updated_at",
1886
+ "type": "timestamp with time zone",
1887
+ "primaryKey": false,
1888
+ "notNull": true,
1889
+ "default": "now()"
1890
+ }
1891
+ },
1892
+ "indexes": {
1893
+ "verifications_identifier_idx": {
1894
+ "name": "verifications_identifier_idx",
1895
+ "columns": [
1896
+ {
1897
+ "expression": "identifier",
1898
+ "isExpression": false,
1899
+ "asc": true,
1900
+ "nulls": "last"
1901
+ }
1902
+ ],
1903
+ "isUnique": false,
1904
+ "concurrently": false,
1905
+ "method": "btree",
1906
+ "with": {}
1907
+ }
1908
+ },
1909
+ "foreignKeys": {},
1910
+ "compositePrimaryKeys": {},
1911
+ "uniqueConstraints": {},
1912
+ "policies": {},
1913
+ "checkConstraints": {},
1914
+ "isRLSEnabled": false
1915
+ },
1916
+ "public.webhook_deliveries": {
1917
+ "name": "webhook_deliveries",
1918
+ "schema": "",
1919
+ "columns": {
1920
+ "id": {
1921
+ "name": "id",
1922
+ "type": "uuid",
1923
+ "primaryKey": true,
1924
+ "notNull": true,
1925
+ "default": "gen_random_uuid()"
1926
+ },
1927
+ "webhook_id": {
1928
+ "name": "webhook_id",
1929
+ "type": "uuid",
1930
+ "primaryKey": false,
1931
+ "notNull": true
1932
+ },
1933
+ "event": {
1934
+ "name": "event",
1935
+ "type": "text",
1936
+ "primaryKey": false,
1937
+ "notNull": true
1938
+ },
1939
+ "payload": {
1940
+ "name": "payload",
1941
+ "type": "jsonb",
1942
+ "primaryKey": false,
1943
+ "notNull": true
1944
+ },
1945
+ "status": {
1946
+ "name": "status",
1947
+ "type": "integer",
1948
+ "primaryKey": false,
1949
+ "notNull": false
1950
+ },
1951
+ "error": {
1952
+ "name": "error",
1953
+ "type": "text",
1954
+ "primaryKey": false,
1955
+ "notNull": false
1956
+ },
1957
+ "attempt": {
1958
+ "name": "attempt",
1959
+ "type": "integer",
1960
+ "primaryKey": false,
1961
+ "notNull": true,
1962
+ "default": 1
1963
+ },
1964
+ "created_at": {
1965
+ "name": "created_at",
1966
+ "type": "timestamp with time zone",
1967
+ "primaryKey": false,
1968
+ "notNull": true,
1969
+ "default": "now()"
1970
+ }
1971
+ },
1972
+ "indexes": {
1973
+ "webhook_deliveries_webhook_idx": {
1974
+ "name": "webhook_deliveries_webhook_idx",
1975
+ "columns": [
1976
+ {
1977
+ "expression": "webhook_id",
1978
+ "isExpression": false,
1979
+ "asc": true,
1980
+ "nulls": "last"
1981
+ },
1982
+ {
1983
+ "expression": "created_at",
1984
+ "isExpression": false,
1985
+ "asc": true,
1986
+ "nulls": "last"
1987
+ }
1988
+ ],
1989
+ "isUnique": false,
1990
+ "concurrently": false,
1991
+ "method": "btree",
1992
+ "with": {}
1993
+ }
1994
+ },
1995
+ "foreignKeys": {
1996
+ "webhook_deliveries_webhook_id_webhooks_id_fk": {
1997
+ "name": "webhook_deliveries_webhook_id_webhooks_id_fk",
1998
+ "tableFrom": "webhook_deliveries",
1999
+ "tableTo": "webhooks",
2000
+ "columnsFrom": ["webhook_id"],
2001
+ "columnsTo": ["id"],
2002
+ "onDelete": "cascade",
2003
+ "onUpdate": "no action"
2004
+ }
2005
+ },
2006
+ "compositePrimaryKeys": {},
2007
+ "uniqueConstraints": {},
2008
+ "policies": {},
2009
+ "checkConstraints": {},
2010
+ "isRLSEnabled": false
2011
+ },
2012
+ "public.webhooks": {
2013
+ "name": "webhooks",
2014
+ "schema": "",
2015
+ "columns": {
2016
+ "id": {
2017
+ "name": "id",
2018
+ "type": "uuid",
2019
+ "primaryKey": true,
2020
+ "notNull": true,
2021
+ "default": "gen_random_uuid()"
2022
+ },
2023
+ "space_id": {
2024
+ "name": "space_id",
2025
+ "type": "uuid",
2026
+ "primaryKey": false,
2027
+ "notNull": true
2028
+ },
2029
+ "name": {
2030
+ "name": "name",
2031
+ "type": "text",
2032
+ "primaryKey": false,
2033
+ "notNull": true
2034
+ },
2035
+ "url": {
2036
+ "name": "url",
2037
+ "type": "text",
2038
+ "primaryKey": false,
2039
+ "notNull": true
2040
+ },
2041
+ "secret": {
2042
+ "name": "secret",
2043
+ "type": "text",
2044
+ "primaryKey": false,
2045
+ "notNull": false
2046
+ },
2047
+ "events": {
2048
+ "name": "events",
2049
+ "type": "jsonb",
2050
+ "primaryKey": false,
2051
+ "notNull": true,
2052
+ "default": "'[]'::jsonb"
2053
+ },
2054
+ "enabled": {
2055
+ "name": "enabled",
2056
+ "type": "boolean",
2057
+ "primaryKey": false,
2058
+ "notNull": true,
2059
+ "default": true
2060
+ },
2061
+ "created_at": {
2062
+ "name": "created_at",
2063
+ "type": "timestamp with time zone",
2064
+ "primaryKey": false,
2065
+ "notNull": true,
2066
+ "default": "now()"
2067
+ }
2068
+ },
2069
+ "indexes": {
2070
+ "webhooks_space_idx": {
2071
+ "name": "webhooks_space_idx",
2072
+ "columns": [
2073
+ {
2074
+ "expression": "space_id",
2075
+ "isExpression": false,
2076
+ "asc": true,
2077
+ "nulls": "last"
2078
+ }
2079
+ ],
2080
+ "isUnique": false,
2081
+ "concurrently": false,
2082
+ "method": "btree",
2083
+ "with": {}
2084
+ }
2085
+ },
2086
+ "foreignKeys": {
2087
+ "webhooks_space_id_spaces_id_fk": {
2088
+ "name": "webhooks_space_id_spaces_id_fk",
2089
+ "tableFrom": "webhooks",
2090
+ "tableTo": "spaces",
2091
+ "columnsFrom": ["space_id"],
2092
+ "columnsTo": ["id"],
2093
+ "onDelete": "cascade",
2094
+ "onUpdate": "no action"
2095
+ }
2096
+ },
2097
+ "compositePrimaryKeys": {},
2098
+ "uniqueConstraints": {},
2099
+ "policies": {},
2100
+ "checkConstraints": {},
2101
+ "isRLSEnabled": false
2102
+ }
2103
+ },
2104
+ "enums": {},
2105
+ "schemas": {},
2106
+ "sequences": {},
2107
+ "roles": {},
2108
+ "policies": {},
2109
+ "views": {},
2110
+ "_meta": {
2111
+ "columns": {},
2112
+ "schemas": {},
2113
+ "tables": {}
2114
+ }
2115
+ }