@sentry/junior 0.114.0 → 0.115.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.
- package/dist/{agent-hooks-WNBUY4OB.js → agent-hooks-4EUUXP2F.js} +12 -11
- package/dist/api/conversations/detail.d.ts +2 -0
- package/dist/api/conversations/event-list.d.ts +2 -0
- package/dist/api/health.d.ts +7 -0
- package/dist/api/plugin-reports.d.ts +62 -0
- package/dist/api/plugins.d.ts +9 -0
- package/dist/api/runtime.d.ts +24 -0
- package/dist/api/schema/conversation.d.ts +8 -0
- package/dist/api/schema.d.ts +2 -2
- package/dist/api/schema.js +6 -6
- package/dist/api/skills.d.ts +6 -0
- package/dist/api.js +123 -99
- package/dist/app.js +1104 -5006
- package/dist/catalog-runtime-Y32UEQLB.js +18 -0
- package/dist/chat/agent/request.d.ts +6 -0
- package/dist/chat/agent/sandbox.d.ts +2 -0
- package/dist/chat/agent/tools.d.ts +2 -0
- package/dist/chat/config.d.ts +2 -0
- package/dist/chat/conversations/history.d.ts +6 -0
- package/dist/chat/local/credential-sync.d.ts +5 -0
- package/dist/chat/local/oauth-relay.d.ts +4 -0
- package/dist/chat/mcp/oauth.d.ts +1 -0
- package/dist/chat/oauth-authorization.d.ts +17 -0
- package/dist/chat/oauth-flow.d.ts +9 -0
- package/dist/chat/sandbox/egress/schemas.d.ts +46 -0
- package/dist/chat/sandbox/egress/signals.d.ts +9 -0
- package/dist/chat/sandbox/sandbox.d.ts +2 -0
- package/dist/chat/sentry-payload-filter.d.ts +4 -4
- package/dist/chat/services/mcp-auth-orchestration.d.ts +5 -3
- package/dist/chat/services/plugin-auth-orchestration.d.ts +2 -0
- package/dist/chat/slack/message-control.d.ts +2 -0
- package/dist/chat/slack/oauth-authorization-message.d.ts +3 -0
- package/dist/chat/task-execution/slack-work.d.ts +2 -0
- package/dist/chat/tool-support/zod-tool.d.ts +1 -1
- package/dist/chat/tools/definition.d.ts +5 -0
- package/dist/{chunk-TLGM5X2M.js → chunk-2QG4MZQ7.js} +2 -2
- package/dist/{chunk-WV4UJBAS.js → chunk-43RYMWJ2.js} +523 -2373
- package/dist/chunk-4CODA7P5.js +43 -0
- package/dist/{chunk-YU6PO42Q.js → chunk-67CVNDJ7.js} +1 -1
- package/dist/{chunk-OSKEC4XU.js → chunk-6FKLPVF3.js} +1 -1
- package/dist/{chunk-2ZTTXTSZ.js → chunk-6OPTF4BQ.js} +10 -4
- package/dist/{chunk-W6RDUAO3.js → chunk-6V762AB4.js} +1 -1
- package/dist/{chunk-ABPSDO6M.js → chunk-AGLQYELI.js} +77 -8
- package/dist/{chunk-6QWPVTMO.js → chunk-CEYOL62C.js} +9 -7
- package/dist/{chunk-RD7EJI7H.js → chunk-CWEZEPD4.js} +3 -3
- package/dist/chunk-DIB4GX3G.js +8 -0
- package/dist/{chunk-K2W4CK7K.js → chunk-EW5MLKT5.js} +10 -75
- package/dist/{chunk-42WRQLJ6.js → chunk-F3B2YJ76.js} +0 -14
- package/dist/chunk-FA6POGLH.js +70 -0
- package/dist/{chunk-PM3PX42K.js → chunk-FHC4JUSF.js} +1 -1
- package/dist/{chunk-6Y5L4BOM.js → chunk-FXOYURO4.js} +5 -3
- package/dist/{chunk-S4QDH23A.js → chunk-G36V2YGB.js} +83 -81
- package/dist/{chunk-O4GT7LYB.js → chunk-G5SX4UPR.js} +3 -43
- package/dist/chunk-HDSDCEPK.js +80 -0
- package/dist/{chunk-FIGAF6KL.js → chunk-HWCQRGLL.js} +5 -3
- package/dist/{chunk-C4MZ3GP5.js → chunk-HZF5P5UN.js} +1 -1
- package/dist/chunk-LYA2AB5G.js +1914 -0
- package/dist/{chunk-4FUEG3QY.js → chunk-NVUQSFWX.js} +2 -2
- package/dist/chunk-OB42YVAE.js +16 -0
- package/dist/{chunk-XLFBQJUO.js → chunk-PVZHG2XZ.js} +4 -4
- package/dist/{chunk-VNNBSKCO.js → chunk-RAVKCKXA.js} +7 -7
- package/dist/{chunk-ZGXH3REA.js → chunk-SYJT7AKB.js} +12 -2
- package/dist/{chunk-5CZ7RETL.js → chunk-TVE25LPW.js} +1 -1
- package/dist/chunk-W3U3YQYI.js +71 -0
- package/dist/chunk-YCLO7D7M.js +4267 -0
- package/dist/cli/chat.js +72 -40
- package/dist/cli/check.js +10 -8
- package/dist/cli/init.js +1 -0
- package/dist/cli/plugins.js +16 -14
- package/dist/cli/snapshot-warmup.js +13 -11
- package/dist/cli/upgrade.js +10 -8
- package/dist/{db-4VLP7KBF.js → db-KBSJHAZU.js} +8 -7
- package/dist/handlers/sandbox-egress-signals.d.ts +4 -0
- package/dist/instrumentation.js +72 -4
- package/dist/nitro.js +2 -2
- package/dist/oauth-callback-server-EYRMJTCS.js +231 -0
- package/dist/oauth-relay-3ZU72UGL.js +9 -0
- package/dist/reporting-schema.d.ts +12 -4
- package/dist/reporting.d.ts +5 -5
- package/dist/{runner-IPXLWQOF.js → runner-RQGZ5Z2S.js} +139 -72
- package/dist/sandbox-egress-signals-CDFAP67O.js +75 -0
- package/dist/{skills-QCNZISNF.js → skills-JJQIE3BT.js} +10 -8
- package/dist/validation-MZ47PZP5.js +21 -0
- package/dist/version.js +1 -1
- package/package.json +5 -5
- package/dist/catalog-runtime-6O4M6JGA.js +0 -16
- package/dist/chat/oauth-authorization-message.d.ts +0 -6
- package/dist/validation-I2BW3UHD.js +0 -19
|
@@ -5,9 +5,37 @@ import {
|
|
|
5
5
|
juniorDestinationKindSchema
|
|
6
6
|
} from "./chunk-VFUK3X5B.js";
|
|
7
7
|
|
|
8
|
-
// src/api/
|
|
8
|
+
// src/api/activity.ts
|
|
9
9
|
import { z } from "zod";
|
|
10
|
-
var
|
|
10
|
+
var dailyConversationActivitySchema = z.object({
|
|
11
|
+
active: z.number(),
|
|
12
|
+
conversations: z.number(),
|
|
13
|
+
date: z.string(),
|
|
14
|
+
durationMs: z.number(),
|
|
15
|
+
failed: z.number(),
|
|
16
|
+
tokens: z.number().optional()
|
|
17
|
+
}).strict();
|
|
18
|
+
function emptyActivityDay(date) {
|
|
19
|
+
return {
|
|
20
|
+
active: 0,
|
|
21
|
+
conversations: 0,
|
|
22
|
+
date,
|
|
23
|
+
durationMs: 0,
|
|
24
|
+
failed: 0
|
|
25
|
+
};
|
|
26
|
+
}
|
|
27
|
+
function activityDays(days, nowMs, count) {
|
|
28
|
+
const items = [];
|
|
29
|
+
const end = new Date(nowMs);
|
|
30
|
+
end.setUTCHours(0, 0, 0, 0);
|
|
31
|
+
const start = new Date(end);
|
|
32
|
+
start.setUTCDate(start.getUTCDate() - (count - 1));
|
|
33
|
+
for (const cursor = new Date(start); cursor.getTime() <= end.getTime(); cursor.setUTCDate(cursor.getUTCDate() + 1)) {
|
|
34
|
+
const date = cursor.toISOString().slice(0, 10);
|
|
35
|
+
items.push(days.get(date) ?? emptyActivityDay(date));
|
|
36
|
+
}
|
|
37
|
+
return items;
|
|
38
|
+
}
|
|
11
39
|
|
|
12
40
|
// src/api/schema/conversation.ts
|
|
13
41
|
import { z as z2 } from "zod";
|
|
@@ -130,6 +158,7 @@ var conversationReportCompactionEventDataSchema = z2.object({
|
|
|
130
158
|
type: z2.literal("compaction"),
|
|
131
159
|
modelProfile: z2.string().min(1).optional(),
|
|
132
160
|
modelId: z2.string().min(1).optional(),
|
|
161
|
+
summary: z2.string().min(1).optional(),
|
|
133
162
|
details: z2.object({
|
|
134
163
|
reason: z2.literal("capacity"),
|
|
135
164
|
estimatedInputTokens: z2.number().int().nonnegative(),
|
|
@@ -146,7 +175,8 @@ var conversationReportHandoffEventDataSchema = z2.object({
|
|
|
146
175
|
modelProfile: z2.string().min(1),
|
|
147
176
|
modelId: z2.string().min(1),
|
|
148
177
|
reasoningLevel: z2.string().min(1).optional(),
|
|
149
|
-
triggeringToolCallId: z2.string().min(1).optional()
|
|
178
|
+
triggeringToolCallId: z2.string().min(1).optional(),
|
|
179
|
+
summary: z2.string().min(1).optional()
|
|
150
180
|
}).strict();
|
|
151
181
|
var conversationReportSubagentEventDataSchema = z2.object({
|
|
152
182
|
type: z2.literal("subagent"),
|
|
@@ -282,37 +312,58 @@ var conversationStatsReportSchema = z2.object({
|
|
|
282
312
|
windowStart: z2.string()
|
|
283
313
|
}).strict();
|
|
284
314
|
|
|
285
|
-
// src/api/
|
|
315
|
+
// src/api/schema/person.ts
|
|
286
316
|
import { z as z3 } from "zod";
|
|
287
|
-
var
|
|
317
|
+
var personParamsSchema = z3.object({ email: z3.string().trim().min(1) }).strict();
|
|
318
|
+
var peopleConversationStatsItemSchema = conversationStatsItemSchema.omit({ costUsd: true });
|
|
319
|
+
var actorActivityDayReportSchema = z3.object({
|
|
288
320
|
active: z3.number(),
|
|
289
321
|
conversations: z3.number(),
|
|
322
|
+
costUsd: z3.number().optional(),
|
|
290
323
|
date: z3.string(),
|
|
291
324
|
durationMs: z3.number(),
|
|
292
325
|
failed: z3.number(),
|
|
293
326
|
tokens: z3.number().optional()
|
|
294
327
|
}).strict();
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
328
|
+
var peopleActivityDayReportSchema = z3.object({
|
|
329
|
+
activePeople: z3.number(),
|
|
330
|
+
conversations: z3.number(),
|
|
331
|
+
date: z3.string()
|
|
332
|
+
}).strict();
|
|
333
|
+
var actorTotalsReportSchema = z3.object({
|
|
334
|
+
active: z3.number(),
|
|
335
|
+
activeDays: z3.number(),
|
|
336
|
+
conversations: z3.number(),
|
|
337
|
+
durationMs: z3.number(),
|
|
338
|
+
failed: z3.number(),
|
|
339
|
+
tokens: z3.number().optional()
|
|
340
|
+
}).strict();
|
|
341
|
+
var identifiedActorSchema = actorIdentitySchema.extend({ email: z3.string().min(1) }).strict();
|
|
342
|
+
var actorSummaryReportSchema = actorTotalsReportSchema.extend({
|
|
343
|
+
firstSeenAt: z3.string(),
|
|
344
|
+
lastSeenAt: z3.string(),
|
|
345
|
+
actor: identifiedActorSchema
|
|
346
|
+
}).strict();
|
|
347
|
+
var actorDirectoryReportSchema = z3.object({
|
|
348
|
+
activityDays: z3.array(peopleActivityDayReportSchema),
|
|
349
|
+
generatedAt: z3.string(),
|
|
350
|
+
people: z3.array(actorSummaryReportSchema),
|
|
351
|
+
source: z3.literal("conversation_index"),
|
|
352
|
+
windowEnd: z3.string(),
|
|
353
|
+
windowStart: z3.string()
|
|
354
|
+
}).strict();
|
|
355
|
+
var actorProfileReportSchema = z3.object({
|
|
356
|
+
activityDays: z3.array(actorActivityDayReportSchema),
|
|
357
|
+
generatedAt: z3.string(),
|
|
358
|
+
locations: z3.array(peopleConversationStatsItemSchema),
|
|
359
|
+
recentConversations: z3.array(conversationSummaryReportSchema),
|
|
360
|
+
actor: identifiedActorSchema,
|
|
361
|
+
source: z3.literal("conversation_index"),
|
|
362
|
+
surfaces: z3.array(peopleConversationStatsItemSchema),
|
|
363
|
+
totals: actorTotalsReportSchema,
|
|
364
|
+
windowEnd: z3.string(),
|
|
365
|
+
windowStart: z3.string()
|
|
366
|
+
}).strict();
|
|
316
367
|
|
|
317
368
|
// src/api/schema/location.ts
|
|
318
369
|
import { z as z4 } from "zod";
|
|
@@ -351,58 +402,9 @@ var locationDetailReportSchema = locationSummaryReportSchema.extend({
|
|
|
351
402
|
windowStart: z4.string()
|
|
352
403
|
}).strict();
|
|
353
404
|
|
|
354
|
-
// src/api/schema/
|
|
405
|
+
// src/api/schema/common.ts
|
|
355
406
|
import { z as z5 } from "zod";
|
|
356
|
-
var
|
|
357
|
-
var peopleConversationStatsItemSchema = conversationStatsItemSchema.omit({ costUsd: true });
|
|
358
|
-
var actorActivityDayReportSchema = z5.object({
|
|
359
|
-
active: z5.number(),
|
|
360
|
-
conversations: z5.number(),
|
|
361
|
-
costUsd: z5.number().optional(),
|
|
362
|
-
date: z5.string(),
|
|
363
|
-
durationMs: z5.number(),
|
|
364
|
-
failed: z5.number(),
|
|
365
|
-
tokens: z5.number().optional()
|
|
366
|
-
}).strict();
|
|
367
|
-
var peopleActivityDayReportSchema = z5.object({
|
|
368
|
-
activePeople: z5.number(),
|
|
369
|
-
conversations: z5.number(),
|
|
370
|
-
date: z5.string()
|
|
371
|
-
}).strict();
|
|
372
|
-
var actorTotalsReportSchema = z5.object({
|
|
373
|
-
active: z5.number(),
|
|
374
|
-
activeDays: z5.number(),
|
|
375
|
-
conversations: z5.number(),
|
|
376
|
-
durationMs: z5.number(),
|
|
377
|
-
failed: z5.number(),
|
|
378
|
-
tokens: z5.number().optional()
|
|
379
|
-
}).strict();
|
|
380
|
-
var identifiedActorSchema = actorIdentitySchema.extend({ email: z5.string().min(1) }).strict();
|
|
381
|
-
var actorSummaryReportSchema = actorTotalsReportSchema.extend({
|
|
382
|
-
firstSeenAt: z5.string(),
|
|
383
|
-
lastSeenAt: z5.string(),
|
|
384
|
-
actor: identifiedActorSchema
|
|
385
|
-
}).strict();
|
|
386
|
-
var actorDirectoryReportSchema = z5.object({
|
|
387
|
-
activityDays: z5.array(peopleActivityDayReportSchema),
|
|
388
|
-
generatedAt: z5.string(),
|
|
389
|
-
people: z5.array(actorSummaryReportSchema),
|
|
390
|
-
source: z5.literal("conversation_index"),
|
|
391
|
-
windowEnd: z5.string(),
|
|
392
|
-
windowStart: z5.string()
|
|
393
|
-
}).strict();
|
|
394
|
-
var actorProfileReportSchema = z5.object({
|
|
395
|
-
activityDays: z5.array(actorActivityDayReportSchema),
|
|
396
|
-
generatedAt: z5.string(),
|
|
397
|
-
locations: z5.array(peopleConversationStatsItemSchema),
|
|
398
|
-
recentConversations: z5.array(conversationSummaryReportSchema),
|
|
399
|
-
actor: identifiedActorSchema,
|
|
400
|
-
source: z5.literal("conversation_index"),
|
|
401
|
-
surfaces: z5.array(peopleConversationStatsItemSchema),
|
|
402
|
-
totals: actorTotalsReportSchema,
|
|
403
|
-
windowEnd: z5.string(),
|
|
404
|
-
windowStart: z5.string()
|
|
405
|
-
}).strict();
|
|
407
|
+
var apiErrorSchema = z5.object({ error: z5.string().min(1) }).strict();
|
|
406
408
|
|
|
407
409
|
export {
|
|
408
410
|
apiErrorSchema,
|
|
@@ -422,11 +424,11 @@ export {
|
|
|
422
424
|
conversationStatsReportSchema,
|
|
423
425
|
dailyConversationActivitySchema,
|
|
424
426
|
activityDays,
|
|
427
|
+
personParamsSchema,
|
|
428
|
+
actorDirectoryReportSchema,
|
|
429
|
+
actorProfileReportSchema,
|
|
425
430
|
locationParamsSchema,
|
|
426
431
|
locationActivityDayReportSchema,
|
|
427
432
|
locationDirectoryReportSchema,
|
|
428
|
-
locationDetailReportSchema
|
|
429
|
-
personParamsSchema,
|
|
430
|
-
actorDirectoryReportSchema,
|
|
431
|
-
actorProfileReportSchema
|
|
433
|
+
locationDetailReportSchema
|
|
432
434
|
};
|
|
@@ -1,15 +1,12 @@
|
|
|
1
1
|
import {
|
|
2
2
|
healthReportSchema
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-6OPTF4BQ.js";
|
|
4
4
|
import {
|
|
5
5
|
normalizeSlackConversationId
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-CWEZEPD4.js";
|
|
7
7
|
import {
|
|
8
8
|
parseSlackThreadId
|
|
9
|
-
} from "./chunk-
|
|
10
|
-
import {
|
|
11
|
-
getClient
|
|
12
|
-
} from "./chunk-6GWA276C.js";
|
|
9
|
+
} from "./chunk-FXOYURO4.js";
|
|
13
10
|
|
|
14
11
|
// src/handlers/health.ts
|
|
15
12
|
function readHealthReport() {
|
|
@@ -23,42 +20,6 @@ function GET() {
|
|
|
23
20
|
return Response.json(readHealthReport());
|
|
24
21
|
}
|
|
25
22
|
|
|
26
|
-
// src/chat/sentry-links.ts
|
|
27
|
-
function getSentryOrgSlug() {
|
|
28
|
-
const slug = process.env.SENTRY_ORG_SLUG?.trim();
|
|
29
|
-
return slug || void 0;
|
|
30
|
-
}
|
|
31
|
-
function isSentrySaasDsnHost(host) {
|
|
32
|
-
return host === "sentry.io" || host.endsWith(".sentry.io");
|
|
33
|
-
}
|
|
34
|
-
function buildSentryWebBaseUrl(dsn) {
|
|
35
|
-
if (isSentrySaasDsnHost(dsn.host)) {
|
|
36
|
-
return "https://sentry.io";
|
|
37
|
-
}
|
|
38
|
-
const port = dsn.port ? `:${dsn.port}` : "";
|
|
39
|
-
const path = dsn.path ? `/${dsn.path}` : "";
|
|
40
|
-
return `${dsn.protocol}://${dsn.host}${port}${path}`;
|
|
41
|
-
}
|
|
42
|
-
function buildSentryConversationUrl(conversationId) {
|
|
43
|
-
const client = getClient();
|
|
44
|
-
const dsn = client?.getDsn();
|
|
45
|
-
if (!dsn?.host || !dsn.projectId) {
|
|
46
|
-
return void 0;
|
|
47
|
-
}
|
|
48
|
-
const orgSlug = getSentryOrgSlug();
|
|
49
|
-
if (!orgSlug) {
|
|
50
|
-
return void 0;
|
|
51
|
-
}
|
|
52
|
-
const encodedId = encodeURIComponent(conversationId);
|
|
53
|
-
const params = new URLSearchParams();
|
|
54
|
-
params.set("project", dsn.projectId);
|
|
55
|
-
const path = `explore/conversations/${encodedId}/?${params.toString()}`;
|
|
56
|
-
if (isSentrySaasDsnHost(dsn.host)) {
|
|
57
|
-
return `https://${orgSlug}.sentry.io/${path}`;
|
|
58
|
-
}
|
|
59
|
-
return `${buildSentryWebBaseUrl(dsn)}/organizations/${orgSlug}/${path}`;
|
|
60
|
-
}
|
|
61
|
-
|
|
62
23
|
// src/chat/slack/conversation-context.ts
|
|
63
24
|
function normalizeConversationName(type, channelName) {
|
|
64
25
|
const trimmed = channelName?.trim();
|
|
@@ -144,7 +105,6 @@ function formatSlackConversationRedactedLabel(context) {
|
|
|
144
105
|
export {
|
|
145
106
|
readHealthReport,
|
|
146
107
|
GET,
|
|
147
|
-
buildSentryConversationUrl,
|
|
148
108
|
conversationVisibilityFromSlackChannelType,
|
|
149
109
|
resolveSlackChannelTypeFromMessage,
|
|
150
110
|
resolveSlackConversationContext,
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
import {
|
|
2
|
+
credentialContextSchema
|
|
3
|
+
} from "./chunk-W3U3YQYI.js";
|
|
4
|
+
|
|
5
|
+
// src/chat/sandbox/egress/schemas.ts
|
|
6
|
+
import { z } from "zod";
|
|
7
|
+
import {
|
|
8
|
+
pluginAuthorizationSchema,
|
|
9
|
+
pluginCredentialHeaderTransformSchema,
|
|
10
|
+
pluginGrantSchema,
|
|
11
|
+
pluginProviderAccountSchema
|
|
12
|
+
} from "@sentry/junior-plugin-api";
|
|
13
|
+
var finiteNumberSchema = z.number().refine(Number.isFinite);
|
|
14
|
+
var httpStatusSchema = z.number().int().min(100).max(599);
|
|
15
|
+
var providerNameSchema = z.string().regex(/^[a-z][a-z0-9-]*$/);
|
|
16
|
+
var credentialSignalKindSchema = z.enum(["auth_required", "unavailable"]);
|
|
17
|
+
var sandboxEgressGrantSchema = pluginGrantSchema;
|
|
18
|
+
var sandboxEgressCredentialContextSchema = z.object({
|
|
19
|
+
credentials: credentialContextSchema,
|
|
20
|
+
egressId: z.string().min(1),
|
|
21
|
+
expiresAtMs: finiteNumberSchema,
|
|
22
|
+
contextId: z.string().min(1)
|
|
23
|
+
}).strict();
|
|
24
|
+
var sandboxEgressCredentialLeaseSchema = z.object({
|
|
25
|
+
account: pluginProviderAccountSchema.optional(),
|
|
26
|
+
authorization: pluginAuthorizationSchema.optional(),
|
|
27
|
+
grant: sandboxEgressGrantSchema,
|
|
28
|
+
provider: providerNameSchema,
|
|
29
|
+
expiresAt: z.string().min(1),
|
|
30
|
+
headerTransforms: z.array(pluginCredentialHeaderTransformSchema).min(1)
|
|
31
|
+
}).strict();
|
|
32
|
+
var sandboxEgressAuthRequiredSignalSchema = z.object({
|
|
33
|
+
authorization: pluginAuthorizationSchema.optional(),
|
|
34
|
+
grant: sandboxEgressGrantSchema,
|
|
35
|
+
kind: credentialSignalKindSchema.default("auth_required"),
|
|
36
|
+
provider: providerNameSchema,
|
|
37
|
+
message: z.string().optional(),
|
|
38
|
+
createdAtMs: finiteNumberSchema
|
|
39
|
+
}).strict().superRefine((signal, ctx) => {
|
|
40
|
+
if (signal.authorization && signal.authorization.provider !== signal.provider) {
|
|
41
|
+
ctx.addIssue({
|
|
42
|
+
code: z.ZodIssueCode.custom,
|
|
43
|
+
message: "Auth signal authorization provider must match provider",
|
|
44
|
+
path: ["authorization", "provider"]
|
|
45
|
+
});
|
|
46
|
+
}
|
|
47
|
+
});
|
|
48
|
+
var sandboxEgressPermissionDeniedSignalSchema = z.object({
|
|
49
|
+
account: pluginProviderAccountSchema.optional(),
|
|
50
|
+
acceptedPermissions: z.string().optional(),
|
|
51
|
+
grant: sandboxEgressGrantSchema,
|
|
52
|
+
message: z.string().min(1),
|
|
53
|
+
provider: providerNameSchema,
|
|
54
|
+
source: z.literal("upstream"),
|
|
55
|
+
sso: z.string().optional(),
|
|
56
|
+
status: httpStatusSchema,
|
|
57
|
+
upstreamHost: z.string().min(1),
|
|
58
|
+
upstreamPath: z.string().min(1),
|
|
59
|
+
createdAtMs: finiteNumberSchema
|
|
60
|
+
}).strict();
|
|
61
|
+
var sandboxEgressSignalsResponseSchema = z.object({
|
|
62
|
+
auth_required: sandboxEgressAuthRequiredSignalSchema.optional(),
|
|
63
|
+
permission_denied: sandboxEgressPermissionDeniedSignalSchema.optional()
|
|
64
|
+
}).strict();
|
|
65
|
+
function parseSandboxEgressAuthRequiredSignal(value) {
|
|
66
|
+
const result = sandboxEgressAuthRequiredSignalSchema.safeParse(value);
|
|
67
|
+
return result.success ? result.data : void 0;
|
|
68
|
+
}
|
|
69
|
+
function parseSandboxEgressPermissionDeniedSignal(value) {
|
|
70
|
+
const result = sandboxEgressPermissionDeniedSignalSchema.safeParse(value);
|
|
71
|
+
return result.success ? result.data : void 0;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
export {
|
|
75
|
+
sandboxEgressCredentialContextSchema,
|
|
76
|
+
sandboxEgressCredentialLeaseSchema,
|
|
77
|
+
sandboxEgressSignalsResponseSchema,
|
|
78
|
+
parseSandboxEgressAuthRequiredSignal,
|
|
79
|
+
parseSandboxEgressPermissionDeniedSignal
|
|
80
|
+
};
|
|
@@ -9,17 +9,17 @@ import {
|
|
|
9
9
|
TURN_REASONING_LEVELS,
|
|
10
10
|
getChatConfig,
|
|
11
11
|
modelProfileSchema
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-SYJT7AKB.js";
|
|
13
13
|
import {
|
|
14
14
|
juniorDestinations
|
|
15
15
|
} from "./chunk-VFUK3X5B.js";
|
|
16
16
|
import {
|
|
17
17
|
normalizeIdentityEmail
|
|
18
|
-
} from "./chunk-
|
|
18
|
+
} from "./chunk-NVUQSFWX.js";
|
|
19
19
|
import {
|
|
20
20
|
parseSlackChannelReferenceId,
|
|
21
21
|
parseSlackTeamId
|
|
22
|
-
} from "./chunk-
|
|
22
|
+
} from "./chunk-F3B2YJ76.js";
|
|
23
23
|
|
|
24
24
|
// src/chat/conversations/sql/store.ts
|
|
25
25
|
import { randomUUID as randomUUID2 } from "crypto";
|
|
@@ -827,6 +827,7 @@ var historyReplacementEventDataSchema = z2.discriminatedUnion("type", [
|
|
|
827
827
|
modelId: z2.string().min(1),
|
|
828
828
|
reasoningLevel: z2.string().min(1).optional(),
|
|
829
829
|
triggeringToolCallId: z2.string().min(1).optional(),
|
|
830
|
+
summary: z2.string().min(1).optional(),
|
|
830
831
|
replacementHistory: replacementHistorySchema
|
|
831
832
|
}).strict(),
|
|
832
833
|
z2.object({
|
|
@@ -834,6 +835,7 @@ var historyReplacementEventDataSchema = z2.discriminatedUnion("type", [
|
|
|
834
835
|
modelProfile: modelProfileSchema,
|
|
835
836
|
modelId: z2.string().min(1),
|
|
836
837
|
details: compactionDetailsSchema.optional(),
|
|
838
|
+
summary: z2.string().min(1).optional(),
|
|
837
839
|
replacementHistory: replacementHistorySchema
|
|
838
840
|
}).strict()
|
|
839
841
|
]);
|