@sentry/junior 0.114.0 → 0.116.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (147) hide show
  1. package/dist/{agent-hooks-WNBUY4OB.js → agent-hooks-67NFITDH.js} +13 -12
  2. package/dist/api/conversations/detail.d.ts +20 -0
  3. package/dist/api/conversations/event-list.d.ts +2 -0
  4. package/dist/api/conversations/event-page.d.ts +1 -1
  5. package/dist/api/conversations/events.d.ts +1 -1
  6. package/dist/api/health.d.ts +7 -0
  7. package/dist/api/people/profile.d.ts +2 -2
  8. package/dist/api/people/shared.d.ts +1 -1
  9. package/dist/api/personal-tokens/create.d.ts +11 -0
  10. package/dist/api/personal-tokens/list.d.ts +12 -0
  11. package/dist/api/personal-tokens/revoke.d.ts +5 -0
  12. package/dist/api/personal-tokens/routes.d.ts +4 -0
  13. package/dist/api/plugin-reports.d.ts +62 -0
  14. package/dist/api/plugins.d.ts +8 -0
  15. package/dist/api/route.d.ts +1 -1
  16. package/dist/api/runtime.d.ts +24 -0
  17. package/dist/api/schema/conversation.d.ts +26 -0
  18. package/dist/api/schema/person.d.ts +3 -3
  19. package/dist/api/schema/personal-token.d.ts +38 -0
  20. package/dist/api/schema.d.ts +4 -2
  21. package/dist/api/schema.js +19 -7
  22. package/dist/api/skills.d.ts +6 -0
  23. package/dist/api.d.ts +1 -0
  24. package/dist/api.js +285 -121
  25. package/dist/app.js +1957 -5677
  26. package/dist/catalog-runtime-CWZY6GTH.js +18 -0
  27. package/dist/chat/agent/request.d.ts +7 -0
  28. package/dist/chat/agent/resume.d.ts +1 -0
  29. package/dist/chat/agent/sandbox.d.ts +3 -0
  30. package/dist/chat/agent/tools.d.ts +3 -0
  31. package/dist/chat/agent-dispatch/context.d.ts +2 -0
  32. package/dist/chat/agent-dispatch/heartbeat.d.ts +11 -5
  33. package/dist/chat/agent-dispatch/signing.d.ts +14 -5
  34. package/dist/chat/agent-dispatch/store.d.ts +36 -15
  35. package/dist/chat/agent-dispatch/types.d.ts +23 -10
  36. package/dist/chat/agent-dispatch/work.d.ts +58 -0
  37. package/dist/chat/app/factory.d.ts +12 -3
  38. package/dist/chat/config.d.ts +2 -0
  39. package/dist/chat/conversations/history.d.ts +291 -290
  40. package/dist/chat/conversations/projection.d.ts +2 -2
  41. package/dist/chat/local/credential-sync.d.ts +5 -0
  42. package/dist/chat/local/oauth-relay.d.ts +4 -0
  43. package/dist/chat/mcp/oauth.d.ts +1 -0
  44. package/dist/chat/mcp/tool-manager.d.ts +2 -1
  45. package/dist/chat/oauth-authorization.d.ts +17 -0
  46. package/dist/chat/oauth-flow.d.ts +9 -0
  47. package/dist/chat/pi/conversation-events.d.ts +6 -2
  48. package/dist/chat/plugins/annotations.d.ts +8 -0
  49. package/dist/chat/plugins/registry.d.ts +0 -3
  50. package/dist/chat/plugins/types.d.ts +0 -2
  51. package/dist/chat/runtime/agent-continue-runner.d.ts +4 -0
  52. package/dist/chat/runtime/reply-executor.d.ts +6 -1
  53. package/dist/chat/runtime/slack-resume.d.ts +5 -1
  54. package/dist/chat/runtime/turn-input.d.ts +3 -0
  55. package/dist/chat/sandbox/egress/schemas.d.ts +46 -0
  56. package/dist/chat/sandbox/egress/signals.d.ts +9 -0
  57. package/dist/chat/sandbox/sandbox.d.ts +4 -1
  58. package/dist/chat/sandbox/session.d.ts +2 -11
  59. package/dist/chat/sandbox/workspace.d.ts +10 -2
  60. package/dist/chat/sentry-payload-filter.d.ts +4 -4
  61. package/dist/chat/services/mcp-auth-orchestration.d.ts +5 -3
  62. package/dist/chat/services/plugin-auth-orchestration.d.ts +2 -0
  63. package/dist/chat/services/turn-session-record.d.ts +14 -1
  64. package/dist/chat/slack/dispatch-turn.d.ts +25 -0
  65. package/dist/chat/slack/message-control.d.ts +2 -0
  66. package/dist/chat/slack/oauth-authorization-message.d.ts +3 -0
  67. package/dist/chat/state/turn-session.d.ts +11 -0
  68. package/dist/chat/task-execution/slack-work.d.ts +2 -0
  69. package/dist/chat/tool-support/text-range-result.d.ts +3 -0
  70. package/dist/chat/tool-support/zod-tool.d.ts +2 -1
  71. package/dist/chat/tools/definition.d.ts +3 -5
  72. package/dist/chat/tools/query-conversation-events.d.ts +68 -0
  73. package/dist/chat/tools/sandbox/file-utils.d.ts +8 -1
  74. package/dist/chat/tools/sandbox/find-files.d.ts +2 -1
  75. package/dist/chat/tools/sandbox/grep.d.ts +2 -1
  76. package/dist/{chunk-OSKEC4XU.js → chunk-25GU5B5E.js} +1 -1
  77. package/dist/{chunk-XLFBQJUO.js → chunk-3H45VOBZ.js} +32 -7
  78. package/dist/{chunk-4FUEG3QY.js → chunk-3JOGUT46.js} +4 -16
  79. package/dist/chunk-4CODA7P5.js +43 -0
  80. package/dist/{chunk-O4GT7LYB.js → chunk-4DD6AOCG.js} +3 -43
  81. package/dist/{chunk-YU6PO42Q.js → chunk-53ZKTQO6.js} +1 -1
  82. package/dist/{chunk-WV4UJBAS.js → chunk-5UNB623T.js} +1282 -2536
  83. package/dist/{chunk-TLGM5X2M.js → chunk-6RQ5GCWH.js} +2 -2
  84. package/dist/{chunk-MIAKQNYX.js → chunk-6ZK6FZIV.js} +1 -1
  85. package/dist/{chunk-W6RDUAO3.js → chunk-BXLS3I4W.js} +1 -1
  86. package/dist/{chunk-RD7EJI7H.js → chunk-CI3VK7X5.js} +69 -3
  87. package/dist/chunk-DIB4GX3G.js +8 -0
  88. package/dist/{chunk-42WRQLJ6.js → chunk-F3B2YJ76.js} +0 -14
  89. package/dist/chunk-FA6POGLH.js +70 -0
  90. package/dist/{chunk-6Y5L4BOM.js → chunk-FXOYURO4.js} +5 -3
  91. package/dist/chunk-HDSDCEPK.js +80 -0
  92. package/dist/{chunk-C4MZ3GP5.js → chunk-HZF5P5UN.js} +1 -1
  93. package/dist/{chunk-K2W4CK7K.js → chunk-JZPQ5K4V.js} +10 -129
  94. package/dist/{chunk-FIGAF6KL.js → chunk-KBNDFU6J.js} +108 -38
  95. package/dist/{chunk-PM3PX42K.js → chunk-MGH5ADQS.js} +1 -2
  96. package/dist/{chunk-5CZ7RETL.js → chunk-N7TMYLF2.js} +1 -1
  97. package/dist/chunk-OB42YVAE.js +16 -0
  98. package/dist/{chunk-6QWPVTMO.js → chunk-OF5FODBL.js} +125 -23
  99. package/dist/{chunk-2ZTTXTSZ.js → chunk-PE44LDDQ.js} +9 -4
  100. package/dist/chunk-PGKWXHYJ.js +1870 -0
  101. package/dist/{chunk-ZGXH3REA.js → chunk-PZGPCOSD.js} +12 -2
  102. package/dist/{chunk-JQFJO5WH.js → chunk-RXRQJF7Y.js} +74 -17
  103. package/dist/{chunk-S4QDH23A.js → chunk-TC4ZEM2D.js} +113 -79
  104. package/dist/{chunk-ABPSDO6M.js → chunk-UEVLIYK5.js} +234 -165
  105. package/dist/chunk-VKZ6WVAY.js +4318 -0
  106. package/dist/{chunk-VNNBSKCO.js → chunk-VZCSLYCE.js} +22 -7
  107. package/dist/chunk-W3U3YQYI.js +71 -0
  108. package/dist/{chunk-SG5WAA7H.js → chunk-WKU7TY22.js} +0 -3
  109. package/dist/cli/chat.js +74 -42
  110. package/dist/cli/check.js +10 -8
  111. package/dist/cli/init.js +1 -0
  112. package/dist/cli/plugins.js +18 -16
  113. package/dist/cli/snapshot-warmup.js +13 -11
  114. package/dist/cli/upgrade.js +12 -10
  115. package/dist/db/schema/api-tokens.d.ts +160 -0
  116. package/dist/db/schema/conversation-annotations.d.ts +142 -0
  117. package/dist/db/schema.d.ts +305 -1
  118. package/dist/{db-4VLP7KBF.js → db-57FHVGGQ.js} +9 -8
  119. package/dist/handlers/agent-dispatch.d.ts +7 -3
  120. package/dist/handlers/sandbox-egress-signals.d.ts +4 -0
  121. package/dist/instrumentation.js +72 -4
  122. package/dist/nitro.js +5 -5
  123. package/dist/oauth-callback-server-PAQRPXZX.js +231 -0
  124. package/dist/oauth-relay-3ZU72UGL.js +9 -0
  125. package/dist/personal-tokens/store.d.ts +27 -0
  126. package/dist/{plugins-PZMDS7AT.js → plugins-IUJA4VBU.js} +1 -1
  127. package/dist/reporting-schema.d.ts +10 -4
  128. package/dist/reporting.d.ts +5 -5
  129. package/dist/{runner-IPXLWQOF.js → runner-4ISZYJEX.js} +141 -74
  130. package/dist/sandbox-egress-signals-CDFAP67O.js +75 -0
  131. package/dist/{skills-QCNZISNF.js → skills-UE2KXQMB.js} +10 -8
  132. package/dist/validation-PO5LHTJT.js +21 -0
  133. package/dist/version.js +1 -1
  134. package/migrations/0008_sticky_rage.sql +14 -0
  135. package/migrations/0009_slippery_harrier.sql +12 -0
  136. package/migrations/0010_native_conversation_history.sql +142 -0
  137. package/migrations/meta/0008_snapshot.json +1076 -0
  138. package/migrations/meta/0009_snapshot.json +1146 -0
  139. package/migrations/meta/0010_snapshot.json +1190 -0
  140. package/migrations/meta/_journal.json +22 -1
  141. package/package.json +6 -7
  142. package/dist/catalog-runtime-6O4M6JGA.js +0 -16
  143. package/dist/chat/agent-dispatch/runner.d.ts +0 -13
  144. package/dist/chat/capabilities/catalog.d.ts +0 -16
  145. package/dist/chat/oauth-authorization-message.d.ts +0 -6
  146. package/dist/validation-I2BW3UHD.js +0 -19
  147. package/dist/{chunk-KNFROR7R.js → chunk-5I6ORJUY.js} +1 -1
@@ -0,0 +1,1146 @@
1
+ {
2
+ "id": "a28495fc-55ba-423b-b4ab-a5e16a85444f",
3
+ "prevId": "000fd8df-3f20-485a-8669-ef5e66d7177c",
4
+ "version": "7",
5
+ "dialect": "postgresql",
6
+ "tables": {
7
+ "public.junior_api_tokens": {
8
+ "name": "junior_api_tokens",
9
+ "schema": "",
10
+ "columns": {
11
+ "id": {
12
+ "name": "id",
13
+ "type": "text",
14
+ "primaryKey": true,
15
+ "notNull": true
16
+ },
17
+ "owner_email_normalized": {
18
+ "name": "owner_email_normalized",
19
+ "type": "text",
20
+ "primaryKey": false,
21
+ "notNull": true
22
+ },
23
+ "name": {
24
+ "name": "name",
25
+ "type": "text",
26
+ "primaryKey": false,
27
+ "notNull": true
28
+ },
29
+ "token_hash": {
30
+ "name": "token_hash",
31
+ "type": "text",
32
+ "primaryKey": false,
33
+ "notNull": true
34
+ },
35
+ "token_suffix": {
36
+ "name": "token_suffix",
37
+ "type": "text",
38
+ "primaryKey": false,
39
+ "notNull": true
40
+ },
41
+ "created_at": {
42
+ "name": "created_at",
43
+ "type": "timestamp with time zone",
44
+ "primaryKey": false,
45
+ "notNull": true
46
+ },
47
+ "expires_at": {
48
+ "name": "expires_at",
49
+ "type": "timestamp with time zone",
50
+ "primaryKey": false,
51
+ "notNull": true
52
+ },
53
+ "last_used_at": {
54
+ "name": "last_used_at",
55
+ "type": "timestamp with time zone",
56
+ "primaryKey": false,
57
+ "notNull": false
58
+ },
59
+ "revoked_at": {
60
+ "name": "revoked_at",
61
+ "type": "timestamp with time zone",
62
+ "primaryKey": false,
63
+ "notNull": false
64
+ }
65
+ },
66
+ "indexes": {
67
+ "junior_api_tokens_token_hash_uidx": {
68
+ "name": "junior_api_tokens_token_hash_uidx",
69
+ "columns": [
70
+ {
71
+ "expression": "token_hash",
72
+ "isExpression": false,
73
+ "asc": true,
74
+ "nulls": "last"
75
+ }
76
+ ],
77
+ "isUnique": true,
78
+ "concurrently": false,
79
+ "method": "btree",
80
+ "with": {}
81
+ },
82
+ "junior_api_tokens_owner_email_idx": {
83
+ "name": "junior_api_tokens_owner_email_idx",
84
+ "columns": [
85
+ {
86
+ "expression": "owner_email_normalized",
87
+ "isExpression": false,
88
+ "asc": true,
89
+ "nulls": "last"
90
+ }
91
+ ],
92
+ "isUnique": false,
93
+ "concurrently": false,
94
+ "method": "btree",
95
+ "with": {}
96
+ }
97
+ },
98
+ "foreignKeys": {},
99
+ "compositePrimaryKeys": {},
100
+ "uniqueConstraints": {},
101
+ "policies": {},
102
+ "checkConstraints": {},
103
+ "isRLSEnabled": false
104
+ },
105
+ "public.junior_conversation_annotations": {
106
+ "name": "junior_conversation_annotations",
107
+ "schema": "",
108
+ "columns": {
109
+ "conversation_id": {
110
+ "name": "conversation_id",
111
+ "type": "text",
112
+ "primaryKey": false,
113
+ "notNull": true
114
+ },
115
+ "plugin": {
116
+ "name": "plugin",
117
+ "type": "text",
118
+ "primaryKey": false,
119
+ "notNull": true
120
+ },
121
+ "kind": {
122
+ "name": "kind",
123
+ "type": "text",
124
+ "primaryKey": false,
125
+ "notNull": true
126
+ },
127
+ "key": {
128
+ "name": "key",
129
+ "type": "text",
130
+ "primaryKey": false,
131
+ "notNull": true
132
+ },
133
+ "annotation_json": {
134
+ "name": "annotation_json",
135
+ "type": "jsonb",
136
+ "primaryKey": false,
137
+ "notNull": true
138
+ },
139
+ "created_at": {
140
+ "name": "created_at",
141
+ "type": "timestamp with time zone",
142
+ "primaryKey": false,
143
+ "notNull": true
144
+ },
145
+ "updated_at": {
146
+ "name": "updated_at",
147
+ "type": "timestamp with time zone",
148
+ "primaryKey": false,
149
+ "notNull": true
150
+ }
151
+ },
152
+ "indexes": {},
153
+ "foreignKeys": {
154
+ "junior_conversation_annotations_conversation_id_fk": {
155
+ "name": "junior_conversation_annotations_conversation_id_fk",
156
+ "tableFrom": "junior_conversation_annotations",
157
+ "tableTo": "junior_conversations",
158
+ "columnsFrom": ["conversation_id"],
159
+ "columnsTo": ["conversation_id"],
160
+ "onDelete": "cascade",
161
+ "onUpdate": "no action"
162
+ }
163
+ },
164
+ "compositePrimaryKeys": {
165
+ "junior_conversation_annotations_pk": {
166
+ "name": "junior_conversation_annotations_pk",
167
+ "columns": ["conversation_id", "plugin", "kind", "key"]
168
+ }
169
+ },
170
+ "uniqueConstraints": {},
171
+ "policies": {},
172
+ "checkConstraints": {},
173
+ "isRLSEnabled": false
174
+ },
175
+ "public.junior_conversation_events": {
176
+ "name": "junior_conversation_events",
177
+ "schema": "",
178
+ "columns": {
179
+ "conversation_id": {
180
+ "name": "conversation_id",
181
+ "type": "text",
182
+ "primaryKey": false,
183
+ "notNull": true
184
+ },
185
+ "seq": {
186
+ "name": "seq",
187
+ "type": "integer",
188
+ "primaryKey": false,
189
+ "notNull": true
190
+ },
191
+ "history_version": {
192
+ "name": "history_version",
193
+ "type": "integer",
194
+ "primaryKey": false,
195
+ "notNull": true
196
+ },
197
+ "schema_version": {
198
+ "name": "schema_version",
199
+ "type": "integer",
200
+ "primaryKey": false,
201
+ "notNull": true,
202
+ "default": 1
203
+ },
204
+ "idempotency_key": {
205
+ "name": "idempotency_key",
206
+ "type": "text",
207
+ "primaryKey": false,
208
+ "notNull": false
209
+ },
210
+ "type": {
211
+ "name": "type",
212
+ "type": "text",
213
+ "primaryKey": false,
214
+ "notNull": true
215
+ },
216
+ "payload": {
217
+ "name": "payload",
218
+ "type": "jsonb",
219
+ "primaryKey": false,
220
+ "notNull": true
221
+ },
222
+ "created_at": {
223
+ "name": "created_at",
224
+ "type": "timestamp with time zone",
225
+ "primaryKey": false,
226
+ "notNull": true
227
+ }
228
+ },
229
+ "indexes": {
230
+ "junior_conversation_events_history_version_idx": {
231
+ "name": "junior_conversation_events_history_version_idx",
232
+ "columns": [
233
+ {
234
+ "expression": "conversation_id",
235
+ "isExpression": false,
236
+ "asc": true,
237
+ "nulls": "last"
238
+ },
239
+ {
240
+ "expression": "history_version",
241
+ "isExpression": false,
242
+ "asc": true,
243
+ "nulls": "last"
244
+ },
245
+ {
246
+ "expression": "seq",
247
+ "isExpression": false,
248
+ "asc": true,
249
+ "nulls": "last"
250
+ }
251
+ ],
252
+ "isUnique": false,
253
+ "concurrently": false,
254
+ "method": "btree",
255
+ "with": {}
256
+ },
257
+ "junior_conversation_events_type_idx": {
258
+ "name": "junior_conversation_events_type_idx",
259
+ "columns": [
260
+ {
261
+ "expression": "conversation_id",
262
+ "isExpression": false,
263
+ "asc": true,
264
+ "nulls": "last"
265
+ },
266
+ {
267
+ "expression": "type",
268
+ "isExpression": false,
269
+ "asc": true,
270
+ "nulls": "last"
271
+ },
272
+ {
273
+ "expression": "seq",
274
+ "isExpression": false,
275
+ "asc": true,
276
+ "nulls": "last"
277
+ }
278
+ ],
279
+ "isUnique": false,
280
+ "concurrently": false,
281
+ "method": "btree",
282
+ "with": {}
283
+ },
284
+ "junior_conversation_events_message_search_idx": {
285
+ "name": "junior_conversation_events_message_search_idx",
286
+ "columns": [
287
+ {
288
+ "expression": "to_tsvector('english', \"payload\"->>'text')",
289
+ "asc": true,
290
+ "isExpression": true,
291
+ "nulls": "last"
292
+ }
293
+ ],
294
+ "isUnique": false,
295
+ "where": "\"junior_conversation_events\".\"type\" = 'message'",
296
+ "concurrently": false,
297
+ "method": "gin",
298
+ "with": {}
299
+ },
300
+ "junior_conversation_events_idempotency_idx": {
301
+ "name": "junior_conversation_events_idempotency_idx",
302
+ "columns": [
303
+ {
304
+ "expression": "conversation_id",
305
+ "isExpression": false,
306
+ "asc": true,
307
+ "nulls": "last"
308
+ },
309
+ {
310
+ "expression": "idempotency_key",
311
+ "isExpression": false,
312
+ "asc": true,
313
+ "nulls": "last"
314
+ }
315
+ ],
316
+ "isUnique": true,
317
+ "concurrently": false,
318
+ "method": "btree",
319
+ "with": {}
320
+ }
321
+ },
322
+ "foreignKeys": {
323
+ "junior_conversation_events_conversation_id_junior_conversations_conversation_id_fk": {
324
+ "name": "junior_conversation_events_conversation_id_junior_conversations_conversation_id_fk",
325
+ "tableFrom": "junior_conversation_events",
326
+ "tableTo": "junior_conversations",
327
+ "columnsFrom": ["conversation_id"],
328
+ "columnsTo": ["conversation_id"],
329
+ "onDelete": "no action",
330
+ "onUpdate": "no action"
331
+ }
332
+ },
333
+ "compositePrimaryKeys": {
334
+ "junior_conversation_events_conversation_id_seq_pk": {
335
+ "name": "junior_conversation_events_conversation_id_seq_pk",
336
+ "columns": ["conversation_id", "seq"]
337
+ }
338
+ },
339
+ "uniqueConstraints": {},
340
+ "policies": {},
341
+ "checkConstraints": {},
342
+ "isRLSEnabled": false
343
+ },
344
+ "public.junior_conversations": {
345
+ "name": "junior_conversations",
346
+ "schema": "",
347
+ "columns": {
348
+ "conversation_id": {
349
+ "name": "conversation_id",
350
+ "type": "text",
351
+ "primaryKey": true,
352
+ "notNull": true
353
+ },
354
+ "schema_version": {
355
+ "name": "schema_version",
356
+ "type": "integer",
357
+ "primaryKey": false,
358
+ "notNull": true,
359
+ "default": 1
360
+ },
361
+ "source": {
362
+ "name": "source",
363
+ "type": "text",
364
+ "primaryKey": false,
365
+ "notNull": false
366
+ },
367
+ "origin_type": {
368
+ "name": "origin_type",
369
+ "type": "text",
370
+ "primaryKey": false,
371
+ "notNull": false
372
+ },
373
+ "origin_id": {
374
+ "name": "origin_id",
375
+ "type": "text",
376
+ "primaryKey": false,
377
+ "notNull": false
378
+ },
379
+ "origin_run_id": {
380
+ "name": "origin_run_id",
381
+ "type": "text",
382
+ "primaryKey": false,
383
+ "notNull": false
384
+ },
385
+ "destination_id": {
386
+ "name": "destination_id",
387
+ "type": "text",
388
+ "primaryKey": false,
389
+ "notNull": false
390
+ },
391
+ "destination_json": {
392
+ "name": "destination_json",
393
+ "type": "jsonb",
394
+ "primaryKey": false,
395
+ "notNull": false
396
+ },
397
+ "actor_identity_id": {
398
+ "name": "actor_identity_id",
399
+ "type": "text",
400
+ "primaryKey": false,
401
+ "notNull": false
402
+ },
403
+ "creator_identity_id": {
404
+ "name": "creator_identity_id",
405
+ "type": "text",
406
+ "primaryKey": false,
407
+ "notNull": false
408
+ },
409
+ "credential_subject_identity_id": {
410
+ "name": "credential_subject_identity_id",
411
+ "type": "text",
412
+ "primaryKey": false,
413
+ "notNull": false
414
+ },
415
+ "actor_json": {
416
+ "name": "actor_json",
417
+ "type": "jsonb",
418
+ "primaryKey": false,
419
+ "notNull": false
420
+ },
421
+ "channel_name": {
422
+ "name": "channel_name",
423
+ "type": "text",
424
+ "primaryKey": false,
425
+ "notNull": false
426
+ },
427
+ "title": {
428
+ "name": "title",
429
+ "type": "text",
430
+ "primaryKey": false,
431
+ "notNull": false
432
+ },
433
+ "created_at": {
434
+ "name": "created_at",
435
+ "type": "timestamp with time zone",
436
+ "primaryKey": false,
437
+ "notNull": true
438
+ },
439
+ "last_activity_at": {
440
+ "name": "last_activity_at",
441
+ "type": "timestamp with time zone",
442
+ "primaryKey": false,
443
+ "notNull": true
444
+ },
445
+ "updated_at": {
446
+ "name": "updated_at",
447
+ "type": "timestamp with time zone",
448
+ "primaryKey": false,
449
+ "notNull": true
450
+ },
451
+ "execution_updated_at": {
452
+ "name": "execution_updated_at",
453
+ "type": "timestamp with time zone",
454
+ "primaryKey": false,
455
+ "notNull": false
456
+ },
457
+ "execution_status": {
458
+ "name": "execution_status",
459
+ "type": "text",
460
+ "primaryKey": false,
461
+ "notNull": true
462
+ },
463
+ "run_id": {
464
+ "name": "run_id",
465
+ "type": "text",
466
+ "primaryKey": false,
467
+ "notNull": false
468
+ },
469
+ "last_checkpoint_at": {
470
+ "name": "last_checkpoint_at",
471
+ "type": "timestamp with time zone",
472
+ "primaryKey": false,
473
+ "notNull": false
474
+ },
475
+ "last_enqueued_at": {
476
+ "name": "last_enqueued_at",
477
+ "type": "timestamp with time zone",
478
+ "primaryKey": false,
479
+ "notNull": false
480
+ },
481
+ "parent_conversation_id": {
482
+ "name": "parent_conversation_id",
483
+ "type": "text",
484
+ "primaryKey": false,
485
+ "notNull": false
486
+ },
487
+ "root_conversation_id": {
488
+ "name": "root_conversation_id",
489
+ "type": "text",
490
+ "primaryKey": false,
491
+ "notNull": false
492
+ },
493
+ "transcript_purged_at": {
494
+ "name": "transcript_purged_at",
495
+ "type": "timestamp with time zone",
496
+ "primaryKey": false,
497
+ "notNull": false
498
+ },
499
+ "duration_ms": {
500
+ "name": "duration_ms",
501
+ "type": "integer",
502
+ "primaryKey": false,
503
+ "notNull": true,
504
+ "default": 0
505
+ },
506
+ "usage_json": {
507
+ "name": "usage_json",
508
+ "type": "jsonb",
509
+ "primaryKey": false,
510
+ "notNull": false
511
+ },
512
+ "execution_duration_ms": {
513
+ "name": "execution_duration_ms",
514
+ "type": "integer",
515
+ "primaryKey": false,
516
+ "notNull": true,
517
+ "default": 0
518
+ },
519
+ "execution_usage_json": {
520
+ "name": "execution_usage_json",
521
+ "type": "jsonb",
522
+ "primaryKey": false,
523
+ "notNull": false
524
+ },
525
+ "metric_run_id": {
526
+ "name": "metric_run_id",
527
+ "type": "text",
528
+ "primaryKey": false,
529
+ "notNull": false
530
+ },
531
+ "archived_at": {
532
+ "name": "archived_at",
533
+ "type": "timestamp with time zone",
534
+ "primaryKey": false,
535
+ "notNull": false
536
+ }
537
+ },
538
+ "indexes": {
539
+ "junior_conversations_last_activity_idx": {
540
+ "name": "junior_conversations_last_activity_idx",
541
+ "columns": [
542
+ {
543
+ "expression": "last_activity_at",
544
+ "isExpression": false,
545
+ "asc": false,
546
+ "nulls": "last"
547
+ },
548
+ {
549
+ "expression": "conversation_id",
550
+ "isExpression": false,
551
+ "asc": true,
552
+ "nulls": "last"
553
+ }
554
+ ],
555
+ "isUnique": false,
556
+ "concurrently": false,
557
+ "method": "btree",
558
+ "with": {}
559
+ },
560
+ "junior_conversations_active_idx": {
561
+ "name": "junior_conversations_active_idx",
562
+ "columns": [
563
+ {
564
+ "expression": "coalesce(\"execution_updated_at\", \"updated_at\")",
565
+ "asc": true,
566
+ "isExpression": true,
567
+ "nulls": "last"
568
+ },
569
+ {
570
+ "expression": "conversation_id",
571
+ "isExpression": false,
572
+ "asc": true,
573
+ "nulls": "last"
574
+ }
575
+ ],
576
+ "isUnique": false,
577
+ "where": "\"junior_conversations\".\"execution_status\" <> 'idle'",
578
+ "concurrently": false,
579
+ "method": "btree",
580
+ "with": {}
581
+ },
582
+ "junior_conversations_destination_activity_idx": {
583
+ "name": "junior_conversations_destination_activity_idx",
584
+ "columns": [
585
+ {
586
+ "expression": "destination_id",
587
+ "isExpression": false,
588
+ "asc": true,
589
+ "nulls": "last"
590
+ },
591
+ {
592
+ "expression": "last_activity_at",
593
+ "isExpression": false,
594
+ "asc": false,
595
+ "nulls": "last"
596
+ }
597
+ ],
598
+ "isUnique": false,
599
+ "concurrently": false,
600
+ "method": "btree",
601
+ "with": {}
602
+ },
603
+ "junior_conversations_actor_activity_idx": {
604
+ "name": "junior_conversations_actor_activity_idx",
605
+ "columns": [
606
+ {
607
+ "expression": "actor_identity_id",
608
+ "isExpression": false,
609
+ "asc": true,
610
+ "nulls": "last"
611
+ },
612
+ {
613
+ "expression": "last_activity_at",
614
+ "isExpression": false,
615
+ "asc": false,
616
+ "nulls": "last"
617
+ }
618
+ ],
619
+ "isUnique": false,
620
+ "concurrently": false,
621
+ "method": "btree",
622
+ "with": {}
623
+ },
624
+ "junior_conversations_origin_idx": {
625
+ "name": "junior_conversations_origin_idx",
626
+ "columns": [
627
+ {
628
+ "expression": "origin_type",
629
+ "isExpression": false,
630
+ "asc": true,
631
+ "nulls": "last"
632
+ },
633
+ {
634
+ "expression": "origin_id",
635
+ "isExpression": false,
636
+ "asc": true,
637
+ "nulls": "last"
638
+ },
639
+ {
640
+ "expression": "last_activity_at",
641
+ "isExpression": false,
642
+ "asc": false,
643
+ "nulls": "last"
644
+ }
645
+ ],
646
+ "isUnique": false,
647
+ "concurrently": false,
648
+ "method": "btree",
649
+ "with": {}
650
+ },
651
+ "junior_conversations_parent_idx": {
652
+ "name": "junior_conversations_parent_idx",
653
+ "columns": [
654
+ {
655
+ "expression": "parent_conversation_id",
656
+ "isExpression": false,
657
+ "asc": true,
658
+ "nulls": "last"
659
+ }
660
+ ],
661
+ "isUnique": false,
662
+ "concurrently": false,
663
+ "method": "btree",
664
+ "with": {}
665
+ },
666
+ "junior_conversations_root_idx": {
667
+ "name": "junior_conversations_root_idx",
668
+ "columns": [
669
+ {
670
+ "expression": "root_conversation_id",
671
+ "isExpression": false,
672
+ "asc": true,
673
+ "nulls": "last"
674
+ }
675
+ ],
676
+ "isUnique": false,
677
+ "concurrently": false,
678
+ "method": "btree",
679
+ "with": {}
680
+ }
681
+ },
682
+ "foreignKeys": {
683
+ "junior_conversations_destination_id_junior_destinations_id_fk": {
684
+ "name": "junior_conversations_destination_id_junior_destinations_id_fk",
685
+ "tableFrom": "junior_conversations",
686
+ "tableTo": "junior_destinations",
687
+ "columnsFrom": ["destination_id"],
688
+ "columnsTo": ["id"],
689
+ "onDelete": "no action",
690
+ "onUpdate": "no action"
691
+ },
692
+ "junior_conversations_actor_identity_id_junior_identities_id_fk": {
693
+ "name": "junior_conversations_actor_identity_id_junior_identities_id_fk",
694
+ "tableFrom": "junior_conversations",
695
+ "tableTo": "junior_identities",
696
+ "columnsFrom": ["actor_identity_id"],
697
+ "columnsTo": ["id"],
698
+ "onDelete": "no action",
699
+ "onUpdate": "no action"
700
+ },
701
+ "junior_conversations_creator_identity_id_junior_identities_id_fk": {
702
+ "name": "junior_conversations_creator_identity_id_junior_identities_id_fk",
703
+ "tableFrom": "junior_conversations",
704
+ "tableTo": "junior_identities",
705
+ "columnsFrom": ["creator_identity_id"],
706
+ "columnsTo": ["id"],
707
+ "onDelete": "no action",
708
+ "onUpdate": "no action"
709
+ },
710
+ "junior_conversations_credential_subject_identity_id_junior_identities_id_fk": {
711
+ "name": "junior_conversations_credential_subject_identity_id_junior_identities_id_fk",
712
+ "tableFrom": "junior_conversations",
713
+ "tableTo": "junior_identities",
714
+ "columnsFrom": ["credential_subject_identity_id"],
715
+ "columnsTo": ["id"],
716
+ "onDelete": "no action",
717
+ "onUpdate": "no action"
718
+ },
719
+ "junior_conversations_parent_conversation_id_junior_conversations_conversation_id_fk": {
720
+ "name": "junior_conversations_parent_conversation_id_junior_conversations_conversation_id_fk",
721
+ "tableFrom": "junior_conversations",
722
+ "tableTo": "junior_conversations",
723
+ "columnsFrom": ["parent_conversation_id"],
724
+ "columnsTo": ["conversation_id"],
725
+ "onDelete": "no action",
726
+ "onUpdate": "no action"
727
+ },
728
+ "junior_conversations_root_conversation_id_junior_conversations_conversation_id_fk": {
729
+ "name": "junior_conversations_root_conversation_id_junior_conversations_conversation_id_fk",
730
+ "tableFrom": "junior_conversations",
731
+ "tableTo": "junior_conversations",
732
+ "columnsFrom": ["root_conversation_id"],
733
+ "columnsTo": ["conversation_id"],
734
+ "onDelete": "no action",
735
+ "onUpdate": "no action"
736
+ }
737
+ },
738
+ "compositePrimaryKeys": {},
739
+ "uniqueConstraints": {},
740
+ "policies": {},
741
+ "checkConstraints": {},
742
+ "isRLSEnabled": false
743
+ },
744
+ "public.junior_destinations": {
745
+ "name": "junior_destinations",
746
+ "schema": "",
747
+ "columns": {
748
+ "id": {
749
+ "name": "id",
750
+ "type": "text",
751
+ "primaryKey": true,
752
+ "notNull": true
753
+ },
754
+ "provider": {
755
+ "name": "provider",
756
+ "type": "text",
757
+ "primaryKey": false,
758
+ "notNull": true
759
+ },
760
+ "provider_tenant_id": {
761
+ "name": "provider_tenant_id",
762
+ "type": "text",
763
+ "primaryKey": false,
764
+ "notNull": true,
765
+ "default": "''"
766
+ },
767
+ "provider_destination_id": {
768
+ "name": "provider_destination_id",
769
+ "type": "text",
770
+ "primaryKey": false,
771
+ "notNull": true
772
+ },
773
+ "kind": {
774
+ "name": "kind",
775
+ "type": "text",
776
+ "primaryKey": false,
777
+ "notNull": true
778
+ },
779
+ "parent_destination_id": {
780
+ "name": "parent_destination_id",
781
+ "type": "text",
782
+ "primaryKey": false,
783
+ "notNull": false
784
+ },
785
+ "display_name": {
786
+ "name": "display_name",
787
+ "type": "text",
788
+ "primaryKey": false,
789
+ "notNull": false
790
+ },
791
+ "visibility": {
792
+ "name": "visibility",
793
+ "type": "text",
794
+ "primaryKey": false,
795
+ "notNull": true,
796
+ "default": "'unknown'"
797
+ },
798
+ "metadata_json": {
799
+ "name": "metadata_json",
800
+ "type": "jsonb",
801
+ "primaryKey": false,
802
+ "notNull": false
803
+ },
804
+ "created_at": {
805
+ "name": "created_at",
806
+ "type": "timestamp with time zone",
807
+ "primaryKey": false,
808
+ "notNull": true
809
+ },
810
+ "updated_at": {
811
+ "name": "updated_at",
812
+ "type": "timestamp with time zone",
813
+ "primaryKey": false,
814
+ "notNull": true
815
+ }
816
+ },
817
+ "indexes": {
818
+ "junior_destinations_provider_destination_uidx": {
819
+ "name": "junior_destinations_provider_destination_uidx",
820
+ "columns": [
821
+ {
822
+ "expression": "provider",
823
+ "isExpression": false,
824
+ "asc": true,
825
+ "nulls": "last"
826
+ },
827
+ {
828
+ "expression": "provider_tenant_id",
829
+ "isExpression": false,
830
+ "asc": true,
831
+ "nulls": "last"
832
+ },
833
+ {
834
+ "expression": "provider_destination_id",
835
+ "isExpression": false,
836
+ "asc": true,
837
+ "nulls": "last"
838
+ }
839
+ ],
840
+ "isUnique": true,
841
+ "concurrently": false,
842
+ "method": "btree",
843
+ "with": {}
844
+ },
845
+ "junior_destinations_provider_kind_idx": {
846
+ "name": "junior_destinations_provider_kind_idx",
847
+ "columns": [
848
+ {
849
+ "expression": "provider",
850
+ "isExpression": false,
851
+ "asc": true,
852
+ "nulls": "last"
853
+ },
854
+ {
855
+ "expression": "kind",
856
+ "isExpression": false,
857
+ "asc": true,
858
+ "nulls": "last"
859
+ }
860
+ ],
861
+ "isUnique": false,
862
+ "concurrently": false,
863
+ "method": "btree",
864
+ "with": {}
865
+ }
866
+ },
867
+ "foreignKeys": {},
868
+ "compositePrimaryKeys": {},
869
+ "uniqueConstraints": {},
870
+ "policies": {},
871
+ "checkConstraints": {},
872
+ "isRLSEnabled": false
873
+ },
874
+ "public.junior_identities": {
875
+ "name": "junior_identities",
876
+ "schema": "",
877
+ "columns": {
878
+ "id": {
879
+ "name": "id",
880
+ "type": "text",
881
+ "primaryKey": true,
882
+ "notNull": true
883
+ },
884
+ "kind": {
885
+ "name": "kind",
886
+ "type": "text",
887
+ "primaryKey": false,
888
+ "notNull": true
889
+ },
890
+ "provider": {
891
+ "name": "provider",
892
+ "type": "text",
893
+ "primaryKey": false,
894
+ "notNull": true
895
+ },
896
+ "provider_tenant_id": {
897
+ "name": "provider_tenant_id",
898
+ "type": "text",
899
+ "primaryKey": false,
900
+ "notNull": true,
901
+ "default": "''"
902
+ },
903
+ "provider_subject_id": {
904
+ "name": "provider_subject_id",
905
+ "type": "text",
906
+ "primaryKey": false,
907
+ "notNull": true
908
+ },
909
+ "display_name": {
910
+ "name": "display_name",
911
+ "type": "text",
912
+ "primaryKey": false,
913
+ "notNull": false
914
+ },
915
+ "handle": {
916
+ "name": "handle",
917
+ "type": "text",
918
+ "primaryKey": false,
919
+ "notNull": false
920
+ },
921
+ "email": {
922
+ "name": "email",
923
+ "type": "text",
924
+ "primaryKey": false,
925
+ "notNull": false
926
+ },
927
+ "avatar_url": {
928
+ "name": "avatar_url",
929
+ "type": "text",
930
+ "primaryKey": false,
931
+ "notNull": false
932
+ },
933
+ "metadata_json": {
934
+ "name": "metadata_json",
935
+ "type": "jsonb",
936
+ "primaryKey": false,
937
+ "notNull": false
938
+ },
939
+ "created_at": {
940
+ "name": "created_at",
941
+ "type": "timestamp with time zone",
942
+ "primaryKey": false,
943
+ "notNull": true
944
+ },
945
+ "updated_at": {
946
+ "name": "updated_at",
947
+ "type": "timestamp with time zone",
948
+ "primaryKey": false,
949
+ "notNull": true
950
+ },
951
+ "user_id": {
952
+ "name": "user_id",
953
+ "type": "text",
954
+ "primaryKey": false,
955
+ "notNull": false
956
+ },
957
+ "email_normalized": {
958
+ "name": "email_normalized",
959
+ "type": "text",
960
+ "primaryKey": false,
961
+ "notNull": false
962
+ },
963
+ "email_verified": {
964
+ "name": "email_verified",
965
+ "type": "boolean",
966
+ "primaryKey": false,
967
+ "notNull": true,
968
+ "default": false
969
+ }
970
+ },
971
+ "indexes": {
972
+ "junior_identities_provider_subject_uidx": {
973
+ "name": "junior_identities_provider_subject_uidx",
974
+ "columns": [
975
+ {
976
+ "expression": "provider",
977
+ "isExpression": false,
978
+ "asc": true,
979
+ "nulls": "last"
980
+ },
981
+ {
982
+ "expression": "provider_tenant_id",
983
+ "isExpression": false,
984
+ "asc": true,
985
+ "nulls": "last"
986
+ },
987
+ {
988
+ "expression": "provider_subject_id",
989
+ "isExpression": false,
990
+ "asc": true,
991
+ "nulls": "last"
992
+ }
993
+ ],
994
+ "isUnique": true,
995
+ "concurrently": false,
996
+ "method": "btree",
997
+ "with": {}
998
+ },
999
+ "junior_identities_user_idx": {
1000
+ "name": "junior_identities_user_idx",
1001
+ "columns": [
1002
+ {
1003
+ "expression": "user_id",
1004
+ "isExpression": false,
1005
+ "asc": true,
1006
+ "nulls": "last"
1007
+ }
1008
+ ],
1009
+ "isUnique": false,
1010
+ "concurrently": false,
1011
+ "method": "btree",
1012
+ "with": {}
1013
+ },
1014
+ "junior_identities_verified_email_idx": {
1015
+ "name": "junior_identities_verified_email_idx",
1016
+ "columns": [
1017
+ {
1018
+ "expression": "email_normalized",
1019
+ "isExpression": false,
1020
+ "asc": true,
1021
+ "nulls": "last"
1022
+ }
1023
+ ],
1024
+ "isUnique": false,
1025
+ "where": "\"junior_identities\".\"email_verified\" = true AND \"junior_identities\".\"email_normalized\" IS NOT NULL",
1026
+ "concurrently": false,
1027
+ "method": "btree",
1028
+ "with": {}
1029
+ },
1030
+ "junior_identities_kind_provider_idx": {
1031
+ "name": "junior_identities_kind_provider_idx",
1032
+ "columns": [
1033
+ {
1034
+ "expression": "kind",
1035
+ "isExpression": false,
1036
+ "asc": true,
1037
+ "nulls": "last"
1038
+ },
1039
+ {
1040
+ "expression": "provider",
1041
+ "isExpression": false,
1042
+ "asc": true,
1043
+ "nulls": "last"
1044
+ }
1045
+ ],
1046
+ "isUnique": false,
1047
+ "concurrently": false,
1048
+ "method": "btree",
1049
+ "with": {}
1050
+ }
1051
+ },
1052
+ "foreignKeys": {
1053
+ "junior_identities_user_id_junior_users_id_fk": {
1054
+ "name": "junior_identities_user_id_junior_users_id_fk",
1055
+ "tableFrom": "junior_identities",
1056
+ "tableTo": "junior_users",
1057
+ "columnsFrom": ["user_id"],
1058
+ "columnsTo": ["id"],
1059
+ "onDelete": "no action",
1060
+ "onUpdate": "no action"
1061
+ }
1062
+ },
1063
+ "compositePrimaryKeys": {},
1064
+ "uniqueConstraints": {},
1065
+ "policies": {},
1066
+ "checkConstraints": {},
1067
+ "isRLSEnabled": false
1068
+ },
1069
+ "public.junior_users": {
1070
+ "name": "junior_users",
1071
+ "schema": "",
1072
+ "columns": {
1073
+ "id": {
1074
+ "name": "id",
1075
+ "type": "text",
1076
+ "primaryKey": true,
1077
+ "notNull": true
1078
+ },
1079
+ "primary_email": {
1080
+ "name": "primary_email",
1081
+ "type": "text",
1082
+ "primaryKey": false,
1083
+ "notNull": true
1084
+ },
1085
+ "primary_email_normalized": {
1086
+ "name": "primary_email_normalized",
1087
+ "type": "text",
1088
+ "primaryKey": false,
1089
+ "notNull": true
1090
+ },
1091
+ "display_name": {
1092
+ "name": "display_name",
1093
+ "type": "text",
1094
+ "primaryKey": false,
1095
+ "notNull": false
1096
+ },
1097
+ "created_at": {
1098
+ "name": "created_at",
1099
+ "type": "timestamp with time zone",
1100
+ "primaryKey": false,
1101
+ "notNull": true
1102
+ },
1103
+ "updated_at": {
1104
+ "name": "updated_at",
1105
+ "type": "timestamp with time zone",
1106
+ "primaryKey": false,
1107
+ "notNull": true
1108
+ }
1109
+ },
1110
+ "indexes": {
1111
+ "junior_users_primary_email_normalized_uidx": {
1112
+ "name": "junior_users_primary_email_normalized_uidx",
1113
+ "columns": [
1114
+ {
1115
+ "expression": "primary_email_normalized",
1116
+ "isExpression": false,
1117
+ "asc": true,
1118
+ "nulls": "last"
1119
+ }
1120
+ ],
1121
+ "isUnique": true,
1122
+ "concurrently": false,
1123
+ "method": "btree",
1124
+ "with": {}
1125
+ }
1126
+ },
1127
+ "foreignKeys": {},
1128
+ "compositePrimaryKeys": {},
1129
+ "uniqueConstraints": {},
1130
+ "policies": {},
1131
+ "checkConstraints": {},
1132
+ "isRLSEnabled": false
1133
+ }
1134
+ },
1135
+ "enums": {},
1136
+ "schemas": {},
1137
+ "sequences": {},
1138
+ "roles": {},
1139
+ "policies": {},
1140
+ "views": {},
1141
+ "_meta": {
1142
+ "columns": {},
1143
+ "schemas": {},
1144
+ "tables": {}
1145
+ }
1146
+ }