@inkeep/agents-core 0.0.0-dev-20260204182014 → 0.0.0-dev-20260204210021

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 (59) hide show
  1. package/dist/auth/auth-schema.d.ts +104 -104
  2. package/dist/auth/auth-validation-schemas.d.ts +129 -129
  3. package/dist/auth/auth.d.ts +54 -54
  4. package/dist/auth/permissions.d.ts +13 -13
  5. package/dist/client-exports.d.ts +2 -2
  6. package/dist/data-access/index.d.ts +1 -3
  7. package/dist/data-access/index.js +1 -3
  8. package/dist/data-access/manage/agents.d.ts +36 -36
  9. package/dist/data-access/manage/artifactComponents.d.ts +10 -10
  10. package/dist/data-access/manage/contextConfigs.d.ts +16 -16
  11. package/dist/data-access/manage/dataComponents.d.ts +6 -6
  12. package/dist/data-access/manage/functionTools.d.ts +12 -12
  13. package/dist/data-access/manage/subAgentExternalAgentRelations.d.ts +24 -24
  14. package/dist/data-access/manage/subAgentRelations.d.ts +20 -20
  15. package/dist/data-access/manage/subAgentTeamAgentRelations.d.ts +18 -18
  16. package/dist/data-access/manage/subAgents.d.ts +12 -12
  17. package/dist/data-access/manage/tools.d.ts +21 -21
  18. package/dist/data-access/runtime/apiKeys.d.ts +16 -16
  19. package/dist/data-access/runtime/conversations.d.ts +27 -27
  20. package/dist/data-access/runtime/messages.d.ts +9 -9
  21. package/dist/data-access/runtime/tasks.d.ts +6 -6
  22. package/dist/db/manage/manage-schema.d.ts +304 -524
  23. package/dist/db/manage/manage-schema.js +2 -27
  24. package/dist/db/runtime/runtime-schema.d.ts +240 -1153
  25. package/dist/db/runtime/runtime-schema.js +2 -98
  26. package/dist/index.d.ts +5 -10
  27. package/dist/index.js +4 -9
  28. package/dist/types/entities.d.ts +2 -8
  29. package/dist/types/index.d.ts +2 -2
  30. package/dist/utils/index.d.ts +1 -4
  31. package/dist/utils/index.js +1 -4
  32. package/dist/utils/trigger-auth.d.ts +1 -1
  33. package/dist/validation/dolt-schemas.d.ts +1 -1
  34. package/dist/validation/drizzle-schema-helpers.d.ts +3 -3
  35. package/dist/validation/index.d.ts +2 -2
  36. package/dist/validation/index.js +2 -2
  37. package/dist/validation/schemas.d.ts +1627 -4187
  38. package/dist/validation/schemas.js +4 -66
  39. package/drizzle/manage/meta/_journal.json +0 -7
  40. package/drizzle/runtime/meta/_journal.json +0 -14
  41. package/package.json +1 -1
  42. package/dist/auth/create-test-users.d.ts +0 -1
  43. package/dist/auth/create-test-users.js +0 -102
  44. package/dist/data-access/manage/workAppConfigs.d.ts +0 -228
  45. package/dist/data-access/manage/workAppConfigs.js +0 -120
  46. package/dist/data-access/runtime/workAppSlack.d.ts +0 -45
  47. package/dist/data-access/runtime/workAppSlack.js +0 -154
  48. package/dist/utils/slack-link-token.d.ts +0 -60
  49. package/dist/utils/slack-link-token.js +0 -124
  50. package/dist/utils/slack-user-token.d.ts +0 -87
  51. package/dist/utils/slack-user-token.js +0 -156
  52. package/dist/utils/sse-parser.d.ts +0 -35
  53. package/dist/utils/sse-parser.js +0 -71
  54. package/drizzle/manage/0007_whole_skreet.sql +0 -17
  55. package/drizzle/manage/meta/0007_snapshot.json +0 -3265
  56. package/drizzle/runtime/0011_grey_energizer.sql +0 -131
  57. package/drizzle/runtime/0012_salty_zuras.sql +0 -6
  58. package/drizzle/runtime/meta/0011_snapshot.json +0 -3747
  59. package/drizzle/runtime/meta/0012_snapshot.json +0 -3747
@@ -1,3747 +0,0 @@
1
- {
2
- "id": "593db0fe-3436-46a7-a9e6-da9edddf7368",
3
- "prevId": "4dfaa0bf-0565-473f-8b0a-a0651ac1e634",
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.api_keys": {
130
- "name": "api_keys",
131
- "schema": "",
132
- "columns": {
133
- "tenant_id": {
134
- "name": "tenant_id",
135
- "type": "varchar(256)",
136
- "primaryKey": false,
137
- "notNull": true
138
- },
139
- "id": {
140
- "name": "id",
141
- "type": "varchar(256)",
142
- "primaryKey": false,
143
- "notNull": true
144
- },
145
- "project_id": {
146
- "name": "project_id",
147
- "type": "varchar(256)",
148
- "primaryKey": false,
149
- "notNull": true
150
- },
151
- "agent_id": {
152
- "name": "agent_id",
153
- "type": "varchar(256)",
154
- "primaryKey": false,
155
- "notNull": true
156
- },
157
- "public_id": {
158
- "name": "public_id",
159
- "type": "varchar(256)",
160
- "primaryKey": false,
161
- "notNull": true
162
- },
163
- "key_hash": {
164
- "name": "key_hash",
165
- "type": "varchar(256)",
166
- "primaryKey": false,
167
- "notNull": true
168
- },
169
- "key_prefix": {
170
- "name": "key_prefix",
171
- "type": "varchar(256)",
172
- "primaryKey": false,
173
- "notNull": true
174
- },
175
- "name": {
176
- "name": "name",
177
- "type": "varchar(256)",
178
- "primaryKey": false,
179
- "notNull": false
180
- },
181
- "last_used_at": {
182
- "name": "last_used_at",
183
- "type": "timestamp",
184
- "primaryKey": false,
185
- "notNull": false
186
- },
187
- "expires_at": {
188
- "name": "expires_at",
189
- "type": "timestamp",
190
- "primaryKey": false,
191
- "notNull": false
192
- },
193
- "created_at": {
194
- "name": "created_at",
195
- "type": "timestamp",
196
- "primaryKey": false,
197
- "notNull": true,
198
- "default": "now()"
199
- },
200
- "updated_at": {
201
- "name": "updated_at",
202
- "type": "timestamp",
203
- "primaryKey": false,
204
- "notNull": true,
205
- "default": "now()"
206
- }
207
- },
208
- "indexes": {
209
- "api_keys_tenant_agent_idx": {
210
- "name": "api_keys_tenant_agent_idx",
211
- "columns": [
212
- {
213
- "expression": "tenant_id",
214
- "isExpression": false,
215
- "asc": true,
216
- "nulls": "last"
217
- },
218
- {
219
- "expression": "agent_id",
220
- "isExpression": false,
221
- "asc": true,
222
- "nulls": "last"
223
- }
224
- ],
225
- "isUnique": false,
226
- "concurrently": false,
227
- "method": "btree",
228
- "with": {}
229
- },
230
- "api_keys_prefix_idx": {
231
- "name": "api_keys_prefix_idx",
232
- "columns": [
233
- {
234
- "expression": "key_prefix",
235
- "isExpression": false,
236
- "asc": true,
237
- "nulls": "last"
238
- }
239
- ],
240
- "isUnique": false,
241
- "concurrently": false,
242
- "method": "btree",
243
- "with": {}
244
- },
245
- "api_keys_public_id_idx": {
246
- "name": "api_keys_public_id_idx",
247
- "columns": [
248
- {
249
- "expression": "public_id",
250
- "isExpression": false,
251
- "asc": true,
252
- "nulls": "last"
253
- }
254
- ],
255
- "isUnique": false,
256
- "concurrently": false,
257
- "method": "btree",
258
- "with": {}
259
- }
260
- },
261
- "foreignKeys": {
262
- "api_keys_organization_fk": {
263
- "name": "api_keys_organization_fk",
264
- "tableFrom": "api_keys",
265
- "tableTo": "organization",
266
- "columnsFrom": [
267
- "tenant_id"
268
- ],
269
- "columnsTo": [
270
- "id"
271
- ],
272
- "onDelete": "cascade",
273
- "onUpdate": "no action"
274
- }
275
- },
276
- "compositePrimaryKeys": {},
277
- "uniqueConstraints": {
278
- "api_keys_public_id_unique": {
279
- "name": "api_keys_public_id_unique",
280
- "nullsNotDistinct": false,
281
- "columns": [
282
- "public_id"
283
- ]
284
- }
285
- },
286
- "policies": {},
287
- "checkConstraints": {},
288
- "isRLSEnabled": false
289
- },
290
- "public.context_cache": {
291
- "name": "context_cache",
292
- "schema": "",
293
- "columns": {
294
- "tenant_id": {
295
- "name": "tenant_id",
296
- "type": "varchar(256)",
297
- "primaryKey": false,
298
- "notNull": true
299
- },
300
- "id": {
301
- "name": "id",
302
- "type": "varchar(256)",
303
- "primaryKey": false,
304
- "notNull": true
305
- },
306
- "project_id": {
307
- "name": "project_id",
308
- "type": "varchar(256)",
309
- "primaryKey": false,
310
- "notNull": true
311
- },
312
- "conversation_id": {
313
- "name": "conversation_id",
314
- "type": "varchar(256)",
315
- "primaryKey": false,
316
- "notNull": true
317
- },
318
- "context_config_id": {
319
- "name": "context_config_id",
320
- "type": "varchar(256)",
321
- "primaryKey": false,
322
- "notNull": true
323
- },
324
- "context_variable_key": {
325
- "name": "context_variable_key",
326
- "type": "varchar(256)",
327
- "primaryKey": false,
328
- "notNull": true
329
- },
330
- "ref": {
331
- "name": "ref",
332
- "type": "jsonb",
333
- "primaryKey": false,
334
- "notNull": false
335
- },
336
- "value": {
337
- "name": "value",
338
- "type": "jsonb",
339
- "primaryKey": false,
340
- "notNull": true
341
- },
342
- "request_hash": {
343
- "name": "request_hash",
344
- "type": "varchar(256)",
345
- "primaryKey": false,
346
- "notNull": false
347
- },
348
- "fetched_at": {
349
- "name": "fetched_at",
350
- "type": "timestamp",
351
- "primaryKey": false,
352
- "notNull": true,
353
- "default": "now()"
354
- },
355
- "fetch_source": {
356
- "name": "fetch_source",
357
- "type": "varchar(256)",
358
- "primaryKey": false,
359
- "notNull": false
360
- },
361
- "created_at": {
362
- "name": "created_at",
363
- "type": "timestamp",
364
- "primaryKey": false,
365
- "notNull": true,
366
- "default": "now()"
367
- },
368
- "updated_at": {
369
- "name": "updated_at",
370
- "type": "timestamp",
371
- "primaryKey": false,
372
- "notNull": true,
373
- "default": "now()"
374
- }
375
- },
376
- "indexes": {
377
- "context_cache_lookup_idx": {
378
- "name": "context_cache_lookup_idx",
379
- "columns": [
380
- {
381
- "expression": "conversation_id",
382
- "isExpression": false,
383
- "asc": true,
384
- "nulls": "last"
385
- },
386
- {
387
- "expression": "context_config_id",
388
- "isExpression": false,
389
- "asc": true,
390
- "nulls": "last"
391
- },
392
- {
393
- "expression": "context_variable_key",
394
- "isExpression": false,
395
- "asc": true,
396
- "nulls": "last"
397
- }
398
- ],
399
- "isUnique": false,
400
- "concurrently": false,
401
- "method": "btree",
402
- "with": {}
403
- }
404
- },
405
- "foreignKeys": {
406
- "context_cache_conversation_fk": {
407
- "name": "context_cache_conversation_fk",
408
- "tableFrom": "context_cache",
409
- "tableTo": "conversations",
410
- "columnsFrom": [
411
- "tenant_id",
412
- "project_id",
413
- "conversation_id"
414
- ],
415
- "columnsTo": [
416
- "tenant_id",
417
- "project_id",
418
- "id"
419
- ],
420
- "onDelete": "cascade",
421
- "onUpdate": "no action"
422
- }
423
- },
424
- "compositePrimaryKeys": {
425
- "context_cache_tenant_id_project_id_id_pk": {
426
- "name": "context_cache_tenant_id_project_id_id_pk",
427
- "columns": [
428
- "tenant_id",
429
- "project_id",
430
- "id"
431
- ]
432
- }
433
- },
434
- "uniqueConstraints": {},
435
- "policies": {},
436
- "checkConstraints": {},
437
- "isRLSEnabled": false
438
- },
439
- "public.conversations": {
440
- "name": "conversations",
441
- "schema": "",
442
- "columns": {
443
- "tenant_id": {
444
- "name": "tenant_id",
445
- "type": "varchar(256)",
446
- "primaryKey": false,
447
- "notNull": true
448
- },
449
- "id": {
450
- "name": "id",
451
- "type": "varchar(256)",
452
- "primaryKey": false,
453
- "notNull": true
454
- },
455
- "project_id": {
456
- "name": "project_id",
457
- "type": "varchar(256)",
458
- "primaryKey": false,
459
- "notNull": true
460
- },
461
- "user_id": {
462
- "name": "user_id",
463
- "type": "varchar(256)",
464
- "primaryKey": false,
465
- "notNull": false
466
- },
467
- "agent_id": {
468
- "name": "agent_id",
469
- "type": "varchar(256)",
470
- "primaryKey": false,
471
- "notNull": false
472
- },
473
- "active_sub_agent_id": {
474
- "name": "active_sub_agent_id",
475
- "type": "varchar(256)",
476
- "primaryKey": false,
477
- "notNull": true
478
- },
479
- "ref": {
480
- "name": "ref",
481
- "type": "jsonb",
482
- "primaryKey": false,
483
- "notNull": false
484
- },
485
- "title": {
486
- "name": "title",
487
- "type": "text",
488
- "primaryKey": false,
489
- "notNull": false
490
- },
491
- "last_context_resolution": {
492
- "name": "last_context_resolution",
493
- "type": "timestamp",
494
- "primaryKey": false,
495
- "notNull": false
496
- },
497
- "metadata": {
498
- "name": "metadata",
499
- "type": "jsonb",
500
- "primaryKey": false,
501
- "notNull": false
502
- },
503
- "created_at": {
504
- "name": "created_at",
505
- "type": "timestamp",
506
- "primaryKey": false,
507
- "notNull": true,
508
- "default": "now()"
509
- },
510
- "updated_at": {
511
- "name": "updated_at",
512
- "type": "timestamp",
513
- "primaryKey": false,
514
- "notNull": true,
515
- "default": "now()"
516
- }
517
- },
518
- "indexes": {},
519
- "foreignKeys": {},
520
- "compositePrimaryKeys": {
521
- "conversations_tenant_id_project_id_id_pk": {
522
- "name": "conversations_tenant_id_project_id_id_pk",
523
- "columns": [
524
- "tenant_id",
525
- "project_id",
526
- "id"
527
- ]
528
- }
529
- },
530
- "uniqueConstraints": {},
531
- "policies": {},
532
- "checkConstraints": {},
533
- "isRLSEnabled": false
534
- },
535
- "public.dataset_run": {
536
- "name": "dataset_run",
537
- "schema": "",
538
- "columns": {
539
- "tenant_id": {
540
- "name": "tenant_id",
541
- "type": "varchar(256)",
542
- "primaryKey": false,
543
- "notNull": true
544
- },
545
- "id": {
546
- "name": "id",
547
- "type": "varchar(256)",
548
- "primaryKey": false,
549
- "notNull": true
550
- },
551
- "project_id": {
552
- "name": "project_id",
553
- "type": "varchar(256)",
554
- "primaryKey": false,
555
- "notNull": true
556
- },
557
- "dataset_id": {
558
- "name": "dataset_id",
559
- "type": "text",
560
- "primaryKey": false,
561
- "notNull": true
562
- },
563
- "dataset_run_config_id": {
564
- "name": "dataset_run_config_id",
565
- "type": "text",
566
- "primaryKey": false,
567
- "notNull": false
568
- },
569
- "evaluation_job_config_id": {
570
- "name": "evaluation_job_config_id",
571
- "type": "text",
572
- "primaryKey": false,
573
- "notNull": false
574
- },
575
- "created_at": {
576
- "name": "created_at",
577
- "type": "timestamp",
578
- "primaryKey": false,
579
- "notNull": true,
580
- "default": "now()"
581
- },
582
- "updated_at": {
583
- "name": "updated_at",
584
- "type": "timestamp",
585
- "primaryKey": false,
586
- "notNull": true,
587
- "default": "now()"
588
- }
589
- },
590
- "indexes": {},
591
- "foreignKeys": {},
592
- "compositePrimaryKeys": {
593
- "dataset_run_tenant_id_project_id_id_pk": {
594
- "name": "dataset_run_tenant_id_project_id_id_pk",
595
- "columns": [
596
- "tenant_id",
597
- "project_id",
598
- "id"
599
- ]
600
- }
601
- },
602
- "uniqueConstraints": {},
603
- "policies": {},
604
- "checkConstraints": {},
605
- "isRLSEnabled": false
606
- },
607
- "public.dataset_run_conversation_relations": {
608
- "name": "dataset_run_conversation_relations",
609
- "schema": "",
610
- "columns": {
611
- "tenant_id": {
612
- "name": "tenant_id",
613
- "type": "varchar(256)",
614
- "primaryKey": false,
615
- "notNull": true
616
- },
617
- "id": {
618
- "name": "id",
619
- "type": "varchar(256)",
620
- "primaryKey": false,
621
- "notNull": true
622
- },
623
- "project_id": {
624
- "name": "project_id",
625
- "type": "varchar(256)",
626
- "primaryKey": false,
627
- "notNull": true
628
- },
629
- "dataset_run_id": {
630
- "name": "dataset_run_id",
631
- "type": "text",
632
- "primaryKey": false,
633
- "notNull": true
634
- },
635
- "conversation_id": {
636
- "name": "conversation_id",
637
- "type": "text",
638
- "primaryKey": false,
639
- "notNull": true
640
- },
641
- "dataset_item_id": {
642
- "name": "dataset_item_id",
643
- "type": "text",
644
- "primaryKey": false,
645
- "notNull": true
646
- },
647
- "created_at": {
648
- "name": "created_at",
649
- "type": "timestamp",
650
- "primaryKey": false,
651
- "notNull": true,
652
- "default": "now()"
653
- },
654
- "updated_at": {
655
- "name": "updated_at",
656
- "type": "timestamp",
657
- "primaryKey": false,
658
- "notNull": true,
659
- "default": "now()"
660
- }
661
- },
662
- "indexes": {},
663
- "foreignKeys": {
664
- "dataset_run_conversation_relations_run_fk": {
665
- "name": "dataset_run_conversation_relations_run_fk",
666
- "tableFrom": "dataset_run_conversation_relations",
667
- "tableTo": "dataset_run",
668
- "columnsFrom": [
669
- "tenant_id",
670
- "project_id",
671
- "dataset_run_id"
672
- ],
673
- "columnsTo": [
674
- "tenant_id",
675
- "project_id",
676
- "id"
677
- ],
678
- "onDelete": "cascade",
679
- "onUpdate": "no action"
680
- },
681
- "dataset_run_conversation_relations_conversation_fk": {
682
- "name": "dataset_run_conversation_relations_conversation_fk",
683
- "tableFrom": "dataset_run_conversation_relations",
684
- "tableTo": "conversations",
685
- "columnsFrom": [
686
- "tenant_id",
687
- "project_id",
688
- "conversation_id"
689
- ],
690
- "columnsTo": [
691
- "tenant_id",
692
- "project_id",
693
- "id"
694
- ],
695
- "onDelete": "cascade",
696
- "onUpdate": "no action"
697
- }
698
- },
699
- "compositePrimaryKeys": {
700
- "dataset_run_conversation_relations_tenant_id_project_id_id_pk": {
701
- "name": "dataset_run_conversation_relations_tenant_id_project_id_id_pk",
702
- "columns": [
703
- "tenant_id",
704
- "project_id",
705
- "id"
706
- ]
707
- }
708
- },
709
- "uniqueConstraints": {
710
- "dataset_run_conversation_relations_unique": {
711
- "name": "dataset_run_conversation_relations_unique",
712
- "nullsNotDistinct": false,
713
- "columns": [
714
- "dataset_run_id",
715
- "conversation_id"
716
- ]
717
- }
718
- },
719
- "policies": {},
720
- "checkConstraints": {},
721
- "isRLSEnabled": false
722
- },
723
- "public.device_code": {
724
- "name": "device_code",
725
- "schema": "",
726
- "columns": {
727
- "id": {
728
- "name": "id",
729
- "type": "text",
730
- "primaryKey": true,
731
- "notNull": true
732
- },
733
- "device_code": {
734
- "name": "device_code",
735
- "type": "text",
736
- "primaryKey": false,
737
- "notNull": true
738
- },
739
- "user_code": {
740
- "name": "user_code",
741
- "type": "text",
742
- "primaryKey": false,
743
- "notNull": true
744
- },
745
- "user_id": {
746
- "name": "user_id",
747
- "type": "text",
748
- "primaryKey": false,
749
- "notNull": false
750
- },
751
- "expires_at": {
752
- "name": "expires_at",
753
- "type": "timestamp",
754
- "primaryKey": false,
755
- "notNull": true
756
- },
757
- "status": {
758
- "name": "status",
759
- "type": "text",
760
- "primaryKey": false,
761
- "notNull": true
762
- },
763
- "last_polled_at": {
764
- "name": "last_polled_at",
765
- "type": "timestamp",
766
- "primaryKey": false,
767
- "notNull": false
768
- },
769
- "polling_interval": {
770
- "name": "polling_interval",
771
- "type": "integer",
772
- "primaryKey": false,
773
- "notNull": false
774
- },
775
- "client_id": {
776
- "name": "client_id",
777
- "type": "text",
778
- "primaryKey": false,
779
- "notNull": false
780
- },
781
- "scope": {
782
- "name": "scope",
783
- "type": "text",
784
- "primaryKey": false,
785
- "notNull": false
786
- }
787
- },
788
- "indexes": {},
789
- "foreignKeys": {},
790
- "compositePrimaryKeys": {},
791
- "uniqueConstraints": {},
792
- "policies": {},
793
- "checkConstraints": {},
794
- "isRLSEnabled": false
795
- },
796
- "public.evaluation_result": {
797
- "name": "evaluation_result",
798
- "schema": "",
799
- "columns": {
800
- "tenant_id": {
801
- "name": "tenant_id",
802
- "type": "varchar(256)",
803
- "primaryKey": false,
804
- "notNull": true
805
- },
806
- "id": {
807
- "name": "id",
808
- "type": "varchar(256)",
809
- "primaryKey": false,
810
- "notNull": true
811
- },
812
- "project_id": {
813
- "name": "project_id",
814
- "type": "varchar(256)",
815
- "primaryKey": false,
816
- "notNull": true
817
- },
818
- "conversation_id": {
819
- "name": "conversation_id",
820
- "type": "text",
821
- "primaryKey": false,
822
- "notNull": true
823
- },
824
- "evaluator_id": {
825
- "name": "evaluator_id",
826
- "type": "text",
827
- "primaryKey": false,
828
- "notNull": true
829
- },
830
- "evaluation_run_id": {
831
- "name": "evaluation_run_id",
832
- "type": "text",
833
- "primaryKey": false,
834
- "notNull": false
835
- },
836
- "output": {
837
- "name": "output",
838
- "type": "jsonb",
839
- "primaryKey": false,
840
- "notNull": false
841
- },
842
- "created_at": {
843
- "name": "created_at",
844
- "type": "timestamp",
845
- "primaryKey": false,
846
- "notNull": true,
847
- "default": "now()"
848
- },
849
- "updated_at": {
850
- "name": "updated_at",
851
- "type": "timestamp",
852
- "primaryKey": false,
853
- "notNull": true,
854
- "default": "now()"
855
- }
856
- },
857
- "indexes": {},
858
- "foreignKeys": {
859
- "evaluation_result_conversation_fk": {
860
- "name": "evaluation_result_conversation_fk",
861
- "tableFrom": "evaluation_result",
862
- "tableTo": "conversations",
863
- "columnsFrom": [
864
- "tenant_id",
865
- "project_id",
866
- "conversation_id"
867
- ],
868
- "columnsTo": [
869
- "tenant_id",
870
- "project_id",
871
- "id"
872
- ],
873
- "onDelete": "cascade",
874
- "onUpdate": "no action"
875
- },
876
- "evaluation_result_evaluation_run_fk": {
877
- "name": "evaluation_result_evaluation_run_fk",
878
- "tableFrom": "evaluation_result",
879
- "tableTo": "evaluation_run",
880
- "columnsFrom": [
881
- "tenant_id",
882
- "project_id",
883
- "evaluation_run_id"
884
- ],
885
- "columnsTo": [
886
- "tenant_id",
887
- "project_id",
888
- "id"
889
- ],
890
- "onDelete": "cascade",
891
- "onUpdate": "no action"
892
- }
893
- },
894
- "compositePrimaryKeys": {
895
- "evaluation_result_tenant_id_project_id_id_pk": {
896
- "name": "evaluation_result_tenant_id_project_id_id_pk",
897
- "columns": [
898
- "tenant_id",
899
- "project_id",
900
- "id"
901
- ]
902
- }
903
- },
904
- "uniqueConstraints": {},
905
- "policies": {},
906
- "checkConstraints": {},
907
- "isRLSEnabled": false
908
- },
909
- "public.evaluation_run": {
910
- "name": "evaluation_run",
911
- "schema": "",
912
- "columns": {
913
- "tenant_id": {
914
- "name": "tenant_id",
915
- "type": "varchar(256)",
916
- "primaryKey": false,
917
- "notNull": true
918
- },
919
- "id": {
920
- "name": "id",
921
- "type": "varchar(256)",
922
- "primaryKey": false,
923
- "notNull": true
924
- },
925
- "project_id": {
926
- "name": "project_id",
927
- "type": "varchar(256)",
928
- "primaryKey": false,
929
- "notNull": true
930
- },
931
- "evaluation_job_config_id": {
932
- "name": "evaluation_job_config_id",
933
- "type": "text",
934
- "primaryKey": false,
935
- "notNull": false
936
- },
937
- "evaluation_run_config_id": {
938
- "name": "evaluation_run_config_id",
939
- "type": "text",
940
- "primaryKey": false,
941
- "notNull": false
942
- },
943
- "created_at": {
944
- "name": "created_at",
945
- "type": "timestamp",
946
- "primaryKey": false,
947
- "notNull": true,
948
- "default": "now()"
949
- },
950
- "updated_at": {
951
- "name": "updated_at",
952
- "type": "timestamp",
953
- "primaryKey": false,
954
- "notNull": true,
955
- "default": "now()"
956
- }
957
- },
958
- "indexes": {},
959
- "foreignKeys": {},
960
- "compositePrimaryKeys": {
961
- "evaluation_run_tenant_id_project_id_id_pk": {
962
- "name": "evaluation_run_tenant_id_project_id_id_pk",
963
- "columns": [
964
- "tenant_id",
965
- "project_id",
966
- "id"
967
- ]
968
- }
969
- },
970
- "uniqueConstraints": {},
971
- "policies": {},
972
- "checkConstraints": {},
973
- "isRLSEnabled": false
974
- },
975
- "public.invitation": {
976
- "name": "invitation",
977
- "schema": "",
978
- "columns": {
979
- "id": {
980
- "name": "id",
981
- "type": "text",
982
- "primaryKey": true,
983
- "notNull": true
984
- },
985
- "organization_id": {
986
- "name": "organization_id",
987
- "type": "text",
988
- "primaryKey": false,
989
- "notNull": true
990
- },
991
- "email": {
992
- "name": "email",
993
- "type": "text",
994
- "primaryKey": false,
995
- "notNull": true
996
- },
997
- "role": {
998
- "name": "role",
999
- "type": "text",
1000
- "primaryKey": false,
1001
- "notNull": false
1002
- },
1003
- "status": {
1004
- "name": "status",
1005
- "type": "text",
1006
- "primaryKey": false,
1007
- "notNull": true,
1008
- "default": "'pending'"
1009
- },
1010
- "expires_at": {
1011
- "name": "expires_at",
1012
- "type": "timestamp",
1013
- "primaryKey": false,
1014
- "notNull": true
1015
- },
1016
- "created_at": {
1017
- "name": "created_at",
1018
- "type": "timestamp",
1019
- "primaryKey": false,
1020
- "notNull": true,
1021
- "default": "now()"
1022
- },
1023
- "inviter_id": {
1024
- "name": "inviter_id",
1025
- "type": "text",
1026
- "primaryKey": false,
1027
- "notNull": true
1028
- }
1029
- },
1030
- "indexes": {
1031
- "invitation_organizationId_idx": {
1032
- "name": "invitation_organizationId_idx",
1033
- "columns": [
1034
- {
1035
- "expression": "organization_id",
1036
- "isExpression": false,
1037
- "asc": true,
1038
- "nulls": "last"
1039
- }
1040
- ],
1041
- "isUnique": false,
1042
- "concurrently": false,
1043
- "method": "btree",
1044
- "with": {}
1045
- },
1046
- "invitation_email_idx": {
1047
- "name": "invitation_email_idx",
1048
- "columns": [
1049
- {
1050
- "expression": "email",
1051
- "isExpression": false,
1052
- "asc": true,
1053
- "nulls": "last"
1054
- }
1055
- ],
1056
- "isUnique": false,
1057
- "concurrently": false,
1058
- "method": "btree",
1059
- "with": {}
1060
- }
1061
- },
1062
- "foreignKeys": {
1063
- "invitation_organization_id_organization_id_fk": {
1064
- "name": "invitation_organization_id_organization_id_fk",
1065
- "tableFrom": "invitation",
1066
- "tableTo": "organization",
1067
- "columnsFrom": [
1068
- "organization_id"
1069
- ],
1070
- "columnsTo": [
1071
- "id"
1072
- ],
1073
- "onDelete": "cascade",
1074
- "onUpdate": "no action"
1075
- },
1076
- "invitation_inviter_id_user_id_fk": {
1077
- "name": "invitation_inviter_id_user_id_fk",
1078
- "tableFrom": "invitation",
1079
- "tableTo": "user",
1080
- "columnsFrom": [
1081
- "inviter_id"
1082
- ],
1083
- "columnsTo": [
1084
- "id"
1085
- ],
1086
- "onDelete": "cascade",
1087
- "onUpdate": "no action"
1088
- }
1089
- },
1090
- "compositePrimaryKeys": {},
1091
- "uniqueConstraints": {},
1092
- "policies": {},
1093
- "checkConstraints": {},
1094
- "isRLSEnabled": false
1095
- },
1096
- "public.ledger_artifacts": {
1097
- "name": "ledger_artifacts",
1098
- "schema": "",
1099
- "columns": {
1100
- "tenant_id": {
1101
- "name": "tenant_id",
1102
- "type": "varchar(256)",
1103
- "primaryKey": false,
1104
- "notNull": true
1105
- },
1106
- "id": {
1107
- "name": "id",
1108
- "type": "varchar(256)",
1109
- "primaryKey": false,
1110
- "notNull": true
1111
- },
1112
- "project_id": {
1113
- "name": "project_id",
1114
- "type": "varchar(256)",
1115
- "primaryKey": false,
1116
- "notNull": true
1117
- },
1118
- "task_id": {
1119
- "name": "task_id",
1120
- "type": "varchar(256)",
1121
- "primaryKey": false,
1122
- "notNull": true
1123
- },
1124
- "tool_call_id": {
1125
- "name": "tool_call_id",
1126
- "type": "varchar(256)",
1127
- "primaryKey": false,
1128
- "notNull": false
1129
- },
1130
- "context_id": {
1131
- "name": "context_id",
1132
- "type": "varchar(256)",
1133
- "primaryKey": false,
1134
- "notNull": true
1135
- },
1136
- "type": {
1137
- "name": "type",
1138
- "type": "varchar(256)",
1139
- "primaryKey": false,
1140
- "notNull": true,
1141
- "default": "'source'"
1142
- },
1143
- "name": {
1144
- "name": "name",
1145
- "type": "varchar(256)",
1146
- "primaryKey": false,
1147
- "notNull": false
1148
- },
1149
- "description": {
1150
- "name": "description",
1151
- "type": "text",
1152
- "primaryKey": false,
1153
- "notNull": false
1154
- },
1155
- "parts": {
1156
- "name": "parts",
1157
- "type": "jsonb",
1158
- "primaryKey": false,
1159
- "notNull": false
1160
- },
1161
- "metadata": {
1162
- "name": "metadata",
1163
- "type": "jsonb",
1164
- "primaryKey": false,
1165
- "notNull": false
1166
- },
1167
- "summary": {
1168
- "name": "summary",
1169
- "type": "text",
1170
- "primaryKey": false,
1171
- "notNull": false
1172
- },
1173
- "mime": {
1174
- "name": "mime",
1175
- "type": "jsonb",
1176
- "primaryKey": false,
1177
- "notNull": false
1178
- },
1179
- "visibility": {
1180
- "name": "visibility",
1181
- "type": "varchar(256)",
1182
- "primaryKey": false,
1183
- "notNull": false,
1184
- "default": "'context'"
1185
- },
1186
- "allowed_agents": {
1187
- "name": "allowed_agents",
1188
- "type": "jsonb",
1189
- "primaryKey": false,
1190
- "notNull": false
1191
- },
1192
- "derived_from": {
1193
- "name": "derived_from",
1194
- "type": "varchar(256)",
1195
- "primaryKey": false,
1196
- "notNull": false
1197
- },
1198
- "created_at": {
1199
- "name": "created_at",
1200
- "type": "timestamp",
1201
- "primaryKey": false,
1202
- "notNull": true,
1203
- "default": "now()"
1204
- },
1205
- "updated_at": {
1206
- "name": "updated_at",
1207
- "type": "timestamp",
1208
- "primaryKey": false,
1209
- "notNull": true,
1210
- "default": "now()"
1211
- }
1212
- },
1213
- "indexes": {
1214
- "ledger_artifacts_task_id_idx": {
1215
- "name": "ledger_artifacts_task_id_idx",
1216
- "columns": [
1217
- {
1218
- "expression": "task_id",
1219
- "isExpression": false,
1220
- "asc": true,
1221
- "nulls": "last"
1222
- }
1223
- ],
1224
- "isUnique": false,
1225
- "concurrently": false,
1226
- "method": "btree",
1227
- "with": {}
1228
- },
1229
- "ledger_artifacts_tool_call_id_idx": {
1230
- "name": "ledger_artifacts_tool_call_id_idx",
1231
- "columns": [
1232
- {
1233
- "expression": "tool_call_id",
1234
- "isExpression": false,
1235
- "asc": true,
1236
- "nulls": "last"
1237
- }
1238
- ],
1239
- "isUnique": false,
1240
- "concurrently": false,
1241
- "method": "btree",
1242
- "with": {}
1243
- },
1244
- "ledger_artifacts_context_id_idx": {
1245
- "name": "ledger_artifacts_context_id_idx",
1246
- "columns": [
1247
- {
1248
- "expression": "context_id",
1249
- "isExpression": false,
1250
- "asc": true,
1251
- "nulls": "last"
1252
- }
1253
- ],
1254
- "isUnique": false,
1255
- "concurrently": false,
1256
- "method": "btree",
1257
- "with": {}
1258
- }
1259
- },
1260
- "foreignKeys": {
1261
- "ledger_artifacts_conversation_fk": {
1262
- "name": "ledger_artifacts_conversation_fk",
1263
- "tableFrom": "ledger_artifacts",
1264
- "tableTo": "conversations",
1265
- "columnsFrom": [
1266
- "tenant_id",
1267
- "project_id",
1268
- "context_id"
1269
- ],
1270
- "columnsTo": [
1271
- "tenant_id",
1272
- "project_id",
1273
- "id"
1274
- ],
1275
- "onDelete": "cascade",
1276
- "onUpdate": "no action"
1277
- }
1278
- },
1279
- "compositePrimaryKeys": {
1280
- "ledger_artifacts_tenant_id_project_id_id_task_id_pk": {
1281
- "name": "ledger_artifacts_tenant_id_project_id_id_task_id_pk",
1282
- "columns": [
1283
- "tenant_id",
1284
- "project_id",
1285
- "id",
1286
- "task_id"
1287
- ]
1288
- }
1289
- },
1290
- "uniqueConstraints": {
1291
- "ledger_artifacts_task_context_name_unique": {
1292
- "name": "ledger_artifacts_task_context_name_unique",
1293
- "nullsNotDistinct": false,
1294
- "columns": [
1295
- "task_id",
1296
- "context_id",
1297
- "name"
1298
- ]
1299
- }
1300
- },
1301
- "policies": {},
1302
- "checkConstraints": {},
1303
- "isRLSEnabled": false
1304
- },
1305
- "public.member": {
1306
- "name": "member",
1307
- "schema": "",
1308
- "columns": {
1309
- "id": {
1310
- "name": "id",
1311
- "type": "text",
1312
- "primaryKey": true,
1313
- "notNull": true
1314
- },
1315
- "organization_id": {
1316
- "name": "organization_id",
1317
- "type": "text",
1318
- "primaryKey": false,
1319
- "notNull": true
1320
- },
1321
- "user_id": {
1322
- "name": "user_id",
1323
- "type": "text",
1324
- "primaryKey": false,
1325
- "notNull": true
1326
- },
1327
- "role": {
1328
- "name": "role",
1329
- "type": "text",
1330
- "primaryKey": false,
1331
- "notNull": true,
1332
- "default": "'member'"
1333
- },
1334
- "created_at": {
1335
- "name": "created_at",
1336
- "type": "timestamp",
1337
- "primaryKey": false,
1338
- "notNull": true
1339
- }
1340
- },
1341
- "indexes": {
1342
- "member_organizationId_idx": {
1343
- "name": "member_organizationId_idx",
1344
- "columns": [
1345
- {
1346
- "expression": "organization_id",
1347
- "isExpression": false,
1348
- "asc": true,
1349
- "nulls": "last"
1350
- }
1351
- ],
1352
- "isUnique": false,
1353
- "concurrently": false,
1354
- "method": "btree",
1355
- "with": {}
1356
- },
1357
- "member_userId_idx": {
1358
- "name": "member_userId_idx",
1359
- "columns": [
1360
- {
1361
- "expression": "user_id",
1362
- "isExpression": false,
1363
- "asc": true,
1364
- "nulls": "last"
1365
- }
1366
- ],
1367
- "isUnique": false,
1368
- "concurrently": false,
1369
- "method": "btree",
1370
- "with": {}
1371
- }
1372
- },
1373
- "foreignKeys": {
1374
- "member_organization_id_organization_id_fk": {
1375
- "name": "member_organization_id_organization_id_fk",
1376
- "tableFrom": "member",
1377
- "tableTo": "organization",
1378
- "columnsFrom": [
1379
- "organization_id"
1380
- ],
1381
- "columnsTo": [
1382
- "id"
1383
- ],
1384
- "onDelete": "cascade",
1385
- "onUpdate": "no action"
1386
- },
1387
- "member_user_id_user_id_fk": {
1388
- "name": "member_user_id_user_id_fk",
1389
- "tableFrom": "member",
1390
- "tableTo": "user",
1391
- "columnsFrom": [
1392
- "user_id"
1393
- ],
1394
- "columnsTo": [
1395
- "id"
1396
- ],
1397
- "onDelete": "cascade",
1398
- "onUpdate": "no action"
1399
- }
1400
- },
1401
- "compositePrimaryKeys": {},
1402
- "uniqueConstraints": {},
1403
- "policies": {},
1404
- "checkConstraints": {},
1405
- "isRLSEnabled": false
1406
- },
1407
- "public.messages": {
1408
- "name": "messages",
1409
- "schema": "",
1410
- "columns": {
1411
- "tenant_id": {
1412
- "name": "tenant_id",
1413
- "type": "varchar(256)",
1414
- "primaryKey": false,
1415
- "notNull": true
1416
- },
1417
- "id": {
1418
- "name": "id",
1419
- "type": "varchar(256)",
1420
- "primaryKey": false,
1421
- "notNull": true
1422
- },
1423
- "project_id": {
1424
- "name": "project_id",
1425
- "type": "varchar(256)",
1426
- "primaryKey": false,
1427
- "notNull": true
1428
- },
1429
- "conversation_id": {
1430
- "name": "conversation_id",
1431
- "type": "varchar(256)",
1432
- "primaryKey": false,
1433
- "notNull": true
1434
- },
1435
- "role": {
1436
- "name": "role",
1437
- "type": "varchar(256)",
1438
- "primaryKey": false,
1439
- "notNull": true
1440
- },
1441
- "from_sub_agent_id": {
1442
- "name": "from_sub_agent_id",
1443
- "type": "varchar(256)",
1444
- "primaryKey": false,
1445
- "notNull": false
1446
- },
1447
- "to_sub_agent_id": {
1448
- "name": "to_sub_agent_id",
1449
- "type": "varchar(256)",
1450
- "primaryKey": false,
1451
- "notNull": false
1452
- },
1453
- "from_external_sub_agent_id": {
1454
- "name": "from_external_sub_agent_id",
1455
- "type": "varchar(256)",
1456
- "primaryKey": false,
1457
- "notNull": false
1458
- },
1459
- "to_external_sub_agent_id": {
1460
- "name": "to_external_sub_agent_id",
1461
- "type": "varchar(256)",
1462
- "primaryKey": false,
1463
- "notNull": false
1464
- },
1465
- "from_team_agent_id": {
1466
- "name": "from_team_agent_id",
1467
- "type": "varchar(256)",
1468
- "primaryKey": false,
1469
- "notNull": false
1470
- },
1471
- "to_team_agent_id": {
1472
- "name": "to_team_agent_id",
1473
- "type": "varchar(256)",
1474
- "primaryKey": false,
1475
- "notNull": false
1476
- },
1477
- "content": {
1478
- "name": "content",
1479
- "type": "jsonb",
1480
- "primaryKey": false,
1481
- "notNull": true
1482
- },
1483
- "visibility": {
1484
- "name": "visibility",
1485
- "type": "varchar(256)",
1486
- "primaryKey": false,
1487
- "notNull": true,
1488
- "default": "'user-facing'"
1489
- },
1490
- "message_type": {
1491
- "name": "message_type",
1492
- "type": "varchar(256)",
1493
- "primaryKey": false,
1494
- "notNull": true,
1495
- "default": "'chat'"
1496
- },
1497
- "task_id": {
1498
- "name": "task_id",
1499
- "type": "varchar(256)",
1500
- "primaryKey": false,
1501
- "notNull": false
1502
- },
1503
- "parent_message_id": {
1504
- "name": "parent_message_id",
1505
- "type": "varchar(256)",
1506
- "primaryKey": false,
1507
- "notNull": false
1508
- },
1509
- "a2a_task_id": {
1510
- "name": "a2a_task_id",
1511
- "type": "varchar(256)",
1512
- "primaryKey": false,
1513
- "notNull": false
1514
- },
1515
- "a2a_session_id": {
1516
- "name": "a2a_session_id",
1517
- "type": "varchar(256)",
1518
- "primaryKey": false,
1519
- "notNull": false
1520
- },
1521
- "metadata": {
1522
- "name": "metadata",
1523
- "type": "jsonb",
1524
- "primaryKey": false,
1525
- "notNull": false
1526
- },
1527
- "created_at": {
1528
- "name": "created_at",
1529
- "type": "timestamp",
1530
- "primaryKey": false,
1531
- "notNull": true,
1532
- "default": "now()"
1533
- },
1534
- "updated_at": {
1535
- "name": "updated_at",
1536
- "type": "timestamp",
1537
- "primaryKey": false,
1538
- "notNull": true,
1539
- "default": "now()"
1540
- }
1541
- },
1542
- "indexes": {},
1543
- "foreignKeys": {
1544
- "messages_conversation_fk": {
1545
- "name": "messages_conversation_fk",
1546
- "tableFrom": "messages",
1547
- "tableTo": "conversations",
1548
- "columnsFrom": [
1549
- "tenant_id",
1550
- "project_id",
1551
- "conversation_id"
1552
- ],
1553
- "columnsTo": [
1554
- "tenant_id",
1555
- "project_id",
1556
- "id"
1557
- ],
1558
- "onDelete": "cascade",
1559
- "onUpdate": "no action"
1560
- }
1561
- },
1562
- "compositePrimaryKeys": {
1563
- "messages_tenant_id_project_id_id_pk": {
1564
- "name": "messages_tenant_id_project_id_id_pk",
1565
- "columns": [
1566
- "tenant_id",
1567
- "project_id",
1568
- "id"
1569
- ]
1570
- }
1571
- },
1572
- "uniqueConstraints": {},
1573
- "policies": {},
1574
- "checkConstraints": {},
1575
- "isRLSEnabled": false
1576
- },
1577
- "public.organization": {
1578
- "name": "organization",
1579
- "schema": "",
1580
- "columns": {
1581
- "id": {
1582
- "name": "id",
1583
- "type": "text",
1584
- "primaryKey": true,
1585
- "notNull": true
1586
- },
1587
- "name": {
1588
- "name": "name",
1589
- "type": "text",
1590
- "primaryKey": false,
1591
- "notNull": true
1592
- },
1593
- "slug": {
1594
- "name": "slug",
1595
- "type": "text",
1596
- "primaryKey": false,
1597
- "notNull": true
1598
- },
1599
- "logo": {
1600
- "name": "logo",
1601
- "type": "text",
1602
- "primaryKey": false,
1603
- "notNull": false
1604
- },
1605
- "created_at": {
1606
- "name": "created_at",
1607
- "type": "timestamp",
1608
- "primaryKey": false,
1609
- "notNull": true
1610
- },
1611
- "metadata": {
1612
- "name": "metadata",
1613
- "type": "text",
1614
- "primaryKey": false,
1615
- "notNull": false
1616
- }
1617
- },
1618
- "indexes": {},
1619
- "foreignKeys": {},
1620
- "compositePrimaryKeys": {},
1621
- "uniqueConstraints": {
1622
- "organization_slug_unique": {
1623
- "name": "organization_slug_unique",
1624
- "nullsNotDistinct": false,
1625
- "columns": [
1626
- "slug"
1627
- ]
1628
- }
1629
- },
1630
- "policies": {},
1631
- "checkConstraints": {},
1632
- "isRLSEnabled": false
1633
- },
1634
- "public.project_metadata": {
1635
- "name": "project_metadata",
1636
- "schema": "",
1637
- "columns": {
1638
- "id": {
1639
- "name": "id",
1640
- "type": "varchar(256)",
1641
- "primaryKey": false,
1642
- "notNull": true
1643
- },
1644
- "tenant_id": {
1645
- "name": "tenant_id",
1646
- "type": "varchar(256)",
1647
- "primaryKey": false,
1648
- "notNull": true
1649
- },
1650
- "created_at": {
1651
- "name": "created_at",
1652
- "type": "timestamp",
1653
- "primaryKey": false,
1654
- "notNull": true,
1655
- "default": "now()"
1656
- },
1657
- "created_by": {
1658
- "name": "created_by",
1659
- "type": "varchar(256)",
1660
- "primaryKey": false,
1661
- "notNull": false
1662
- },
1663
- "main_branch_name": {
1664
- "name": "main_branch_name",
1665
- "type": "varchar(512)",
1666
- "primaryKey": false,
1667
- "notNull": true
1668
- }
1669
- },
1670
- "indexes": {
1671
- "project_metadata_tenant_idx": {
1672
- "name": "project_metadata_tenant_idx",
1673
- "columns": [
1674
- {
1675
- "expression": "tenant_id",
1676
- "isExpression": false,
1677
- "asc": true,
1678
- "nulls": "last"
1679
- }
1680
- ],
1681
- "isUnique": false,
1682
- "concurrently": false,
1683
- "method": "btree",
1684
- "with": {}
1685
- },
1686
- "project_metadata_main_branch_idx": {
1687
- "name": "project_metadata_main_branch_idx",
1688
- "columns": [
1689
- {
1690
- "expression": "main_branch_name",
1691
- "isExpression": false,
1692
- "asc": true,
1693
- "nulls": "last"
1694
- }
1695
- ],
1696
- "isUnique": false,
1697
- "concurrently": false,
1698
- "method": "btree",
1699
- "with": {}
1700
- }
1701
- },
1702
- "foreignKeys": {
1703
- "project_metadata_organization_fk": {
1704
- "name": "project_metadata_organization_fk",
1705
- "tableFrom": "project_metadata",
1706
- "tableTo": "organization",
1707
- "columnsFrom": [
1708
- "tenant_id"
1709
- ],
1710
- "columnsTo": [
1711
- "id"
1712
- ],
1713
- "onDelete": "cascade",
1714
- "onUpdate": "no action"
1715
- }
1716
- },
1717
- "compositePrimaryKeys": {
1718
- "project_metadata_tenant_id_id_pk": {
1719
- "name": "project_metadata_tenant_id_id_pk",
1720
- "columns": [
1721
- "tenant_id",
1722
- "id"
1723
- ]
1724
- }
1725
- },
1726
- "uniqueConstraints": {},
1727
- "policies": {},
1728
- "checkConstraints": {},
1729
- "isRLSEnabled": false
1730
- },
1731
- "public.session": {
1732
- "name": "session",
1733
- "schema": "",
1734
- "columns": {
1735
- "id": {
1736
- "name": "id",
1737
- "type": "text",
1738
- "primaryKey": true,
1739
- "notNull": true
1740
- },
1741
- "expires_at": {
1742
- "name": "expires_at",
1743
- "type": "timestamp",
1744
- "primaryKey": false,
1745
- "notNull": true
1746
- },
1747
- "token": {
1748
- "name": "token",
1749
- "type": "text",
1750
- "primaryKey": false,
1751
- "notNull": true
1752
- },
1753
- "created_at": {
1754
- "name": "created_at",
1755
- "type": "timestamp",
1756
- "primaryKey": false,
1757
- "notNull": true,
1758
- "default": "now()"
1759
- },
1760
- "updated_at": {
1761
- "name": "updated_at",
1762
- "type": "timestamp",
1763
- "primaryKey": false,
1764
- "notNull": true
1765
- },
1766
- "ip_address": {
1767
- "name": "ip_address",
1768
- "type": "text",
1769
- "primaryKey": false,
1770
- "notNull": false
1771
- },
1772
- "user_agent": {
1773
- "name": "user_agent",
1774
- "type": "text",
1775
- "primaryKey": false,
1776
- "notNull": false
1777
- },
1778
- "user_id": {
1779
- "name": "user_id",
1780
- "type": "text",
1781
- "primaryKey": false,
1782
- "notNull": true
1783
- },
1784
- "active_organization_id": {
1785
- "name": "active_organization_id",
1786
- "type": "text",
1787
- "primaryKey": false,
1788
- "notNull": false
1789
- }
1790
- },
1791
- "indexes": {
1792
- "session_userId_idx": {
1793
- "name": "session_userId_idx",
1794
- "columns": [
1795
- {
1796
- "expression": "user_id",
1797
- "isExpression": false,
1798
- "asc": true,
1799
- "nulls": "last"
1800
- }
1801
- ],
1802
- "isUnique": false,
1803
- "concurrently": false,
1804
- "method": "btree",
1805
- "with": {}
1806
- }
1807
- },
1808
- "foreignKeys": {
1809
- "session_user_id_user_id_fk": {
1810
- "name": "session_user_id_user_id_fk",
1811
- "tableFrom": "session",
1812
- "tableTo": "user",
1813
- "columnsFrom": [
1814
- "user_id"
1815
- ],
1816
- "columnsTo": [
1817
- "id"
1818
- ],
1819
- "onDelete": "cascade",
1820
- "onUpdate": "no action"
1821
- }
1822
- },
1823
- "compositePrimaryKeys": {},
1824
- "uniqueConstraints": {
1825
- "session_token_unique": {
1826
- "name": "session_token_unique",
1827
- "nullsNotDistinct": false,
1828
- "columns": [
1829
- "token"
1830
- ]
1831
- }
1832
- },
1833
- "policies": {},
1834
- "checkConstraints": {},
1835
- "isRLSEnabled": false
1836
- },
1837
- "public.sso_provider": {
1838
- "name": "sso_provider",
1839
- "schema": "",
1840
- "columns": {
1841
- "id": {
1842
- "name": "id",
1843
- "type": "text",
1844
- "primaryKey": true,
1845
- "notNull": true
1846
- },
1847
- "issuer": {
1848
- "name": "issuer",
1849
- "type": "text",
1850
- "primaryKey": false,
1851
- "notNull": true
1852
- },
1853
- "oidc_config": {
1854
- "name": "oidc_config",
1855
- "type": "text",
1856
- "primaryKey": false,
1857
- "notNull": false
1858
- },
1859
- "saml_config": {
1860
- "name": "saml_config",
1861
- "type": "text",
1862
- "primaryKey": false,
1863
- "notNull": false
1864
- },
1865
- "user_id": {
1866
- "name": "user_id",
1867
- "type": "text",
1868
- "primaryKey": false,
1869
- "notNull": false
1870
- },
1871
- "provider_id": {
1872
- "name": "provider_id",
1873
- "type": "text",
1874
- "primaryKey": false,
1875
- "notNull": true
1876
- },
1877
- "organization_id": {
1878
- "name": "organization_id",
1879
- "type": "text",
1880
- "primaryKey": false,
1881
- "notNull": false
1882
- },
1883
- "domain": {
1884
- "name": "domain",
1885
- "type": "text",
1886
- "primaryKey": false,
1887
- "notNull": true
1888
- }
1889
- },
1890
- "indexes": {},
1891
- "foreignKeys": {
1892
- "sso_provider_user_id_user_id_fk": {
1893
- "name": "sso_provider_user_id_user_id_fk",
1894
- "tableFrom": "sso_provider",
1895
- "tableTo": "user",
1896
- "columnsFrom": [
1897
- "user_id"
1898
- ],
1899
- "columnsTo": [
1900
- "id"
1901
- ],
1902
- "onDelete": "cascade",
1903
- "onUpdate": "no action"
1904
- }
1905
- },
1906
- "compositePrimaryKeys": {},
1907
- "uniqueConstraints": {
1908
- "sso_provider_provider_id_unique": {
1909
- "name": "sso_provider_provider_id_unique",
1910
- "nullsNotDistinct": false,
1911
- "columns": [
1912
- "provider_id"
1913
- ]
1914
- }
1915
- },
1916
- "policies": {},
1917
- "checkConstraints": {},
1918
- "isRLSEnabled": false
1919
- },
1920
- "public.task_relations": {
1921
- "name": "task_relations",
1922
- "schema": "",
1923
- "columns": {
1924
- "tenant_id": {
1925
- "name": "tenant_id",
1926
- "type": "varchar(256)",
1927
- "primaryKey": false,
1928
- "notNull": true
1929
- },
1930
- "id": {
1931
- "name": "id",
1932
- "type": "varchar(256)",
1933
- "primaryKey": false,
1934
- "notNull": true
1935
- },
1936
- "project_id": {
1937
- "name": "project_id",
1938
- "type": "varchar(256)",
1939
- "primaryKey": false,
1940
- "notNull": true
1941
- },
1942
- "parent_task_id": {
1943
- "name": "parent_task_id",
1944
- "type": "varchar(256)",
1945
- "primaryKey": false,
1946
- "notNull": true
1947
- },
1948
- "child_task_id": {
1949
- "name": "child_task_id",
1950
- "type": "varchar(256)",
1951
- "primaryKey": false,
1952
- "notNull": true
1953
- },
1954
- "relation_type": {
1955
- "name": "relation_type",
1956
- "type": "varchar(256)",
1957
- "primaryKey": false,
1958
- "notNull": false,
1959
- "default": "'parent_child'"
1960
- },
1961
- "created_at": {
1962
- "name": "created_at",
1963
- "type": "timestamp",
1964
- "primaryKey": false,
1965
- "notNull": true,
1966
- "default": "now()"
1967
- },
1968
- "updated_at": {
1969
- "name": "updated_at",
1970
- "type": "timestamp",
1971
- "primaryKey": false,
1972
- "notNull": true,
1973
- "default": "now()"
1974
- }
1975
- },
1976
- "indexes": {},
1977
- "foreignKeys": {
1978
- "task_relations_parent_fk": {
1979
- "name": "task_relations_parent_fk",
1980
- "tableFrom": "task_relations",
1981
- "tableTo": "tasks",
1982
- "columnsFrom": [
1983
- "tenant_id",
1984
- "project_id",
1985
- "parent_task_id"
1986
- ],
1987
- "columnsTo": [
1988
- "tenant_id",
1989
- "project_id",
1990
- "id"
1991
- ],
1992
- "onDelete": "cascade",
1993
- "onUpdate": "no action"
1994
- },
1995
- "task_relations_child_fk": {
1996
- "name": "task_relations_child_fk",
1997
- "tableFrom": "task_relations",
1998
- "tableTo": "tasks",
1999
- "columnsFrom": [
2000
- "tenant_id",
2001
- "project_id",
2002
- "child_task_id"
2003
- ],
2004
- "columnsTo": [
2005
- "tenant_id",
2006
- "project_id",
2007
- "id"
2008
- ],
2009
- "onDelete": "cascade",
2010
- "onUpdate": "no action"
2011
- }
2012
- },
2013
- "compositePrimaryKeys": {
2014
- "task_relations_tenant_id_project_id_id_pk": {
2015
- "name": "task_relations_tenant_id_project_id_id_pk",
2016
- "columns": [
2017
- "tenant_id",
2018
- "project_id",
2019
- "id"
2020
- ]
2021
- }
2022
- },
2023
- "uniqueConstraints": {},
2024
- "policies": {},
2025
- "checkConstraints": {},
2026
- "isRLSEnabled": false
2027
- },
2028
- "public.tasks": {
2029
- "name": "tasks",
2030
- "schema": "",
2031
- "columns": {
2032
- "tenant_id": {
2033
- "name": "tenant_id",
2034
- "type": "varchar(256)",
2035
- "primaryKey": false,
2036
- "notNull": true
2037
- },
2038
- "id": {
2039
- "name": "id",
2040
- "type": "varchar(256)",
2041
- "primaryKey": false,
2042
- "notNull": true
2043
- },
2044
- "project_id": {
2045
- "name": "project_id",
2046
- "type": "varchar(256)",
2047
- "primaryKey": false,
2048
- "notNull": true
2049
- },
2050
- "agent_id": {
2051
- "name": "agent_id",
2052
- "type": "varchar(256)",
2053
- "primaryKey": false,
2054
- "notNull": true
2055
- },
2056
- "sub_agent_id": {
2057
- "name": "sub_agent_id",
2058
- "type": "varchar(256)",
2059
- "primaryKey": false,
2060
- "notNull": true
2061
- },
2062
- "context_id": {
2063
- "name": "context_id",
2064
- "type": "varchar(256)",
2065
- "primaryKey": false,
2066
- "notNull": true
2067
- },
2068
- "ref": {
2069
- "name": "ref",
2070
- "type": "jsonb",
2071
- "primaryKey": false,
2072
- "notNull": false
2073
- },
2074
- "status": {
2075
- "name": "status",
2076
- "type": "varchar(256)",
2077
- "primaryKey": false,
2078
- "notNull": true
2079
- },
2080
- "metadata": {
2081
- "name": "metadata",
2082
- "type": "jsonb",
2083
- "primaryKey": false,
2084
- "notNull": false
2085
- },
2086
- "created_at": {
2087
- "name": "created_at",
2088
- "type": "timestamp",
2089
- "primaryKey": false,
2090
- "notNull": true,
2091
- "default": "now()"
2092
- },
2093
- "updated_at": {
2094
- "name": "updated_at",
2095
- "type": "timestamp",
2096
- "primaryKey": false,
2097
- "notNull": true,
2098
- "default": "now()"
2099
- }
2100
- },
2101
- "indexes": {},
2102
- "foreignKeys": {},
2103
- "compositePrimaryKeys": {
2104
- "tasks_tenant_id_project_id_id_pk": {
2105
- "name": "tasks_tenant_id_project_id_id_pk",
2106
- "columns": [
2107
- "tenant_id",
2108
- "project_id",
2109
- "id"
2110
- ]
2111
- }
2112
- },
2113
- "uniqueConstraints": {},
2114
- "policies": {},
2115
- "checkConstraints": {},
2116
- "isRLSEnabled": false
2117
- },
2118
- "public.trigger_invocations": {
2119
- "name": "trigger_invocations",
2120
- "schema": "",
2121
- "columns": {
2122
- "tenant_id": {
2123
- "name": "tenant_id",
2124
- "type": "varchar(256)",
2125
- "primaryKey": false,
2126
- "notNull": true
2127
- },
2128
- "id": {
2129
- "name": "id",
2130
- "type": "varchar(256)",
2131
- "primaryKey": false,
2132
- "notNull": true
2133
- },
2134
- "project_id": {
2135
- "name": "project_id",
2136
- "type": "varchar(256)",
2137
- "primaryKey": false,
2138
- "notNull": true
2139
- },
2140
- "agent_id": {
2141
- "name": "agent_id",
2142
- "type": "varchar(256)",
2143
- "primaryKey": false,
2144
- "notNull": true
2145
- },
2146
- "trigger_id": {
2147
- "name": "trigger_id",
2148
- "type": "varchar(256)",
2149
- "primaryKey": false,
2150
- "notNull": true
2151
- },
2152
- "conversation_id": {
2153
- "name": "conversation_id",
2154
- "type": "varchar(256)",
2155
- "primaryKey": false,
2156
- "notNull": false
2157
- },
2158
- "status": {
2159
- "name": "status",
2160
- "type": "varchar(20)",
2161
- "primaryKey": false,
2162
- "notNull": true,
2163
- "default": "'pending'"
2164
- },
2165
- "request_payload": {
2166
- "name": "request_payload",
2167
- "type": "jsonb",
2168
- "primaryKey": false,
2169
- "notNull": true
2170
- },
2171
- "transformed_payload": {
2172
- "name": "transformed_payload",
2173
- "type": "jsonb",
2174
- "primaryKey": false,
2175
- "notNull": false
2176
- },
2177
- "error_message": {
2178
- "name": "error_message",
2179
- "type": "text",
2180
- "primaryKey": false,
2181
- "notNull": false
2182
- },
2183
- "created_at": {
2184
- "name": "created_at",
2185
- "type": "timestamp",
2186
- "primaryKey": false,
2187
- "notNull": true,
2188
- "default": "now()"
2189
- }
2190
- },
2191
- "indexes": {
2192
- "trigger_invocations_trigger_idx": {
2193
- "name": "trigger_invocations_trigger_idx",
2194
- "columns": [
2195
- {
2196
- "expression": "trigger_id",
2197
- "isExpression": false,
2198
- "asc": true,
2199
- "nulls": "last"
2200
- },
2201
- {
2202
- "expression": "created_at",
2203
- "isExpression": false,
2204
- "asc": true,
2205
- "nulls": "last"
2206
- }
2207
- ],
2208
- "isUnique": false,
2209
- "concurrently": false,
2210
- "method": "btree",
2211
- "with": {}
2212
- },
2213
- "trigger_invocations_status_idx": {
2214
- "name": "trigger_invocations_status_idx",
2215
- "columns": [
2216
- {
2217
- "expression": "trigger_id",
2218
- "isExpression": false,
2219
- "asc": true,
2220
- "nulls": "last"
2221
- },
2222
- {
2223
- "expression": "status",
2224
- "isExpression": false,
2225
- "asc": true,
2226
- "nulls": "last"
2227
- }
2228
- ],
2229
- "isUnique": false,
2230
- "concurrently": false,
2231
- "method": "btree",
2232
- "with": {}
2233
- }
2234
- },
2235
- "foreignKeys": {},
2236
- "compositePrimaryKeys": {
2237
- "trigger_invocations_tenant_id_project_id_agent_id_id_pk": {
2238
- "name": "trigger_invocations_tenant_id_project_id_agent_id_id_pk",
2239
- "columns": [
2240
- "tenant_id",
2241
- "project_id",
2242
- "agent_id",
2243
- "id"
2244
- ]
2245
- }
2246
- },
2247
- "uniqueConstraints": {},
2248
- "policies": {},
2249
- "checkConstraints": {},
2250
- "isRLSEnabled": false
2251
- },
2252
- "public.user": {
2253
- "name": "user",
2254
- "schema": "",
2255
- "columns": {
2256
- "id": {
2257
- "name": "id",
2258
- "type": "text",
2259
- "primaryKey": true,
2260
- "notNull": true
2261
- },
2262
- "name": {
2263
- "name": "name",
2264
- "type": "text",
2265
- "primaryKey": false,
2266
- "notNull": true
2267
- },
2268
- "email": {
2269
- "name": "email",
2270
- "type": "text",
2271
- "primaryKey": false,
2272
- "notNull": true
2273
- },
2274
- "email_verified": {
2275
- "name": "email_verified",
2276
- "type": "boolean",
2277
- "primaryKey": false,
2278
- "notNull": true,
2279
- "default": false
2280
- },
2281
- "image": {
2282
- "name": "image",
2283
- "type": "text",
2284
- "primaryKey": false,
2285
- "notNull": false
2286
- },
2287
- "created_at": {
2288
- "name": "created_at",
2289
- "type": "timestamp",
2290
- "primaryKey": false,
2291
- "notNull": true,
2292
- "default": "now()"
2293
- },
2294
- "updated_at": {
2295
- "name": "updated_at",
2296
- "type": "timestamp",
2297
- "primaryKey": false,
2298
- "notNull": true,
2299
- "default": "now()"
2300
- }
2301
- },
2302
- "indexes": {},
2303
- "foreignKeys": {},
2304
- "compositePrimaryKeys": {},
2305
- "uniqueConstraints": {
2306
- "user_email_unique": {
2307
- "name": "user_email_unique",
2308
- "nullsNotDistinct": false,
2309
- "columns": [
2310
- "email"
2311
- ]
2312
- }
2313
- },
2314
- "policies": {},
2315
- "checkConstraints": {},
2316
- "isRLSEnabled": false
2317
- },
2318
- "public.verification": {
2319
- "name": "verification",
2320
- "schema": "",
2321
- "columns": {
2322
- "id": {
2323
- "name": "id",
2324
- "type": "text",
2325
- "primaryKey": true,
2326
- "notNull": true
2327
- },
2328
- "identifier": {
2329
- "name": "identifier",
2330
- "type": "text",
2331
- "primaryKey": false,
2332
- "notNull": true
2333
- },
2334
- "value": {
2335
- "name": "value",
2336
- "type": "text",
2337
- "primaryKey": false,
2338
- "notNull": true
2339
- },
2340
- "expires_at": {
2341
- "name": "expires_at",
2342
- "type": "timestamp",
2343
- "primaryKey": false,
2344
- "notNull": true
2345
- },
2346
- "created_at": {
2347
- "name": "created_at",
2348
- "type": "timestamp",
2349
- "primaryKey": false,
2350
- "notNull": true,
2351
- "default": "now()"
2352
- },
2353
- "updated_at": {
2354
- "name": "updated_at",
2355
- "type": "timestamp",
2356
- "primaryKey": false,
2357
- "notNull": true,
2358
- "default": "now()"
2359
- }
2360
- },
2361
- "indexes": {
2362
- "verification_identifier_idx": {
2363
- "name": "verification_identifier_idx",
2364
- "columns": [
2365
- {
2366
- "expression": "identifier",
2367
- "isExpression": false,
2368
- "asc": true,
2369
- "nulls": "last"
2370
- }
2371
- ],
2372
- "isUnique": false,
2373
- "concurrently": false,
2374
- "method": "btree",
2375
- "with": {}
2376
- }
2377
- },
2378
- "foreignKeys": {},
2379
- "compositePrimaryKeys": {},
2380
- "uniqueConstraints": {},
2381
- "policies": {},
2382
- "checkConstraints": {},
2383
- "isRLSEnabled": false
2384
- },
2385
- "public.work_app_github_installations": {
2386
- "name": "work_app_github_installations",
2387
- "schema": "",
2388
- "columns": {
2389
- "tenant_id": {
2390
- "name": "tenant_id",
2391
- "type": "varchar(256)",
2392
- "primaryKey": false,
2393
- "notNull": true
2394
- },
2395
- "id": {
2396
- "name": "id",
2397
- "type": "varchar(256)",
2398
- "primaryKey": false,
2399
- "notNull": true
2400
- },
2401
- "installation_id": {
2402
- "name": "installation_id",
2403
- "type": "text",
2404
- "primaryKey": false,
2405
- "notNull": true
2406
- },
2407
- "account_login": {
2408
- "name": "account_login",
2409
- "type": "varchar(256)",
2410
- "primaryKey": false,
2411
- "notNull": true
2412
- },
2413
- "account_id": {
2414
- "name": "account_id",
2415
- "type": "text",
2416
- "primaryKey": false,
2417
- "notNull": true
2418
- },
2419
- "account_type": {
2420
- "name": "account_type",
2421
- "type": "varchar(20)",
2422
- "primaryKey": false,
2423
- "notNull": true
2424
- },
2425
- "status": {
2426
- "name": "status",
2427
- "type": "varchar(20)",
2428
- "primaryKey": false,
2429
- "notNull": true,
2430
- "default": "'active'"
2431
- },
2432
- "created_at": {
2433
- "name": "created_at",
2434
- "type": "timestamp",
2435
- "primaryKey": false,
2436
- "notNull": true,
2437
- "default": "now()"
2438
- },
2439
- "updated_at": {
2440
- "name": "updated_at",
2441
- "type": "timestamp",
2442
- "primaryKey": false,
2443
- "notNull": true,
2444
- "default": "now()"
2445
- }
2446
- },
2447
- "indexes": {
2448
- "work_app_github_installations_tenant_idx": {
2449
- "name": "work_app_github_installations_tenant_idx",
2450
- "columns": [
2451
- {
2452
- "expression": "tenant_id",
2453
- "isExpression": false,
2454
- "asc": true,
2455
- "nulls": "last"
2456
- }
2457
- ],
2458
- "isUnique": false,
2459
- "concurrently": false,
2460
- "method": "btree",
2461
- "with": {}
2462
- },
2463
- "work_app_github_installations_installation_id_idx": {
2464
- "name": "work_app_github_installations_installation_id_idx",
2465
- "columns": [
2466
- {
2467
- "expression": "installation_id",
2468
- "isExpression": false,
2469
- "asc": true,
2470
- "nulls": "last"
2471
- }
2472
- ],
2473
- "isUnique": false,
2474
- "concurrently": false,
2475
- "method": "btree",
2476
- "with": {}
2477
- }
2478
- },
2479
- "foreignKeys": {
2480
- "work_app_github_installations_organization_fk": {
2481
- "name": "work_app_github_installations_organization_fk",
2482
- "tableFrom": "work_app_github_installations",
2483
- "tableTo": "organization",
2484
- "columnsFrom": [
2485
- "tenant_id"
2486
- ],
2487
- "columnsTo": [
2488
- "id"
2489
- ],
2490
- "onDelete": "cascade",
2491
- "onUpdate": "no action"
2492
- }
2493
- },
2494
- "compositePrimaryKeys": {},
2495
- "uniqueConstraints": {
2496
- "work_app_github_installations_installation_id_unique": {
2497
- "name": "work_app_github_installations_installation_id_unique",
2498
- "nullsNotDistinct": false,
2499
- "columns": [
2500
- "installation_id"
2501
- ]
2502
- }
2503
- },
2504
- "policies": {},
2505
- "checkConstraints": {},
2506
- "isRLSEnabled": false
2507
- },
2508
- "public.work_app_github_mcp_tool_access_mode": {
2509
- "name": "work_app_github_mcp_tool_access_mode",
2510
- "schema": "",
2511
- "columns": {
2512
- "tool_id": {
2513
- "name": "tool_id",
2514
- "type": "varchar(256)",
2515
- "primaryKey": false,
2516
- "notNull": true
2517
- },
2518
- "tenant_id": {
2519
- "name": "tenant_id",
2520
- "type": "varchar(256)",
2521
- "primaryKey": false,
2522
- "notNull": true
2523
- },
2524
- "project_id": {
2525
- "name": "project_id",
2526
- "type": "varchar(256)",
2527
- "primaryKey": false,
2528
- "notNull": true
2529
- },
2530
- "mode": {
2531
- "name": "mode",
2532
- "type": "varchar(20)",
2533
- "primaryKey": false,
2534
- "notNull": true
2535
- },
2536
- "created_at": {
2537
- "name": "created_at",
2538
- "type": "timestamp",
2539
- "primaryKey": false,
2540
- "notNull": true,
2541
- "default": "now()"
2542
- },
2543
- "updated_at": {
2544
- "name": "updated_at",
2545
- "type": "timestamp",
2546
- "primaryKey": false,
2547
- "notNull": true,
2548
- "default": "now()"
2549
- }
2550
- },
2551
- "indexes": {
2552
- "work_app_github_mcp_tool_access_mode_tenant_idx": {
2553
- "name": "work_app_github_mcp_tool_access_mode_tenant_idx",
2554
- "columns": [
2555
- {
2556
- "expression": "tenant_id",
2557
- "isExpression": false,
2558
- "asc": true,
2559
- "nulls": "last"
2560
- }
2561
- ],
2562
- "isUnique": false,
2563
- "concurrently": false,
2564
- "method": "btree",
2565
- "with": {}
2566
- },
2567
- "work_app_github_mcp_tool_access_mode_project_idx": {
2568
- "name": "work_app_github_mcp_tool_access_mode_project_idx",
2569
- "columns": [
2570
- {
2571
- "expression": "project_id",
2572
- "isExpression": false,
2573
- "asc": true,
2574
- "nulls": "last"
2575
- }
2576
- ],
2577
- "isUnique": false,
2578
- "concurrently": false,
2579
- "method": "btree",
2580
- "with": {}
2581
- }
2582
- },
2583
- "foreignKeys": {
2584
- "work_app_github_mcp_tool_access_mode_tenant_fk": {
2585
- "name": "work_app_github_mcp_tool_access_mode_tenant_fk",
2586
- "tableFrom": "work_app_github_mcp_tool_access_mode",
2587
- "tableTo": "organization",
2588
- "columnsFrom": [
2589
- "tenant_id"
2590
- ],
2591
- "columnsTo": [
2592
- "id"
2593
- ],
2594
- "onDelete": "cascade",
2595
- "onUpdate": "no action"
2596
- }
2597
- },
2598
- "compositePrimaryKeys": {
2599
- "work_app_github_mcp_tool_access_mode_tool_id_pk": {
2600
- "name": "work_app_github_mcp_tool_access_mode_tool_id_pk",
2601
- "columns": [
2602
- "tool_id"
2603
- ]
2604
- }
2605
- },
2606
- "uniqueConstraints": {},
2607
- "policies": {},
2608
- "checkConstraints": {},
2609
- "isRLSEnabled": false
2610
- },
2611
- "public.work_app_github_mcp_tool_repository_access": {
2612
- "name": "work_app_github_mcp_tool_repository_access",
2613
- "schema": "",
2614
- "columns": {
2615
- "tenant_id": {
2616
- "name": "tenant_id",
2617
- "type": "varchar(256)",
2618
- "primaryKey": false,
2619
- "notNull": true
2620
- },
2621
- "id": {
2622
- "name": "id",
2623
- "type": "varchar(256)",
2624
- "primaryKey": false,
2625
- "notNull": true
2626
- },
2627
- "project_id": {
2628
- "name": "project_id",
2629
- "type": "varchar(256)",
2630
- "primaryKey": false,
2631
- "notNull": true
2632
- },
2633
- "tool_id": {
2634
- "name": "tool_id",
2635
- "type": "varchar(256)",
2636
- "primaryKey": false,
2637
- "notNull": true
2638
- },
2639
- "repository_db_id": {
2640
- "name": "repository_db_id",
2641
- "type": "varchar(256)",
2642
- "primaryKey": false,
2643
- "notNull": true
2644
- },
2645
- "created_at": {
2646
- "name": "created_at",
2647
- "type": "timestamp",
2648
- "primaryKey": false,
2649
- "notNull": true,
2650
- "default": "now()"
2651
- },
2652
- "updated_at": {
2653
- "name": "updated_at",
2654
- "type": "timestamp",
2655
- "primaryKey": false,
2656
- "notNull": true,
2657
- "default": "now()"
2658
- }
2659
- },
2660
- "indexes": {
2661
- "work_app_github_mcp_tool_repository_access_tool_idx": {
2662
- "name": "work_app_github_mcp_tool_repository_access_tool_idx",
2663
- "columns": [
2664
- {
2665
- "expression": "tool_id",
2666
- "isExpression": false,
2667
- "asc": true,
2668
- "nulls": "last"
2669
- }
2670
- ],
2671
- "isUnique": false,
2672
- "concurrently": false,
2673
- "method": "btree",
2674
- "with": {}
2675
- },
2676
- "work_app_github_mcp_tool_repository_access_tenant_idx": {
2677
- "name": "work_app_github_mcp_tool_repository_access_tenant_idx",
2678
- "columns": [
2679
- {
2680
- "expression": "tenant_id",
2681
- "isExpression": false,
2682
- "asc": true,
2683
- "nulls": "last"
2684
- }
2685
- ],
2686
- "isUnique": false,
2687
- "concurrently": false,
2688
- "method": "btree",
2689
- "with": {}
2690
- },
2691
- "work_app_github_mcp_tool_repository_access_project_idx": {
2692
- "name": "work_app_github_mcp_tool_repository_access_project_idx",
2693
- "columns": [
2694
- {
2695
- "expression": "project_id",
2696
- "isExpression": false,
2697
- "asc": true,
2698
- "nulls": "last"
2699
- }
2700
- ],
2701
- "isUnique": false,
2702
- "concurrently": false,
2703
- "method": "btree",
2704
- "with": {}
2705
- }
2706
- },
2707
- "foreignKeys": {
2708
- "work_app_github_mcp_tool_repository_access_tenant_fk": {
2709
- "name": "work_app_github_mcp_tool_repository_access_tenant_fk",
2710
- "tableFrom": "work_app_github_mcp_tool_repository_access",
2711
- "tableTo": "organization",
2712
- "columnsFrom": [
2713
- "tenant_id"
2714
- ],
2715
- "columnsTo": [
2716
- "id"
2717
- ],
2718
- "onDelete": "cascade",
2719
- "onUpdate": "no action"
2720
- },
2721
- "work_app_github_mcp_tool_repository_access_repo_fk": {
2722
- "name": "work_app_github_mcp_tool_repository_access_repo_fk",
2723
- "tableFrom": "work_app_github_mcp_tool_repository_access",
2724
- "tableTo": "work_app_github_repositories",
2725
- "columnsFrom": [
2726
- "repository_db_id"
2727
- ],
2728
- "columnsTo": [
2729
- "id"
2730
- ],
2731
- "onDelete": "cascade",
2732
- "onUpdate": "no action"
2733
- }
2734
- },
2735
- "compositePrimaryKeys": {},
2736
- "uniqueConstraints": {
2737
- "work_app_github_mcp_tool_repository_access_unique": {
2738
- "name": "work_app_github_mcp_tool_repository_access_unique",
2739
- "nullsNotDistinct": false,
2740
- "columns": [
2741
- "tool_id",
2742
- "repository_db_id"
2743
- ]
2744
- }
2745
- },
2746
- "policies": {},
2747
- "checkConstraints": {},
2748
- "isRLSEnabled": false
2749
- },
2750
- "public.work_app_github_project_access_mode": {
2751
- "name": "work_app_github_project_access_mode",
2752
- "schema": "",
2753
- "columns": {
2754
- "tenant_id": {
2755
- "name": "tenant_id",
2756
- "type": "varchar(256)",
2757
- "primaryKey": false,
2758
- "notNull": true
2759
- },
2760
- "project_id": {
2761
- "name": "project_id",
2762
- "type": "varchar(256)",
2763
- "primaryKey": false,
2764
- "notNull": true
2765
- },
2766
- "mode": {
2767
- "name": "mode",
2768
- "type": "varchar(20)",
2769
- "primaryKey": false,
2770
- "notNull": true
2771
- },
2772
- "created_at": {
2773
- "name": "created_at",
2774
- "type": "timestamp",
2775
- "primaryKey": false,
2776
- "notNull": true,
2777
- "default": "now()"
2778
- },
2779
- "updated_at": {
2780
- "name": "updated_at",
2781
- "type": "timestamp",
2782
- "primaryKey": false,
2783
- "notNull": true,
2784
- "default": "now()"
2785
- }
2786
- },
2787
- "indexes": {},
2788
- "foreignKeys": {
2789
- "work_app_github_project_access_mode_tenant_fk": {
2790
- "name": "work_app_github_project_access_mode_tenant_fk",
2791
- "tableFrom": "work_app_github_project_access_mode",
2792
- "tableTo": "organization",
2793
- "columnsFrom": [
2794
- "tenant_id"
2795
- ],
2796
- "columnsTo": [
2797
- "id"
2798
- ],
2799
- "onDelete": "cascade",
2800
- "onUpdate": "no action"
2801
- }
2802
- },
2803
- "compositePrimaryKeys": {
2804
- "work_app_github_project_access_mode_tenant_id_project_id_pk": {
2805
- "name": "work_app_github_project_access_mode_tenant_id_project_id_pk",
2806
- "columns": [
2807
- "tenant_id",
2808
- "project_id"
2809
- ]
2810
- }
2811
- },
2812
- "uniqueConstraints": {},
2813
- "policies": {},
2814
- "checkConstraints": {},
2815
- "isRLSEnabled": false
2816
- },
2817
- "public.work_app_github_project_repository_access": {
2818
- "name": "work_app_github_project_repository_access",
2819
- "schema": "",
2820
- "columns": {
2821
- "tenant_id": {
2822
- "name": "tenant_id",
2823
- "type": "varchar(256)",
2824
- "primaryKey": false,
2825
- "notNull": true
2826
- },
2827
- "id": {
2828
- "name": "id",
2829
- "type": "varchar(256)",
2830
- "primaryKey": false,
2831
- "notNull": true
2832
- },
2833
- "project_id": {
2834
- "name": "project_id",
2835
- "type": "varchar(256)",
2836
- "primaryKey": false,
2837
- "notNull": true
2838
- },
2839
- "repository_db_id": {
2840
- "name": "repository_db_id",
2841
- "type": "varchar(256)",
2842
- "primaryKey": false,
2843
- "notNull": true
2844
- },
2845
- "created_at": {
2846
- "name": "created_at",
2847
- "type": "timestamp",
2848
- "primaryKey": false,
2849
- "notNull": true,
2850
- "default": "now()"
2851
- },
2852
- "updated_at": {
2853
- "name": "updated_at",
2854
- "type": "timestamp",
2855
- "primaryKey": false,
2856
- "notNull": true,
2857
- "default": "now()"
2858
- }
2859
- },
2860
- "indexes": {
2861
- "work_app_github_project_repository_access_tenant_idx": {
2862
- "name": "work_app_github_project_repository_access_tenant_idx",
2863
- "columns": [
2864
- {
2865
- "expression": "tenant_id",
2866
- "isExpression": false,
2867
- "asc": true,
2868
- "nulls": "last"
2869
- }
2870
- ],
2871
- "isUnique": false,
2872
- "concurrently": false,
2873
- "method": "btree",
2874
- "with": {}
2875
- },
2876
- "work_app_github_project_repository_access_project_idx": {
2877
- "name": "work_app_github_project_repository_access_project_idx",
2878
- "columns": [
2879
- {
2880
- "expression": "project_id",
2881
- "isExpression": false,
2882
- "asc": true,
2883
- "nulls": "last"
2884
- }
2885
- ],
2886
- "isUnique": false,
2887
- "concurrently": false,
2888
- "method": "btree",
2889
- "with": {}
2890
- }
2891
- },
2892
- "foreignKeys": {
2893
- "work_app_github_project_repository_access_tenant_fk": {
2894
- "name": "work_app_github_project_repository_access_tenant_fk",
2895
- "tableFrom": "work_app_github_project_repository_access",
2896
- "tableTo": "organization",
2897
- "columnsFrom": [
2898
- "tenant_id"
2899
- ],
2900
- "columnsTo": [
2901
- "id"
2902
- ],
2903
- "onDelete": "cascade",
2904
- "onUpdate": "no action"
2905
- },
2906
- "work_app_github_project_repository_access_repo_fk": {
2907
- "name": "work_app_github_project_repository_access_repo_fk",
2908
- "tableFrom": "work_app_github_project_repository_access",
2909
- "tableTo": "work_app_github_repositories",
2910
- "columnsFrom": [
2911
- "repository_db_id"
2912
- ],
2913
- "columnsTo": [
2914
- "id"
2915
- ],
2916
- "onDelete": "cascade",
2917
- "onUpdate": "no action"
2918
- }
2919
- },
2920
- "compositePrimaryKeys": {},
2921
- "uniqueConstraints": {
2922
- "work_app_github_project_repository_access_unique": {
2923
- "name": "work_app_github_project_repository_access_unique",
2924
- "nullsNotDistinct": false,
2925
- "columns": [
2926
- "tenant_id",
2927
- "project_id",
2928
- "repository_db_id"
2929
- ]
2930
- }
2931
- },
2932
- "policies": {},
2933
- "checkConstraints": {},
2934
- "isRLSEnabled": false
2935
- },
2936
- "public.work_app_github_repositories": {
2937
- "name": "work_app_github_repositories",
2938
- "schema": "",
2939
- "columns": {
2940
- "id": {
2941
- "name": "id",
2942
- "type": "varchar(256)",
2943
- "primaryKey": true,
2944
- "notNull": true
2945
- },
2946
- "installation_db_id": {
2947
- "name": "installation_db_id",
2948
- "type": "varchar(256)",
2949
- "primaryKey": false,
2950
- "notNull": true
2951
- },
2952
- "repository_id": {
2953
- "name": "repository_id",
2954
- "type": "text",
2955
- "primaryKey": false,
2956
- "notNull": true
2957
- },
2958
- "repository_name": {
2959
- "name": "repository_name",
2960
- "type": "varchar(256)",
2961
- "primaryKey": false,
2962
- "notNull": true
2963
- },
2964
- "repository_full_name": {
2965
- "name": "repository_full_name",
2966
- "type": "varchar(512)",
2967
- "primaryKey": false,
2968
- "notNull": true
2969
- },
2970
- "private": {
2971
- "name": "private",
2972
- "type": "boolean",
2973
- "primaryKey": false,
2974
- "notNull": true,
2975
- "default": false
2976
- },
2977
- "created_at": {
2978
- "name": "created_at",
2979
- "type": "timestamp",
2980
- "primaryKey": false,
2981
- "notNull": true,
2982
- "default": "now()"
2983
- },
2984
- "updated_at": {
2985
- "name": "updated_at",
2986
- "type": "timestamp",
2987
- "primaryKey": false,
2988
- "notNull": true,
2989
- "default": "now()"
2990
- }
2991
- },
2992
- "indexes": {
2993
- "work_app_github_repositories_installation_idx": {
2994
- "name": "work_app_github_repositories_installation_idx",
2995
- "columns": [
2996
- {
2997
- "expression": "installation_db_id",
2998
- "isExpression": false,
2999
- "asc": true,
3000
- "nulls": "last"
3001
- }
3002
- ],
3003
- "isUnique": false,
3004
- "concurrently": false,
3005
- "method": "btree",
3006
- "with": {}
3007
- },
3008
- "work_app_github_repositories_full_name_idx": {
3009
- "name": "work_app_github_repositories_full_name_idx",
3010
- "columns": [
3011
- {
3012
- "expression": "repository_full_name",
3013
- "isExpression": false,
3014
- "asc": true,
3015
- "nulls": "last"
3016
- }
3017
- ],
3018
- "isUnique": false,
3019
- "concurrently": false,
3020
- "method": "btree",
3021
- "with": {}
3022
- }
3023
- },
3024
- "foreignKeys": {
3025
- "work_app_github_repositories_installation_fk": {
3026
- "name": "work_app_github_repositories_installation_fk",
3027
- "tableFrom": "work_app_github_repositories",
3028
- "tableTo": "work_app_github_installations",
3029
- "columnsFrom": [
3030
- "installation_db_id"
3031
- ],
3032
- "columnsTo": [
3033
- "id"
3034
- ],
3035
- "onDelete": "cascade",
3036
- "onUpdate": "no action"
3037
- }
3038
- },
3039
- "compositePrimaryKeys": {},
3040
- "uniqueConstraints": {
3041
- "work_app_github_repositories_repo_installation_unique": {
3042
- "name": "work_app_github_repositories_repo_installation_unique",
3043
- "nullsNotDistinct": false,
3044
- "columns": [
3045
- "installation_db_id",
3046
- "repository_id"
3047
- ]
3048
- }
3049
- },
3050
- "policies": {},
3051
- "checkConstraints": {},
3052
- "isRLSEnabled": false
3053
- },
3054
- "public.work_app_slack_channel_agent_configs": {
3055
- "name": "work_app_slack_channel_agent_configs",
3056
- "schema": "",
3057
- "columns": {
3058
- "id": {
3059
- "name": "id",
3060
- "type": "varchar(256)",
3061
- "primaryKey": true,
3062
- "notNull": true
3063
- },
3064
- "tenant_id": {
3065
- "name": "tenant_id",
3066
- "type": "varchar(256)",
3067
- "primaryKey": false,
3068
- "notNull": true
3069
- },
3070
- "slack_team_id": {
3071
- "name": "slack_team_id",
3072
- "type": "varchar(256)",
3073
- "primaryKey": false,
3074
- "notNull": true
3075
- },
3076
- "slack_channel_id": {
3077
- "name": "slack_channel_id",
3078
- "type": "varchar(256)",
3079
- "primaryKey": false,
3080
- "notNull": true
3081
- },
3082
- "slack_channel_name": {
3083
- "name": "slack_channel_name",
3084
- "type": "varchar(256)",
3085
- "primaryKey": false,
3086
- "notNull": false
3087
- },
3088
- "slack_channel_type": {
3089
- "name": "slack_channel_type",
3090
- "type": "varchar(50)",
3091
- "primaryKey": false,
3092
- "notNull": false
3093
- },
3094
- "project_id": {
3095
- "name": "project_id",
3096
- "type": "varchar(256)",
3097
- "primaryKey": false,
3098
- "notNull": true
3099
- },
3100
- "agent_id": {
3101
- "name": "agent_id",
3102
- "type": "varchar(256)",
3103
- "primaryKey": false,
3104
- "notNull": true
3105
- },
3106
- "agent_name": {
3107
- "name": "agent_name",
3108
- "type": "varchar(256)",
3109
- "primaryKey": false,
3110
- "notNull": false
3111
- },
3112
- "configured_by_user_id": {
3113
- "name": "configured_by_user_id",
3114
- "type": "text",
3115
- "primaryKey": false,
3116
- "notNull": false
3117
- },
3118
- "enabled": {
3119
- "name": "enabled",
3120
- "type": "boolean",
3121
- "primaryKey": false,
3122
- "notNull": true,
3123
- "default": true
3124
- },
3125
- "created_at": {
3126
- "name": "created_at",
3127
- "type": "timestamp",
3128
- "primaryKey": false,
3129
- "notNull": true,
3130
- "default": "now()"
3131
- },
3132
- "updated_at": {
3133
- "name": "updated_at",
3134
- "type": "timestamp",
3135
- "primaryKey": false,
3136
- "notNull": true,
3137
- "default": "now()"
3138
- }
3139
- },
3140
- "indexes": {
3141
- "work_app_slack_channel_agent_configs_tenant_idx": {
3142
- "name": "work_app_slack_channel_agent_configs_tenant_idx",
3143
- "columns": [
3144
- {
3145
- "expression": "tenant_id",
3146
- "isExpression": false,
3147
- "asc": true,
3148
- "nulls": "last"
3149
- }
3150
- ],
3151
- "isUnique": false,
3152
- "concurrently": false,
3153
- "method": "btree",
3154
- "with": {}
3155
- },
3156
- "work_app_slack_channel_agent_configs_team_idx": {
3157
- "name": "work_app_slack_channel_agent_configs_team_idx",
3158
- "columns": [
3159
- {
3160
- "expression": "slack_team_id",
3161
- "isExpression": false,
3162
- "asc": true,
3163
- "nulls": "last"
3164
- }
3165
- ],
3166
- "isUnique": false,
3167
- "concurrently": false,
3168
- "method": "btree",
3169
- "with": {}
3170
- },
3171
- "work_app_slack_channel_agent_configs_channel_idx": {
3172
- "name": "work_app_slack_channel_agent_configs_channel_idx",
3173
- "columns": [
3174
- {
3175
- "expression": "slack_channel_id",
3176
- "isExpression": false,
3177
- "asc": true,
3178
- "nulls": "last"
3179
- }
3180
- ],
3181
- "isUnique": false,
3182
- "concurrently": false,
3183
- "method": "btree",
3184
- "with": {}
3185
- }
3186
- },
3187
- "foreignKeys": {
3188
- "work_app_slack_channel_agent_configs_tenant_id_organization_id_fk": {
3189
- "name": "work_app_slack_channel_agent_configs_tenant_id_organization_id_fk",
3190
- "tableFrom": "work_app_slack_channel_agent_configs",
3191
- "tableTo": "organization",
3192
- "columnsFrom": [
3193
- "tenant_id"
3194
- ],
3195
- "columnsTo": [
3196
- "id"
3197
- ],
3198
- "onDelete": "cascade",
3199
- "onUpdate": "no action"
3200
- },
3201
- "work_app_slack_channel_agent_configs_configured_by_user_id_user_id_fk": {
3202
- "name": "work_app_slack_channel_agent_configs_configured_by_user_id_user_id_fk",
3203
- "tableFrom": "work_app_slack_channel_agent_configs",
3204
- "tableTo": "user",
3205
- "columnsFrom": [
3206
- "configured_by_user_id"
3207
- ],
3208
- "columnsTo": [
3209
- "id"
3210
- ],
3211
- "onDelete": "set null",
3212
- "onUpdate": "no action"
3213
- }
3214
- },
3215
- "compositePrimaryKeys": {},
3216
- "uniqueConstraints": {
3217
- "work_app_slack_channel_agent_configs_unique": {
3218
- "name": "work_app_slack_channel_agent_configs_unique",
3219
- "nullsNotDistinct": false,
3220
- "columns": [
3221
- "tenant_id",
3222
- "slack_team_id",
3223
- "slack_channel_id"
3224
- ]
3225
- }
3226
- },
3227
- "policies": {},
3228
- "checkConstraints": {},
3229
- "isRLSEnabled": false
3230
- },
3231
- "public.work_app_slack_user_mappings": {
3232
- "name": "work_app_slack_user_mappings",
3233
- "schema": "",
3234
- "columns": {
3235
- "id": {
3236
- "name": "id",
3237
- "type": "varchar(256)",
3238
- "primaryKey": true,
3239
- "notNull": true
3240
- },
3241
- "tenant_id": {
3242
- "name": "tenant_id",
3243
- "type": "varchar(256)",
3244
- "primaryKey": false,
3245
- "notNull": true
3246
- },
3247
- "client_id": {
3248
- "name": "client_id",
3249
- "type": "varchar(256)",
3250
- "primaryKey": false,
3251
- "notNull": true,
3252
- "default": "'work-apps-slack'"
3253
- },
3254
- "slack_user_id": {
3255
- "name": "slack_user_id",
3256
- "type": "varchar(256)",
3257
- "primaryKey": false,
3258
- "notNull": true
3259
- },
3260
- "slack_team_id": {
3261
- "name": "slack_team_id",
3262
- "type": "varchar(256)",
3263
- "primaryKey": false,
3264
- "notNull": true
3265
- },
3266
- "slack_enterprise_id": {
3267
- "name": "slack_enterprise_id",
3268
- "type": "varchar(256)",
3269
- "primaryKey": false,
3270
- "notNull": false
3271
- },
3272
- "inkeep_user_id": {
3273
- "name": "inkeep_user_id",
3274
- "type": "text",
3275
- "primaryKey": false,
3276
- "notNull": true
3277
- },
3278
- "slack_username": {
3279
- "name": "slack_username",
3280
- "type": "varchar(256)",
3281
- "primaryKey": false,
3282
- "notNull": false
3283
- },
3284
- "slack_email": {
3285
- "name": "slack_email",
3286
- "type": "varchar(256)",
3287
- "primaryKey": false,
3288
- "notNull": false
3289
- },
3290
- "linked_at": {
3291
- "name": "linked_at",
3292
- "type": "timestamp",
3293
- "primaryKey": false,
3294
- "notNull": true,
3295
- "default": "now()"
3296
- },
3297
- "last_used_at": {
3298
- "name": "last_used_at",
3299
- "type": "timestamp",
3300
- "primaryKey": false,
3301
- "notNull": false
3302
- },
3303
- "created_at": {
3304
- "name": "created_at",
3305
- "type": "timestamp",
3306
- "primaryKey": false,
3307
- "notNull": true,
3308
- "default": "now()"
3309
- },
3310
- "updated_at": {
3311
- "name": "updated_at",
3312
- "type": "timestamp",
3313
- "primaryKey": false,
3314
- "notNull": true,
3315
- "default": "now()"
3316
- }
3317
- },
3318
- "indexes": {
3319
- "work_app_slack_user_mappings_tenant_idx": {
3320
- "name": "work_app_slack_user_mappings_tenant_idx",
3321
- "columns": [
3322
- {
3323
- "expression": "tenant_id",
3324
- "isExpression": false,
3325
- "asc": true,
3326
- "nulls": "last"
3327
- }
3328
- ],
3329
- "isUnique": false,
3330
- "concurrently": false,
3331
- "method": "btree",
3332
- "with": {}
3333
- },
3334
- "work_app_slack_user_mappings_user_idx": {
3335
- "name": "work_app_slack_user_mappings_user_idx",
3336
- "columns": [
3337
- {
3338
- "expression": "inkeep_user_id",
3339
- "isExpression": false,
3340
- "asc": true,
3341
- "nulls": "last"
3342
- }
3343
- ],
3344
- "isUnique": false,
3345
- "concurrently": false,
3346
- "method": "btree",
3347
- "with": {}
3348
- },
3349
- "work_app_slack_user_mappings_team_idx": {
3350
- "name": "work_app_slack_user_mappings_team_idx",
3351
- "columns": [
3352
- {
3353
- "expression": "slack_team_id",
3354
- "isExpression": false,
3355
- "asc": true,
3356
- "nulls": "last"
3357
- }
3358
- ],
3359
- "isUnique": false,
3360
- "concurrently": false,
3361
- "method": "btree",
3362
- "with": {}
3363
- },
3364
- "work_app_slack_user_mappings_slack_user_idx": {
3365
- "name": "work_app_slack_user_mappings_slack_user_idx",
3366
- "columns": [
3367
- {
3368
- "expression": "slack_user_id",
3369
- "isExpression": false,
3370
- "asc": true,
3371
- "nulls": "last"
3372
- }
3373
- ],
3374
- "isUnique": false,
3375
- "concurrently": false,
3376
- "method": "btree",
3377
- "with": {}
3378
- }
3379
- },
3380
- "foreignKeys": {
3381
- "work_app_slack_user_mappings_tenant_id_organization_id_fk": {
3382
- "name": "work_app_slack_user_mappings_tenant_id_organization_id_fk",
3383
- "tableFrom": "work_app_slack_user_mappings",
3384
- "tableTo": "organization",
3385
- "columnsFrom": [
3386
- "tenant_id"
3387
- ],
3388
- "columnsTo": [
3389
- "id"
3390
- ],
3391
- "onDelete": "cascade",
3392
- "onUpdate": "no action"
3393
- },
3394
- "work_app_slack_user_mappings_inkeep_user_id_user_id_fk": {
3395
- "name": "work_app_slack_user_mappings_inkeep_user_id_user_id_fk",
3396
- "tableFrom": "work_app_slack_user_mappings",
3397
- "tableTo": "user",
3398
- "columnsFrom": [
3399
- "inkeep_user_id"
3400
- ],
3401
- "columnsTo": [
3402
- "id"
3403
- ],
3404
- "onDelete": "cascade",
3405
- "onUpdate": "no action"
3406
- }
3407
- },
3408
- "compositePrimaryKeys": {},
3409
- "uniqueConstraints": {
3410
- "work_app_slack_user_mappings_unique": {
3411
- "name": "work_app_slack_user_mappings_unique",
3412
- "nullsNotDistinct": false,
3413
- "columns": [
3414
- "tenant_id",
3415
- "client_id",
3416
- "slack_team_id",
3417
- "slack_user_id"
3418
- ]
3419
- }
3420
- },
3421
- "policies": {},
3422
- "checkConstraints": {},
3423
- "isRLSEnabled": false
3424
- },
3425
- "public.work_app_slack_user_settings": {
3426
- "name": "work_app_slack_user_settings",
3427
- "schema": "",
3428
- "columns": {
3429
- "id": {
3430
- "name": "id",
3431
- "type": "varchar(256)",
3432
- "primaryKey": true,
3433
- "notNull": true
3434
- },
3435
- "tenant_id": {
3436
- "name": "tenant_id",
3437
- "type": "varchar(256)",
3438
- "primaryKey": false,
3439
- "notNull": true
3440
- },
3441
- "slack_team_id": {
3442
- "name": "slack_team_id",
3443
- "type": "varchar(256)",
3444
- "primaryKey": false,
3445
- "notNull": true
3446
- },
3447
- "slack_user_id": {
3448
- "name": "slack_user_id",
3449
- "type": "varchar(256)",
3450
- "primaryKey": false,
3451
- "notNull": true
3452
- },
3453
- "default_project_id": {
3454
- "name": "default_project_id",
3455
- "type": "varchar(256)",
3456
- "primaryKey": false,
3457
- "notNull": false
3458
- },
3459
- "default_agent_id": {
3460
- "name": "default_agent_id",
3461
- "type": "varchar(256)",
3462
- "primaryKey": false,
3463
- "notNull": false
3464
- },
3465
- "default_agent_name": {
3466
- "name": "default_agent_name",
3467
- "type": "varchar(256)",
3468
- "primaryKey": false,
3469
- "notNull": false
3470
- },
3471
- "created_at": {
3472
- "name": "created_at",
3473
- "type": "timestamp",
3474
- "primaryKey": false,
3475
- "notNull": true,
3476
- "default": "now()"
3477
- },
3478
- "updated_at": {
3479
- "name": "updated_at",
3480
- "type": "timestamp",
3481
- "primaryKey": false,
3482
- "notNull": true,
3483
- "default": "now()"
3484
- }
3485
- },
3486
- "indexes": {
3487
- "work_app_slack_user_settings_tenant_idx": {
3488
- "name": "work_app_slack_user_settings_tenant_idx",
3489
- "columns": [
3490
- {
3491
- "expression": "tenant_id",
3492
- "isExpression": false,
3493
- "asc": true,
3494
- "nulls": "last"
3495
- }
3496
- ],
3497
- "isUnique": false,
3498
- "concurrently": false,
3499
- "method": "btree",
3500
- "with": {}
3501
- },
3502
- "work_app_slack_user_settings_team_idx": {
3503
- "name": "work_app_slack_user_settings_team_idx",
3504
- "columns": [
3505
- {
3506
- "expression": "slack_team_id",
3507
- "isExpression": false,
3508
- "asc": true,
3509
- "nulls": "last"
3510
- }
3511
- ],
3512
- "isUnique": false,
3513
- "concurrently": false,
3514
- "method": "btree",
3515
- "with": {}
3516
- },
3517
- "work_app_slack_user_settings_user_idx": {
3518
- "name": "work_app_slack_user_settings_user_idx",
3519
- "columns": [
3520
- {
3521
- "expression": "slack_user_id",
3522
- "isExpression": false,
3523
- "asc": true,
3524
- "nulls": "last"
3525
- }
3526
- ],
3527
- "isUnique": false,
3528
- "concurrently": false,
3529
- "method": "btree",
3530
- "with": {}
3531
- }
3532
- },
3533
- "foreignKeys": {
3534
- "work_app_slack_user_settings_tenant_id_organization_id_fk": {
3535
- "name": "work_app_slack_user_settings_tenant_id_organization_id_fk",
3536
- "tableFrom": "work_app_slack_user_settings",
3537
- "tableTo": "organization",
3538
- "columnsFrom": [
3539
- "tenant_id"
3540
- ],
3541
- "columnsTo": [
3542
- "id"
3543
- ],
3544
- "onDelete": "cascade",
3545
- "onUpdate": "no action"
3546
- }
3547
- },
3548
- "compositePrimaryKeys": {},
3549
- "uniqueConstraints": {
3550
- "work_app_slack_user_settings_unique": {
3551
- "name": "work_app_slack_user_settings_unique",
3552
- "nullsNotDistinct": false,
3553
- "columns": [
3554
- "tenant_id",
3555
- "slack_team_id",
3556
- "slack_user_id"
3557
- ]
3558
- }
3559
- },
3560
- "policies": {},
3561
- "checkConstraints": {},
3562
- "isRLSEnabled": false
3563
- },
3564
- "public.work_app_slack_workspaces": {
3565
- "name": "work_app_slack_workspaces",
3566
- "schema": "",
3567
- "columns": {
3568
- "id": {
3569
- "name": "id",
3570
- "type": "varchar(256)",
3571
- "primaryKey": true,
3572
- "notNull": true
3573
- },
3574
- "tenant_id": {
3575
- "name": "tenant_id",
3576
- "type": "varchar(256)",
3577
- "primaryKey": false,
3578
- "notNull": true
3579
- },
3580
- "slack_team_id": {
3581
- "name": "slack_team_id",
3582
- "type": "varchar(256)",
3583
- "primaryKey": false,
3584
- "notNull": true
3585
- },
3586
- "slack_enterprise_id": {
3587
- "name": "slack_enterprise_id",
3588
- "type": "varchar(256)",
3589
- "primaryKey": false,
3590
- "notNull": false
3591
- },
3592
- "slack_app_id": {
3593
- "name": "slack_app_id",
3594
- "type": "varchar(256)",
3595
- "primaryKey": false,
3596
- "notNull": false
3597
- },
3598
- "slack_team_name": {
3599
- "name": "slack_team_name",
3600
- "type": "varchar(512)",
3601
- "primaryKey": false,
3602
- "notNull": false
3603
- },
3604
- "nango_provider_config_key": {
3605
- "name": "nango_provider_config_key",
3606
- "type": "varchar(256)",
3607
- "primaryKey": false,
3608
- "notNull": true,
3609
- "default": "'work-apps-slack'"
3610
- },
3611
- "nango_connection_id": {
3612
- "name": "nango_connection_id",
3613
- "type": "varchar(256)",
3614
- "primaryKey": false,
3615
- "notNull": true
3616
- },
3617
- "status": {
3618
- "name": "status",
3619
- "type": "varchar(20)",
3620
- "primaryKey": false,
3621
- "notNull": true,
3622
- "default": "'active'"
3623
- },
3624
- "installed_by_user_id": {
3625
- "name": "installed_by_user_id",
3626
- "type": "text",
3627
- "primaryKey": false,
3628
- "notNull": false
3629
- },
3630
- "created_at": {
3631
- "name": "created_at",
3632
- "type": "timestamp",
3633
- "primaryKey": false,
3634
- "notNull": true,
3635
- "default": "now()"
3636
- },
3637
- "updated_at": {
3638
- "name": "updated_at",
3639
- "type": "timestamp",
3640
- "primaryKey": false,
3641
- "notNull": true,
3642
- "default": "now()"
3643
- }
3644
- },
3645
- "indexes": {
3646
- "work_app_slack_workspaces_tenant_idx": {
3647
- "name": "work_app_slack_workspaces_tenant_idx",
3648
- "columns": [
3649
- {
3650
- "expression": "tenant_id",
3651
- "isExpression": false,
3652
- "asc": true,
3653
- "nulls": "last"
3654
- }
3655
- ],
3656
- "isUnique": false,
3657
- "concurrently": false,
3658
- "method": "btree",
3659
- "with": {}
3660
- },
3661
- "work_app_slack_workspaces_team_idx": {
3662
- "name": "work_app_slack_workspaces_team_idx",
3663
- "columns": [
3664
- {
3665
- "expression": "slack_team_id",
3666
- "isExpression": false,
3667
- "asc": true,
3668
- "nulls": "last"
3669
- }
3670
- ],
3671
- "isUnique": false,
3672
- "concurrently": false,
3673
- "method": "btree",
3674
- "with": {}
3675
- },
3676
- "work_app_slack_workspaces_nango_idx": {
3677
- "name": "work_app_slack_workspaces_nango_idx",
3678
- "columns": [
3679
- {
3680
- "expression": "nango_connection_id",
3681
- "isExpression": false,
3682
- "asc": true,
3683
- "nulls": "last"
3684
- }
3685
- ],
3686
- "isUnique": false,
3687
- "concurrently": false,
3688
- "method": "btree",
3689
- "with": {}
3690
- }
3691
- },
3692
- "foreignKeys": {
3693
- "work_app_slack_workspaces_tenant_id_organization_id_fk": {
3694
- "name": "work_app_slack_workspaces_tenant_id_organization_id_fk",
3695
- "tableFrom": "work_app_slack_workspaces",
3696
- "tableTo": "organization",
3697
- "columnsFrom": [
3698
- "tenant_id"
3699
- ],
3700
- "columnsTo": [
3701
- "id"
3702
- ],
3703
- "onDelete": "cascade",
3704
- "onUpdate": "no action"
3705
- },
3706
- "work_app_slack_workspaces_installed_by_user_id_user_id_fk": {
3707
- "name": "work_app_slack_workspaces_installed_by_user_id_user_id_fk",
3708
- "tableFrom": "work_app_slack_workspaces",
3709
- "tableTo": "user",
3710
- "columnsFrom": [
3711
- "installed_by_user_id"
3712
- ],
3713
- "columnsTo": [
3714
- "id"
3715
- ],
3716
- "onDelete": "set null",
3717
- "onUpdate": "no action"
3718
- }
3719
- },
3720
- "compositePrimaryKeys": {},
3721
- "uniqueConstraints": {
3722
- "work_app_slack_workspaces_tenant_team_unique": {
3723
- "name": "work_app_slack_workspaces_tenant_team_unique",
3724
- "nullsNotDistinct": false,
3725
- "columns": [
3726
- "tenant_id",
3727
- "slack_team_id"
3728
- ]
3729
- }
3730
- },
3731
- "policies": {},
3732
- "checkConstraints": {},
3733
- "isRLSEnabled": false
3734
- }
3735
- },
3736
- "enums": {},
3737
- "schemas": {},
3738
- "sequences": {},
3739
- "roles": {},
3740
- "policies": {},
3741
- "views": {},
3742
- "_meta": {
3743
- "columns": {},
3744
- "schemas": {},
3745
- "tables": {}
3746
- }
3747
- }