@wraps.dev/cli 2.21.6 → 2.21.11

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 (123) hide show
  1. package/dist/api-lambda.zip +0 -0
  2. package/dist/cli.js +40 -59
  3. package/dist/cli.js.map +1 -1
  4. package/dist/lambda/event-processor/.bundled +1 -1
  5. package/dist/lambda/inbound-processor/.bundled +1 -1
  6. package/dist/lambda/sms-event-processor/.bundled +1 -1
  7. package/dist/selfhost-migrations/0000_absent_rogue.sql +203 -0
  8. package/dist/selfhost-migrations/0001_polite_maverick.sql +17 -0
  9. package/dist/selfhost-migrations/0002_perpetual_scorpion.sql +1 -0
  10. package/dist/selfhost-migrations/0003_wealthy_absorbing_man.sql +1 -0
  11. package/dist/selfhost-migrations/0004_opposite_blur.sql +1 -0
  12. package/dist/selfhost-migrations/0005_clear_terror.sql +4 -0
  13. package/dist/selfhost-migrations/0006_soft_black_widow.sql +20 -0
  14. package/dist/selfhost-migrations/0007_dazzling_saracen.sql +124 -0
  15. package/dist/selfhost-migrations/0008_broad_hannibal_king.sql +33 -0
  16. package/dist/selfhost-migrations/0009_bouncy_mystique.sql +73 -0
  17. package/dist/selfhost-migrations/0010_cheerful_valeria_richards.sql +18 -0
  18. package/dist/selfhost-migrations/0011_absent_thunderbolts.sql +2 -0
  19. package/dist/selfhost-migrations/0012_demonic_donald_blake.sql +1 -0
  20. package/dist/selfhost-migrations/0013_nifty_preak.sql +143 -0
  21. package/dist/selfhost-migrations/0014_hesitant_beast.sql +2 -0
  22. package/dist/selfhost-migrations/0015_blue_giant_girl.sql +1 -0
  23. package/dist/selfhost-migrations/0016_cooing_overlord.sql +1 -0
  24. package/dist/selfhost-migrations/0017_tranquil_ender_wiggin.sql +11 -0
  25. package/dist/selfhost-migrations/0018_talented_groot.sql +8 -0
  26. package/dist/selfhost-migrations/0019_ambitious_devos.sql +3 -0
  27. package/dist/selfhost-migrations/0020_misty_master_mold.sql +95 -0
  28. package/dist/selfhost-migrations/0021_regular_harrier.sql +14 -0
  29. package/dist/selfhost-migrations/0022_sour_blizzard.sql +10 -0
  30. package/dist/selfhost-migrations/0023_flawless_psynapse.sql +1 -0
  31. package/dist/selfhost-migrations/0024_premium_blindfold.sql +1 -0
  32. package/dist/selfhost-migrations/0025_unusual_santa_claus.sql +1 -0
  33. package/dist/selfhost-migrations/0026_volatile_pandemic.sql +2 -0
  34. package/dist/selfhost-migrations/0027_workable_logan.sql +4 -0
  35. package/dist/selfhost-migrations/0028_familiar_prodigy.sql +1 -0
  36. package/dist/selfhost-migrations/0029_cute_maddog.sql +13 -0
  37. package/dist/selfhost-migrations/0030_adorable_scarecrow.sql +1 -0
  38. package/dist/selfhost-migrations/0031_material_slapstick.sql +10 -0
  39. package/dist/selfhost-migrations/0032_hot_dust.sql +11 -0
  40. package/dist/selfhost-migrations/0033_slow_deathbird.sql +1 -0
  41. package/dist/selfhost-migrations/0034_lush_rafael_vega.sql +12 -0
  42. package/dist/selfhost-migrations/0035_normal_red_hulk.sql +8 -0
  43. package/dist/selfhost-migrations/0036_marvelous_ezekiel.sql +1 -0
  44. package/dist/selfhost-migrations/0037_swift_talisman.sql +8 -0
  45. package/dist/selfhost-migrations/0038_first_mandroid.sql +1 -0
  46. package/dist/selfhost-migrations/0039_fixed_stryfe.sql +1 -0
  47. package/dist/selfhost-migrations/0040_add_channel_check_constraints.sql +2 -0
  48. package/dist/selfhost-migrations/0041_black_spencer_smythe.sql +1 -0
  49. package/dist/selfhost-migrations/0042_plain_marvel_zombies.sql +2 -0
  50. package/dist/selfhost-migrations/0043_curved_champions.sql +1 -0
  51. package/dist/selfhost-migrations/0044_clean_iceman.sql +1 -0
  52. package/dist/selfhost-migrations/0045_condemned_steel_serpent.sql +1 -0
  53. package/dist/selfhost-migrations/0046_steep_ultimo.sql +2 -0
  54. package/dist/selfhost-migrations/0047_empty_sleepwalker.sql +2 -0
  55. package/dist/selfhost-migrations/0048_cheerful_multiple_man.sql +1 -0
  56. package/dist/selfhost-migrations/0049_nostalgic_loki.sql +3 -0
  57. package/dist/selfhost-migrations/0050_add_engagement_metadata.sql +4 -0
  58. package/dist/selfhost-migrations/0051_odd_marrow.sql +2 -0
  59. package/dist/selfhost-migrations/0052_redundant_siren.sql +5 -0
  60. package/dist/selfhost-migrations/0053_soft_carnage.sql +31 -0
  61. package/dist/selfhost-migrations/0054_blushing_vin_gonzales.sql +1 -0
  62. package/dist/selfhost-migrations/0055_broadcast_resume_columns.sql +12 -0
  63. package/dist/selfhost-migrations/0056_broadcast_resume_dedup_cleanup.sql +31 -0
  64. package/dist/selfhost-migrations/0057_audit_log_actoremail_jsonb.sql +5 -0
  65. package/dist/selfhost-migrations/meta/0000_snapshot.json +1311 -0
  66. package/dist/selfhost-migrations/meta/0001_snapshot.json +1454 -0
  67. package/dist/selfhost-migrations/meta/0002_snapshot.json +1460 -0
  68. package/dist/selfhost-migrations/meta/0003_snapshot.json +1467 -0
  69. package/dist/selfhost-migrations/meta/0004_snapshot.json +1473 -0
  70. package/dist/selfhost-migrations/meta/0005_snapshot.json +1499 -0
  71. package/dist/selfhost-migrations/meta/0006_snapshot.json +1617 -0
  72. package/dist/selfhost-migrations/meta/0007_snapshot.json +2581 -0
  73. package/dist/selfhost-migrations/meta/0008_snapshot.json +2861 -0
  74. package/dist/selfhost-migrations/meta/0009_snapshot.json +3447 -0
  75. package/dist/selfhost-migrations/meta/0010_snapshot.json +3586 -0
  76. package/dist/selfhost-migrations/meta/0011_snapshot.json +3600 -0
  77. package/dist/selfhost-migrations/meta/0012_snapshot.json +3607 -0
  78. package/dist/selfhost-migrations/meta/0013_snapshot.json +4697 -0
  79. package/dist/selfhost-migrations/meta/0014_snapshot.json +4704 -0
  80. package/dist/selfhost-migrations/meta/0015_snapshot.json +4697 -0
  81. package/dist/selfhost-migrations/meta/0016_snapshot.json +4703 -0
  82. package/dist/selfhost-migrations/meta/0017_snapshot.json +4769 -0
  83. package/dist/selfhost-migrations/meta/0018_snapshot.json +4821 -0
  84. package/dist/selfhost-migrations/meta/0019_snapshot.json +4840 -0
  85. package/dist/selfhost-migrations/meta/0020_snapshot.json +5602 -0
  86. package/dist/selfhost-migrations/meta/0021_snapshot.json +5729 -0
  87. package/dist/selfhost-migrations/meta/0022_snapshot.json +5792 -0
  88. package/dist/selfhost-migrations/meta/0023_snapshot.json +5799 -0
  89. package/dist/selfhost-migrations/meta/0024_snapshot.json +5821 -0
  90. package/dist/selfhost-migrations/meta/0025_snapshot.json +5831 -0
  91. package/dist/selfhost-migrations/meta/0026_snapshot.json +5844 -0
  92. package/dist/selfhost-migrations/meta/0027_snapshot.json +5864 -0
  93. package/dist/selfhost-migrations/meta/0028_snapshot.json +5871 -0
  94. package/dist/selfhost-migrations/meta/0029_snapshot.json +5984 -0
  95. package/dist/selfhost-migrations/meta/0030_snapshot.json +5990 -0
  96. package/dist/selfhost-migrations/meta/0031_snapshot.json +5950 -0
  97. package/dist/selfhost-migrations/meta/0032_snapshot.json +6042 -0
  98. package/dist/selfhost-migrations/meta/0033_snapshot.json +6057 -0
  99. package/dist/selfhost-migrations/meta/0034_snapshot.json +6130 -0
  100. package/dist/selfhost-migrations/meta/0035_snapshot.json +6195 -0
  101. package/dist/selfhost-migrations/meta/0036_snapshot.json +6201 -0
  102. package/dist/selfhost-migrations/meta/0037_snapshot.json +6265 -0
  103. package/dist/selfhost-migrations/meta/0038_snapshot.json +6271 -0
  104. package/dist/selfhost-migrations/meta/0039_snapshot.json +6278 -0
  105. package/dist/selfhost-migrations/meta/0041_snapshot.json +6284 -0
  106. package/dist/selfhost-migrations/meta/0042_snapshot.json +6297 -0
  107. package/dist/selfhost-migrations/meta/0043_snapshot.json +6297 -0
  108. package/dist/selfhost-migrations/meta/0044_snapshot.json +6297 -0
  109. package/dist/selfhost-migrations/meta/0045_snapshot.json +6303 -0
  110. package/dist/selfhost-migrations/meta/0046_snapshot.json +6315 -0
  111. package/dist/selfhost-migrations/meta/0047_snapshot.json +6330 -0
  112. package/dist/selfhost-migrations/meta/0048_snapshot.json +6336 -0
  113. package/dist/selfhost-migrations/meta/0049_snapshot.json +6366 -0
  114. package/dist/selfhost-migrations/meta/0050_snapshot.json +6390 -0
  115. package/dist/selfhost-migrations/meta/0051_snapshot.json +6403 -0
  116. package/dist/selfhost-migrations/meta/0052_snapshot.json +6470 -0
  117. package/dist/selfhost-migrations/meta/0053_snapshot.json +6470 -0
  118. package/dist/selfhost-migrations/meta/0054_snapshot.json +6646 -0
  119. package/dist/selfhost-migrations/meta/0055_snapshot.json +6677 -0
  120. package/dist/selfhost-migrations/meta/0056_snapshot.json +6677 -0
  121. package/dist/selfhost-migrations/meta/0057_snapshot.json +6674 -0
  122. package/dist/selfhost-migrations/meta/_journal.json +412 -0
  123. package/package.json +7 -4
@@ -0,0 +1,1617 @@
1
+ {
2
+ "id": "a366216e-d26e-46c8-859b-5944f85f9961",
3
+ "prevId": "ed4ed76d-af05-4119-a3f2-8f7c2cee0784",
4
+ "version": "7",
5
+ "dialect": "postgresql",
6
+ "tables": {
7
+ "public.api_key": {
8
+ "name": "api_key",
9
+ "schema": "",
10
+ "columns": {
11
+ "id": {
12
+ "name": "id",
13
+ "type": "text",
14
+ "primaryKey": true,
15
+ "notNull": true
16
+ },
17
+ "organization_id": {
18
+ "name": "organization_id",
19
+ "type": "text",
20
+ "primaryKey": false,
21
+ "notNull": true
22
+ },
23
+ "name": {
24
+ "name": "name",
25
+ "type": "text",
26
+ "primaryKey": false,
27
+ "notNull": true
28
+ },
29
+ "key_hash": {
30
+ "name": "key_hash",
31
+ "type": "text",
32
+ "primaryKey": false,
33
+ "notNull": true
34
+ },
35
+ "prefix": {
36
+ "name": "prefix",
37
+ "type": "text",
38
+ "primaryKey": false,
39
+ "notNull": true
40
+ },
41
+ "permissions": {
42
+ "name": "permissions",
43
+ "type": "json",
44
+ "primaryKey": false,
45
+ "notNull": false,
46
+ "default": "'[]'::json"
47
+ },
48
+ "last_used_at": {
49
+ "name": "last_used_at",
50
+ "type": "timestamp",
51
+ "primaryKey": false,
52
+ "notNull": false
53
+ },
54
+ "expires_at": {
55
+ "name": "expires_at",
56
+ "type": "timestamp",
57
+ "primaryKey": false,
58
+ "notNull": false
59
+ },
60
+ "created_by": {
61
+ "name": "created_by",
62
+ "type": "text",
63
+ "primaryKey": false,
64
+ "notNull": false
65
+ },
66
+ "created_at": {
67
+ "name": "created_at",
68
+ "type": "timestamp",
69
+ "primaryKey": false,
70
+ "notNull": true,
71
+ "default": "now()"
72
+ }
73
+ },
74
+ "indexes": {
75
+ "api_key_org_idx": {
76
+ "name": "api_key_org_idx",
77
+ "columns": [
78
+ {
79
+ "expression": "organization_id",
80
+ "isExpression": false,
81
+ "asc": true,
82
+ "nulls": "last"
83
+ }
84
+ ],
85
+ "isUnique": false,
86
+ "concurrently": false,
87
+ "method": "btree",
88
+ "with": {}
89
+ },
90
+ "api_key_prefix_idx": {
91
+ "name": "api_key_prefix_idx",
92
+ "columns": [
93
+ {
94
+ "expression": "prefix",
95
+ "isExpression": false,
96
+ "asc": true,
97
+ "nulls": "last"
98
+ }
99
+ ],
100
+ "isUnique": false,
101
+ "concurrently": false,
102
+ "method": "btree",
103
+ "with": {}
104
+ }
105
+ },
106
+ "foreignKeys": {
107
+ "api_key_organization_id_organization_id_fk": {
108
+ "name": "api_key_organization_id_organization_id_fk",
109
+ "tableFrom": "api_key",
110
+ "tableTo": "organization",
111
+ "columnsFrom": ["organization_id"],
112
+ "columnsTo": ["id"],
113
+ "onDelete": "cascade",
114
+ "onUpdate": "no action"
115
+ },
116
+ "api_key_created_by_user_id_fk": {
117
+ "name": "api_key_created_by_user_id_fk",
118
+ "tableFrom": "api_key",
119
+ "tableTo": "user",
120
+ "columnsFrom": ["created_by"],
121
+ "columnsTo": ["id"],
122
+ "onDelete": "no action",
123
+ "onUpdate": "no action"
124
+ }
125
+ },
126
+ "compositePrimaryKeys": {},
127
+ "uniqueConstraints": {},
128
+ "policies": {},
129
+ "checkConstraints": {},
130
+ "isRLSEnabled": false
131
+ },
132
+ "public.audit_log": {
133
+ "name": "audit_log",
134
+ "schema": "",
135
+ "columns": {
136
+ "id": {
137
+ "name": "id",
138
+ "type": "text",
139
+ "primaryKey": true,
140
+ "notNull": true
141
+ },
142
+ "organization_id": {
143
+ "name": "organization_id",
144
+ "type": "text",
145
+ "primaryKey": false,
146
+ "notNull": true
147
+ },
148
+ "user_id": {
149
+ "name": "user_id",
150
+ "type": "text",
151
+ "primaryKey": false,
152
+ "notNull": false
153
+ },
154
+ "action": {
155
+ "name": "action",
156
+ "type": "text",
157
+ "primaryKey": false,
158
+ "notNull": true
159
+ },
160
+ "resource": {
161
+ "name": "resource",
162
+ "type": "text",
163
+ "primaryKey": false,
164
+ "notNull": true
165
+ },
166
+ "resource_id": {
167
+ "name": "resource_id",
168
+ "type": "text",
169
+ "primaryKey": false,
170
+ "notNull": false
171
+ },
172
+ "metadata": {
173
+ "name": "metadata",
174
+ "type": "json",
175
+ "primaryKey": false,
176
+ "notNull": false
177
+ },
178
+ "ip_address": {
179
+ "name": "ip_address",
180
+ "type": "text",
181
+ "primaryKey": false,
182
+ "notNull": false
183
+ },
184
+ "user_agent": {
185
+ "name": "user_agent",
186
+ "type": "text",
187
+ "primaryKey": false,
188
+ "notNull": false
189
+ },
190
+ "created_at": {
191
+ "name": "created_at",
192
+ "type": "timestamp",
193
+ "primaryKey": false,
194
+ "notNull": true,
195
+ "default": "now()"
196
+ }
197
+ },
198
+ "indexes": {
199
+ "audit_log_org_idx": {
200
+ "name": "audit_log_org_idx",
201
+ "columns": [
202
+ {
203
+ "expression": "organization_id",
204
+ "isExpression": false,
205
+ "asc": true,
206
+ "nulls": "last"
207
+ }
208
+ ],
209
+ "isUnique": false,
210
+ "concurrently": false,
211
+ "method": "btree",
212
+ "with": {}
213
+ },
214
+ "audit_log_timestamp_idx": {
215
+ "name": "audit_log_timestamp_idx",
216
+ "columns": [
217
+ {
218
+ "expression": "created_at",
219
+ "isExpression": false,
220
+ "asc": true,
221
+ "nulls": "last"
222
+ }
223
+ ],
224
+ "isUnique": false,
225
+ "concurrently": false,
226
+ "method": "btree",
227
+ "with": {}
228
+ }
229
+ },
230
+ "foreignKeys": {
231
+ "audit_log_organization_id_organization_id_fk": {
232
+ "name": "audit_log_organization_id_organization_id_fk",
233
+ "tableFrom": "audit_log",
234
+ "tableTo": "organization",
235
+ "columnsFrom": ["organization_id"],
236
+ "columnsTo": ["id"],
237
+ "onDelete": "cascade",
238
+ "onUpdate": "no action"
239
+ },
240
+ "audit_log_user_id_user_id_fk": {
241
+ "name": "audit_log_user_id_user_id_fk",
242
+ "tableFrom": "audit_log",
243
+ "tableTo": "user",
244
+ "columnsFrom": ["user_id"],
245
+ "columnsTo": ["id"],
246
+ "onDelete": "no action",
247
+ "onUpdate": "no action"
248
+ }
249
+ },
250
+ "compositePrimaryKeys": {},
251
+ "uniqueConstraints": {},
252
+ "policies": {},
253
+ "checkConstraints": {},
254
+ "isRLSEnabled": false
255
+ },
256
+ "public.aws_account": {
257
+ "name": "aws_account",
258
+ "schema": "",
259
+ "columns": {
260
+ "id": {
261
+ "name": "id",
262
+ "type": "text",
263
+ "primaryKey": true,
264
+ "notNull": true
265
+ },
266
+ "organization_id": {
267
+ "name": "organization_id",
268
+ "type": "text",
269
+ "primaryKey": false,
270
+ "notNull": true
271
+ },
272
+ "name": {
273
+ "name": "name",
274
+ "type": "text",
275
+ "primaryKey": false,
276
+ "notNull": true
277
+ },
278
+ "account_id": {
279
+ "name": "account_id",
280
+ "type": "text",
281
+ "primaryKey": false,
282
+ "notNull": true
283
+ },
284
+ "region": {
285
+ "name": "region",
286
+ "type": "text",
287
+ "primaryKey": false,
288
+ "notNull": true
289
+ },
290
+ "role_arn": {
291
+ "name": "role_arn",
292
+ "type": "text",
293
+ "primaryKey": false,
294
+ "notNull": true
295
+ },
296
+ "external_id": {
297
+ "name": "external_id",
298
+ "type": "text",
299
+ "primaryKey": false,
300
+ "notNull": true
301
+ },
302
+ "is_verified": {
303
+ "name": "is_verified",
304
+ "type": "boolean",
305
+ "primaryKey": false,
306
+ "notNull": true,
307
+ "default": false
308
+ },
309
+ "last_verified_at": {
310
+ "name": "last_verified_at",
311
+ "type": "timestamp",
312
+ "primaryKey": false,
313
+ "notNull": false
314
+ },
315
+ "archiving_enabled": {
316
+ "name": "archiving_enabled",
317
+ "type": "boolean",
318
+ "primaryKey": false,
319
+ "notNull": true,
320
+ "default": false
321
+ },
322
+ "archive_arn": {
323
+ "name": "archive_arn",
324
+ "type": "text",
325
+ "primaryKey": false,
326
+ "notNull": false
327
+ },
328
+ "event_history_enabled": {
329
+ "name": "event_history_enabled",
330
+ "type": "boolean",
331
+ "primaryKey": false,
332
+ "notNull": true,
333
+ "default": false
334
+ },
335
+ "event_tracking_enabled": {
336
+ "name": "event_tracking_enabled",
337
+ "type": "boolean",
338
+ "primaryKey": false,
339
+ "notNull": true,
340
+ "default": false
341
+ },
342
+ "config_set_name": {
343
+ "name": "config_set_name",
344
+ "type": "text",
345
+ "primaryKey": false,
346
+ "notNull": false
347
+ },
348
+ "custom_tracking_domain": {
349
+ "name": "custom_tracking_domain",
350
+ "type": "text",
351
+ "primaryKey": false,
352
+ "notNull": false
353
+ },
354
+ "created_by": {
355
+ "name": "created_by",
356
+ "type": "text",
357
+ "primaryKey": false,
358
+ "notNull": false
359
+ },
360
+ "created_at": {
361
+ "name": "created_at",
362
+ "type": "timestamp",
363
+ "primaryKey": false,
364
+ "notNull": true,
365
+ "default": "now()"
366
+ },
367
+ "updated_at": {
368
+ "name": "updated_at",
369
+ "type": "timestamp",
370
+ "primaryKey": false,
371
+ "notNull": true,
372
+ "default": "now()"
373
+ }
374
+ },
375
+ "indexes": {
376
+ "aws_account_org_idx": {
377
+ "name": "aws_account_org_idx",
378
+ "columns": [
379
+ {
380
+ "expression": "organization_id",
381
+ "isExpression": false,
382
+ "asc": true,
383
+ "nulls": "last"
384
+ }
385
+ ],
386
+ "isUnique": false,
387
+ "concurrently": false,
388
+ "method": "btree",
389
+ "with": {}
390
+ },
391
+ "aws_account_external_id_idx": {
392
+ "name": "aws_account_external_id_idx",
393
+ "columns": [
394
+ {
395
+ "expression": "external_id",
396
+ "isExpression": false,
397
+ "asc": true,
398
+ "nulls": "last"
399
+ }
400
+ ],
401
+ "isUnique": false,
402
+ "concurrently": false,
403
+ "method": "btree",
404
+ "with": {}
405
+ }
406
+ },
407
+ "foreignKeys": {
408
+ "aws_account_organization_id_organization_id_fk": {
409
+ "name": "aws_account_organization_id_organization_id_fk",
410
+ "tableFrom": "aws_account",
411
+ "tableTo": "organization",
412
+ "columnsFrom": ["organization_id"],
413
+ "columnsTo": ["id"],
414
+ "onDelete": "cascade",
415
+ "onUpdate": "no action"
416
+ },
417
+ "aws_account_created_by_user_id_fk": {
418
+ "name": "aws_account_created_by_user_id_fk",
419
+ "tableFrom": "aws_account",
420
+ "tableTo": "user",
421
+ "columnsFrom": ["created_by"],
422
+ "columnsTo": ["id"],
423
+ "onDelete": "no action",
424
+ "onUpdate": "no action"
425
+ }
426
+ },
427
+ "compositePrimaryKeys": {},
428
+ "uniqueConstraints": {
429
+ "aws_account_external_id_unique": {
430
+ "name": "aws_account_external_id_unique",
431
+ "nullsNotDistinct": false,
432
+ "columns": ["external_id"]
433
+ }
434
+ },
435
+ "policies": {},
436
+ "checkConstraints": {},
437
+ "isRLSEnabled": false
438
+ },
439
+ "public.aws_account_permission": {
440
+ "name": "aws_account_permission",
441
+ "schema": "",
442
+ "columns": {
443
+ "id": {
444
+ "name": "id",
445
+ "type": "text",
446
+ "primaryKey": true,
447
+ "notNull": true
448
+ },
449
+ "user_id": {
450
+ "name": "user_id",
451
+ "type": "text",
452
+ "primaryKey": false,
453
+ "notNull": true
454
+ },
455
+ "aws_account_id": {
456
+ "name": "aws_account_id",
457
+ "type": "text",
458
+ "primaryKey": false,
459
+ "notNull": true
460
+ },
461
+ "permissions": {
462
+ "name": "permissions",
463
+ "type": "json",
464
+ "primaryKey": false,
465
+ "notNull": true
466
+ },
467
+ "granted_by": {
468
+ "name": "granted_by",
469
+ "type": "text",
470
+ "primaryKey": false,
471
+ "notNull": true
472
+ },
473
+ "expires_at": {
474
+ "name": "expires_at",
475
+ "type": "timestamp",
476
+ "primaryKey": false,
477
+ "notNull": false
478
+ },
479
+ "created_at": {
480
+ "name": "created_at",
481
+ "type": "timestamp",
482
+ "primaryKey": false,
483
+ "notNull": true,
484
+ "default": "now()"
485
+ },
486
+ "updated_at": {
487
+ "name": "updated_at",
488
+ "type": "timestamp",
489
+ "primaryKey": false,
490
+ "notNull": true,
491
+ "default": "now()"
492
+ }
493
+ },
494
+ "indexes": {
495
+ "aws_account_permission_user_idx": {
496
+ "name": "aws_account_permission_user_idx",
497
+ "columns": [
498
+ {
499
+ "expression": "user_id",
500
+ "isExpression": false,
501
+ "asc": true,
502
+ "nulls": "last"
503
+ }
504
+ ],
505
+ "isUnique": false,
506
+ "concurrently": false,
507
+ "method": "btree",
508
+ "with": {}
509
+ },
510
+ "aws_account_permission_account_idx": {
511
+ "name": "aws_account_permission_account_idx",
512
+ "columns": [
513
+ {
514
+ "expression": "aws_account_id",
515
+ "isExpression": false,
516
+ "asc": true,
517
+ "nulls": "last"
518
+ }
519
+ ],
520
+ "isUnique": false,
521
+ "concurrently": false,
522
+ "method": "btree",
523
+ "with": {}
524
+ },
525
+ "aws_account_permission_unique_idx": {
526
+ "name": "aws_account_permission_unique_idx",
527
+ "columns": [
528
+ {
529
+ "expression": "user_id",
530
+ "isExpression": false,
531
+ "asc": true,
532
+ "nulls": "last"
533
+ },
534
+ {
535
+ "expression": "aws_account_id",
536
+ "isExpression": false,
537
+ "asc": true,
538
+ "nulls": "last"
539
+ }
540
+ ],
541
+ "isUnique": false,
542
+ "concurrently": false,
543
+ "method": "btree",
544
+ "with": {}
545
+ }
546
+ },
547
+ "foreignKeys": {
548
+ "aws_account_permission_user_id_user_id_fk": {
549
+ "name": "aws_account_permission_user_id_user_id_fk",
550
+ "tableFrom": "aws_account_permission",
551
+ "tableTo": "user",
552
+ "columnsFrom": ["user_id"],
553
+ "columnsTo": ["id"],
554
+ "onDelete": "cascade",
555
+ "onUpdate": "no action"
556
+ },
557
+ "aws_account_permission_aws_account_id_aws_account_id_fk": {
558
+ "name": "aws_account_permission_aws_account_id_aws_account_id_fk",
559
+ "tableFrom": "aws_account_permission",
560
+ "tableTo": "aws_account",
561
+ "columnsFrom": ["aws_account_id"],
562
+ "columnsTo": ["id"],
563
+ "onDelete": "cascade",
564
+ "onUpdate": "no action"
565
+ },
566
+ "aws_account_permission_granted_by_user_id_fk": {
567
+ "name": "aws_account_permission_granted_by_user_id_fk",
568
+ "tableFrom": "aws_account_permission",
569
+ "tableTo": "user",
570
+ "columnsFrom": ["granted_by"],
571
+ "columnsTo": ["id"],
572
+ "onDelete": "no action",
573
+ "onUpdate": "no action"
574
+ }
575
+ },
576
+ "compositePrimaryKeys": {},
577
+ "uniqueConstraints": {},
578
+ "policies": {},
579
+ "checkConstraints": {},
580
+ "isRLSEnabled": false
581
+ },
582
+ "public.email_template": {
583
+ "name": "email_template",
584
+ "schema": "",
585
+ "columns": {
586
+ "id": {
587
+ "name": "id",
588
+ "type": "text",
589
+ "primaryKey": true,
590
+ "notNull": true
591
+ },
592
+ "organization_id": {
593
+ "name": "organization_id",
594
+ "type": "text",
595
+ "primaryKey": false,
596
+ "notNull": true
597
+ },
598
+ "name": {
599
+ "name": "name",
600
+ "type": "text",
601
+ "primaryKey": false,
602
+ "notNull": true
603
+ },
604
+ "subject": {
605
+ "name": "subject",
606
+ "type": "text",
607
+ "primaryKey": false,
608
+ "notNull": false
609
+ },
610
+ "html": {
611
+ "name": "html",
612
+ "type": "text",
613
+ "primaryKey": false,
614
+ "notNull": false
615
+ },
616
+ "variables": {
617
+ "name": "variables",
618
+ "type": "json",
619
+ "primaryKey": false,
620
+ "notNull": false,
621
+ "default": "'[]'::json"
622
+ },
623
+ "created_by": {
624
+ "name": "created_by",
625
+ "type": "text",
626
+ "primaryKey": false,
627
+ "notNull": false
628
+ },
629
+ "created_at": {
630
+ "name": "created_at",
631
+ "type": "timestamp",
632
+ "primaryKey": false,
633
+ "notNull": true,
634
+ "default": "now()"
635
+ },
636
+ "updated_at": {
637
+ "name": "updated_at",
638
+ "type": "timestamp",
639
+ "primaryKey": false,
640
+ "notNull": true,
641
+ "default": "now()"
642
+ }
643
+ },
644
+ "indexes": {
645
+ "email_template_org_idx": {
646
+ "name": "email_template_org_idx",
647
+ "columns": [
648
+ {
649
+ "expression": "organization_id",
650
+ "isExpression": false,
651
+ "asc": true,
652
+ "nulls": "last"
653
+ }
654
+ ],
655
+ "isUnique": false,
656
+ "concurrently": false,
657
+ "method": "btree",
658
+ "with": {}
659
+ }
660
+ },
661
+ "foreignKeys": {
662
+ "email_template_organization_id_organization_id_fk": {
663
+ "name": "email_template_organization_id_organization_id_fk",
664
+ "tableFrom": "email_template",
665
+ "tableTo": "organization",
666
+ "columnsFrom": ["organization_id"],
667
+ "columnsTo": ["id"],
668
+ "onDelete": "cascade",
669
+ "onUpdate": "no action"
670
+ },
671
+ "email_template_created_by_user_id_fk": {
672
+ "name": "email_template_created_by_user_id_fk",
673
+ "tableFrom": "email_template",
674
+ "tableTo": "user",
675
+ "columnsFrom": ["created_by"],
676
+ "columnsTo": ["id"],
677
+ "onDelete": "no action",
678
+ "onUpdate": "no action"
679
+ }
680
+ },
681
+ "compositePrimaryKeys": {},
682
+ "uniqueConstraints": {},
683
+ "policies": {},
684
+ "checkConstraints": {},
685
+ "isRLSEnabled": false
686
+ },
687
+ "public.organization_extension": {
688
+ "name": "organization_extension",
689
+ "schema": "",
690
+ "columns": {
691
+ "organization_id": {
692
+ "name": "organization_id",
693
+ "type": "text",
694
+ "primaryKey": true,
695
+ "notNull": true
696
+ },
697
+ "plan": {
698
+ "name": "plan",
699
+ "type": "text",
700
+ "primaryKey": false,
701
+ "notNull": true,
702
+ "default": "'free'"
703
+ },
704
+ "stripe_customer_id": {
705
+ "name": "stripe_customer_id",
706
+ "type": "text",
707
+ "primaryKey": false,
708
+ "notNull": false
709
+ },
710
+ "stripe_subscription_id": {
711
+ "name": "stripe_subscription_id",
712
+ "type": "text",
713
+ "primaryKey": false,
714
+ "notNull": false
715
+ },
716
+ "aws_account_count": {
717
+ "name": "aws_account_count",
718
+ "type": "integer",
719
+ "primaryKey": false,
720
+ "notNull": true,
721
+ "default": 0
722
+ },
723
+ "member_count": {
724
+ "name": "member_count",
725
+ "type": "integer",
726
+ "primaryKey": false,
727
+ "notNull": true,
728
+ "default": 1
729
+ },
730
+ "onboarding_completed": {
731
+ "name": "onboarding_completed",
732
+ "type": "boolean",
733
+ "primaryKey": false,
734
+ "notNull": true,
735
+ "default": false
736
+ },
737
+ "onboarding_completed_at": {
738
+ "name": "onboarding_completed_at",
739
+ "type": "timestamp",
740
+ "primaryKey": false,
741
+ "notNull": false
742
+ },
743
+ "updated_at": {
744
+ "name": "updated_at",
745
+ "type": "timestamp",
746
+ "primaryKey": false,
747
+ "notNull": true,
748
+ "default": "now()"
749
+ }
750
+ },
751
+ "indexes": {},
752
+ "foreignKeys": {
753
+ "organization_extension_organization_id_organization_id_fk": {
754
+ "name": "organization_extension_organization_id_organization_id_fk",
755
+ "tableFrom": "organization_extension",
756
+ "tableTo": "organization",
757
+ "columnsFrom": ["organization_id"],
758
+ "columnsTo": ["id"],
759
+ "onDelete": "cascade",
760
+ "onUpdate": "no action"
761
+ }
762
+ },
763
+ "compositePrimaryKeys": {},
764
+ "uniqueConstraints": {},
765
+ "policies": {},
766
+ "checkConstraints": {},
767
+ "isRLSEnabled": false
768
+ },
769
+ "public.account": {
770
+ "name": "account",
771
+ "schema": "",
772
+ "columns": {
773
+ "id": {
774
+ "name": "id",
775
+ "type": "text",
776
+ "primaryKey": true,
777
+ "notNull": true
778
+ },
779
+ "account_id": {
780
+ "name": "account_id",
781
+ "type": "text",
782
+ "primaryKey": false,
783
+ "notNull": true
784
+ },
785
+ "provider_id": {
786
+ "name": "provider_id",
787
+ "type": "text",
788
+ "primaryKey": false,
789
+ "notNull": true
790
+ },
791
+ "user_id": {
792
+ "name": "user_id",
793
+ "type": "text",
794
+ "primaryKey": false,
795
+ "notNull": true
796
+ },
797
+ "access_token": {
798
+ "name": "access_token",
799
+ "type": "text",
800
+ "primaryKey": false,
801
+ "notNull": false
802
+ },
803
+ "refresh_token": {
804
+ "name": "refresh_token",
805
+ "type": "text",
806
+ "primaryKey": false,
807
+ "notNull": false
808
+ },
809
+ "id_token": {
810
+ "name": "id_token",
811
+ "type": "text",
812
+ "primaryKey": false,
813
+ "notNull": false
814
+ },
815
+ "access_token_expires_at": {
816
+ "name": "access_token_expires_at",
817
+ "type": "timestamp",
818
+ "primaryKey": false,
819
+ "notNull": false
820
+ },
821
+ "refresh_token_expires_at": {
822
+ "name": "refresh_token_expires_at",
823
+ "type": "timestamp",
824
+ "primaryKey": false,
825
+ "notNull": false
826
+ },
827
+ "scope": {
828
+ "name": "scope",
829
+ "type": "text",
830
+ "primaryKey": false,
831
+ "notNull": false
832
+ },
833
+ "password": {
834
+ "name": "password",
835
+ "type": "text",
836
+ "primaryKey": false,
837
+ "notNull": false
838
+ },
839
+ "created_at": {
840
+ "name": "created_at",
841
+ "type": "timestamp",
842
+ "primaryKey": false,
843
+ "notNull": true
844
+ },
845
+ "updated_at": {
846
+ "name": "updated_at",
847
+ "type": "timestamp",
848
+ "primaryKey": false,
849
+ "notNull": true
850
+ }
851
+ },
852
+ "indexes": {},
853
+ "foreignKeys": {
854
+ "account_user_id_user_id_fk": {
855
+ "name": "account_user_id_user_id_fk",
856
+ "tableFrom": "account",
857
+ "tableTo": "user",
858
+ "columnsFrom": ["user_id"],
859
+ "columnsTo": ["id"],
860
+ "onDelete": "cascade",
861
+ "onUpdate": "no action"
862
+ }
863
+ },
864
+ "compositePrimaryKeys": {},
865
+ "uniqueConstraints": {},
866
+ "policies": {},
867
+ "checkConstraints": {},
868
+ "isRLSEnabled": false
869
+ },
870
+ "public.invitation": {
871
+ "name": "invitation",
872
+ "schema": "",
873
+ "columns": {
874
+ "id": {
875
+ "name": "id",
876
+ "type": "text",
877
+ "primaryKey": true,
878
+ "notNull": true
879
+ },
880
+ "organization_id": {
881
+ "name": "organization_id",
882
+ "type": "text",
883
+ "primaryKey": false,
884
+ "notNull": true
885
+ },
886
+ "email": {
887
+ "name": "email",
888
+ "type": "text",
889
+ "primaryKey": false,
890
+ "notNull": true
891
+ },
892
+ "role": {
893
+ "name": "role",
894
+ "type": "text",
895
+ "primaryKey": false,
896
+ "notNull": false
897
+ },
898
+ "status": {
899
+ "name": "status",
900
+ "type": "text",
901
+ "primaryKey": false,
902
+ "notNull": true
903
+ },
904
+ "expires_at": {
905
+ "name": "expires_at",
906
+ "type": "timestamp",
907
+ "primaryKey": false,
908
+ "notNull": true
909
+ },
910
+ "inviter_id": {
911
+ "name": "inviter_id",
912
+ "type": "text",
913
+ "primaryKey": false,
914
+ "notNull": true
915
+ }
916
+ },
917
+ "indexes": {},
918
+ "foreignKeys": {
919
+ "invitation_organization_id_organization_id_fk": {
920
+ "name": "invitation_organization_id_organization_id_fk",
921
+ "tableFrom": "invitation",
922
+ "tableTo": "organization",
923
+ "columnsFrom": ["organization_id"],
924
+ "columnsTo": ["id"],
925
+ "onDelete": "cascade",
926
+ "onUpdate": "no action"
927
+ },
928
+ "invitation_inviter_id_user_id_fk": {
929
+ "name": "invitation_inviter_id_user_id_fk",
930
+ "tableFrom": "invitation",
931
+ "tableTo": "user",
932
+ "columnsFrom": ["inviter_id"],
933
+ "columnsTo": ["id"],
934
+ "onDelete": "cascade",
935
+ "onUpdate": "no action"
936
+ }
937
+ },
938
+ "compositePrimaryKeys": {},
939
+ "uniqueConstraints": {},
940
+ "policies": {},
941
+ "checkConstraints": {},
942
+ "isRLSEnabled": false
943
+ },
944
+ "public.member": {
945
+ "name": "member",
946
+ "schema": "",
947
+ "columns": {
948
+ "id": {
949
+ "name": "id",
950
+ "type": "text",
951
+ "primaryKey": true,
952
+ "notNull": true
953
+ },
954
+ "organization_id": {
955
+ "name": "organization_id",
956
+ "type": "text",
957
+ "primaryKey": false,
958
+ "notNull": true
959
+ },
960
+ "user_id": {
961
+ "name": "user_id",
962
+ "type": "text",
963
+ "primaryKey": false,
964
+ "notNull": true
965
+ },
966
+ "role": {
967
+ "name": "role",
968
+ "type": "text",
969
+ "primaryKey": false,
970
+ "notNull": true
971
+ },
972
+ "created_at": {
973
+ "name": "created_at",
974
+ "type": "timestamp",
975
+ "primaryKey": false,
976
+ "notNull": true
977
+ }
978
+ },
979
+ "indexes": {},
980
+ "foreignKeys": {
981
+ "member_organization_id_organization_id_fk": {
982
+ "name": "member_organization_id_organization_id_fk",
983
+ "tableFrom": "member",
984
+ "tableTo": "organization",
985
+ "columnsFrom": ["organization_id"],
986
+ "columnsTo": ["id"],
987
+ "onDelete": "cascade",
988
+ "onUpdate": "no action"
989
+ },
990
+ "member_user_id_user_id_fk": {
991
+ "name": "member_user_id_user_id_fk",
992
+ "tableFrom": "member",
993
+ "tableTo": "user",
994
+ "columnsFrom": ["user_id"],
995
+ "columnsTo": ["id"],
996
+ "onDelete": "cascade",
997
+ "onUpdate": "no action"
998
+ }
999
+ },
1000
+ "compositePrimaryKeys": {},
1001
+ "uniqueConstraints": {},
1002
+ "policies": {},
1003
+ "checkConstraints": {},
1004
+ "isRLSEnabled": false
1005
+ },
1006
+ "public.organization": {
1007
+ "name": "organization",
1008
+ "schema": "",
1009
+ "columns": {
1010
+ "id": {
1011
+ "name": "id",
1012
+ "type": "text",
1013
+ "primaryKey": true,
1014
+ "notNull": true
1015
+ },
1016
+ "name": {
1017
+ "name": "name",
1018
+ "type": "text",
1019
+ "primaryKey": false,
1020
+ "notNull": true
1021
+ },
1022
+ "slug": {
1023
+ "name": "slug",
1024
+ "type": "text",
1025
+ "primaryKey": false,
1026
+ "notNull": false
1027
+ },
1028
+ "logo": {
1029
+ "name": "logo",
1030
+ "type": "text",
1031
+ "primaryKey": false,
1032
+ "notNull": false
1033
+ },
1034
+ "metadata": {
1035
+ "name": "metadata",
1036
+ "type": "text",
1037
+ "primaryKey": false,
1038
+ "notNull": false
1039
+ },
1040
+ "created_at": {
1041
+ "name": "created_at",
1042
+ "type": "timestamp",
1043
+ "primaryKey": false,
1044
+ "notNull": true
1045
+ }
1046
+ },
1047
+ "indexes": {},
1048
+ "foreignKeys": {},
1049
+ "compositePrimaryKeys": {},
1050
+ "uniqueConstraints": {
1051
+ "organization_slug_unique": {
1052
+ "name": "organization_slug_unique",
1053
+ "nullsNotDistinct": false,
1054
+ "columns": ["slug"]
1055
+ }
1056
+ },
1057
+ "policies": {},
1058
+ "checkConstraints": {},
1059
+ "isRLSEnabled": false
1060
+ },
1061
+ "public.passkey": {
1062
+ "name": "passkey",
1063
+ "schema": "",
1064
+ "columns": {
1065
+ "id": {
1066
+ "name": "id",
1067
+ "type": "text",
1068
+ "primaryKey": true,
1069
+ "notNull": true
1070
+ },
1071
+ "name": {
1072
+ "name": "name",
1073
+ "type": "text",
1074
+ "primaryKey": false,
1075
+ "notNull": false
1076
+ },
1077
+ "public_key": {
1078
+ "name": "public_key",
1079
+ "type": "text",
1080
+ "primaryKey": false,
1081
+ "notNull": true
1082
+ },
1083
+ "user_id": {
1084
+ "name": "user_id",
1085
+ "type": "text",
1086
+ "primaryKey": false,
1087
+ "notNull": true
1088
+ },
1089
+ "credential_id": {
1090
+ "name": "credential_id",
1091
+ "type": "text",
1092
+ "primaryKey": false,
1093
+ "notNull": true
1094
+ },
1095
+ "counter": {
1096
+ "name": "counter",
1097
+ "type": "integer",
1098
+ "primaryKey": false,
1099
+ "notNull": true
1100
+ },
1101
+ "device_type": {
1102
+ "name": "device_type",
1103
+ "type": "text",
1104
+ "primaryKey": false,
1105
+ "notNull": true
1106
+ },
1107
+ "backed_up": {
1108
+ "name": "backed_up",
1109
+ "type": "boolean",
1110
+ "primaryKey": false,
1111
+ "notNull": true
1112
+ },
1113
+ "transports": {
1114
+ "name": "transports",
1115
+ "type": "text",
1116
+ "primaryKey": false,
1117
+ "notNull": false
1118
+ },
1119
+ "created_at": {
1120
+ "name": "created_at",
1121
+ "type": "timestamp",
1122
+ "primaryKey": false,
1123
+ "notNull": true
1124
+ },
1125
+ "aaguid": {
1126
+ "name": "aaguid",
1127
+ "type": "text",
1128
+ "primaryKey": false,
1129
+ "notNull": false
1130
+ }
1131
+ },
1132
+ "indexes": {},
1133
+ "foreignKeys": {
1134
+ "passkey_user_id_user_id_fk": {
1135
+ "name": "passkey_user_id_user_id_fk",
1136
+ "tableFrom": "passkey",
1137
+ "tableTo": "user",
1138
+ "columnsFrom": ["user_id"],
1139
+ "columnsTo": ["id"],
1140
+ "onDelete": "cascade",
1141
+ "onUpdate": "no action"
1142
+ }
1143
+ },
1144
+ "compositePrimaryKeys": {},
1145
+ "uniqueConstraints": {},
1146
+ "policies": {},
1147
+ "checkConstraints": {},
1148
+ "isRLSEnabled": false
1149
+ },
1150
+ "public.session": {
1151
+ "name": "session",
1152
+ "schema": "",
1153
+ "columns": {
1154
+ "id": {
1155
+ "name": "id",
1156
+ "type": "text",
1157
+ "primaryKey": true,
1158
+ "notNull": true
1159
+ },
1160
+ "expires_at": {
1161
+ "name": "expires_at",
1162
+ "type": "timestamp",
1163
+ "primaryKey": false,
1164
+ "notNull": true
1165
+ },
1166
+ "token": {
1167
+ "name": "token",
1168
+ "type": "text",
1169
+ "primaryKey": false,
1170
+ "notNull": true
1171
+ },
1172
+ "created_at": {
1173
+ "name": "created_at",
1174
+ "type": "timestamp",
1175
+ "primaryKey": false,
1176
+ "notNull": true
1177
+ },
1178
+ "updated_at": {
1179
+ "name": "updated_at",
1180
+ "type": "timestamp",
1181
+ "primaryKey": false,
1182
+ "notNull": true
1183
+ },
1184
+ "ip_address": {
1185
+ "name": "ip_address",
1186
+ "type": "text",
1187
+ "primaryKey": false,
1188
+ "notNull": false
1189
+ },
1190
+ "user_agent": {
1191
+ "name": "user_agent",
1192
+ "type": "text",
1193
+ "primaryKey": false,
1194
+ "notNull": false
1195
+ },
1196
+ "user_id": {
1197
+ "name": "user_id",
1198
+ "type": "text",
1199
+ "primaryKey": false,
1200
+ "notNull": true
1201
+ },
1202
+ "active_organization_id": {
1203
+ "name": "active_organization_id",
1204
+ "type": "text",
1205
+ "primaryKey": false,
1206
+ "notNull": false
1207
+ }
1208
+ },
1209
+ "indexes": {},
1210
+ "foreignKeys": {
1211
+ "session_user_id_user_id_fk": {
1212
+ "name": "session_user_id_user_id_fk",
1213
+ "tableFrom": "session",
1214
+ "tableTo": "user",
1215
+ "columnsFrom": ["user_id"],
1216
+ "columnsTo": ["id"],
1217
+ "onDelete": "cascade",
1218
+ "onUpdate": "no action"
1219
+ }
1220
+ },
1221
+ "compositePrimaryKeys": {},
1222
+ "uniqueConstraints": {
1223
+ "session_token_unique": {
1224
+ "name": "session_token_unique",
1225
+ "nullsNotDistinct": false,
1226
+ "columns": ["token"]
1227
+ }
1228
+ },
1229
+ "policies": {},
1230
+ "checkConstraints": {},
1231
+ "isRLSEnabled": false
1232
+ },
1233
+ "public.statement": {
1234
+ "name": "statement",
1235
+ "schema": "",
1236
+ "columns": {
1237
+ "id": {
1238
+ "name": "id",
1239
+ "type": "text",
1240
+ "primaryKey": true,
1241
+ "notNull": true
1242
+ },
1243
+ "user_id": {
1244
+ "name": "user_id",
1245
+ "type": "text",
1246
+ "primaryKey": false,
1247
+ "notNull": false
1248
+ },
1249
+ "organization_id": {
1250
+ "name": "organization_id",
1251
+ "type": "text",
1252
+ "primaryKey": false,
1253
+ "notNull": false
1254
+ },
1255
+ "role_id": {
1256
+ "name": "role_id",
1257
+ "type": "text",
1258
+ "primaryKey": false,
1259
+ "notNull": false
1260
+ },
1261
+ "effect": {
1262
+ "name": "effect",
1263
+ "type": "text",
1264
+ "primaryKey": false,
1265
+ "notNull": true
1266
+ },
1267
+ "action": {
1268
+ "name": "action",
1269
+ "type": "text",
1270
+ "primaryKey": false,
1271
+ "notNull": true
1272
+ },
1273
+ "resource": {
1274
+ "name": "resource",
1275
+ "type": "text",
1276
+ "primaryKey": false,
1277
+ "notNull": true
1278
+ },
1279
+ "condition": {
1280
+ "name": "condition",
1281
+ "type": "text",
1282
+ "primaryKey": false,
1283
+ "notNull": false
1284
+ },
1285
+ "expires_at": {
1286
+ "name": "expires_at",
1287
+ "type": "timestamp",
1288
+ "primaryKey": false,
1289
+ "notNull": false
1290
+ },
1291
+ "created_at": {
1292
+ "name": "created_at",
1293
+ "type": "timestamp",
1294
+ "primaryKey": false,
1295
+ "notNull": true
1296
+ },
1297
+ "updated_at": {
1298
+ "name": "updated_at",
1299
+ "type": "timestamp",
1300
+ "primaryKey": false,
1301
+ "notNull": true
1302
+ }
1303
+ },
1304
+ "indexes": {},
1305
+ "foreignKeys": {
1306
+ "statement_user_id_user_id_fk": {
1307
+ "name": "statement_user_id_user_id_fk",
1308
+ "tableFrom": "statement",
1309
+ "tableTo": "user",
1310
+ "columnsFrom": ["user_id"],
1311
+ "columnsTo": ["id"],
1312
+ "onDelete": "cascade",
1313
+ "onUpdate": "no action"
1314
+ },
1315
+ "statement_organization_id_organization_id_fk": {
1316
+ "name": "statement_organization_id_organization_id_fk",
1317
+ "tableFrom": "statement",
1318
+ "tableTo": "organization",
1319
+ "columnsFrom": ["organization_id"],
1320
+ "columnsTo": ["id"],
1321
+ "onDelete": "cascade",
1322
+ "onUpdate": "no action"
1323
+ }
1324
+ },
1325
+ "compositePrimaryKeys": {},
1326
+ "uniqueConstraints": {},
1327
+ "policies": {},
1328
+ "checkConstraints": {},
1329
+ "isRLSEnabled": false
1330
+ },
1331
+ "public.subscription": {
1332
+ "name": "subscription",
1333
+ "schema": "",
1334
+ "columns": {
1335
+ "id": {
1336
+ "name": "id",
1337
+ "type": "text",
1338
+ "primaryKey": true,
1339
+ "notNull": true
1340
+ },
1341
+ "plan": {
1342
+ "name": "plan",
1343
+ "type": "text",
1344
+ "primaryKey": false,
1345
+ "notNull": true
1346
+ },
1347
+ "reference_id": {
1348
+ "name": "reference_id",
1349
+ "type": "text",
1350
+ "primaryKey": false,
1351
+ "notNull": true
1352
+ },
1353
+ "stripe_customer_id": {
1354
+ "name": "stripe_customer_id",
1355
+ "type": "text",
1356
+ "primaryKey": false,
1357
+ "notNull": false
1358
+ },
1359
+ "stripe_subscription_id": {
1360
+ "name": "stripe_subscription_id",
1361
+ "type": "text",
1362
+ "primaryKey": false,
1363
+ "notNull": false
1364
+ },
1365
+ "status": {
1366
+ "name": "status",
1367
+ "type": "text",
1368
+ "primaryKey": false,
1369
+ "notNull": true
1370
+ },
1371
+ "period_start": {
1372
+ "name": "period_start",
1373
+ "type": "timestamp",
1374
+ "primaryKey": false,
1375
+ "notNull": false
1376
+ },
1377
+ "period_end": {
1378
+ "name": "period_end",
1379
+ "type": "timestamp",
1380
+ "primaryKey": false,
1381
+ "notNull": false
1382
+ },
1383
+ "cancel_at_period_end": {
1384
+ "name": "cancel_at_period_end",
1385
+ "type": "boolean",
1386
+ "primaryKey": false,
1387
+ "notNull": false
1388
+ },
1389
+ "seats": {
1390
+ "name": "seats",
1391
+ "type": "integer",
1392
+ "primaryKey": false,
1393
+ "notNull": false
1394
+ },
1395
+ "trial_start": {
1396
+ "name": "trial_start",
1397
+ "type": "timestamp",
1398
+ "primaryKey": false,
1399
+ "notNull": false
1400
+ },
1401
+ "trial_end": {
1402
+ "name": "trial_end",
1403
+ "type": "timestamp",
1404
+ "primaryKey": false,
1405
+ "notNull": false
1406
+ },
1407
+ "created_at": {
1408
+ "name": "created_at",
1409
+ "type": "timestamp",
1410
+ "primaryKey": false,
1411
+ "notNull": true,
1412
+ "default": "now()"
1413
+ },
1414
+ "updated_at": {
1415
+ "name": "updated_at",
1416
+ "type": "timestamp",
1417
+ "primaryKey": false,
1418
+ "notNull": true,
1419
+ "default": "now()"
1420
+ }
1421
+ },
1422
+ "indexes": {},
1423
+ "foreignKeys": {},
1424
+ "compositePrimaryKeys": {},
1425
+ "uniqueConstraints": {},
1426
+ "policies": {},
1427
+ "checkConstraints": {},
1428
+ "isRLSEnabled": false
1429
+ },
1430
+ "public.two_factor": {
1431
+ "name": "two_factor",
1432
+ "schema": "",
1433
+ "columns": {
1434
+ "id": {
1435
+ "name": "id",
1436
+ "type": "text",
1437
+ "primaryKey": true,
1438
+ "notNull": true
1439
+ },
1440
+ "secret": {
1441
+ "name": "secret",
1442
+ "type": "text",
1443
+ "primaryKey": false,
1444
+ "notNull": true
1445
+ },
1446
+ "backup_codes": {
1447
+ "name": "backup_codes",
1448
+ "type": "text",
1449
+ "primaryKey": false,
1450
+ "notNull": true
1451
+ },
1452
+ "user_id": {
1453
+ "name": "user_id",
1454
+ "type": "text",
1455
+ "primaryKey": false,
1456
+ "notNull": true
1457
+ }
1458
+ },
1459
+ "indexes": {},
1460
+ "foreignKeys": {
1461
+ "two_factor_user_id_user_id_fk": {
1462
+ "name": "two_factor_user_id_user_id_fk",
1463
+ "tableFrom": "two_factor",
1464
+ "tableTo": "user",
1465
+ "columnsFrom": ["user_id"],
1466
+ "columnsTo": ["id"],
1467
+ "onDelete": "cascade",
1468
+ "onUpdate": "no action"
1469
+ }
1470
+ },
1471
+ "compositePrimaryKeys": {},
1472
+ "uniqueConstraints": {},
1473
+ "policies": {},
1474
+ "checkConstraints": {},
1475
+ "isRLSEnabled": false
1476
+ },
1477
+ "public.user": {
1478
+ "name": "user",
1479
+ "schema": "",
1480
+ "columns": {
1481
+ "id": {
1482
+ "name": "id",
1483
+ "type": "text",
1484
+ "primaryKey": true,
1485
+ "notNull": true
1486
+ },
1487
+ "name": {
1488
+ "name": "name",
1489
+ "type": "text",
1490
+ "primaryKey": false,
1491
+ "notNull": true
1492
+ },
1493
+ "email": {
1494
+ "name": "email",
1495
+ "type": "text",
1496
+ "primaryKey": false,
1497
+ "notNull": true
1498
+ },
1499
+ "email_verified": {
1500
+ "name": "email_verified",
1501
+ "type": "boolean",
1502
+ "primaryKey": false,
1503
+ "notNull": true
1504
+ },
1505
+ "image": {
1506
+ "name": "image",
1507
+ "type": "text",
1508
+ "primaryKey": false,
1509
+ "notNull": false
1510
+ },
1511
+ "created_at": {
1512
+ "name": "created_at",
1513
+ "type": "timestamp",
1514
+ "primaryKey": false,
1515
+ "notNull": true
1516
+ },
1517
+ "updated_at": {
1518
+ "name": "updated_at",
1519
+ "type": "timestamp",
1520
+ "primaryKey": false,
1521
+ "notNull": true
1522
+ },
1523
+ "two_factor_enabled": {
1524
+ "name": "two_factor_enabled",
1525
+ "type": "boolean",
1526
+ "primaryKey": false,
1527
+ "notNull": false
1528
+ },
1529
+ "last_login_method": {
1530
+ "name": "last_login_method",
1531
+ "type": "text",
1532
+ "primaryKey": false,
1533
+ "notNull": false
1534
+ },
1535
+ "stripe_customer_id": {
1536
+ "name": "stripe_customer_id",
1537
+ "type": "text",
1538
+ "primaryKey": false,
1539
+ "notNull": false
1540
+ }
1541
+ },
1542
+ "indexes": {},
1543
+ "foreignKeys": {},
1544
+ "compositePrimaryKeys": {},
1545
+ "uniqueConstraints": {
1546
+ "user_email_unique": {
1547
+ "name": "user_email_unique",
1548
+ "nullsNotDistinct": false,
1549
+ "columns": ["email"]
1550
+ }
1551
+ },
1552
+ "policies": {},
1553
+ "checkConstraints": {},
1554
+ "isRLSEnabled": false
1555
+ },
1556
+ "public.verification": {
1557
+ "name": "verification",
1558
+ "schema": "",
1559
+ "columns": {
1560
+ "id": {
1561
+ "name": "id",
1562
+ "type": "text",
1563
+ "primaryKey": true,
1564
+ "notNull": true
1565
+ },
1566
+ "identifier": {
1567
+ "name": "identifier",
1568
+ "type": "text",
1569
+ "primaryKey": false,
1570
+ "notNull": true
1571
+ },
1572
+ "value": {
1573
+ "name": "value",
1574
+ "type": "text",
1575
+ "primaryKey": false,
1576
+ "notNull": true
1577
+ },
1578
+ "expires_at": {
1579
+ "name": "expires_at",
1580
+ "type": "timestamp",
1581
+ "primaryKey": false,
1582
+ "notNull": true
1583
+ },
1584
+ "created_at": {
1585
+ "name": "created_at",
1586
+ "type": "timestamp",
1587
+ "primaryKey": false,
1588
+ "notNull": false
1589
+ },
1590
+ "updated_at": {
1591
+ "name": "updated_at",
1592
+ "type": "timestamp",
1593
+ "primaryKey": false,
1594
+ "notNull": false
1595
+ }
1596
+ },
1597
+ "indexes": {},
1598
+ "foreignKeys": {},
1599
+ "compositePrimaryKeys": {},
1600
+ "uniqueConstraints": {},
1601
+ "policies": {},
1602
+ "checkConstraints": {},
1603
+ "isRLSEnabled": false
1604
+ }
1605
+ },
1606
+ "enums": {},
1607
+ "schemas": {},
1608
+ "sequences": {},
1609
+ "roles": {},
1610
+ "policies": {},
1611
+ "views": {},
1612
+ "_meta": {
1613
+ "columns": {},
1614
+ "schemas": {},
1615
+ "tables": {}
1616
+ }
1617
+ }