@maudecode/kanvil 0.0.0-stage → 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.
Files changed (97) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +35 -2
  3. package/apps/server/.env.example +41 -0
  4. package/apps/server/dist/auth-BscXb1NQ.mjs +2666 -0
  5. package/apps/server/dist/config-Qxr_7oqZ.mjs +575 -0
  6. package/apps/server/dist/configure.mjs +23 -0
  7. package/apps/server/dist/index.mjs +1754 -0
  8. package/apps/server/dist/migrate-C9f4ozB4.mjs +17 -0
  9. package/apps/server/dist/migrate.mjs +12 -0
  10. package/apps/server/dist/recover.mjs +52 -0
  11. package/apps/server/drizzle/0000_foundation.sql +437 -0
  12. package/apps/server/drizzle/0001_claim_identity.sql +1 -0
  13. package/apps/server/drizzle/0002_transactional_attachments.sql +6 -0
  14. package/apps/server/drizzle/0003_durable_claim_fence.sql +4 -0
  15. package/apps/server/drizzle/0004_lumpy_archangel.sql +6 -0
  16. package/apps/server/drizzle/0005_unique_toxin.sql +28 -0
  17. package/apps/server/drizzle/0006_instance_services.sql +48 -0
  18. package/apps/server/drizzle/0007_optional_broker.sql +6 -0
  19. package/apps/server/drizzle/0008_workspaces.sql +37 -0
  20. package/apps/server/drizzle/0009_project_icons.sql +6 -0
  21. package/apps/server/drizzle/0010_project_labels.sql +14 -0
  22. package/apps/server/drizzle/0011_due_dates.sql +1 -0
  23. package/apps/server/drizzle/0012_label_colors.sql +7 -0
  24. package/apps/server/drizzle/meta/0000_snapshot.json +3210 -0
  25. package/apps/server/drizzle/meta/0001_snapshot.json +3216 -0
  26. package/apps/server/drizzle/meta/0002_snapshot.json +3255 -0
  27. package/apps/server/drizzle/meta/0003_snapshot.json +3262 -0
  28. package/apps/server/drizzle/meta/0004_snapshot.json +3302 -0
  29. package/apps/server/drizzle/meta/0005_snapshot.json +3518 -0
  30. package/apps/server/drizzle/meta/0006_snapshot.json +3842 -0
  31. package/apps/server/drizzle/meta/0007_snapshot.json +3874 -0
  32. package/apps/server/drizzle/meta/0008_snapshot.json +4051 -0
  33. package/apps/server/drizzle/meta/0009_snapshot.json +4105 -0
  34. package/apps/server/drizzle/meta/0010_snapshot.json +4174 -0
  35. package/apps/server/drizzle/meta/0011_snapshot.json +4180 -0
  36. package/apps/server/drizzle/meta/0012_snapshot.json +4226 -0
  37. package/apps/server/drizzle/meta/_journal.json +97 -0
  38. package/apps/web/dist/apple-touch-icon.png +0 -0
  39. package/apps/web/dist/assets/CompositeItem-D9KvUNiq.js +1 -0
  40. package/apps/web/dist/assets/admin-settings-B0u2-aAK.js +1 -0
  41. package/apps/web/dist/assets/camera-Cv5wKkKn.js +1 -0
  42. package/apps/web/dist/assets/date-picker-lhXxKIlN.js +1 -0
  43. package/apps/web/dist/assets/ellipsis-CN74O_EP.js +1 -0
  44. package/apps/web/dist/assets/forms-456UbfIC.js +92 -0
  45. package/apps/web/dist/assets/geist-cyrillic-ext-wght-normal-DjL33-gN.woff2 +0 -0
  46. package/apps/web/dist/assets/geist-cyrillic-wght-normal-BEAKL7Jp.woff2 +0 -0
  47. package/apps/web/dist/assets/geist-latin-ext-wght-normal-DC-KSUi6.woff2 +0 -0
  48. package/apps/web/dist/assets/geist-latin-wght-normal-BgDaEnEv.woff2 +0 -0
  49. package/apps/web/dist/assets/geist-vietnamese-wght-normal-6IgcOCM7.woff2 +0 -0
  50. package/apps/web/dist/assets/index-CVzq9BMC.css +2 -0
  51. package/apps/web/dist/assets/index-Dt8wYIVA.js +51 -0
  52. package/apps/web/dist/assets/instance-BCNvOvYa.js +1 -0
  53. package/apps/web/dist/assets/list-order-1UoOT5nR.js +1 -0
  54. package/apps/web/dist/assets/lucide-U995NW8E.js +1 -0
  55. package/apps/web/dist/assets/member-directory-C81ugis6.js +1 -0
  56. package/apps/web/dist/assets/popover-BWk65ByY.js +1 -0
  57. package/apps/web/dist/assets/project-settings-DnpVfVf5.js +1 -0
  58. package/apps/web/dist/assets/rotate-ccw-BLeWpuu1.js +1 -0
  59. package/apps/web/dist/assets/settings-DUXuOgWn.js +1 -0
  60. package/apps/web/dist/assets/settings-layout-xR4hrfte.js +1 -0
  61. package/apps/web/dist/assets/table-BQbZG4BK.js +1 -0
  62. package/apps/web/dist/assets/ticket-detail-B9M_eaVu.js +2 -0
  63. package/apps/web/dist/assets/ticket-editor-Chg1lDuU.js +1 -0
  64. package/apps/web/dist/assets/ticket-list-C8500tXj.js +5 -0
  65. package/apps/web/dist/assets/ticket-tags-cbwQ93Gt.js +1 -0
  66. package/apps/web/dist/assets/upload-5Wg5ou_Z.js +1 -0
  67. package/apps/web/dist/assets/workspace-settings-Dte44Kkx.js +1 -0
  68. package/apps/web/dist/brand/icon-192.png +0 -0
  69. package/apps/web/dist/brand/icon-512.png +0 -0
  70. package/apps/web/dist/brand/mark-blue.svg +1 -0
  71. package/apps/web/dist/brand/mark-white.svg +1 -0
  72. package/apps/web/dist/brand/mark.svg +1 -0
  73. package/apps/web/dist/brand/maskable-512.png +0 -0
  74. package/apps/web/dist/brand/social.png +0 -0
  75. package/apps/web/dist/favicon.ico +0 -0
  76. package/apps/web/dist/favicon.svg +1 -0
  77. package/apps/web/dist/fonts/OFL.txt +93 -0
  78. package/apps/web/dist/fonts/ibm-plex-sans-latin.woff2 +0 -0
  79. package/apps/web/dist/icon.svg +1 -0
  80. package/apps/web/dist/index.html +31 -0
  81. package/apps/web/dist/site.webmanifest +29 -0
  82. package/apps/web/dist/third-party-icons.txt +64 -0
  83. package/apps/web/dist/third-party-themes.txt +548 -0
  84. package/bin/kanvil.mjs +27 -0
  85. package/compose.yml +66 -0
  86. package/docs/api.md +87 -0
  87. package/docs/branding.md +13 -0
  88. package/docs/design.md +37 -0
  89. package/docs/infrastructure.md +94 -0
  90. package/docs/mobile.md +79 -0
  91. package/docs/plan.md +111 -0
  92. package/docs/releasing.md +18 -0
  93. package/docs/self-hosting.md +204 -0
  94. package/docs/themes.md +38 -0
  95. package/docs/verification.md +83 -0
  96. package/docs/workspaces.md +21 -0
  97. package/package.json +45 -4
@@ -0,0 +1,3210 @@
1
+ {
2
+ "id": "1c171085-0030-4387-ad7a-2e18692ba468",
3
+ "prevId": "00000000-0000-0000-0000-000000000000",
4
+ "version": "7",
5
+ "dialect": "postgresql",
6
+ "tables": {
7
+ "public.account": {
8
+ "name": "account",
9
+ "schema": "",
10
+ "columns": {
11
+ "id": {
12
+ "name": "id",
13
+ "type": "text",
14
+ "primaryKey": true,
15
+ "notNull": true
16
+ },
17
+ "account_id": {
18
+ "name": "account_id",
19
+ "type": "text",
20
+ "primaryKey": false,
21
+ "notNull": true
22
+ },
23
+ "provider_id": {
24
+ "name": "provider_id",
25
+ "type": "text",
26
+ "primaryKey": false,
27
+ "notNull": true
28
+ },
29
+ "user_id": {
30
+ "name": "user_id",
31
+ "type": "text",
32
+ "primaryKey": false,
33
+ "notNull": true
34
+ },
35
+ "access_token": {
36
+ "name": "access_token",
37
+ "type": "text",
38
+ "primaryKey": false,
39
+ "notNull": false
40
+ },
41
+ "refresh_token": {
42
+ "name": "refresh_token",
43
+ "type": "text",
44
+ "primaryKey": false,
45
+ "notNull": false
46
+ },
47
+ "id_token": {
48
+ "name": "id_token",
49
+ "type": "text",
50
+ "primaryKey": false,
51
+ "notNull": false
52
+ },
53
+ "access_token_expires_at": {
54
+ "name": "access_token_expires_at",
55
+ "type": "timestamp",
56
+ "primaryKey": false,
57
+ "notNull": false
58
+ },
59
+ "refresh_token_expires_at": {
60
+ "name": "refresh_token_expires_at",
61
+ "type": "timestamp",
62
+ "primaryKey": false,
63
+ "notNull": false
64
+ },
65
+ "scope": {
66
+ "name": "scope",
67
+ "type": "text",
68
+ "primaryKey": false,
69
+ "notNull": false
70
+ },
71
+ "password": {
72
+ "name": "password",
73
+ "type": "text",
74
+ "primaryKey": false,
75
+ "notNull": false
76
+ },
77
+ "created_at": {
78
+ "name": "created_at",
79
+ "type": "timestamp",
80
+ "primaryKey": false,
81
+ "notNull": true,
82
+ "default": "now()"
83
+ },
84
+ "updated_at": {
85
+ "name": "updated_at",
86
+ "type": "timestamp",
87
+ "primaryKey": false,
88
+ "notNull": true
89
+ }
90
+ },
91
+ "indexes": {
92
+ "account_userId_idx": {
93
+ "name": "account_userId_idx",
94
+ "columns": [
95
+ {
96
+ "expression": "user_id",
97
+ "isExpression": false,
98
+ "asc": true,
99
+ "nulls": "last"
100
+ }
101
+ ],
102
+ "isUnique": false,
103
+ "concurrently": false,
104
+ "method": "btree",
105
+ "with": {}
106
+ }
107
+ },
108
+ "foreignKeys": {
109
+ "account_user_id_user_id_fk": {
110
+ "name": "account_user_id_user_id_fk",
111
+ "tableFrom": "account",
112
+ "tableTo": "user",
113
+ "columnsFrom": [
114
+ "user_id"
115
+ ],
116
+ "columnsTo": [
117
+ "id"
118
+ ],
119
+ "onDelete": "cascade",
120
+ "onUpdate": "no action"
121
+ }
122
+ },
123
+ "compositePrimaryKeys": {},
124
+ "uniqueConstraints": {},
125
+ "policies": {},
126
+ "checkConstraints": {},
127
+ "isRLSEnabled": false
128
+ },
129
+ "public.apikey": {
130
+ "name": "apikey",
131
+ "schema": "",
132
+ "columns": {
133
+ "id": {
134
+ "name": "id",
135
+ "type": "text",
136
+ "primaryKey": true,
137
+ "notNull": true
138
+ },
139
+ "config_id": {
140
+ "name": "config_id",
141
+ "type": "text",
142
+ "primaryKey": false,
143
+ "notNull": true,
144
+ "default": "'default'"
145
+ },
146
+ "name": {
147
+ "name": "name",
148
+ "type": "text",
149
+ "primaryKey": false,
150
+ "notNull": false
151
+ },
152
+ "start": {
153
+ "name": "start",
154
+ "type": "text",
155
+ "primaryKey": false,
156
+ "notNull": false
157
+ },
158
+ "reference_id": {
159
+ "name": "reference_id",
160
+ "type": "text",
161
+ "primaryKey": false,
162
+ "notNull": true
163
+ },
164
+ "prefix": {
165
+ "name": "prefix",
166
+ "type": "text",
167
+ "primaryKey": false,
168
+ "notNull": false
169
+ },
170
+ "key": {
171
+ "name": "key",
172
+ "type": "text",
173
+ "primaryKey": false,
174
+ "notNull": true
175
+ },
176
+ "refill_interval": {
177
+ "name": "refill_interval",
178
+ "type": "integer",
179
+ "primaryKey": false,
180
+ "notNull": false
181
+ },
182
+ "refill_amount": {
183
+ "name": "refill_amount",
184
+ "type": "integer",
185
+ "primaryKey": false,
186
+ "notNull": false
187
+ },
188
+ "last_refill_at": {
189
+ "name": "last_refill_at",
190
+ "type": "timestamp",
191
+ "primaryKey": false,
192
+ "notNull": false
193
+ },
194
+ "enabled": {
195
+ "name": "enabled",
196
+ "type": "boolean",
197
+ "primaryKey": false,
198
+ "notNull": false,
199
+ "default": true
200
+ },
201
+ "rate_limit_enabled": {
202
+ "name": "rate_limit_enabled",
203
+ "type": "boolean",
204
+ "primaryKey": false,
205
+ "notNull": false,
206
+ "default": true
207
+ },
208
+ "rate_limit_time_window": {
209
+ "name": "rate_limit_time_window",
210
+ "type": "integer",
211
+ "primaryKey": false,
212
+ "notNull": false,
213
+ "default": 86400000
214
+ },
215
+ "rate_limit_max": {
216
+ "name": "rate_limit_max",
217
+ "type": "integer",
218
+ "primaryKey": false,
219
+ "notNull": false,
220
+ "default": 10
221
+ },
222
+ "request_count": {
223
+ "name": "request_count",
224
+ "type": "integer",
225
+ "primaryKey": false,
226
+ "notNull": false,
227
+ "default": 0
228
+ },
229
+ "remaining": {
230
+ "name": "remaining",
231
+ "type": "integer",
232
+ "primaryKey": false,
233
+ "notNull": false
234
+ },
235
+ "last_request": {
236
+ "name": "last_request",
237
+ "type": "timestamp",
238
+ "primaryKey": false,
239
+ "notNull": false
240
+ },
241
+ "expires_at": {
242
+ "name": "expires_at",
243
+ "type": "timestamp",
244
+ "primaryKey": false,
245
+ "notNull": false
246
+ },
247
+ "created_at": {
248
+ "name": "created_at",
249
+ "type": "timestamp",
250
+ "primaryKey": false,
251
+ "notNull": true
252
+ },
253
+ "updated_at": {
254
+ "name": "updated_at",
255
+ "type": "timestamp",
256
+ "primaryKey": false,
257
+ "notNull": true
258
+ },
259
+ "permissions": {
260
+ "name": "permissions",
261
+ "type": "text",
262
+ "primaryKey": false,
263
+ "notNull": false
264
+ },
265
+ "metadata": {
266
+ "name": "metadata",
267
+ "type": "text",
268
+ "primaryKey": false,
269
+ "notNull": false
270
+ }
271
+ },
272
+ "indexes": {
273
+ "apikey_configId_idx": {
274
+ "name": "apikey_configId_idx",
275
+ "columns": [
276
+ {
277
+ "expression": "config_id",
278
+ "isExpression": false,
279
+ "asc": true,
280
+ "nulls": "last"
281
+ }
282
+ ],
283
+ "isUnique": false,
284
+ "concurrently": false,
285
+ "method": "btree",
286
+ "with": {}
287
+ },
288
+ "apikey_referenceId_idx": {
289
+ "name": "apikey_referenceId_idx",
290
+ "columns": [
291
+ {
292
+ "expression": "reference_id",
293
+ "isExpression": false,
294
+ "asc": true,
295
+ "nulls": "last"
296
+ }
297
+ ],
298
+ "isUnique": false,
299
+ "concurrently": false,
300
+ "method": "btree",
301
+ "with": {}
302
+ },
303
+ "apikey_key_idx": {
304
+ "name": "apikey_key_idx",
305
+ "columns": [
306
+ {
307
+ "expression": "key",
308
+ "isExpression": false,
309
+ "asc": true,
310
+ "nulls": "last"
311
+ }
312
+ ],
313
+ "isUnique": false,
314
+ "concurrently": false,
315
+ "method": "btree",
316
+ "with": {}
317
+ }
318
+ },
319
+ "foreignKeys": {},
320
+ "compositePrimaryKeys": {},
321
+ "uniqueConstraints": {},
322
+ "policies": {},
323
+ "checkConstraints": {},
324
+ "isRLSEnabled": false
325
+ },
326
+ "public.jwks": {
327
+ "name": "jwks",
328
+ "schema": "",
329
+ "columns": {
330
+ "id": {
331
+ "name": "id",
332
+ "type": "text",
333
+ "primaryKey": true,
334
+ "notNull": true
335
+ },
336
+ "public_key": {
337
+ "name": "public_key",
338
+ "type": "text",
339
+ "primaryKey": false,
340
+ "notNull": true
341
+ },
342
+ "private_key": {
343
+ "name": "private_key",
344
+ "type": "text",
345
+ "primaryKey": false,
346
+ "notNull": true
347
+ },
348
+ "created_at": {
349
+ "name": "created_at",
350
+ "type": "timestamp",
351
+ "primaryKey": false,
352
+ "notNull": true
353
+ },
354
+ "expires_at": {
355
+ "name": "expires_at",
356
+ "type": "timestamp",
357
+ "primaryKey": false,
358
+ "notNull": false
359
+ },
360
+ "alg": {
361
+ "name": "alg",
362
+ "type": "text",
363
+ "primaryKey": false,
364
+ "notNull": false
365
+ },
366
+ "crv": {
367
+ "name": "crv",
368
+ "type": "text",
369
+ "primaryKey": false,
370
+ "notNull": false
371
+ }
372
+ },
373
+ "indexes": {},
374
+ "foreignKeys": {},
375
+ "compositePrimaryKeys": {},
376
+ "uniqueConstraints": {},
377
+ "policies": {},
378
+ "checkConstraints": {},
379
+ "isRLSEnabled": false
380
+ },
381
+ "public.oauth_access_token": {
382
+ "name": "oauth_access_token",
383
+ "schema": "",
384
+ "columns": {
385
+ "id": {
386
+ "name": "id",
387
+ "type": "text",
388
+ "primaryKey": true,
389
+ "notNull": true
390
+ },
391
+ "token": {
392
+ "name": "token",
393
+ "type": "text",
394
+ "primaryKey": false,
395
+ "notNull": true
396
+ },
397
+ "client_id": {
398
+ "name": "client_id",
399
+ "type": "text",
400
+ "primaryKey": false,
401
+ "notNull": true
402
+ },
403
+ "session_id": {
404
+ "name": "session_id",
405
+ "type": "text",
406
+ "primaryKey": false,
407
+ "notNull": false
408
+ },
409
+ "user_id": {
410
+ "name": "user_id",
411
+ "type": "text",
412
+ "primaryKey": false,
413
+ "notNull": false
414
+ },
415
+ "reference_id": {
416
+ "name": "reference_id",
417
+ "type": "text",
418
+ "primaryKey": false,
419
+ "notNull": false
420
+ },
421
+ "authorization_code_id": {
422
+ "name": "authorization_code_id",
423
+ "type": "text",
424
+ "primaryKey": false,
425
+ "notNull": false
426
+ },
427
+ "resources": {
428
+ "name": "resources",
429
+ "type": "text[]",
430
+ "primaryKey": false,
431
+ "notNull": false
432
+ },
433
+ "requested_user_info_claims": {
434
+ "name": "requested_user_info_claims",
435
+ "type": "text[]",
436
+ "primaryKey": false,
437
+ "notNull": false
438
+ },
439
+ "refresh_id": {
440
+ "name": "refresh_id",
441
+ "type": "text",
442
+ "primaryKey": false,
443
+ "notNull": false
444
+ },
445
+ "expires_at": {
446
+ "name": "expires_at",
447
+ "type": "timestamp",
448
+ "primaryKey": false,
449
+ "notNull": true
450
+ },
451
+ "created_at": {
452
+ "name": "created_at",
453
+ "type": "timestamp",
454
+ "primaryKey": false,
455
+ "notNull": true
456
+ },
457
+ "revoked": {
458
+ "name": "revoked",
459
+ "type": "timestamp",
460
+ "primaryKey": false,
461
+ "notNull": false
462
+ },
463
+ "confirmation": {
464
+ "name": "confirmation",
465
+ "type": "jsonb",
466
+ "primaryKey": false,
467
+ "notNull": false
468
+ },
469
+ "scopes": {
470
+ "name": "scopes",
471
+ "type": "text[]",
472
+ "primaryKey": false,
473
+ "notNull": true
474
+ }
475
+ },
476
+ "indexes": {
477
+ "oauthAccessToken_clientId_idx": {
478
+ "name": "oauthAccessToken_clientId_idx",
479
+ "columns": [
480
+ {
481
+ "expression": "client_id",
482
+ "isExpression": false,
483
+ "asc": true,
484
+ "nulls": "last"
485
+ }
486
+ ],
487
+ "isUnique": false,
488
+ "concurrently": false,
489
+ "method": "btree",
490
+ "with": {}
491
+ },
492
+ "oauthAccessToken_sessionId_idx": {
493
+ "name": "oauthAccessToken_sessionId_idx",
494
+ "columns": [
495
+ {
496
+ "expression": "session_id",
497
+ "isExpression": false,
498
+ "asc": true,
499
+ "nulls": "last"
500
+ }
501
+ ],
502
+ "isUnique": false,
503
+ "concurrently": false,
504
+ "method": "btree",
505
+ "with": {}
506
+ },
507
+ "oauthAccessToken_userId_idx": {
508
+ "name": "oauthAccessToken_userId_idx",
509
+ "columns": [
510
+ {
511
+ "expression": "user_id",
512
+ "isExpression": false,
513
+ "asc": true,
514
+ "nulls": "last"
515
+ }
516
+ ],
517
+ "isUnique": false,
518
+ "concurrently": false,
519
+ "method": "btree",
520
+ "with": {}
521
+ },
522
+ "oauthAccessToken_authorizationCodeId_idx": {
523
+ "name": "oauthAccessToken_authorizationCodeId_idx",
524
+ "columns": [
525
+ {
526
+ "expression": "authorization_code_id",
527
+ "isExpression": false,
528
+ "asc": true,
529
+ "nulls": "last"
530
+ }
531
+ ],
532
+ "isUnique": false,
533
+ "concurrently": false,
534
+ "method": "btree",
535
+ "with": {}
536
+ },
537
+ "oauthAccessToken_refreshId_idx": {
538
+ "name": "oauthAccessToken_refreshId_idx",
539
+ "columns": [
540
+ {
541
+ "expression": "refresh_id",
542
+ "isExpression": false,
543
+ "asc": true,
544
+ "nulls": "last"
545
+ }
546
+ ],
547
+ "isUnique": false,
548
+ "concurrently": false,
549
+ "method": "btree",
550
+ "with": {}
551
+ }
552
+ },
553
+ "foreignKeys": {
554
+ "oauth_access_token_client_id_oauth_client_client_id_fk": {
555
+ "name": "oauth_access_token_client_id_oauth_client_client_id_fk",
556
+ "tableFrom": "oauth_access_token",
557
+ "tableTo": "oauth_client",
558
+ "columnsFrom": [
559
+ "client_id"
560
+ ],
561
+ "columnsTo": [
562
+ "client_id"
563
+ ],
564
+ "onDelete": "cascade",
565
+ "onUpdate": "no action"
566
+ },
567
+ "oauth_access_token_session_id_session_id_fk": {
568
+ "name": "oauth_access_token_session_id_session_id_fk",
569
+ "tableFrom": "oauth_access_token",
570
+ "tableTo": "session",
571
+ "columnsFrom": [
572
+ "session_id"
573
+ ],
574
+ "columnsTo": [
575
+ "id"
576
+ ],
577
+ "onDelete": "set null",
578
+ "onUpdate": "no action"
579
+ },
580
+ "oauth_access_token_user_id_user_id_fk": {
581
+ "name": "oauth_access_token_user_id_user_id_fk",
582
+ "tableFrom": "oauth_access_token",
583
+ "tableTo": "user",
584
+ "columnsFrom": [
585
+ "user_id"
586
+ ],
587
+ "columnsTo": [
588
+ "id"
589
+ ],
590
+ "onDelete": "cascade",
591
+ "onUpdate": "no action"
592
+ },
593
+ "oauth_access_token_refresh_id_oauth_refresh_token_id_fk": {
594
+ "name": "oauth_access_token_refresh_id_oauth_refresh_token_id_fk",
595
+ "tableFrom": "oauth_access_token",
596
+ "tableTo": "oauth_refresh_token",
597
+ "columnsFrom": [
598
+ "refresh_id"
599
+ ],
600
+ "columnsTo": [
601
+ "id"
602
+ ],
603
+ "onDelete": "cascade",
604
+ "onUpdate": "no action"
605
+ }
606
+ },
607
+ "compositePrimaryKeys": {},
608
+ "uniqueConstraints": {
609
+ "oauth_access_token_token_unique": {
610
+ "name": "oauth_access_token_token_unique",
611
+ "nullsNotDistinct": false,
612
+ "columns": [
613
+ "token"
614
+ ]
615
+ }
616
+ },
617
+ "policies": {},
618
+ "checkConstraints": {},
619
+ "isRLSEnabled": false
620
+ },
621
+ "public.oauth_client": {
622
+ "name": "oauth_client",
623
+ "schema": "",
624
+ "columns": {
625
+ "id": {
626
+ "name": "id",
627
+ "type": "text",
628
+ "primaryKey": true,
629
+ "notNull": true
630
+ },
631
+ "client_id": {
632
+ "name": "client_id",
633
+ "type": "text",
634
+ "primaryKey": false,
635
+ "notNull": true
636
+ },
637
+ "client_secret": {
638
+ "name": "client_secret",
639
+ "type": "text",
640
+ "primaryKey": false,
641
+ "notNull": false
642
+ },
643
+ "client_discovery_id": {
644
+ "name": "client_discovery_id",
645
+ "type": "text",
646
+ "primaryKey": false,
647
+ "notNull": false
648
+ },
649
+ "disabled": {
650
+ "name": "disabled",
651
+ "type": "boolean",
652
+ "primaryKey": false,
653
+ "notNull": false,
654
+ "default": false
655
+ },
656
+ "skip_consent": {
657
+ "name": "skip_consent",
658
+ "type": "boolean",
659
+ "primaryKey": false,
660
+ "notNull": false
661
+ },
662
+ "enable_end_session": {
663
+ "name": "enable_end_session",
664
+ "type": "boolean",
665
+ "primaryKey": false,
666
+ "notNull": false
667
+ },
668
+ "subject_type": {
669
+ "name": "subject_type",
670
+ "type": "text",
671
+ "primaryKey": false,
672
+ "notNull": false
673
+ },
674
+ "scopes": {
675
+ "name": "scopes",
676
+ "type": "text[]",
677
+ "primaryKey": false,
678
+ "notNull": false
679
+ },
680
+ "client_credentials_scopes": {
681
+ "name": "client_credentials_scopes",
682
+ "type": "text[]",
683
+ "primaryKey": false,
684
+ "notNull": false,
685
+ "default": "'{}'"
686
+ },
687
+ "user_id": {
688
+ "name": "user_id",
689
+ "type": "text",
690
+ "primaryKey": false,
691
+ "notNull": false
692
+ },
693
+ "created_at": {
694
+ "name": "created_at",
695
+ "type": "timestamp",
696
+ "primaryKey": false,
697
+ "notNull": false
698
+ },
699
+ "updated_at": {
700
+ "name": "updated_at",
701
+ "type": "timestamp",
702
+ "primaryKey": false,
703
+ "notNull": false
704
+ },
705
+ "name": {
706
+ "name": "name",
707
+ "type": "text",
708
+ "primaryKey": false,
709
+ "notNull": false
710
+ },
711
+ "uri": {
712
+ "name": "uri",
713
+ "type": "text",
714
+ "primaryKey": false,
715
+ "notNull": false
716
+ },
717
+ "icon": {
718
+ "name": "icon",
719
+ "type": "text",
720
+ "primaryKey": false,
721
+ "notNull": false
722
+ },
723
+ "contacts": {
724
+ "name": "contacts",
725
+ "type": "text[]",
726
+ "primaryKey": false,
727
+ "notNull": false
728
+ },
729
+ "tos": {
730
+ "name": "tos",
731
+ "type": "text",
732
+ "primaryKey": false,
733
+ "notNull": false
734
+ },
735
+ "policy": {
736
+ "name": "policy",
737
+ "type": "text",
738
+ "primaryKey": false,
739
+ "notNull": false
740
+ },
741
+ "software_id": {
742
+ "name": "software_id",
743
+ "type": "text",
744
+ "primaryKey": false,
745
+ "notNull": false
746
+ },
747
+ "software_version": {
748
+ "name": "software_version",
749
+ "type": "text",
750
+ "primaryKey": false,
751
+ "notNull": false
752
+ },
753
+ "software_statement": {
754
+ "name": "software_statement",
755
+ "type": "text",
756
+ "primaryKey": false,
757
+ "notNull": false
758
+ },
759
+ "redirect_uris": {
760
+ "name": "redirect_uris",
761
+ "type": "text[]",
762
+ "primaryKey": false,
763
+ "notNull": true
764
+ },
765
+ "post_logout_redirect_uris": {
766
+ "name": "post_logout_redirect_uris",
767
+ "type": "text[]",
768
+ "primaryKey": false,
769
+ "notNull": false
770
+ },
771
+ "backchannel_logout_uri": {
772
+ "name": "backchannel_logout_uri",
773
+ "type": "text",
774
+ "primaryKey": false,
775
+ "notNull": false
776
+ },
777
+ "backchannel_logout_session_required": {
778
+ "name": "backchannel_logout_session_required",
779
+ "type": "boolean",
780
+ "primaryKey": false,
781
+ "notNull": false
782
+ },
783
+ "token_endpoint_auth_method": {
784
+ "name": "token_endpoint_auth_method",
785
+ "type": "text",
786
+ "primaryKey": false,
787
+ "notNull": false
788
+ },
789
+ "application_type": {
790
+ "name": "application_type",
791
+ "type": "text",
792
+ "primaryKey": false,
793
+ "notNull": false
794
+ },
795
+ "jwks": {
796
+ "name": "jwks",
797
+ "type": "text",
798
+ "primaryKey": false,
799
+ "notNull": false
800
+ },
801
+ "jwks_uri": {
802
+ "name": "jwks_uri",
803
+ "type": "text",
804
+ "primaryKey": false,
805
+ "notNull": false
806
+ },
807
+ "grant_types": {
808
+ "name": "grant_types",
809
+ "type": "text[]",
810
+ "primaryKey": false,
811
+ "notNull": false
812
+ },
813
+ "response_types": {
814
+ "name": "response_types",
815
+ "type": "text[]",
816
+ "primaryKey": false,
817
+ "notNull": false
818
+ },
819
+ "require_pkce": {
820
+ "name": "require_pkce",
821
+ "type": "boolean",
822
+ "primaryKey": false,
823
+ "notNull": false
824
+ },
825
+ "dpop_bound_access_tokens": {
826
+ "name": "dpop_bound_access_tokens",
827
+ "type": "boolean",
828
+ "primaryKey": false,
829
+ "notNull": false,
830
+ "default": false
831
+ },
832
+ "reference_id": {
833
+ "name": "reference_id",
834
+ "type": "text",
835
+ "primaryKey": false,
836
+ "notNull": false
837
+ },
838
+ "metadata": {
839
+ "name": "metadata",
840
+ "type": "jsonb",
841
+ "primaryKey": false,
842
+ "notNull": false
843
+ }
844
+ },
845
+ "indexes": {
846
+ "oauthClient_userId_idx": {
847
+ "name": "oauthClient_userId_idx",
848
+ "columns": [
849
+ {
850
+ "expression": "user_id",
851
+ "isExpression": false,
852
+ "asc": true,
853
+ "nulls": "last"
854
+ }
855
+ ],
856
+ "isUnique": false,
857
+ "concurrently": false,
858
+ "method": "btree",
859
+ "with": {}
860
+ }
861
+ },
862
+ "foreignKeys": {
863
+ "oauth_client_user_id_user_id_fk": {
864
+ "name": "oauth_client_user_id_user_id_fk",
865
+ "tableFrom": "oauth_client",
866
+ "tableTo": "user",
867
+ "columnsFrom": [
868
+ "user_id"
869
+ ],
870
+ "columnsTo": [
871
+ "id"
872
+ ],
873
+ "onDelete": "cascade",
874
+ "onUpdate": "no action"
875
+ }
876
+ },
877
+ "compositePrimaryKeys": {},
878
+ "uniqueConstraints": {
879
+ "oauth_client_client_id_unique": {
880
+ "name": "oauth_client_client_id_unique",
881
+ "nullsNotDistinct": false,
882
+ "columns": [
883
+ "client_id"
884
+ ]
885
+ }
886
+ },
887
+ "policies": {},
888
+ "checkConstraints": {},
889
+ "isRLSEnabled": false
890
+ },
891
+ "public.oauth_client_assertion": {
892
+ "name": "oauth_client_assertion",
893
+ "schema": "",
894
+ "columns": {
895
+ "id": {
896
+ "name": "id",
897
+ "type": "text",
898
+ "primaryKey": true,
899
+ "notNull": true
900
+ },
901
+ "expires_at": {
902
+ "name": "expires_at",
903
+ "type": "timestamp",
904
+ "primaryKey": false,
905
+ "notNull": true
906
+ }
907
+ },
908
+ "indexes": {},
909
+ "foreignKeys": {},
910
+ "compositePrimaryKeys": {},
911
+ "uniqueConstraints": {},
912
+ "policies": {},
913
+ "checkConstraints": {},
914
+ "isRLSEnabled": false
915
+ },
916
+ "public.oauth_client_resource": {
917
+ "name": "oauth_client_resource",
918
+ "schema": "",
919
+ "columns": {
920
+ "id": {
921
+ "name": "id",
922
+ "type": "text",
923
+ "primaryKey": true,
924
+ "notNull": true
925
+ },
926
+ "client_id": {
927
+ "name": "client_id",
928
+ "type": "text",
929
+ "primaryKey": false,
930
+ "notNull": true
931
+ },
932
+ "resource_id": {
933
+ "name": "resource_id",
934
+ "type": "text",
935
+ "primaryKey": false,
936
+ "notNull": true
937
+ },
938
+ "metadata": {
939
+ "name": "metadata",
940
+ "type": "jsonb",
941
+ "primaryKey": false,
942
+ "notNull": false
943
+ },
944
+ "created_at": {
945
+ "name": "created_at",
946
+ "type": "timestamp",
947
+ "primaryKey": false,
948
+ "notNull": false
949
+ }
950
+ },
951
+ "indexes": {
952
+ "oauthClientResource_clientId_resourceId_uidx": {
953
+ "name": "oauthClientResource_clientId_resourceId_uidx",
954
+ "columns": [
955
+ {
956
+ "expression": "client_id",
957
+ "isExpression": false,
958
+ "asc": true,
959
+ "nulls": "last"
960
+ },
961
+ {
962
+ "expression": "resource_id",
963
+ "isExpression": false,
964
+ "asc": true,
965
+ "nulls": "last"
966
+ }
967
+ ],
968
+ "isUnique": true,
969
+ "concurrently": false,
970
+ "method": "btree",
971
+ "with": {}
972
+ },
973
+ "oauthClientResource_clientId_idx": {
974
+ "name": "oauthClientResource_clientId_idx",
975
+ "columns": [
976
+ {
977
+ "expression": "client_id",
978
+ "isExpression": false,
979
+ "asc": true,
980
+ "nulls": "last"
981
+ }
982
+ ],
983
+ "isUnique": false,
984
+ "concurrently": false,
985
+ "method": "btree",
986
+ "with": {}
987
+ },
988
+ "oauthClientResource_resourceId_idx": {
989
+ "name": "oauthClientResource_resourceId_idx",
990
+ "columns": [
991
+ {
992
+ "expression": "resource_id",
993
+ "isExpression": false,
994
+ "asc": true,
995
+ "nulls": "last"
996
+ }
997
+ ],
998
+ "isUnique": false,
999
+ "concurrently": false,
1000
+ "method": "btree",
1001
+ "with": {}
1002
+ }
1003
+ },
1004
+ "foreignKeys": {
1005
+ "oauth_client_resource_client_id_oauth_client_client_id_fk": {
1006
+ "name": "oauth_client_resource_client_id_oauth_client_client_id_fk",
1007
+ "tableFrom": "oauth_client_resource",
1008
+ "tableTo": "oauth_client",
1009
+ "columnsFrom": [
1010
+ "client_id"
1011
+ ],
1012
+ "columnsTo": [
1013
+ "client_id"
1014
+ ],
1015
+ "onDelete": "cascade",
1016
+ "onUpdate": "no action"
1017
+ },
1018
+ "oauth_client_resource_resource_id_oauth_resource_identifier_fk": {
1019
+ "name": "oauth_client_resource_resource_id_oauth_resource_identifier_fk",
1020
+ "tableFrom": "oauth_client_resource",
1021
+ "tableTo": "oauth_resource",
1022
+ "columnsFrom": [
1023
+ "resource_id"
1024
+ ],
1025
+ "columnsTo": [
1026
+ "identifier"
1027
+ ],
1028
+ "onDelete": "cascade",
1029
+ "onUpdate": "no action"
1030
+ }
1031
+ },
1032
+ "compositePrimaryKeys": {},
1033
+ "uniqueConstraints": {},
1034
+ "policies": {},
1035
+ "checkConstraints": {},
1036
+ "isRLSEnabled": false
1037
+ },
1038
+ "public.oauth_consent": {
1039
+ "name": "oauth_consent",
1040
+ "schema": "",
1041
+ "columns": {
1042
+ "id": {
1043
+ "name": "id",
1044
+ "type": "text",
1045
+ "primaryKey": true,
1046
+ "notNull": true
1047
+ },
1048
+ "client_id": {
1049
+ "name": "client_id",
1050
+ "type": "text",
1051
+ "primaryKey": false,
1052
+ "notNull": true
1053
+ },
1054
+ "user_id": {
1055
+ "name": "user_id",
1056
+ "type": "text",
1057
+ "primaryKey": false,
1058
+ "notNull": false
1059
+ },
1060
+ "reference_id": {
1061
+ "name": "reference_id",
1062
+ "type": "text",
1063
+ "primaryKey": false,
1064
+ "notNull": false
1065
+ },
1066
+ "resources": {
1067
+ "name": "resources",
1068
+ "type": "text[]",
1069
+ "primaryKey": false,
1070
+ "notNull": false
1071
+ },
1072
+ "requested_user_info_claims": {
1073
+ "name": "requested_user_info_claims",
1074
+ "type": "text[]",
1075
+ "primaryKey": false,
1076
+ "notNull": false
1077
+ },
1078
+ "scopes": {
1079
+ "name": "scopes",
1080
+ "type": "text[]",
1081
+ "primaryKey": false,
1082
+ "notNull": true
1083
+ },
1084
+ "created_at": {
1085
+ "name": "created_at",
1086
+ "type": "timestamp",
1087
+ "primaryKey": false,
1088
+ "notNull": true
1089
+ },
1090
+ "updated_at": {
1091
+ "name": "updated_at",
1092
+ "type": "timestamp",
1093
+ "primaryKey": false,
1094
+ "notNull": true
1095
+ }
1096
+ },
1097
+ "indexes": {
1098
+ "oauthConsent_clientId_idx": {
1099
+ "name": "oauthConsent_clientId_idx",
1100
+ "columns": [
1101
+ {
1102
+ "expression": "client_id",
1103
+ "isExpression": false,
1104
+ "asc": true,
1105
+ "nulls": "last"
1106
+ }
1107
+ ],
1108
+ "isUnique": false,
1109
+ "concurrently": false,
1110
+ "method": "btree",
1111
+ "with": {}
1112
+ },
1113
+ "oauthConsent_userId_idx": {
1114
+ "name": "oauthConsent_userId_idx",
1115
+ "columns": [
1116
+ {
1117
+ "expression": "user_id",
1118
+ "isExpression": false,
1119
+ "asc": true,
1120
+ "nulls": "last"
1121
+ }
1122
+ ],
1123
+ "isUnique": false,
1124
+ "concurrently": false,
1125
+ "method": "btree",
1126
+ "with": {}
1127
+ }
1128
+ },
1129
+ "foreignKeys": {
1130
+ "oauth_consent_client_id_oauth_client_client_id_fk": {
1131
+ "name": "oauth_consent_client_id_oauth_client_client_id_fk",
1132
+ "tableFrom": "oauth_consent",
1133
+ "tableTo": "oauth_client",
1134
+ "columnsFrom": [
1135
+ "client_id"
1136
+ ],
1137
+ "columnsTo": [
1138
+ "client_id"
1139
+ ],
1140
+ "onDelete": "cascade",
1141
+ "onUpdate": "no action"
1142
+ },
1143
+ "oauth_consent_user_id_user_id_fk": {
1144
+ "name": "oauth_consent_user_id_user_id_fk",
1145
+ "tableFrom": "oauth_consent",
1146
+ "tableTo": "user",
1147
+ "columnsFrom": [
1148
+ "user_id"
1149
+ ],
1150
+ "columnsTo": [
1151
+ "id"
1152
+ ],
1153
+ "onDelete": "cascade",
1154
+ "onUpdate": "no action"
1155
+ }
1156
+ },
1157
+ "compositePrimaryKeys": {},
1158
+ "uniqueConstraints": {},
1159
+ "policies": {},
1160
+ "checkConstraints": {},
1161
+ "isRLSEnabled": false
1162
+ },
1163
+ "public.oauth_refresh_token": {
1164
+ "name": "oauth_refresh_token",
1165
+ "schema": "",
1166
+ "columns": {
1167
+ "id": {
1168
+ "name": "id",
1169
+ "type": "text",
1170
+ "primaryKey": true,
1171
+ "notNull": true
1172
+ },
1173
+ "token": {
1174
+ "name": "token",
1175
+ "type": "text",
1176
+ "primaryKey": false,
1177
+ "notNull": true
1178
+ },
1179
+ "client_id": {
1180
+ "name": "client_id",
1181
+ "type": "text",
1182
+ "primaryKey": false,
1183
+ "notNull": true
1184
+ },
1185
+ "session_id": {
1186
+ "name": "session_id",
1187
+ "type": "text",
1188
+ "primaryKey": false,
1189
+ "notNull": false
1190
+ },
1191
+ "user_id": {
1192
+ "name": "user_id",
1193
+ "type": "text",
1194
+ "primaryKey": false,
1195
+ "notNull": true
1196
+ },
1197
+ "reference_id": {
1198
+ "name": "reference_id",
1199
+ "type": "text",
1200
+ "primaryKey": false,
1201
+ "notNull": false
1202
+ },
1203
+ "authorization_code_id": {
1204
+ "name": "authorization_code_id",
1205
+ "type": "text",
1206
+ "primaryKey": false,
1207
+ "notNull": false
1208
+ },
1209
+ "resources": {
1210
+ "name": "resources",
1211
+ "type": "text[]",
1212
+ "primaryKey": false,
1213
+ "notNull": false
1214
+ },
1215
+ "requested_user_info_claims": {
1216
+ "name": "requested_user_info_claims",
1217
+ "type": "text[]",
1218
+ "primaryKey": false,
1219
+ "notNull": false
1220
+ },
1221
+ "expires_at": {
1222
+ "name": "expires_at",
1223
+ "type": "timestamp",
1224
+ "primaryKey": false,
1225
+ "notNull": true
1226
+ },
1227
+ "created_at": {
1228
+ "name": "created_at",
1229
+ "type": "timestamp",
1230
+ "primaryKey": false,
1231
+ "notNull": true
1232
+ },
1233
+ "revoked": {
1234
+ "name": "revoked",
1235
+ "type": "timestamp",
1236
+ "primaryKey": false,
1237
+ "notNull": false
1238
+ },
1239
+ "rotated_at": {
1240
+ "name": "rotated_at",
1241
+ "type": "timestamp",
1242
+ "primaryKey": false,
1243
+ "notNull": false
1244
+ },
1245
+ "rotation_replay_response": {
1246
+ "name": "rotation_replay_response",
1247
+ "type": "text",
1248
+ "primaryKey": false,
1249
+ "notNull": false
1250
+ },
1251
+ "rotation_replay_expires_at": {
1252
+ "name": "rotation_replay_expires_at",
1253
+ "type": "timestamp",
1254
+ "primaryKey": false,
1255
+ "notNull": false
1256
+ },
1257
+ "auth_time": {
1258
+ "name": "auth_time",
1259
+ "type": "timestamp",
1260
+ "primaryKey": false,
1261
+ "notNull": false
1262
+ },
1263
+ "confirmation": {
1264
+ "name": "confirmation",
1265
+ "type": "jsonb",
1266
+ "primaryKey": false,
1267
+ "notNull": false
1268
+ },
1269
+ "scopes": {
1270
+ "name": "scopes",
1271
+ "type": "text[]",
1272
+ "primaryKey": false,
1273
+ "notNull": true
1274
+ }
1275
+ },
1276
+ "indexes": {
1277
+ "oauthRefreshToken_clientId_idx": {
1278
+ "name": "oauthRefreshToken_clientId_idx",
1279
+ "columns": [
1280
+ {
1281
+ "expression": "client_id",
1282
+ "isExpression": false,
1283
+ "asc": true,
1284
+ "nulls": "last"
1285
+ }
1286
+ ],
1287
+ "isUnique": false,
1288
+ "concurrently": false,
1289
+ "method": "btree",
1290
+ "with": {}
1291
+ },
1292
+ "oauthRefreshToken_sessionId_idx": {
1293
+ "name": "oauthRefreshToken_sessionId_idx",
1294
+ "columns": [
1295
+ {
1296
+ "expression": "session_id",
1297
+ "isExpression": false,
1298
+ "asc": true,
1299
+ "nulls": "last"
1300
+ }
1301
+ ],
1302
+ "isUnique": false,
1303
+ "concurrently": false,
1304
+ "method": "btree",
1305
+ "with": {}
1306
+ },
1307
+ "oauthRefreshToken_userId_idx": {
1308
+ "name": "oauthRefreshToken_userId_idx",
1309
+ "columns": [
1310
+ {
1311
+ "expression": "user_id",
1312
+ "isExpression": false,
1313
+ "asc": true,
1314
+ "nulls": "last"
1315
+ }
1316
+ ],
1317
+ "isUnique": false,
1318
+ "concurrently": false,
1319
+ "method": "btree",
1320
+ "with": {}
1321
+ },
1322
+ "oauthRefreshToken_authorizationCodeId_idx": {
1323
+ "name": "oauthRefreshToken_authorizationCodeId_idx",
1324
+ "columns": [
1325
+ {
1326
+ "expression": "authorization_code_id",
1327
+ "isExpression": false,
1328
+ "asc": true,
1329
+ "nulls": "last"
1330
+ }
1331
+ ],
1332
+ "isUnique": false,
1333
+ "concurrently": false,
1334
+ "method": "btree",
1335
+ "with": {}
1336
+ }
1337
+ },
1338
+ "foreignKeys": {
1339
+ "oauth_refresh_token_client_id_oauth_client_client_id_fk": {
1340
+ "name": "oauth_refresh_token_client_id_oauth_client_client_id_fk",
1341
+ "tableFrom": "oauth_refresh_token",
1342
+ "tableTo": "oauth_client",
1343
+ "columnsFrom": [
1344
+ "client_id"
1345
+ ],
1346
+ "columnsTo": [
1347
+ "client_id"
1348
+ ],
1349
+ "onDelete": "cascade",
1350
+ "onUpdate": "no action"
1351
+ },
1352
+ "oauth_refresh_token_session_id_session_id_fk": {
1353
+ "name": "oauth_refresh_token_session_id_session_id_fk",
1354
+ "tableFrom": "oauth_refresh_token",
1355
+ "tableTo": "session",
1356
+ "columnsFrom": [
1357
+ "session_id"
1358
+ ],
1359
+ "columnsTo": [
1360
+ "id"
1361
+ ],
1362
+ "onDelete": "set null",
1363
+ "onUpdate": "no action"
1364
+ },
1365
+ "oauth_refresh_token_user_id_user_id_fk": {
1366
+ "name": "oauth_refresh_token_user_id_user_id_fk",
1367
+ "tableFrom": "oauth_refresh_token",
1368
+ "tableTo": "user",
1369
+ "columnsFrom": [
1370
+ "user_id"
1371
+ ],
1372
+ "columnsTo": [
1373
+ "id"
1374
+ ],
1375
+ "onDelete": "cascade",
1376
+ "onUpdate": "no action"
1377
+ }
1378
+ },
1379
+ "compositePrimaryKeys": {},
1380
+ "uniqueConstraints": {
1381
+ "oauth_refresh_token_token_unique": {
1382
+ "name": "oauth_refresh_token_token_unique",
1383
+ "nullsNotDistinct": false,
1384
+ "columns": [
1385
+ "token"
1386
+ ]
1387
+ }
1388
+ },
1389
+ "policies": {},
1390
+ "checkConstraints": {},
1391
+ "isRLSEnabled": false
1392
+ },
1393
+ "public.oauth_resource": {
1394
+ "name": "oauth_resource",
1395
+ "schema": "",
1396
+ "columns": {
1397
+ "id": {
1398
+ "name": "id",
1399
+ "type": "text",
1400
+ "primaryKey": true,
1401
+ "notNull": true
1402
+ },
1403
+ "identifier": {
1404
+ "name": "identifier",
1405
+ "type": "text",
1406
+ "primaryKey": false,
1407
+ "notNull": true
1408
+ },
1409
+ "name": {
1410
+ "name": "name",
1411
+ "type": "text",
1412
+ "primaryKey": false,
1413
+ "notNull": true
1414
+ },
1415
+ "access_token_ttl": {
1416
+ "name": "access_token_ttl",
1417
+ "type": "integer",
1418
+ "primaryKey": false,
1419
+ "notNull": false
1420
+ },
1421
+ "refresh_token_ttl": {
1422
+ "name": "refresh_token_ttl",
1423
+ "type": "integer",
1424
+ "primaryKey": false,
1425
+ "notNull": false
1426
+ },
1427
+ "signing_algorithm": {
1428
+ "name": "signing_algorithm",
1429
+ "type": "text",
1430
+ "primaryKey": false,
1431
+ "notNull": false
1432
+ },
1433
+ "signing_key_id": {
1434
+ "name": "signing_key_id",
1435
+ "type": "text",
1436
+ "primaryKey": false,
1437
+ "notNull": false
1438
+ },
1439
+ "allowed_scopes": {
1440
+ "name": "allowed_scopes",
1441
+ "type": "text[]",
1442
+ "primaryKey": false,
1443
+ "notNull": false
1444
+ },
1445
+ "custom_claims": {
1446
+ "name": "custom_claims",
1447
+ "type": "jsonb",
1448
+ "primaryKey": false,
1449
+ "notNull": false
1450
+ },
1451
+ "dpop_bound_access_tokens_required": {
1452
+ "name": "dpop_bound_access_tokens_required",
1453
+ "type": "boolean",
1454
+ "primaryKey": false,
1455
+ "notNull": false,
1456
+ "default": false
1457
+ },
1458
+ "disabled": {
1459
+ "name": "disabled",
1460
+ "type": "boolean",
1461
+ "primaryKey": false,
1462
+ "notNull": false,
1463
+ "default": false
1464
+ },
1465
+ "created_at": {
1466
+ "name": "created_at",
1467
+ "type": "timestamp",
1468
+ "primaryKey": false,
1469
+ "notNull": false
1470
+ },
1471
+ "updated_at": {
1472
+ "name": "updated_at",
1473
+ "type": "timestamp",
1474
+ "primaryKey": false,
1475
+ "notNull": false
1476
+ },
1477
+ "policy_version": {
1478
+ "name": "policy_version",
1479
+ "type": "integer",
1480
+ "primaryKey": false,
1481
+ "notNull": false,
1482
+ "default": 1
1483
+ },
1484
+ "metadata": {
1485
+ "name": "metadata",
1486
+ "type": "jsonb",
1487
+ "primaryKey": false,
1488
+ "notNull": false
1489
+ }
1490
+ },
1491
+ "indexes": {},
1492
+ "foreignKeys": {},
1493
+ "compositePrimaryKeys": {},
1494
+ "uniqueConstraints": {
1495
+ "oauth_resource_identifier_unique": {
1496
+ "name": "oauth_resource_identifier_unique",
1497
+ "nullsNotDistinct": false,
1498
+ "columns": [
1499
+ "identifier"
1500
+ ]
1501
+ }
1502
+ },
1503
+ "policies": {},
1504
+ "checkConstraints": {},
1505
+ "isRLSEnabled": false
1506
+ },
1507
+ "public.session": {
1508
+ "name": "session",
1509
+ "schema": "",
1510
+ "columns": {
1511
+ "id": {
1512
+ "name": "id",
1513
+ "type": "text",
1514
+ "primaryKey": true,
1515
+ "notNull": true
1516
+ },
1517
+ "expires_at": {
1518
+ "name": "expires_at",
1519
+ "type": "timestamp",
1520
+ "primaryKey": false,
1521
+ "notNull": true
1522
+ },
1523
+ "token": {
1524
+ "name": "token",
1525
+ "type": "text",
1526
+ "primaryKey": false,
1527
+ "notNull": true
1528
+ },
1529
+ "created_at": {
1530
+ "name": "created_at",
1531
+ "type": "timestamp",
1532
+ "primaryKey": false,
1533
+ "notNull": true,
1534
+ "default": "now()"
1535
+ },
1536
+ "updated_at": {
1537
+ "name": "updated_at",
1538
+ "type": "timestamp",
1539
+ "primaryKey": false,
1540
+ "notNull": true
1541
+ },
1542
+ "ip_address": {
1543
+ "name": "ip_address",
1544
+ "type": "text",
1545
+ "primaryKey": false,
1546
+ "notNull": false
1547
+ },
1548
+ "user_agent": {
1549
+ "name": "user_agent",
1550
+ "type": "text",
1551
+ "primaryKey": false,
1552
+ "notNull": false
1553
+ },
1554
+ "user_id": {
1555
+ "name": "user_id",
1556
+ "type": "text",
1557
+ "primaryKey": false,
1558
+ "notNull": true
1559
+ },
1560
+ "impersonated_by": {
1561
+ "name": "impersonated_by",
1562
+ "type": "text",
1563
+ "primaryKey": false,
1564
+ "notNull": false
1565
+ }
1566
+ },
1567
+ "indexes": {
1568
+ "session_userId_idx": {
1569
+ "name": "session_userId_idx",
1570
+ "columns": [
1571
+ {
1572
+ "expression": "user_id",
1573
+ "isExpression": false,
1574
+ "asc": true,
1575
+ "nulls": "last"
1576
+ }
1577
+ ],
1578
+ "isUnique": false,
1579
+ "concurrently": false,
1580
+ "method": "btree",
1581
+ "with": {}
1582
+ }
1583
+ },
1584
+ "foreignKeys": {
1585
+ "session_user_id_user_id_fk": {
1586
+ "name": "session_user_id_user_id_fk",
1587
+ "tableFrom": "session",
1588
+ "tableTo": "user",
1589
+ "columnsFrom": [
1590
+ "user_id"
1591
+ ],
1592
+ "columnsTo": [
1593
+ "id"
1594
+ ],
1595
+ "onDelete": "cascade",
1596
+ "onUpdate": "no action"
1597
+ }
1598
+ },
1599
+ "compositePrimaryKeys": {},
1600
+ "uniqueConstraints": {
1601
+ "session_token_unique": {
1602
+ "name": "session_token_unique",
1603
+ "nullsNotDistinct": false,
1604
+ "columns": [
1605
+ "token"
1606
+ ]
1607
+ }
1608
+ },
1609
+ "policies": {},
1610
+ "checkConstraints": {},
1611
+ "isRLSEnabled": false
1612
+ },
1613
+ "public.user": {
1614
+ "name": "user",
1615
+ "schema": "",
1616
+ "columns": {
1617
+ "id": {
1618
+ "name": "id",
1619
+ "type": "text",
1620
+ "primaryKey": true,
1621
+ "notNull": true
1622
+ },
1623
+ "name": {
1624
+ "name": "name",
1625
+ "type": "text",
1626
+ "primaryKey": false,
1627
+ "notNull": true
1628
+ },
1629
+ "email": {
1630
+ "name": "email",
1631
+ "type": "text",
1632
+ "primaryKey": false,
1633
+ "notNull": true
1634
+ },
1635
+ "email_verified": {
1636
+ "name": "email_verified",
1637
+ "type": "boolean",
1638
+ "primaryKey": false,
1639
+ "notNull": true,
1640
+ "default": false
1641
+ },
1642
+ "image": {
1643
+ "name": "image",
1644
+ "type": "text",
1645
+ "primaryKey": false,
1646
+ "notNull": false
1647
+ },
1648
+ "created_at": {
1649
+ "name": "created_at",
1650
+ "type": "timestamp",
1651
+ "primaryKey": false,
1652
+ "notNull": true,
1653
+ "default": "now()"
1654
+ },
1655
+ "updated_at": {
1656
+ "name": "updated_at",
1657
+ "type": "timestamp",
1658
+ "primaryKey": false,
1659
+ "notNull": true,
1660
+ "default": "now()"
1661
+ },
1662
+ "role": {
1663
+ "name": "role",
1664
+ "type": "text",
1665
+ "primaryKey": false,
1666
+ "notNull": false
1667
+ },
1668
+ "banned": {
1669
+ "name": "banned",
1670
+ "type": "boolean",
1671
+ "primaryKey": false,
1672
+ "notNull": false,
1673
+ "default": false
1674
+ },
1675
+ "ban_reason": {
1676
+ "name": "ban_reason",
1677
+ "type": "text",
1678
+ "primaryKey": false,
1679
+ "notNull": false
1680
+ },
1681
+ "ban_expires": {
1682
+ "name": "ban_expires",
1683
+ "type": "timestamp",
1684
+ "primaryKey": false,
1685
+ "notNull": false
1686
+ }
1687
+ },
1688
+ "indexes": {},
1689
+ "foreignKeys": {},
1690
+ "compositePrimaryKeys": {},
1691
+ "uniqueConstraints": {
1692
+ "user_email_unique": {
1693
+ "name": "user_email_unique",
1694
+ "nullsNotDistinct": false,
1695
+ "columns": [
1696
+ "email"
1697
+ ]
1698
+ }
1699
+ },
1700
+ "policies": {},
1701
+ "checkConstraints": {},
1702
+ "isRLSEnabled": false
1703
+ },
1704
+ "public.verification": {
1705
+ "name": "verification",
1706
+ "schema": "",
1707
+ "columns": {
1708
+ "id": {
1709
+ "name": "id",
1710
+ "type": "text",
1711
+ "primaryKey": true,
1712
+ "notNull": true
1713
+ },
1714
+ "identifier": {
1715
+ "name": "identifier",
1716
+ "type": "text",
1717
+ "primaryKey": false,
1718
+ "notNull": true
1719
+ },
1720
+ "value": {
1721
+ "name": "value",
1722
+ "type": "text",
1723
+ "primaryKey": false,
1724
+ "notNull": true
1725
+ },
1726
+ "expires_at": {
1727
+ "name": "expires_at",
1728
+ "type": "timestamp",
1729
+ "primaryKey": false,
1730
+ "notNull": true
1731
+ },
1732
+ "created_at": {
1733
+ "name": "created_at",
1734
+ "type": "timestamp",
1735
+ "primaryKey": false,
1736
+ "notNull": true,
1737
+ "default": "now()"
1738
+ },
1739
+ "updated_at": {
1740
+ "name": "updated_at",
1741
+ "type": "timestamp",
1742
+ "primaryKey": false,
1743
+ "notNull": true,
1744
+ "default": "now()"
1745
+ }
1746
+ },
1747
+ "indexes": {
1748
+ "verification_identifier_idx": {
1749
+ "name": "verification_identifier_idx",
1750
+ "columns": [
1751
+ {
1752
+ "expression": "identifier",
1753
+ "isExpression": false,
1754
+ "asc": true,
1755
+ "nulls": "last"
1756
+ }
1757
+ ],
1758
+ "isUnique": false,
1759
+ "concurrently": false,
1760
+ "method": "btree",
1761
+ "with": {}
1762
+ }
1763
+ },
1764
+ "foreignKeys": {},
1765
+ "compositePrimaryKeys": {},
1766
+ "uniqueConstraints": {},
1767
+ "policies": {},
1768
+ "checkConstraints": {},
1769
+ "isRLSEnabled": false
1770
+ },
1771
+ "public.attachments": {
1772
+ "name": "attachments",
1773
+ "schema": "",
1774
+ "columns": {
1775
+ "id": {
1776
+ "name": "id",
1777
+ "type": "uuid",
1778
+ "primaryKey": true,
1779
+ "notNull": true,
1780
+ "default": "gen_random_uuid()"
1781
+ },
1782
+ "project_id": {
1783
+ "name": "project_id",
1784
+ "type": "uuid",
1785
+ "primaryKey": false,
1786
+ "notNull": true
1787
+ },
1788
+ "ticket_id": {
1789
+ "name": "ticket_id",
1790
+ "type": "uuid",
1791
+ "primaryKey": false,
1792
+ "notNull": true
1793
+ },
1794
+ "actor_id": {
1795
+ "name": "actor_id",
1796
+ "type": "text",
1797
+ "primaryKey": false,
1798
+ "notNull": true
1799
+ },
1800
+ "name": {
1801
+ "name": "name",
1802
+ "type": "text",
1803
+ "primaryKey": false,
1804
+ "notNull": true
1805
+ },
1806
+ "content_type": {
1807
+ "name": "content_type",
1808
+ "type": "text",
1809
+ "primaryKey": false,
1810
+ "notNull": true
1811
+ },
1812
+ "size": {
1813
+ "name": "size",
1814
+ "type": "integer",
1815
+ "primaryKey": false,
1816
+ "notNull": true
1817
+ },
1818
+ "created_at": {
1819
+ "name": "created_at",
1820
+ "type": "timestamp with time zone",
1821
+ "primaryKey": false,
1822
+ "notNull": true,
1823
+ "default": "now()"
1824
+ }
1825
+ },
1826
+ "indexes": {},
1827
+ "foreignKeys": {
1828
+ "attachments_project_id_projects_id_fk": {
1829
+ "name": "attachments_project_id_projects_id_fk",
1830
+ "tableFrom": "attachments",
1831
+ "tableTo": "projects",
1832
+ "columnsFrom": [
1833
+ "project_id"
1834
+ ],
1835
+ "columnsTo": [
1836
+ "id"
1837
+ ],
1838
+ "onDelete": "cascade",
1839
+ "onUpdate": "no action"
1840
+ },
1841
+ "attachments_ticket_id_tickets_id_fk": {
1842
+ "name": "attachments_ticket_id_tickets_id_fk",
1843
+ "tableFrom": "attachments",
1844
+ "tableTo": "tickets",
1845
+ "columnsFrom": [
1846
+ "ticket_id"
1847
+ ],
1848
+ "columnsTo": [
1849
+ "id"
1850
+ ],
1851
+ "onDelete": "cascade",
1852
+ "onUpdate": "no action"
1853
+ },
1854
+ "attachments_actor_id_user_id_fk": {
1855
+ "name": "attachments_actor_id_user_id_fk",
1856
+ "tableFrom": "attachments",
1857
+ "tableTo": "user",
1858
+ "columnsFrom": [
1859
+ "actor_id"
1860
+ ],
1861
+ "columnsTo": [
1862
+ "id"
1863
+ ],
1864
+ "onDelete": "no action",
1865
+ "onUpdate": "no action"
1866
+ }
1867
+ },
1868
+ "compositePrimaryKeys": {},
1869
+ "uniqueConstraints": {},
1870
+ "policies": {},
1871
+ "checkConstraints": {},
1872
+ "isRLSEnabled": false
1873
+ },
1874
+ "public.claims": {
1875
+ "name": "claims",
1876
+ "schema": "",
1877
+ "columns": {
1878
+ "id": {
1879
+ "name": "id",
1880
+ "type": "uuid",
1881
+ "primaryKey": true,
1882
+ "notNull": true,
1883
+ "default": "gen_random_uuid()"
1884
+ },
1885
+ "project_id": {
1886
+ "name": "project_id",
1887
+ "type": "uuid",
1888
+ "primaryKey": false,
1889
+ "notNull": true
1890
+ },
1891
+ "ticket_id": {
1892
+ "name": "ticket_id",
1893
+ "type": "uuid",
1894
+ "primaryKey": false,
1895
+ "notNull": true
1896
+ },
1897
+ "actor_id": {
1898
+ "name": "actor_id",
1899
+ "type": "text",
1900
+ "primaryKey": false,
1901
+ "notNull": true
1902
+ },
1903
+ "worker_id": {
1904
+ "name": "worker_id",
1905
+ "type": "text",
1906
+ "primaryKey": false,
1907
+ "notNull": true
1908
+ },
1909
+ "expires_at": {
1910
+ "name": "expires_at",
1911
+ "type": "timestamp with time zone",
1912
+ "primaryKey": false,
1913
+ "notNull": true
1914
+ },
1915
+ "created_at": {
1916
+ "name": "created_at",
1917
+ "type": "timestamp with time zone",
1918
+ "primaryKey": false,
1919
+ "notNull": true,
1920
+ "default": "now()"
1921
+ }
1922
+ },
1923
+ "indexes": {},
1924
+ "foreignKeys": {
1925
+ "claims_project_id_projects_id_fk": {
1926
+ "name": "claims_project_id_projects_id_fk",
1927
+ "tableFrom": "claims",
1928
+ "tableTo": "projects",
1929
+ "columnsFrom": [
1930
+ "project_id"
1931
+ ],
1932
+ "columnsTo": [
1933
+ "id"
1934
+ ],
1935
+ "onDelete": "cascade",
1936
+ "onUpdate": "no action"
1937
+ },
1938
+ "claims_ticket_id_tickets_id_fk": {
1939
+ "name": "claims_ticket_id_tickets_id_fk",
1940
+ "tableFrom": "claims",
1941
+ "tableTo": "tickets",
1942
+ "columnsFrom": [
1943
+ "ticket_id"
1944
+ ],
1945
+ "columnsTo": [
1946
+ "id"
1947
+ ],
1948
+ "onDelete": "cascade",
1949
+ "onUpdate": "no action"
1950
+ },
1951
+ "claims_actor_id_user_id_fk": {
1952
+ "name": "claims_actor_id_user_id_fk",
1953
+ "tableFrom": "claims",
1954
+ "tableTo": "user",
1955
+ "columnsFrom": [
1956
+ "actor_id"
1957
+ ],
1958
+ "columnsTo": [
1959
+ "id"
1960
+ ],
1961
+ "onDelete": "no action",
1962
+ "onUpdate": "no action"
1963
+ }
1964
+ },
1965
+ "compositePrimaryKeys": {},
1966
+ "uniqueConstraints": {
1967
+ "claims_ticket_id_unique": {
1968
+ "name": "claims_ticket_id_unique",
1969
+ "nullsNotDistinct": false,
1970
+ "columns": [
1971
+ "ticket_id"
1972
+ ]
1973
+ }
1974
+ },
1975
+ "policies": {},
1976
+ "checkConstraints": {},
1977
+ "isRLSEnabled": false
1978
+ },
1979
+ "public.comments": {
1980
+ "name": "comments",
1981
+ "schema": "",
1982
+ "columns": {
1983
+ "id": {
1984
+ "name": "id",
1985
+ "type": "uuid",
1986
+ "primaryKey": true,
1987
+ "notNull": true,
1988
+ "default": "gen_random_uuid()"
1989
+ },
1990
+ "project_id": {
1991
+ "name": "project_id",
1992
+ "type": "uuid",
1993
+ "primaryKey": false,
1994
+ "notNull": true
1995
+ },
1996
+ "ticket_id": {
1997
+ "name": "ticket_id",
1998
+ "type": "uuid",
1999
+ "primaryKey": false,
2000
+ "notNull": true
2001
+ },
2002
+ "actor_id": {
2003
+ "name": "actor_id",
2004
+ "type": "text",
2005
+ "primaryKey": false,
2006
+ "notNull": true
2007
+ },
2008
+ "body": {
2009
+ "name": "body",
2010
+ "type": "text",
2011
+ "primaryKey": false,
2012
+ "notNull": true
2013
+ },
2014
+ "version": {
2015
+ "name": "version",
2016
+ "type": "integer",
2017
+ "primaryKey": false,
2018
+ "notNull": true,
2019
+ "default": 1
2020
+ },
2021
+ "created_at": {
2022
+ "name": "created_at",
2023
+ "type": "timestamp with time zone",
2024
+ "primaryKey": false,
2025
+ "notNull": true,
2026
+ "default": "now()"
2027
+ },
2028
+ "updated_at": {
2029
+ "name": "updated_at",
2030
+ "type": "timestamp with time zone",
2031
+ "primaryKey": false,
2032
+ "notNull": true,
2033
+ "default": "now()"
2034
+ }
2035
+ },
2036
+ "indexes": {
2037
+ "comment_ticket": {
2038
+ "name": "comment_ticket",
2039
+ "columns": [
2040
+ {
2041
+ "expression": "ticket_id",
2042
+ "isExpression": false,
2043
+ "asc": true,
2044
+ "nulls": "last"
2045
+ }
2046
+ ],
2047
+ "isUnique": false,
2048
+ "concurrently": false,
2049
+ "method": "btree",
2050
+ "with": {}
2051
+ }
2052
+ },
2053
+ "foreignKeys": {
2054
+ "comments_project_id_projects_id_fk": {
2055
+ "name": "comments_project_id_projects_id_fk",
2056
+ "tableFrom": "comments",
2057
+ "tableTo": "projects",
2058
+ "columnsFrom": [
2059
+ "project_id"
2060
+ ],
2061
+ "columnsTo": [
2062
+ "id"
2063
+ ],
2064
+ "onDelete": "cascade",
2065
+ "onUpdate": "no action"
2066
+ },
2067
+ "comments_ticket_id_tickets_id_fk": {
2068
+ "name": "comments_ticket_id_tickets_id_fk",
2069
+ "tableFrom": "comments",
2070
+ "tableTo": "tickets",
2071
+ "columnsFrom": [
2072
+ "ticket_id"
2073
+ ],
2074
+ "columnsTo": [
2075
+ "id"
2076
+ ],
2077
+ "onDelete": "cascade",
2078
+ "onUpdate": "no action"
2079
+ },
2080
+ "comments_actor_id_user_id_fk": {
2081
+ "name": "comments_actor_id_user_id_fk",
2082
+ "tableFrom": "comments",
2083
+ "tableTo": "user",
2084
+ "columnsFrom": [
2085
+ "actor_id"
2086
+ ],
2087
+ "columnsTo": [
2088
+ "id"
2089
+ ],
2090
+ "onDelete": "no action",
2091
+ "onUpdate": "no action"
2092
+ }
2093
+ },
2094
+ "compositePrimaryKeys": {},
2095
+ "uniqueConstraints": {},
2096
+ "policies": {},
2097
+ "checkConstraints": {},
2098
+ "isRLSEnabled": false
2099
+ },
2100
+ "public.event_clock": {
2101
+ "name": "event_clock",
2102
+ "schema": "",
2103
+ "columns": {
2104
+ "id": {
2105
+ "name": "id",
2106
+ "type": "integer",
2107
+ "primaryKey": true,
2108
+ "notNull": true
2109
+ },
2110
+ "value": {
2111
+ "name": "value",
2112
+ "type": "bigint",
2113
+ "primaryKey": false,
2114
+ "notNull": true,
2115
+ "default": "0"
2116
+ },
2117
+ "floor": {
2118
+ "name": "floor",
2119
+ "type": "bigint",
2120
+ "primaryKey": false,
2121
+ "notNull": true,
2122
+ "default": "0"
2123
+ }
2124
+ },
2125
+ "indexes": {},
2126
+ "foreignKeys": {},
2127
+ "compositePrimaryKeys": {},
2128
+ "uniqueConstraints": {},
2129
+ "policies": {},
2130
+ "checkConstraints": {},
2131
+ "isRLSEnabled": false
2132
+ },
2133
+ "public.events": {
2134
+ "name": "events",
2135
+ "schema": "",
2136
+ "columns": {
2137
+ "id": {
2138
+ "name": "id",
2139
+ "type": "bigint",
2140
+ "primaryKey": true,
2141
+ "notNull": true
2142
+ },
2143
+ "project_id": {
2144
+ "name": "project_id",
2145
+ "type": "uuid",
2146
+ "primaryKey": false,
2147
+ "notNull": true
2148
+ },
2149
+ "ticket_id": {
2150
+ "name": "ticket_id",
2151
+ "type": "uuid",
2152
+ "primaryKey": false,
2153
+ "notNull": false
2154
+ },
2155
+ "actor_id": {
2156
+ "name": "actor_id",
2157
+ "type": "text",
2158
+ "primaryKey": false,
2159
+ "notNull": true
2160
+ },
2161
+ "type": {
2162
+ "name": "type",
2163
+ "type": "text",
2164
+ "primaryKey": false,
2165
+ "notNull": true
2166
+ },
2167
+ "data": {
2168
+ "name": "data",
2169
+ "type": "jsonb",
2170
+ "primaryKey": false,
2171
+ "notNull": true
2172
+ },
2173
+ "created_at": {
2174
+ "name": "created_at",
2175
+ "type": "timestamp with time zone",
2176
+ "primaryKey": false,
2177
+ "notNull": true,
2178
+ "default": "now()"
2179
+ }
2180
+ },
2181
+ "indexes": {
2182
+ "event_project_cursor": {
2183
+ "name": "event_project_cursor",
2184
+ "columns": [
2185
+ {
2186
+ "expression": "project_id",
2187
+ "isExpression": false,
2188
+ "asc": true,
2189
+ "nulls": "last"
2190
+ },
2191
+ {
2192
+ "expression": "id",
2193
+ "isExpression": false,
2194
+ "asc": true,
2195
+ "nulls": "last"
2196
+ }
2197
+ ],
2198
+ "isUnique": false,
2199
+ "concurrently": false,
2200
+ "method": "btree",
2201
+ "with": {}
2202
+ },
2203
+ "event_ticket": {
2204
+ "name": "event_ticket",
2205
+ "columns": [
2206
+ {
2207
+ "expression": "ticket_id",
2208
+ "isExpression": false,
2209
+ "asc": true,
2210
+ "nulls": "last"
2211
+ },
2212
+ {
2213
+ "expression": "id",
2214
+ "isExpression": false,
2215
+ "asc": true,
2216
+ "nulls": "last"
2217
+ }
2218
+ ],
2219
+ "isUnique": false,
2220
+ "concurrently": false,
2221
+ "method": "btree",
2222
+ "with": {}
2223
+ }
2224
+ },
2225
+ "foreignKeys": {
2226
+ "events_project_id_projects_id_fk": {
2227
+ "name": "events_project_id_projects_id_fk",
2228
+ "tableFrom": "events",
2229
+ "tableTo": "projects",
2230
+ "columnsFrom": [
2231
+ "project_id"
2232
+ ],
2233
+ "columnsTo": [
2234
+ "id"
2235
+ ],
2236
+ "onDelete": "cascade",
2237
+ "onUpdate": "no action"
2238
+ },
2239
+ "events_actor_id_user_id_fk": {
2240
+ "name": "events_actor_id_user_id_fk",
2241
+ "tableFrom": "events",
2242
+ "tableTo": "user",
2243
+ "columnsFrom": [
2244
+ "actor_id"
2245
+ ],
2246
+ "columnsTo": [
2247
+ "id"
2248
+ ],
2249
+ "onDelete": "no action",
2250
+ "onUpdate": "no action"
2251
+ }
2252
+ },
2253
+ "compositePrimaryKeys": {},
2254
+ "uniqueConstraints": {},
2255
+ "policies": {},
2256
+ "checkConstraints": {},
2257
+ "isRLSEnabled": false
2258
+ },
2259
+ "public.evidence": {
2260
+ "name": "evidence",
2261
+ "schema": "",
2262
+ "columns": {
2263
+ "id": {
2264
+ "name": "id",
2265
+ "type": "uuid",
2266
+ "primaryKey": true,
2267
+ "notNull": true,
2268
+ "default": "gen_random_uuid()"
2269
+ },
2270
+ "project_id": {
2271
+ "name": "project_id",
2272
+ "type": "uuid",
2273
+ "primaryKey": false,
2274
+ "notNull": true
2275
+ },
2276
+ "ticket_id": {
2277
+ "name": "ticket_id",
2278
+ "type": "uuid",
2279
+ "primaryKey": false,
2280
+ "notNull": true
2281
+ },
2282
+ "actor_id": {
2283
+ "name": "actor_id",
2284
+ "type": "text",
2285
+ "primaryKey": false,
2286
+ "notNull": true
2287
+ },
2288
+ "title": {
2289
+ "name": "title",
2290
+ "type": "text",
2291
+ "primaryKey": false,
2292
+ "notNull": true
2293
+ },
2294
+ "kind": {
2295
+ "name": "kind",
2296
+ "type": "text",
2297
+ "primaryKey": false,
2298
+ "notNull": true
2299
+ },
2300
+ "url": {
2301
+ "name": "url",
2302
+ "type": "text",
2303
+ "primaryKey": false,
2304
+ "notNull": true
2305
+ },
2306
+ "commit": {
2307
+ "name": "commit",
2308
+ "type": "text",
2309
+ "primaryKey": false,
2310
+ "notNull": false
2311
+ },
2312
+ "outcome": {
2313
+ "name": "outcome",
2314
+ "type": "text",
2315
+ "primaryKey": false,
2316
+ "notNull": true
2317
+ },
2318
+ "note": {
2319
+ "name": "note",
2320
+ "type": "text",
2321
+ "primaryKey": false,
2322
+ "notNull": true
2323
+ },
2324
+ "created_at": {
2325
+ "name": "created_at",
2326
+ "type": "timestamp with time zone",
2327
+ "primaryKey": false,
2328
+ "notNull": true,
2329
+ "default": "now()"
2330
+ }
2331
+ },
2332
+ "indexes": {},
2333
+ "foreignKeys": {
2334
+ "evidence_project_id_projects_id_fk": {
2335
+ "name": "evidence_project_id_projects_id_fk",
2336
+ "tableFrom": "evidence",
2337
+ "tableTo": "projects",
2338
+ "columnsFrom": [
2339
+ "project_id"
2340
+ ],
2341
+ "columnsTo": [
2342
+ "id"
2343
+ ],
2344
+ "onDelete": "cascade",
2345
+ "onUpdate": "no action"
2346
+ },
2347
+ "evidence_ticket_id_tickets_id_fk": {
2348
+ "name": "evidence_ticket_id_tickets_id_fk",
2349
+ "tableFrom": "evidence",
2350
+ "tableTo": "tickets",
2351
+ "columnsFrom": [
2352
+ "ticket_id"
2353
+ ],
2354
+ "columnsTo": [
2355
+ "id"
2356
+ ],
2357
+ "onDelete": "cascade",
2358
+ "onUpdate": "no action"
2359
+ },
2360
+ "evidence_actor_id_user_id_fk": {
2361
+ "name": "evidence_actor_id_user_id_fk",
2362
+ "tableFrom": "evidence",
2363
+ "tableTo": "user",
2364
+ "columnsFrom": [
2365
+ "actor_id"
2366
+ ],
2367
+ "columnsTo": [
2368
+ "id"
2369
+ ],
2370
+ "onDelete": "no action",
2371
+ "onUpdate": "no action"
2372
+ }
2373
+ },
2374
+ "compositePrimaryKeys": {},
2375
+ "uniqueConstraints": {},
2376
+ "policies": {},
2377
+ "checkConstraints": {},
2378
+ "isRLSEnabled": false
2379
+ },
2380
+ "public.project_members": {
2381
+ "name": "project_members",
2382
+ "schema": "",
2383
+ "columns": {
2384
+ "project_id": {
2385
+ "name": "project_id",
2386
+ "type": "uuid",
2387
+ "primaryKey": false,
2388
+ "notNull": true
2389
+ },
2390
+ "user_id": {
2391
+ "name": "user_id",
2392
+ "type": "text",
2393
+ "primaryKey": false,
2394
+ "notNull": true
2395
+ },
2396
+ "role": {
2397
+ "name": "role",
2398
+ "type": "text",
2399
+ "primaryKey": false,
2400
+ "notNull": true
2401
+ }
2402
+ },
2403
+ "indexes": {
2404
+ "member_user": {
2405
+ "name": "member_user",
2406
+ "columns": [
2407
+ {
2408
+ "expression": "user_id",
2409
+ "isExpression": false,
2410
+ "asc": true,
2411
+ "nulls": "last"
2412
+ }
2413
+ ],
2414
+ "isUnique": false,
2415
+ "concurrently": false,
2416
+ "method": "btree",
2417
+ "with": {}
2418
+ }
2419
+ },
2420
+ "foreignKeys": {
2421
+ "project_members_project_id_projects_id_fk": {
2422
+ "name": "project_members_project_id_projects_id_fk",
2423
+ "tableFrom": "project_members",
2424
+ "tableTo": "projects",
2425
+ "columnsFrom": [
2426
+ "project_id"
2427
+ ],
2428
+ "columnsTo": [
2429
+ "id"
2430
+ ],
2431
+ "onDelete": "cascade",
2432
+ "onUpdate": "no action"
2433
+ },
2434
+ "project_members_user_id_user_id_fk": {
2435
+ "name": "project_members_user_id_user_id_fk",
2436
+ "tableFrom": "project_members",
2437
+ "tableTo": "user",
2438
+ "columnsFrom": [
2439
+ "user_id"
2440
+ ],
2441
+ "columnsTo": [
2442
+ "id"
2443
+ ],
2444
+ "onDelete": "cascade",
2445
+ "onUpdate": "no action"
2446
+ }
2447
+ },
2448
+ "compositePrimaryKeys": {
2449
+ "project_members_project_id_user_id_pk": {
2450
+ "name": "project_members_project_id_user_id_pk",
2451
+ "columns": [
2452
+ "project_id",
2453
+ "user_id"
2454
+ ]
2455
+ }
2456
+ },
2457
+ "uniqueConstraints": {},
2458
+ "policies": {},
2459
+ "checkConstraints": {},
2460
+ "isRLSEnabled": false
2461
+ },
2462
+ "public.notifications": {
2463
+ "name": "notifications",
2464
+ "schema": "",
2465
+ "columns": {
2466
+ "id": {
2467
+ "name": "id",
2468
+ "type": "uuid",
2469
+ "primaryKey": true,
2470
+ "notNull": true,
2471
+ "default": "gen_random_uuid()"
2472
+ },
2473
+ "user_id": {
2474
+ "name": "user_id",
2475
+ "type": "text",
2476
+ "primaryKey": false,
2477
+ "notNull": true
2478
+ },
2479
+ "project_id": {
2480
+ "name": "project_id",
2481
+ "type": "uuid",
2482
+ "primaryKey": false,
2483
+ "notNull": true
2484
+ },
2485
+ "event_id": {
2486
+ "name": "event_id",
2487
+ "type": "bigint",
2488
+ "primaryKey": false,
2489
+ "notNull": true
2490
+ },
2491
+ "read_at": {
2492
+ "name": "read_at",
2493
+ "type": "timestamp with time zone",
2494
+ "primaryKey": false,
2495
+ "notNull": false
2496
+ },
2497
+ "created_at": {
2498
+ "name": "created_at",
2499
+ "type": "timestamp with time zone",
2500
+ "primaryKey": false,
2501
+ "notNull": true,
2502
+ "default": "now()"
2503
+ }
2504
+ },
2505
+ "indexes": {},
2506
+ "foreignKeys": {
2507
+ "notifications_user_id_user_id_fk": {
2508
+ "name": "notifications_user_id_user_id_fk",
2509
+ "tableFrom": "notifications",
2510
+ "tableTo": "user",
2511
+ "columnsFrom": [
2512
+ "user_id"
2513
+ ],
2514
+ "columnsTo": [
2515
+ "id"
2516
+ ],
2517
+ "onDelete": "cascade",
2518
+ "onUpdate": "no action"
2519
+ },
2520
+ "notifications_project_id_projects_id_fk": {
2521
+ "name": "notifications_project_id_projects_id_fk",
2522
+ "tableFrom": "notifications",
2523
+ "tableTo": "projects",
2524
+ "columnsFrom": [
2525
+ "project_id"
2526
+ ],
2527
+ "columnsTo": [
2528
+ "id"
2529
+ ],
2530
+ "onDelete": "cascade",
2531
+ "onUpdate": "no action"
2532
+ }
2533
+ },
2534
+ "compositePrimaryKeys": {},
2535
+ "uniqueConstraints": {},
2536
+ "policies": {},
2537
+ "checkConstraints": {},
2538
+ "isRLSEnabled": false
2539
+ },
2540
+ "public.projects": {
2541
+ "name": "projects",
2542
+ "schema": "",
2543
+ "columns": {
2544
+ "id": {
2545
+ "name": "id",
2546
+ "type": "uuid",
2547
+ "primaryKey": true,
2548
+ "notNull": true,
2549
+ "default": "gen_random_uuid()"
2550
+ },
2551
+ "key": {
2552
+ "name": "key",
2553
+ "type": "text",
2554
+ "primaryKey": false,
2555
+ "notNull": true
2556
+ },
2557
+ "name": {
2558
+ "name": "name",
2559
+ "type": "text",
2560
+ "primaryKey": false,
2561
+ "notNull": true
2562
+ },
2563
+ "description": {
2564
+ "name": "description",
2565
+ "type": "text",
2566
+ "primaryKey": false,
2567
+ "notNull": true,
2568
+ "default": "''"
2569
+ },
2570
+ "next_number": {
2571
+ "name": "next_number",
2572
+ "type": "integer",
2573
+ "primaryKey": false,
2574
+ "notNull": true,
2575
+ "default": 1
2576
+ },
2577
+ "version": {
2578
+ "name": "version",
2579
+ "type": "integer",
2580
+ "primaryKey": false,
2581
+ "notNull": true,
2582
+ "default": 1
2583
+ },
2584
+ "created_at": {
2585
+ "name": "created_at",
2586
+ "type": "timestamp with time zone",
2587
+ "primaryKey": false,
2588
+ "notNull": true,
2589
+ "default": "now()"
2590
+ },
2591
+ "updated_at": {
2592
+ "name": "updated_at",
2593
+ "type": "timestamp with time zone",
2594
+ "primaryKey": false,
2595
+ "notNull": true,
2596
+ "default": "now()"
2597
+ }
2598
+ },
2599
+ "indexes": {},
2600
+ "foreignKeys": {},
2601
+ "compositePrimaryKeys": {},
2602
+ "uniqueConstraints": {
2603
+ "projects_key_unique": {
2604
+ "name": "projects_key_unique",
2605
+ "nullsNotDistinct": false,
2606
+ "columns": [
2607
+ "key"
2608
+ ]
2609
+ }
2610
+ },
2611
+ "policies": {},
2612
+ "checkConstraints": {},
2613
+ "isRLSEnabled": false
2614
+ },
2615
+ "public.mutation_receipts": {
2616
+ "name": "mutation_receipts",
2617
+ "schema": "",
2618
+ "columns": {
2619
+ "actor_id": {
2620
+ "name": "actor_id",
2621
+ "type": "text",
2622
+ "primaryKey": false,
2623
+ "notNull": true
2624
+ },
2625
+ "request_id": {
2626
+ "name": "request_id",
2627
+ "type": "uuid",
2628
+ "primaryKey": false,
2629
+ "notNull": true
2630
+ },
2631
+ "operation": {
2632
+ "name": "operation",
2633
+ "type": "text",
2634
+ "primaryKey": false,
2635
+ "notNull": true
2636
+ },
2637
+ "hash": {
2638
+ "name": "hash",
2639
+ "type": "text",
2640
+ "primaryKey": false,
2641
+ "notNull": true
2642
+ },
2643
+ "result": {
2644
+ "name": "result",
2645
+ "type": "jsonb",
2646
+ "primaryKey": false,
2647
+ "notNull": true
2648
+ },
2649
+ "created_at": {
2650
+ "name": "created_at",
2651
+ "type": "timestamp with time zone",
2652
+ "primaryKey": false,
2653
+ "notNull": true,
2654
+ "default": "now()"
2655
+ }
2656
+ },
2657
+ "indexes": {},
2658
+ "foreignKeys": {
2659
+ "mutation_receipts_actor_id_user_id_fk": {
2660
+ "name": "mutation_receipts_actor_id_user_id_fk",
2661
+ "tableFrom": "mutation_receipts",
2662
+ "tableTo": "user",
2663
+ "columnsFrom": [
2664
+ "actor_id"
2665
+ ],
2666
+ "columnsTo": [
2667
+ "id"
2668
+ ],
2669
+ "onDelete": "no action",
2670
+ "onUpdate": "no action"
2671
+ }
2672
+ },
2673
+ "compositePrimaryKeys": {
2674
+ "mutation_receipts_actor_id_request_id_pk": {
2675
+ "name": "mutation_receipts_actor_id_request_id_pk",
2676
+ "columns": [
2677
+ "actor_id",
2678
+ "request_id"
2679
+ ]
2680
+ }
2681
+ },
2682
+ "uniqueConstraints": {},
2683
+ "policies": {},
2684
+ "checkConstraints": {},
2685
+ "isRLSEnabled": false
2686
+ },
2687
+ "public.ticket_relations": {
2688
+ "name": "ticket_relations",
2689
+ "schema": "",
2690
+ "columns": {
2691
+ "id": {
2692
+ "name": "id",
2693
+ "type": "uuid",
2694
+ "primaryKey": true,
2695
+ "notNull": true,
2696
+ "default": "gen_random_uuid()"
2697
+ },
2698
+ "project_id": {
2699
+ "name": "project_id",
2700
+ "type": "uuid",
2701
+ "primaryKey": false,
2702
+ "notNull": true
2703
+ },
2704
+ "source_id": {
2705
+ "name": "source_id",
2706
+ "type": "uuid",
2707
+ "primaryKey": false,
2708
+ "notNull": true
2709
+ },
2710
+ "target_id": {
2711
+ "name": "target_id",
2712
+ "type": "uuid",
2713
+ "primaryKey": false,
2714
+ "notNull": true
2715
+ },
2716
+ "type": {
2717
+ "name": "type",
2718
+ "type": "text",
2719
+ "primaryKey": false,
2720
+ "notNull": true
2721
+ }
2722
+ },
2723
+ "indexes": {
2724
+ "relation_target": {
2725
+ "name": "relation_target",
2726
+ "columns": [
2727
+ {
2728
+ "expression": "target_id",
2729
+ "isExpression": false,
2730
+ "asc": true,
2731
+ "nulls": "last"
2732
+ }
2733
+ ],
2734
+ "isUnique": false,
2735
+ "concurrently": false,
2736
+ "method": "btree",
2737
+ "with": {}
2738
+ }
2739
+ },
2740
+ "foreignKeys": {
2741
+ "ticket_relations_project_id_projects_id_fk": {
2742
+ "name": "ticket_relations_project_id_projects_id_fk",
2743
+ "tableFrom": "ticket_relations",
2744
+ "tableTo": "projects",
2745
+ "columnsFrom": [
2746
+ "project_id"
2747
+ ],
2748
+ "columnsTo": [
2749
+ "id"
2750
+ ],
2751
+ "onDelete": "cascade",
2752
+ "onUpdate": "no action"
2753
+ },
2754
+ "ticket_relations_source_id_tickets_id_fk": {
2755
+ "name": "ticket_relations_source_id_tickets_id_fk",
2756
+ "tableFrom": "ticket_relations",
2757
+ "tableTo": "tickets",
2758
+ "columnsFrom": [
2759
+ "source_id"
2760
+ ],
2761
+ "columnsTo": [
2762
+ "id"
2763
+ ],
2764
+ "onDelete": "cascade",
2765
+ "onUpdate": "no action"
2766
+ },
2767
+ "ticket_relations_target_id_tickets_id_fk": {
2768
+ "name": "ticket_relations_target_id_tickets_id_fk",
2769
+ "tableFrom": "ticket_relations",
2770
+ "tableTo": "tickets",
2771
+ "columnsFrom": [
2772
+ "target_id"
2773
+ ],
2774
+ "columnsTo": [
2775
+ "id"
2776
+ ],
2777
+ "onDelete": "cascade",
2778
+ "onUpdate": "no action"
2779
+ }
2780
+ },
2781
+ "compositePrimaryKeys": {},
2782
+ "uniqueConstraints": {
2783
+ "ticket_relation_edge": {
2784
+ "name": "ticket_relation_edge",
2785
+ "nullsNotDistinct": false,
2786
+ "columns": [
2787
+ "source_id",
2788
+ "target_id",
2789
+ "type"
2790
+ ]
2791
+ }
2792
+ },
2793
+ "policies": {},
2794
+ "checkConstraints": {},
2795
+ "isRLSEnabled": false
2796
+ },
2797
+ "public.subscriptions": {
2798
+ "name": "subscriptions",
2799
+ "schema": "",
2800
+ "columns": {
2801
+ "project_id": {
2802
+ "name": "project_id",
2803
+ "type": "uuid",
2804
+ "primaryKey": false,
2805
+ "notNull": true
2806
+ },
2807
+ "ticket_id": {
2808
+ "name": "ticket_id",
2809
+ "type": "uuid",
2810
+ "primaryKey": false,
2811
+ "notNull": true
2812
+ },
2813
+ "user_id": {
2814
+ "name": "user_id",
2815
+ "type": "text",
2816
+ "primaryKey": false,
2817
+ "notNull": true
2818
+ }
2819
+ },
2820
+ "indexes": {},
2821
+ "foreignKeys": {
2822
+ "subscriptions_project_id_projects_id_fk": {
2823
+ "name": "subscriptions_project_id_projects_id_fk",
2824
+ "tableFrom": "subscriptions",
2825
+ "tableTo": "projects",
2826
+ "columnsFrom": [
2827
+ "project_id"
2828
+ ],
2829
+ "columnsTo": [
2830
+ "id"
2831
+ ],
2832
+ "onDelete": "cascade",
2833
+ "onUpdate": "no action"
2834
+ },
2835
+ "subscriptions_ticket_id_tickets_id_fk": {
2836
+ "name": "subscriptions_ticket_id_tickets_id_fk",
2837
+ "tableFrom": "subscriptions",
2838
+ "tableTo": "tickets",
2839
+ "columnsFrom": [
2840
+ "ticket_id"
2841
+ ],
2842
+ "columnsTo": [
2843
+ "id"
2844
+ ],
2845
+ "onDelete": "cascade",
2846
+ "onUpdate": "no action"
2847
+ },
2848
+ "subscriptions_user_id_user_id_fk": {
2849
+ "name": "subscriptions_user_id_user_id_fk",
2850
+ "tableFrom": "subscriptions",
2851
+ "tableTo": "user",
2852
+ "columnsFrom": [
2853
+ "user_id"
2854
+ ],
2855
+ "columnsTo": [
2856
+ "id"
2857
+ ],
2858
+ "onDelete": "cascade",
2859
+ "onUpdate": "no action"
2860
+ }
2861
+ },
2862
+ "compositePrimaryKeys": {
2863
+ "subscriptions_ticket_id_user_id_pk": {
2864
+ "name": "subscriptions_ticket_id_user_id_pk",
2865
+ "columns": [
2866
+ "ticket_id",
2867
+ "user_id"
2868
+ ]
2869
+ }
2870
+ },
2871
+ "uniqueConstraints": {},
2872
+ "policies": {},
2873
+ "checkConstraints": {},
2874
+ "isRLSEnabled": false
2875
+ },
2876
+ "public.tickets": {
2877
+ "name": "tickets",
2878
+ "schema": "",
2879
+ "columns": {
2880
+ "id": {
2881
+ "name": "id",
2882
+ "type": "uuid",
2883
+ "primaryKey": true,
2884
+ "notNull": true,
2885
+ "default": "gen_random_uuid()"
2886
+ },
2887
+ "project_id": {
2888
+ "name": "project_id",
2889
+ "type": "uuid",
2890
+ "primaryKey": false,
2891
+ "notNull": true
2892
+ },
2893
+ "key": {
2894
+ "name": "key",
2895
+ "type": "text",
2896
+ "primaryKey": false,
2897
+ "notNull": true
2898
+ },
2899
+ "number": {
2900
+ "name": "number",
2901
+ "type": "integer",
2902
+ "primaryKey": false,
2903
+ "notNull": true
2904
+ },
2905
+ "title": {
2906
+ "name": "title",
2907
+ "type": "text",
2908
+ "primaryKey": false,
2909
+ "notNull": true
2910
+ },
2911
+ "description": {
2912
+ "name": "description",
2913
+ "type": "text",
2914
+ "primaryKey": false,
2915
+ "notNull": true,
2916
+ "default": "''"
2917
+ },
2918
+ "acceptance_criteria": {
2919
+ "name": "acceptance_criteria",
2920
+ "type": "text",
2921
+ "primaryKey": false,
2922
+ "notNull": true,
2923
+ "default": "''"
2924
+ },
2925
+ "status": {
2926
+ "name": "status",
2927
+ "type": "text",
2928
+ "primaryKey": false,
2929
+ "notNull": true,
2930
+ "default": "'todo'"
2931
+ },
2932
+ "priority": {
2933
+ "name": "priority",
2934
+ "type": "text",
2935
+ "primaryKey": false,
2936
+ "notNull": true,
2937
+ "default": "'medium'"
2938
+ },
2939
+ "kind": {
2940
+ "name": "kind",
2941
+ "type": "text",
2942
+ "primaryKey": false,
2943
+ "notNull": true,
2944
+ "default": "'feature'"
2945
+ },
2946
+ "difficulty": {
2947
+ "name": "difficulty",
2948
+ "type": "text",
2949
+ "primaryKey": false,
2950
+ "notNull": false
2951
+ },
2952
+ "labels": {
2953
+ "name": "labels",
2954
+ "type": "text[]",
2955
+ "primaryKey": false,
2956
+ "notNull": true,
2957
+ "default": "'{}'"
2958
+ },
2959
+ "scopes": {
2960
+ "name": "scopes",
2961
+ "type": "text[]",
2962
+ "primaryKey": false,
2963
+ "notNull": true,
2964
+ "default": "'{}'"
2965
+ },
2966
+ "assignee_id": {
2967
+ "name": "assignee_id",
2968
+ "type": "text",
2969
+ "primaryKey": false,
2970
+ "notNull": false
2971
+ },
2972
+ "parent_id": {
2973
+ "name": "parent_id",
2974
+ "type": "uuid",
2975
+ "primaryKey": false,
2976
+ "notNull": false
2977
+ },
2978
+ "automation_ready": {
2979
+ "name": "automation_ready",
2980
+ "type": "boolean",
2981
+ "primaryKey": false,
2982
+ "notNull": true,
2983
+ "default": false
2984
+ },
2985
+ "hold_reason": {
2986
+ "name": "hold_reason",
2987
+ "type": "text",
2988
+ "primaryKey": false,
2989
+ "notNull": false
2990
+ },
2991
+ "archived": {
2992
+ "name": "archived",
2993
+ "type": "boolean",
2994
+ "primaryKey": false,
2995
+ "notNull": true,
2996
+ "default": false
2997
+ },
2998
+ "created_by": {
2999
+ "name": "created_by",
3000
+ "type": "text",
3001
+ "primaryKey": false,
3002
+ "notNull": true
3003
+ },
3004
+ "version": {
3005
+ "name": "version",
3006
+ "type": "integer",
3007
+ "primaryKey": false,
3008
+ "notNull": true,
3009
+ "default": 1
3010
+ },
3011
+ "created_at": {
3012
+ "name": "created_at",
3013
+ "type": "timestamp with time zone",
3014
+ "primaryKey": false,
3015
+ "notNull": true,
3016
+ "default": "now()"
3017
+ },
3018
+ "updated_at": {
3019
+ "name": "updated_at",
3020
+ "type": "timestamp with time zone",
3021
+ "primaryKey": false,
3022
+ "notNull": true,
3023
+ "default": "now()"
3024
+ }
3025
+ },
3026
+ "indexes": {
3027
+ "ticket_project_status": {
3028
+ "name": "ticket_project_status",
3029
+ "columns": [
3030
+ {
3031
+ "expression": "project_id",
3032
+ "isExpression": false,
3033
+ "asc": true,
3034
+ "nulls": "last"
3035
+ },
3036
+ {
3037
+ "expression": "status",
3038
+ "isExpression": false,
3039
+ "asc": true,
3040
+ "nulls": "last"
3041
+ }
3042
+ ],
3043
+ "isUnique": false,
3044
+ "concurrently": false,
3045
+ "method": "btree",
3046
+ "with": {}
3047
+ },
3048
+ "ticket_parent": {
3049
+ "name": "ticket_parent",
3050
+ "columns": [
3051
+ {
3052
+ "expression": "parent_id",
3053
+ "isExpression": false,
3054
+ "asc": true,
3055
+ "nulls": "last"
3056
+ }
3057
+ ],
3058
+ "isUnique": false,
3059
+ "concurrently": false,
3060
+ "method": "btree",
3061
+ "with": {}
3062
+ }
3063
+ },
3064
+ "foreignKeys": {
3065
+ "tickets_project_id_projects_id_fk": {
3066
+ "name": "tickets_project_id_projects_id_fk",
3067
+ "tableFrom": "tickets",
3068
+ "tableTo": "projects",
3069
+ "columnsFrom": [
3070
+ "project_id"
3071
+ ],
3072
+ "columnsTo": [
3073
+ "id"
3074
+ ],
3075
+ "onDelete": "cascade",
3076
+ "onUpdate": "no action"
3077
+ },
3078
+ "tickets_assignee_id_user_id_fk": {
3079
+ "name": "tickets_assignee_id_user_id_fk",
3080
+ "tableFrom": "tickets",
3081
+ "tableTo": "user",
3082
+ "columnsFrom": [
3083
+ "assignee_id"
3084
+ ],
3085
+ "columnsTo": [
3086
+ "id"
3087
+ ],
3088
+ "onDelete": "set null",
3089
+ "onUpdate": "no action"
3090
+ },
3091
+ "tickets_created_by_user_id_fk": {
3092
+ "name": "tickets_created_by_user_id_fk",
3093
+ "tableFrom": "tickets",
3094
+ "tableTo": "user",
3095
+ "columnsFrom": [
3096
+ "created_by"
3097
+ ],
3098
+ "columnsTo": [
3099
+ "id"
3100
+ ],
3101
+ "onDelete": "no action",
3102
+ "onUpdate": "no action"
3103
+ }
3104
+ },
3105
+ "compositePrimaryKeys": {},
3106
+ "uniqueConstraints": {
3107
+ "tickets_key_unique": {
3108
+ "name": "tickets_key_unique",
3109
+ "nullsNotDistinct": false,
3110
+ "columns": [
3111
+ "key"
3112
+ ]
3113
+ },
3114
+ "ticket_project_number": {
3115
+ "name": "ticket_project_number",
3116
+ "nullsNotDistinct": false,
3117
+ "columns": [
3118
+ "project_id",
3119
+ "number"
3120
+ ]
3121
+ }
3122
+ },
3123
+ "policies": {},
3124
+ "checkConstraints": {},
3125
+ "isRLSEnabled": false
3126
+ },
3127
+ "public.saved_views": {
3128
+ "name": "saved_views",
3129
+ "schema": "",
3130
+ "columns": {
3131
+ "id": {
3132
+ "name": "id",
3133
+ "type": "uuid",
3134
+ "primaryKey": true,
3135
+ "notNull": true,
3136
+ "default": "gen_random_uuid()"
3137
+ },
3138
+ "project_id": {
3139
+ "name": "project_id",
3140
+ "type": "uuid",
3141
+ "primaryKey": false,
3142
+ "notNull": true
3143
+ },
3144
+ "user_id": {
3145
+ "name": "user_id",
3146
+ "type": "text",
3147
+ "primaryKey": false,
3148
+ "notNull": true
3149
+ },
3150
+ "name": {
3151
+ "name": "name",
3152
+ "type": "text",
3153
+ "primaryKey": false,
3154
+ "notNull": true
3155
+ },
3156
+ "filters": {
3157
+ "name": "filters",
3158
+ "type": "jsonb",
3159
+ "primaryKey": false,
3160
+ "notNull": true
3161
+ }
3162
+ },
3163
+ "indexes": {},
3164
+ "foreignKeys": {
3165
+ "saved_views_project_id_projects_id_fk": {
3166
+ "name": "saved_views_project_id_projects_id_fk",
3167
+ "tableFrom": "saved_views",
3168
+ "tableTo": "projects",
3169
+ "columnsFrom": [
3170
+ "project_id"
3171
+ ],
3172
+ "columnsTo": [
3173
+ "id"
3174
+ ],
3175
+ "onDelete": "cascade",
3176
+ "onUpdate": "no action"
3177
+ },
3178
+ "saved_views_user_id_user_id_fk": {
3179
+ "name": "saved_views_user_id_user_id_fk",
3180
+ "tableFrom": "saved_views",
3181
+ "tableTo": "user",
3182
+ "columnsFrom": [
3183
+ "user_id"
3184
+ ],
3185
+ "columnsTo": [
3186
+ "id"
3187
+ ],
3188
+ "onDelete": "cascade",
3189
+ "onUpdate": "no action"
3190
+ }
3191
+ },
3192
+ "compositePrimaryKeys": {},
3193
+ "uniqueConstraints": {},
3194
+ "policies": {},
3195
+ "checkConstraints": {},
3196
+ "isRLSEnabled": false
3197
+ }
3198
+ },
3199
+ "enums": {},
3200
+ "schemas": {},
3201
+ "sequences": {},
3202
+ "roles": {},
3203
+ "policies": {},
3204
+ "views": {},
3205
+ "_meta": {
3206
+ "columns": {},
3207
+ "schemas": {},
3208
+ "tables": {}
3209
+ }
3210
+ }