@sentry/junior 0.236.0 → 0.237.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 (53) hide show
  1. package/dist/{agent-hooks-Da_H0jHv.js → agent-hooks-otHGbhBx.js} +18 -7
  2. package/dist/{agent-runner-uP7QRc4c.js → agent-runner-DMAsnPb9.js} +121 -21
  3. package/dist/api/schema.js +2 -2
  4. package/dist/api.js +19 -19
  5. package/dist/app.js +21 -21
  6. package/dist/{automation-B9Kc1gcf.js → automation-CrQGQ2MT.js} +3 -2
  7. package/dist/{briefs-DrjBPQFy.js → briefs-DDA1ugXk.js} +2 -2
  8. package/dist/{catalog-runtime-C7339Cfm.js → catalog-runtime-DlXuhrmk.js} +1 -1
  9. package/dist/{checkpoint-DaD7_Gsb.js → checkpoint-BlIIiHG5.js} +5 -5
  10. package/dist/cli/chat.js +13 -13
  11. package/dist/cli/check.js +3 -3
  12. package/dist/cli/main.js +1 -1
  13. package/dist/cli/plugins.js +3 -3
  14. package/dist/cli/snapshot-create.js +3 -3
  15. package/dist/cli/upgrade.js +3 -3
  16. package/dist/{client-Ch9Hg9NU.js → client-CPMbTmJU.js} +2 -2
  17. package/dist/{config-JR9wke1W.js → config-CxpPG6nR.js} +2 -2
  18. package/dist/{conversation-privacy-au02dyZK.js → conversation-privacy-Dbkdvozu.js} +1 -1
  19. package/dist/{credential-sync-BWTA3LnL.js → credential-sync-D9yGg3q5.js} +13 -13
  20. package/dist/{executor-BW9XWgUQ.js → executor-BNxfDS1V.js} +3 -2
  21. package/dist/{images-BdG7zcNf.js → images-D6Y3FJDQ.js} +2 -2
  22. package/dist/instrumentation.js +2 -2
  23. package/dist/{job-queue-BqXd0ZPV.js → job-queue-Dq5_zt_l.js} +1 -1
  24. package/dist/{logging-B4sKwmCG.js → logging-rB_ngE_R.js} +1 -1
  25. package/dist/nitro.js +3 -3
  26. package/dist/{oauth-authorization-BjRN99dc.js → oauth-authorization-5T1S1v_1.js} +1 -1
  27. package/dist/{oauth-callback-server-B_1p98Mb.js → oauth-callback-server-Csw7RssK.js} +2 -2
  28. package/dist/{pending-auth-WqF4Gh8Z.js → pending-auth-moCA2mTc.js} +1 -1
  29. package/dist/{profile-BamYnmhO.js → profile-D6apIG2N.js} +4 -4
  30. package/dist/{registry-CXNv9fDX.js → registry-zfTzTHe6.js} +1 -1
  31. package/dist/{resolve-C9ETkt4T.js → resolve-sJtTzuBO.js} +2 -2
  32. package/dist/{runner-DnBGVRnW.js → runner-DkCk8cbc.js} +8 -8
  33. package/dist/{sandbox-egress-signals-DwJ7Boi_.js → sandbox-egress-signals-tSQ8OEcw.js} +1 -1
  34. package/dist/{schema-CJiqDc5r.js → schema-C5bgOpRg.js} +1 -1
  35. package/dist/{skills-Dd8O9Aav.js → skills-BVpr_Gnv.js} +2 -2
  36. package/dist/{spawn-DFdRspSD.js → spawn-CJhmyE4E.js} +2 -2
  37. package/dist/{task-queue-DGQEOk1A.js → task-queue-BAiZ7_CF.js} +3 -3
  38. package/dist/{task-runner-C5XCIDSF.js → task-runner-Bh8XONXT.js} +8 -8
  39. package/dist/{thread-state-D3E29wZk.js → thread-state-BnQln4jO.js} +5 -5
  40. package/dist/{turn-failure-response-TDoj0aZz.js → turn-failure-response-Ba7_kItn.js} +7 -7
  41. package/dist/{turn-lifecycle-DOnU45p7.js → turn-lifecycle-D6CTbkb9.js} +1 -1
  42. package/dist/{turn-session-routing-DbpZZoin.js → turn-session-routing-DNevs9H7.js} +1 -1
  43. package/dist/{validation-B9lMbisx.js → validation-BNPhuAvt.js} +2 -3
  44. package/dist/{version-CWkIGcLU.js → version-EQ4MWuUJ.js} +1 -1
  45. package/dist/version.js +1 -1
  46. package/dist/{web-authorization-PPaoj2ns.js → web-authorization-DDt4FZld.js} +6 -6
  47. package/dist/{web-input-CfNxXtHm.js → web-input-C56ivZuH.js} +22 -90
  48. package/dist/{work-DNaoFrEe.js → work-DJ7hb9Ul.js} +7 -7
  49. package/dist/{worker-xeJLxYwm.js → worker-DiiV8Lba.js} +5 -5
  50. package/migrations/0047_user_timezone.sql +1 -0
  51. package/migrations/meta/0047_snapshot.json +3713 -0
  52. package/migrations/meta/_journal.json +7 -0
  53. package/package.json +4 -4
@@ -1,15 +1,15 @@
1
1
  import { t as __exportAll } from "./rolldown-runtime-B4FMCO8f.js";
2
- import { a as embedTexts, r as completeObject } from "./client-Ch9Hg9NU.js";
3
- import { F as normalizeIdentityEmail, I as isRecord$2, a as extractGenAiUsageSummary, d as logException, f as logInfo, p as logWarn, v as setSpanAttributes, w as withSpan, y as setSpanStatus } from "./logging-B4sKwmCG.js";
2
+ import { a as embedTexts, r as completeObject } from "./client-CPMbTmJU.js";
3
+ import { F as normalizeIdentityEmail, I as isRecord$2, a as extractGenAiUsageSummary, d as logException, f as logInfo, p as logWarn, v as setSpanAttributes, w as withSpan, y as setSpanStatus } from "./logging-rB_ngE_R.js";
4
4
  import { a as getClient$1 } from "./sentry-CgWZM_kV.js";
5
- import { t as canExposeConversationPayload } from "./conversation-privacy-au02dyZK.js";
6
- import { i as getChatConfig, n as botConfig, o as getSlackBotToken } from "./config-JR9wke1W.js";
5
+ import { t as canExposeConversationPayload } from "./conversation-privacy-Dbkdvozu.js";
6
+ import { i as getChatConfig, n as botConfig, o as getSlackBotToken } from "./config-CxpPG6nR.js";
7
7
  import { r as defaultModelId } from "./model-profile-BwU8mqwD.js";
8
8
  import { b as parseSlackMessageTs, c as isActorUserId, h as parseSlackTeamId, m as parseSlackChannelReferenceId, u as parseActorUserId } from "./context-0Et9iVSB.js";
9
9
  import { n as juniorDestinations } from "./destinations-BeBiJeEM.js";
10
- import { C as juniorCodeChanges, D as juniorConversations, E as conversationReadColumns, O as juniorIdentities, S as juniorConversationAnnotations, T as juniorAttachments, _ as juniorConversationBriefs, b as juniorConversationEvents, g as juniorConversationBindings, h as juniorConversationParticipants, i as juniorWorkspaces, k as juniorUsers, n as juniorSnapshots, r as juniorWorkspaceRepos, t as createJuniorSqlExecutor, v as CONVERSATION_METRICS, w as juniorCodeRepositories, y as juniorConversationMetrics } from "./executor-BW9XWgUQ.js";
10
+ import { C as juniorCodeChanges, D as juniorConversations, E as conversationReadColumns, O as juniorIdentities, S as juniorConversationAnnotations, T as juniorAttachments, _ as juniorConversationBriefs, b as juniorConversationEvents, g as juniorConversationBindings, h as juniorConversationParticipants, i as juniorWorkspaces, k as juniorUsers, n as juniorSnapshots, r as juniorWorkspaceRepos, t as createJuniorSqlExecutor, v as CONVERSATION_METRICS, w as juniorCodeRepositories, y as juniorConversationMetrics } from "./executor-BNxfDS1V.js";
11
11
  import { $ as historyReplacementSchema, B as parseBriefInput, C as conversationReportEventSchema, N as readMessageAttachments, Q as decodeStoredConversationEvent, W as readMessageCardRefs, Y as conversationEventDataSchema, et as newConversationEventSchema, ot as usageSchema, tt as encodeHistoryPayload, z as conversationBriefSchema } from "./conversation-9Fxa1Zbq.js";
12
- import { C as getDefaultRedisStateAdapterFor, N as SANDBOX_WORKSPACE_ROOT, k as sleep$1, l as isSandboxMissingError, n as hash, v as getVercelSandboxCredentials, w as getStateAdapter, x as runNonInteractiveCommand } from "./profile-BamYnmhO.js";
12
+ import { C as getDefaultRedisStateAdapterFor, N as SANDBOX_WORKSPACE_ROOT, k as sleep$1, l as isSandboxMissingError, n as hash, v as getVercelSandboxCredentials, w as getStateAdapter, x as runNonInteractiveCommand } from "./profile-D6apIG2N.js";
13
13
  import { n as briefEntriesFromReportEvents, s as generateBrief, t as BRIEF_PROMPT } from "./prompt-Ctwy6hSI.js";
14
14
  import { AsyncLocalStorage } from "node:async_hooks";
15
15
  import { z } from "zod";
@@ -141,6 +141,17 @@ async function upsertIdentityRecord(executor, identity, linkedUserId, nowMs) {
141
141
  ...row.userId ? { userId: row.userId } : void 0
142
142
  };
143
143
  }
144
+ /** Read the saved timezone for one user. */
145
+ async function readUserTimezone(db, userId) {
146
+ return (await db.select({ timezone: juniorUsers.timezone }).from(juniorUsers).where(eq(juniorUsers.id, userId)).limit(1))[0]?.timezone ?? void 0;
147
+ }
148
+ /** Save the IANA timezone for one user. */
149
+ async function saveUserTimezone(db, userId, timezone, nowMs) {
150
+ await db.update(juniorUsers).set({
151
+ timezone,
152
+ updatedAt: dateFromMs$1(nowMs)
153
+ }).where(and(eq(juniorUsers.id, userId), sql`${juniorUsers.timezone} is distinct from ${timezone}`));
154
+ }
144
155
  /** Persist one provider identity observation and link verified emails to users. */
145
156
  async function upsertIdentity(executor, identity, nowMs = Date.now()) {
146
157
  return await upsertIdentityRecord(executor, identity, void 0, nowMs);
@@ -5743,4 +5754,4 @@ function createPluginHookRunner(input = {}) {
5743
5754
  };
5744
5755
  }
5745
5756
  //#endregion
5746
- export { readActorIdentity as $, getConversationMessageSearchStore as $t, getWorkspaceSnapshotBuilder as A, conversationHasParticipantUser as At, SlackActionError as B, readAttachmentVisionSummary as Bt, WorkspaceValidationError as C, createPluginModel as Ct, setWorkspaceSnapshotBuild as D, conversationArchivedForEmail as Dt, setWorkspaceSnapshot as E, conversationArchiveTimes as Et, bindScheduledAutomationCredentialSubject as F, readLatestConversationBrief as Ft, isConversationScopedChannel as G, listConversationAnnotations as Gt, getFilePermalink as H, resolveRootVisibility as Ht, bindSlackDirectCredentialSubject as I, readConversationEventPage as It, runWithSlackInstallationToken as J, agentsInstructionsUpdatedEvent as Jt, isDmChannel as K, listConversationAnnotationsById as Kt, verifyEventAutomationCredentialSubject as L, buildSentryConversationUrl as Lt, workspaceRepoCheckoutPath as M, conversationNotArchivedForUser as Mt, resolveChannelCapabilities as N, viewerConversationMembership as Nt, SANDBOX_RUNTIME as O, conversationArchivedForUser as Ot, bindEventAutomationCredentialSubject as P, createPluginConversationEvents as Pt, findUserByEmail as Q, getConversationEventStore as Qt, verifyScheduledAutomationCredentialSubject as R, getSlackFileId as Rt, updateWorkspace as S, createPluginEmbedder as St, loadSnapshotsForProfile as T, readConversationAccessFromSql as Tt, getHeaderString as U, saveObjectAnnotations as Ut, downloadPrivateSlackFile as V, recordSlackAttachment as Vt, getSlackClient as W, createPluginAnnotations as Wt, getWorkspaceTeamId as X, authenticationUnlinkedEvent as Xt, withSlackRetries as Y, authenticationLinkedEvent as Yt, runWithWorkspaceTeamId as Z, db_exports as Zt, deleteWorkspace as _, upsertLinkedIdentity as _n, getDashboardConversationLink as _t, getPluginRoutes as a, withConversationMutationLock as an, RESOURCE_WATCH_TOOL_SOURCE as at, listWorkspaces as b, requireSlackDestination as bn, setDashboardConversationLinkOptions as bt, getPluginTools as c, parseSessionSource as cn, cancelWatch as ct, setPlugins as d, agentTurnTotalTokens as dn, createWatch as dt, getConversationStore as en, resolveViewerUser as et, validatePlugins as f, agentTurnUsageSchema as fn, deliverWatch as ft, createWorkspace as g, upsertIdentity as gn, JUNIOR_THREAD_STATE_TTL_MS as gt, setBriefsConfig as h, deleteProviderIdentityForSlackUser as hn, takeDueTimerWatches as ht, getPluginApiRoutes as i, withConversationEventLock as in, RESOURCE_SUBSCRIPTION_MAX_TTL_MS as it, tryWorkspaceRepoCheckoutPath as j, conversationNotArchivedForEmail as jt, deleteWorkspaceSnapshotBuilders as k, conversationHasParticipantEmail as kt, getPluginUserPromptContributions as l, addAgentTurnUsage as ln, collectEventMatchKeys as lt, registration_exports as m, resolveRootConversationId as mn, listWatches as mt, applyPluginFormatMarkdown as n, getSqlExecutor as nn, getSlackToolContext as nt, getPluginSlackConversationLink as o, locationFromRow as on, STOP_WATCHING_TOOL_NAME as ot, coreTaskRegistrations as p, hasAgentTurnUsage as pn, findMatchingWatches as pt, normalizeSlackConversationId as q, JUNIOR_NATIVE_EVENT_NAMESPACE as qt, createPluginHookRunner as r, createSqlConversationEventStore as rn, RESOURCE_SUBSCRIPTION_DEFAULT_TTL_MS as rt, getPluginSystemPromptContributions as s, bindProviderConversation as sn, cancelSubscriptions as st, agent_hooks_exports as t, getDb as tn, updateViewerDisplayName as tt, getPlugins as u, agentTurnCostUsd as un, createTimerWatch as ut, getWorkspace as v, createSlackDestination as vn, getDashboardObjectIconLink as vt, invalidateReadySnapshot as w, createPluginLogger as wt, listWorkspacesByRepository as x, sameDestination as xn, createPluginState as xt, getWorkspaceByName as y, parseDestination as yn, getDashboardTaskLink as yt, verifySlackDirectCredentialSubject as z, matchSlackAttachments as zt };
5757
+ export { readActorIdentity as $, getConversationMessageSearchStore as $t, getWorkspaceSnapshotBuilder as A, conversationHasParticipantUser as At, SlackActionError as B, readAttachmentVisionSummary as Bt, WorkspaceValidationError as C, sameDestination as Cn, createPluginModel as Ct, setWorkspaceSnapshotBuild as D, conversationArchivedForEmail as Dt, setWorkspaceSnapshot as E, conversationArchiveTimes as Et, bindScheduledAutomationCredentialSubject as F, readLatestConversationBrief as Ft, isConversationScopedChannel as G, listConversationAnnotations as Gt, getFilePermalink as H, resolveRootVisibility as Ht, bindSlackDirectCredentialSubject as I, readConversationEventPage as It, runWithSlackInstallationToken as J, agentsInstructionsUpdatedEvent as Jt, isDmChannel as K, listConversationAnnotationsById as Kt, verifyEventAutomationCredentialSubject as L, buildSentryConversationUrl as Lt, workspaceRepoCheckoutPath as M, conversationNotArchivedForUser as Mt, resolveChannelCapabilities as N, viewerConversationMembership as Nt, SANDBOX_RUNTIME as O, conversationArchivedForUser as Ot, bindEventAutomationCredentialSubject as P, createPluginConversationEvents as Pt, findUserByEmail as Q, getConversationEventStore as Qt, verifyScheduledAutomationCredentialSubject as R, getSlackFileId as Rt, updateWorkspace as S, requireSlackDestination as Sn, createPluginEmbedder as St, loadSnapshotsForProfile as T, readConversationAccessFromSql as Tt, getHeaderString as U, saveObjectAnnotations as Ut, downloadPrivateSlackFile as V, recordSlackAttachment as Vt, getSlackClient as W, createPluginAnnotations as Wt, getWorkspaceTeamId as X, authenticationUnlinkedEvent as Xt, withSlackRetries as Y, authenticationLinkedEvent as Yt, runWithWorkspaceTeamId as Z, db_exports as Zt, deleteWorkspace as _, saveUserTimezone as _n, getDashboardConversationLink as _t, getPluginRoutes as a, withConversationMutationLock as an, RESOURCE_WATCH_TOOL_SOURCE as at, listWorkspaces as b, createSlackDestination as bn, setDashboardConversationLinkOptions as bt, getPluginTools as c, parseSessionSource as cn, cancelWatch as ct, setPlugins as d, agentTurnTotalTokens as dn, createWatch as dt, getConversationStore as en, resolveViewerUser as et, validatePlugins as f, agentTurnUsageSchema as fn, deliverWatch as ft, createWorkspace as g, readUserTimezone as gn, JUNIOR_THREAD_STATE_TTL_MS as gt, setBriefsConfig as h, deleteProviderIdentityForSlackUser as hn, takeDueTimerWatches as ht, getPluginApiRoutes as i, withConversationEventLock as in, RESOURCE_SUBSCRIPTION_MAX_TTL_MS as it, tryWorkspaceRepoCheckoutPath as j, conversationNotArchivedForEmail as jt, deleteWorkspaceSnapshotBuilders as k, conversationHasParticipantEmail as kt, getPluginUserPromptContributions as l, addAgentTurnUsage as ln, collectEventMatchKeys as lt, registration_exports as m, resolveRootConversationId as mn, listWatches as mt, applyPluginFormatMarkdown as n, getSqlExecutor as nn, getSlackToolContext as nt, getPluginSlackConversationLink as o, locationFromRow as on, STOP_WATCHING_TOOL_NAME as ot, coreTaskRegistrations as p, hasAgentTurnUsage as pn, findMatchingWatches as pt, normalizeSlackConversationId as q, JUNIOR_NATIVE_EVENT_NAMESPACE as qt, createPluginHookRunner as r, createSqlConversationEventStore as rn, RESOURCE_SUBSCRIPTION_DEFAULT_TTL_MS as rt, getPluginSystemPromptContributions as s, bindProviderConversation as sn, cancelSubscriptions as st, agent_hooks_exports as t, getDb as tn, updateViewerDisplayName as tt, getPlugins as u, agentTurnCostUsd as un, createTimerWatch as ut, getWorkspace as v, upsertIdentity as vn, getDashboardObjectIconLink as vt, invalidateReadySnapshot as w, createPluginLogger as wt, listWorkspacesByRepository as x, parseDestination as xn, createPluginState as xt, getWorkspaceByName as y, upsertLinkedIdentity as yn, getDashboardTaskLink as yt, verifySlackDirectCredentialSubject as z, matchSlackAttachments as zt };
@@ -1,27 +1,27 @@
1
1
  import { t as __exportAll } from "./rolldown-runtime-B4FMCO8f.js";
2
- import { b as getGatewayApiKey, c as hasCompactedConversationContext, d as unwrapCurrentInstruction, f as escapeXml, g as getProviderErrorAttributes, h as findProviderError, i as completeText, l as isCompactionSummaryText, m as createProviderError, n as GEN_AI_SERVER_ADDRESS, o as resolveGatewayModel, p as ProviderError, r as completeObject, s as COMPACTION_SUMMARY_PREFIX, t as GEN_AI_PROVIDER_NAME, u as renderCurrentInstruction, v as isProviderRetryError, x as resolveGatewayCredential, y as MISSING_GATEWAY_CREDENTIALS_ERROR } from "./client-Ch9Hg9NU.js";
3
- import { C as withLogContext, F as normalizeIdentityEmail, I as isRecord$3, L as toOptionalNumber, R as toOptionalString, a as extractGenAiUsageSummary, b as setTags, c as getLogContextAttributesForSpan, d as logException, f as logInfo, g as serializeGenAiAttribute, i as extractGenAiUsageAttributes, l as getTracePropagationHeaders, m as normalizeGenAiFinishReason, p as logWarn, s as getLogContextAttributes, u as logError, v as setSpanAttributes, w as withSpan, x as summarizeMessageText, y as setSpanStatus } from "./logging-B4sKwmCG.js";
2
+ import { b as getGatewayApiKey, c as hasCompactedConversationContext, d as unwrapCurrentInstruction, f as escapeXml, g as getProviderErrorAttributes, h as findProviderError, i as completeText, l as isCompactionSummaryText, m as createProviderError, n as GEN_AI_SERVER_ADDRESS, o as resolveGatewayModel, p as ProviderError, r as completeObject, s as COMPACTION_SUMMARY_PREFIX, t as GEN_AI_PROVIDER_NAME, u as renderCurrentInstruction, v as isProviderRetryError, x as resolveGatewayCredential, y as MISSING_GATEWAY_CREDENTIALS_ERROR } from "./client-CPMbTmJU.js";
3
+ import { C as withLogContext, F as normalizeIdentityEmail, I as isRecord$3, L as toOptionalNumber, R as toOptionalString, a as extractGenAiUsageSummary, b as setTags, c as getLogContextAttributesForSpan, d as logException, f as logInfo, g as serializeGenAiAttribute, i as extractGenAiUsageAttributes, l as getTracePropagationHeaders, m as normalizeGenAiFinishReason, p as logWarn, s as getLogContextAttributes, u as logError, v as setSpanAttributes, w as withSpan, x as summarizeMessageText, y as setSpanStatus } from "./logging-rB_ngE_R.js";
4
4
  import { m as startInactiveSpan, n as captureMessage, v as withActiveSpan } from "./sentry-CgWZM_kV.js";
5
- import { a as toCanonicalInputMessage, c as toGenAiPayloadMetadata, i as runWithConversationPrivacy, l as toGenAiPayloadTraceAttributes, o as toCanonicalOutputMessage, r as resolveConversationPrivacy, s as toGenAiMessagesTraceAttributes, t as canExposeConversationPayload } from "./conversation-privacy-au02dyZK.js";
6
- import { i as getChatConfig, n as botConfig, v as normalizeSlackEmojiName } from "./config-JR9wke1W.js";
5
+ import { a as toCanonicalInputMessage, c as toGenAiPayloadMetadata, i as runWithConversationPrivacy, l as toGenAiPayloadTraceAttributes, o as toCanonicalOutputMessage, r as resolveConversationPrivacy, s as toGenAiMessagesTraceAttributes, t as canExposeConversationPayload } from "./conversation-privacy-Dbkdvozu.js";
6
+ import { i as getChatConfig, n as botConfig, o as getSlackBotToken, v as normalizeSlackEmojiName } from "./config-CxpPG6nR.js";
7
7
  import { a as formatModelProfiles, c as profileConfig, i as formatModelProfile, l as TURN_REASONING_LEVELS, n as ModelProfileNotConfiguredError, o as modelIdForProfile, s as modelProfileSchema } from "./model-profile-BwU8mqwD.js";
8
8
  import { b as parseSlackMessageTs, d as parseStoredSlackActor, g as parseSlackUserId, h as parseSlackTeamId, i as credentialUserSubjectId, l as isUserActor, m as parseSlackChannelReferenceId, n as credentialContextSchema, p as parseSlackChannelId, t as credentialContextForActor } from "./context-0Et9iVSB.js";
9
- import { $ as readActorIdentity, $t as getConversationMessageSearchStore, A as getWorkspaceSnapshotBuilder, B as SlackActionError, C as WorkspaceValidationError, D as setWorkspaceSnapshotBuild, E as setWorkspaceSnapshot, G as isConversationScopedChannel, H as getFilePermalink, K as isDmChannel$1, M as workspaceRepoCheckoutPath, N as resolveChannelCapabilities, O as SANDBOX_RUNTIME, Qt as getConversationEventStore, S as updateWorkspace, T as loadSnapshotsForProfile, Ut as saveObjectAnnotations, V as downloadPrivateSlackFile, W as getSlackClient, Wt as createPluginAnnotations, Y as withSlackRetries, _ as deleteWorkspace, _t as getDashboardConversationLink, at as RESOURCE_WATCH_TOOL_SOURCE, b as listWorkspaces, c as getPluginTools, ct as cancelWatch, dt as createWatch, en as getConversationStore, ft as deliverWatch, g as createWorkspace, gt as JUNIOR_THREAD_STATE_TTL_MS, it as RESOURCE_SUBSCRIPTION_MAX_TTL_MS, j as tryWorkspaceRepoCheckoutPath, k as deleteWorkspaceSnapshotBuilders, l as getPluginUserPromptContributions, ln as addAgentTurnUsage, mt as listWatches, n as applyPluginFormatMarkdown, nn as getSqlExecutor, nt as getSlackToolContext, ot as STOP_WATCHING_TOOL_NAME, pn as hasAgentTurnUsage, pt as findMatchingWatches, q as normalizeSlackConversationId, r as createPluginHookRunner, rt as RESOURCE_SUBSCRIPTION_DEFAULT_TTL_MS, s as getPluginSystemPromptContributions, st as cancelSubscriptions, tn as getDb, u as getPlugins, ut as createTimerWatch, v as getWorkspace, w as invalidateReadySnapshot, wt as createPluginLogger, xn as sameDestination$1, y as getWorkspaceByName, yn as parseDestination, yt as getDashboardTaskLink, zt as matchSlackAttachments } from "./agent-hooks-Da_H0jHv.js";
9
+ import { $ as readActorIdentity, $t as getConversationMessageSearchStore, A as getWorkspaceSnapshotBuilder, B as SlackActionError, C as WorkspaceValidationError, Cn as sameDestination$1, D as setWorkspaceSnapshotBuild, E as setWorkspaceSnapshot, G as isConversationScopedChannel, H as getFilePermalink, K as isDmChannel$1, M as workspaceRepoCheckoutPath, N as resolveChannelCapabilities, O as SANDBOX_RUNTIME, Qt as getConversationEventStore, S as updateWorkspace, T as loadSnapshotsForProfile, Ut as saveObjectAnnotations, V as downloadPrivateSlackFile, W as getSlackClient, Wt as createPluginAnnotations, Y as withSlackRetries, _ as deleteWorkspace, _n as saveUserTimezone, _t as getDashboardConversationLink, at as RESOURCE_WATCH_TOOL_SOURCE, b as listWorkspaces, c as getPluginTools, ct as cancelWatch, dt as createWatch, en as getConversationStore, ft as deliverWatch, g as createWorkspace, gn as readUserTimezone, gt as JUNIOR_THREAD_STATE_TTL_MS, it as RESOURCE_SUBSCRIPTION_MAX_TTL_MS, j as tryWorkspaceRepoCheckoutPath, k as deleteWorkspaceSnapshotBuilders, l as getPluginUserPromptContributions, ln as addAgentTurnUsage, mt as listWatches, n as applyPluginFormatMarkdown, nn as getSqlExecutor, nt as getSlackToolContext, ot as STOP_WATCHING_TOOL_NAME, pn as hasAgentTurnUsage, pt as findMatchingWatches, q as normalizeSlackConversationId, r as createPluginHookRunner, rt as RESOURCE_SUBSCRIPTION_DEFAULT_TTL_MS, s as getPluginSystemPromptContributions, st as cancelSubscriptions, tn as getDb, u as getPlugins, ut as createTimerWatch, v as getWorkspace, w as invalidateReadySnapshot, wt as createPluginLogger, xn as parseDestination, y as getWorkspaceByName, yt as getDashboardTaskLink, zt as matchSlackAttachments } from "./agent-hooks-otHGbhBx.js";
10
10
  import { n as juniorDestinations } from "./destinations-BeBiJeEM.js";
11
- import { A as juniorArtifacts, D as juniorConversations, O as juniorIdentities, S as juniorConversationAnnotations, T as juniorAttachments, _ as juniorConversationBriefs, a as juniorSchedulerRuns, f as AGENT_INVOCATION_MAILBOX_STATUSES, l as juniorStats, o as juniorSchedulerTasks, s as juniorAutomationVersions, u as juniorEventAutomations } from "./executor-BW9XWgUQ.js";
11
+ import { A as juniorArtifacts, D as juniorConversations, O as juniorIdentities, S as juniorConversationAnnotations, T as juniorAttachments, _ as juniorConversationBriefs, a as juniorSchedulerRuns, f as AGENT_INVOCATION_MAILBOX_STATUSES, l as juniorStats, o as juniorSchedulerTasks, s as juniorAutomationVersions, u as juniorEventAutomations } from "./executor-BNxfDS1V.js";
12
12
  import { F as isVisionImageMediaType, G as removedCardSchema, L as briefLinkSchema, R as briefOutcomeStatusSchema, at as sameActorIdentity, it as instructionProvenanceFor, nt as contextProvenance, q as KNOWN_CONVERSATION_EVENT_TYPES, rt as instructionActors, z as conversationBriefSchema } from "./conversation-9Fxa1Zbq.js";
13
13
  import { a as listReferenceFiles, c as soulPathCandidates, l as worldPathCandidates } from "./package-discovery-BVvSnQBB.js";
14
- import { a as resolveAuthTokenPlaceholder, c as fetchWithBoundedOAuthErrorBodies, d as CredentialUnavailableError, i as resolvePluginHeaderEnvRefs, l as getOAuthProviderErrorAttributes, o as resolvePluginCommandEnv, s as OAuthProviderError } from "./registry-CXNv9fDX.js";
15
- import { n as pluginCatalogRuntime } from "./catalog-runtime-C7339Cfm.js";
16
- import { a as parseSkillInvocation, i as parseSkillFile, n as findSkillByName, r as loadSkillsByName, t as discoverSkills } from "./skills-Dd8O9Aav.js";
17
- import { C as isToolResultError, D as stripRuntimeTurnContext, E as retainRuntimeTurnContext, H as recordAuthorizationRequested, I as loadTurnRoute, K as recordToolExecutionStarted, L as openConversationProjection, M as loadConnectedMcpProviders, N as loadConversationProjection, O as trimTrailingAssistantMessages, R as recordAgentsInstructionsUpdated, S as isContinuablePiBoundary, T as normalizeToolNameFromResult, U as recordGuardianActionReviewed, W as recordMcpProviderConnected, _ as getTerminalAssistantMessages, _t as historyItemFromPiMessage, d as TurnSliceLimitExceededError, f as assertTurnToolCallLimit, g as getPiMessageRole, gt as getAgentContextInputLimitTokens, h as extractAssistantText, ht as getAgentContextCompactionTriggerTokens, k as TURN_CONTEXT_TAG, m as isTurnExecutionLimitExceededError, mt as estimateTextTokens, n as loadTurnCheckpoint, nt as resolveTaskTitle, q as recordTurnRoute, r as saveTurnCheckpoint, t as continuableMessages, tt as fallbackShortTitle, v as getUserMessageInstructionText, vt as piMessageFromHistoryItem, w as isToolResultMessage, x as isAssistantMessage, y as hasRuntimeTurnContext, z as recordAttachmentsDelivered } from "./checkpoint-DaD7_Gsb.js";
18
- import { A as SANDBOX_DATA_ROOT, C as getDefaultRedisStateAdapterFor, D as fenceLock, E as acquireActiveLock, F as sandboxSkillFile, I as sandboxSkillPathResolution, M as SANDBOX_SKILLS_ROOT, N as SANDBOX_WORKSPACE_ROOT, O as withLock, P as sandboxSkillDir, _ as workspaceSnapshotNotReadyUserMessage, a as isAbortError, b as buildNonInteractiveShellScript, c as isSandboxCommandStreamInterruptedError, d as isSnapshottingError, f as throwSandboxOperationError, g as isWorkspaceSnapshotNotReadyError, h as getWorkspaceSnapshotNotReadyError, i as ensureDockerDaemon, j as SANDBOX_REPOS_ROOT, k as sleep$2, l as isSandboxMissingError, m as WorkspaceSnapshotNotReadyError, n as hash, o as isAlreadyExistsError, p as wrapSandboxSetupError, r as isStale, s as isSandboxApiTransientError, t as create, u as isSandboxUnavailableError, v as getVercelSandboxCredentials, w as getStateAdapter, x as runNonInteractiveCommand, y as buildCommandScript } from "./profile-BamYnmhO.js";
19
- import { n as canReusePendingAuthLink, t as abandonReplacedPendingAuth } from "./pending-auth-WqF4Gh8Z.js";
20
- import { a as NO_REPLY_MARKER, c as CooperativeTurnYieldError, i as sanitizeAssistantText, l as TurnInputCommitLostError, n as decideReply, o as isNoReplyMarker, p as isTurnInputCommitLostError, r as getAssistantReplyText, t as authorizationId } from "./oauth-authorization-BjRN99dc.js";
14
+ import { a as resolveAuthTokenPlaceholder, c as fetchWithBoundedOAuthErrorBodies, d as CredentialUnavailableError, i as resolvePluginHeaderEnvRefs, l as getOAuthProviderErrorAttributes, o as resolvePluginCommandEnv, s as OAuthProviderError } from "./registry-zfTzTHe6.js";
15
+ import { n as pluginCatalogRuntime } from "./catalog-runtime-DlXuhrmk.js";
16
+ import { a as parseSkillInvocation, i as parseSkillFile, n as findSkillByName, r as loadSkillsByName, t as discoverSkills } from "./skills-BVpr_Gnv.js";
17
+ import { C as isToolResultError, D as stripRuntimeTurnContext, E as retainRuntimeTurnContext, H as recordAuthorizationRequested, I as loadTurnRoute, K as recordToolExecutionStarted, L as openConversationProjection, M as loadConnectedMcpProviders, N as loadConversationProjection, O as trimTrailingAssistantMessages, R as recordAgentsInstructionsUpdated, S as isContinuablePiBoundary, T as normalizeToolNameFromResult, U as recordGuardianActionReviewed, W as recordMcpProviderConnected, _ as getTerminalAssistantMessages, _t as historyItemFromPiMessage, d as TurnSliceLimitExceededError, f as assertTurnToolCallLimit, g as getPiMessageRole, gt as getAgentContextInputLimitTokens, h as extractAssistantText, ht as getAgentContextCompactionTriggerTokens, k as TURN_CONTEXT_TAG, m as isTurnExecutionLimitExceededError, mt as estimateTextTokens, n as loadTurnCheckpoint, nt as resolveTaskTitle, q as recordTurnRoute, r as saveTurnCheckpoint, t as continuableMessages, tt as fallbackShortTitle, v as getUserMessageInstructionText, vt as piMessageFromHistoryItem, w as isToolResultMessage, x as isAssistantMessage, y as hasRuntimeTurnContext, z as recordAttachmentsDelivered } from "./checkpoint-BlIIiHG5.js";
18
+ import { A as SANDBOX_DATA_ROOT, C as getDefaultRedisStateAdapterFor, D as fenceLock, E as acquireActiveLock, F as sandboxSkillFile, I as sandboxSkillPathResolution, M as SANDBOX_SKILLS_ROOT, N as SANDBOX_WORKSPACE_ROOT, O as withLock, P as sandboxSkillDir, _ as workspaceSnapshotNotReadyUserMessage, a as isAbortError, b as buildNonInteractiveShellScript, c as isSandboxCommandStreamInterruptedError, d as isSnapshottingError, f as throwSandboxOperationError, g as isWorkspaceSnapshotNotReadyError, h as getWorkspaceSnapshotNotReadyError, i as ensureDockerDaemon, j as SANDBOX_REPOS_ROOT, k as sleep$2, l as isSandboxMissingError, m as WorkspaceSnapshotNotReadyError, n as hash, o as isAlreadyExistsError, p as wrapSandboxSetupError, r as isStale, s as isSandboxApiTransientError, t as create, u as isSandboxUnavailableError, v as getVercelSandboxCredentials, w as getStateAdapter, x as runNonInteractiveCommand, y as buildCommandScript } from "./profile-D6apIG2N.js";
19
+ import { n as canReusePendingAuthLink, t as abandonReplacedPendingAuth } from "./pending-auth-moCA2mTc.js";
20
+ import { a as NO_REPLY_MARKER, c as CooperativeTurnYieldError, i as sanitizeAssistantText, l as TurnInputCommitLostError, n as decideReply, o as isNoReplyMarker, p as isTurnInputCommitLostError, r as getAssistantReplyText, t as authorizationId } from "./oauth-authorization-5T1S1v_1.js";
21
21
  import { r as EVENT_AUTHOR_ID } from "./prompt-Ctwy6hSI.js";
22
- import { a as createSandboxSession, c as postinstall, d as getSandboxResources, i as bindSandboxFileSystem, l as setSnapshotSpanAttributes, n as isMissingError, o as stopSession, r as resolve$1, s as dependencies } from "./resolve-C9ETkt4T.js";
23
- import { a as getVercelConversationWorkQueue, f as getTurnRequestDeadline, n as sendNextWorkspaceSnapshotJob, r as sendWorkspaceSnapshotJob } from "./job-queue-BqXd0ZPV.js";
24
- import { A as eventAutomationSchema, D as scheduledRunSchema, E as scheduledAutomationSchema, L as getZonedDateTimeParts, M as compileScheduleIntent, N as scheduleIntentSchema, O as automationInstructionToolSchema, R as taskOutcomeInputSchema, S as automationVersionSchema, T as SCHEDULED_AUTOMATION_SYSTEM_ACTOR, j as ScheduleIntentError, k as automationTitleSchema } from "./automation-B9Kc1gcf.js";
22
+ import { a as createSandboxSession, c as postinstall, d as getSandboxResources, i as bindSandboxFileSystem, l as setSnapshotSpanAttributes, n as isMissingError, o as stopSession, r as resolve$1, s as dependencies } from "./resolve-sJtTzuBO.js";
23
+ import { a as getVercelConversationWorkQueue, f as getTurnRequestDeadline, n as sendNextWorkspaceSnapshotJob, r as sendWorkspaceSnapshotJob } from "./job-queue-Dq5_zt_l.js";
24
+ import { A as eventAutomationSchema, D as scheduledRunSchema, E as scheduledAutomationSchema, M as compileScheduleIntent, N as isValidTimeZone$1, O as automationInstructionToolSchema, P as scheduleIntentSchema, R as getZonedDateTimeParts, S as automationVersionSchema, T as SCHEDULED_AUTOMATION_SYSTEM_ACTOR, j as ScheduleIntentError, k as automationTitleSchema, z as taskOutcomeInputSchema } from "./automation-CrQGQ2MT.js";
25
25
  import { n as privateTraceResultAttributes } from "./private-trace-result-BLvBjy_e.js";
26
26
  import { streamSimple } from "@earendil-works/pi-ai/compat";
27
27
  import { createGatewayProvider } from "@ai-sdk/gateway";
@@ -11370,6 +11370,76 @@ function logScheduledAutomationRunSkipped(task, run, extras = {}) {
11370
11370
  logInfo("scheduled_automation.run.skipped", scheduledAutomationRunAttributes(task, run, extras));
11371
11371
  }
11372
11372
  //#endregion
11373
+ //#region src/chat/slack/user.ts
11374
+ const slackUserInfoSchema = z.object({
11375
+ ok: z.literal(true),
11376
+ user: z.object({
11377
+ name: z.string().nullish(),
11378
+ tz: z.string().nullish(),
11379
+ profile: z.object({
11380
+ email: z.string().nullish(),
11381
+ real_name: z.string().nullish()
11382
+ }).optional()
11383
+ })
11384
+ });
11385
+ const USER_CACHE_TTL_MS = 3e5;
11386
+ const userCache = /* @__PURE__ */ new Map();
11387
+ function userCacheKey(teamId, userId) {
11388
+ return `${teamId}:${userId}`;
11389
+ }
11390
+ function readFromCache(teamId, userId) {
11391
+ const hit = userCache.get(userCacheKey(teamId, userId));
11392
+ if (!hit) return null;
11393
+ if (hit.expiresAt < Date.now()) {
11394
+ userCache.delete(userCacheKey(teamId, userId));
11395
+ return null;
11396
+ }
11397
+ return hit.value;
11398
+ }
11399
+ function writeToCache(teamId, userId, value) {
11400
+ userCache.set(userCacheKey(teamId, userId), {
11401
+ value,
11402
+ expiresAt: Date.now() + USER_CACHE_TTL_MS
11403
+ });
11404
+ }
11405
+ /** Fetch Slack user profile info with in-memory TTL cache to avoid repeated API calls. */
11406
+ async function lookupSlackUser(teamId, userId) {
11407
+ if (!teamId || !userId) return null;
11408
+ const cached = readFromCache(teamId, userId);
11409
+ if (cached) return cached;
11410
+ const token = getSlackBotToken();
11411
+ if (!token) return null;
11412
+ try {
11413
+ const response = await fetch(`https://slack.com/api/users.info?user=${encodeURIComponent(userId)}`, { headers: { authorization: `Bearer ${token}` } });
11414
+ if (!response.ok) {
11415
+ logWarn("slack.user.lookup.failed", {
11416
+ "enduser.id": userId,
11417
+ "app.slack.team_id": teamId,
11418
+ "http.response.status_code": response.status
11419
+ });
11420
+ return null;
11421
+ }
11422
+ const parsed = slackUserInfoSchema.safeParse(await response.json());
11423
+ if (!parsed.success) return null;
11424
+ const payload = parsed.data;
11425
+ const result = {
11426
+ userName: payload.user.name?.trim() || void 0,
11427
+ fullName: payload.user.profile?.real_name?.trim() || void 0,
11428
+ email: payload.user.profile?.email?.trim() || void 0,
11429
+ timezone: payload.user.tz?.trim() || void 0
11430
+ };
11431
+ writeToCache(teamId, userId, result);
11432
+ return result;
11433
+ } catch (error) {
11434
+ logWarn("slack.user.lookup.failed", {
11435
+ "enduser.id": userId,
11436
+ "app.slack.team_id": teamId,
11437
+ "exception.message": error instanceof Error ? error.message : String(error)
11438
+ });
11439
+ return null;
11440
+ }
11441
+ }
11442
+ //#endregion
11373
11443
  //#region src/chat/scheduled-automations/identity.ts
11374
11444
  const SLACK_USER_ID_PATTERN = /^[UW][A-Z0-9]{5,}$/;
11375
11445
  function clean(value) {
@@ -11621,6 +11691,19 @@ function normalizeStatus(value) {
11621
11691
  function getDefaultScheduleTimezone() {
11622
11692
  return process.env.JUNIOR_TIMEZONE?.trim() || DEFAULT_SCHEDULE_TIMEZONE;
11623
11693
  }
11694
+ /**
11695
+ * Pick the timezone for a new schedule when the user names none: the
11696
+ * creator's Slack profile, then the saved user timezone, then the install
11697
+ * default. A valid Slack timezone is saved on the linked user.
11698
+ */
11699
+ async function resolveCreatorScheduleTimezone(args) {
11700
+ const timezone = (await lookupSlackUser(args.teamId, args.slackUserId))?.timezone;
11701
+ if (timezone && isValidTimeZone$1(timezone)) {
11702
+ if (args.userId) await saveUserTimezone(args.db, args.userId, timezone, args.nowMs);
11703
+ return timezone;
11704
+ }
11705
+ return (args.userId ? await readUserTimezone(args.db, args.userId) : void 0) ?? getDefaultScheduleTimezone();
11706
+ }
11624
11707
  //#endregion
11625
11708
  //#region src/chat/scheduled-automations/tools/create.ts
11626
11709
  /** Create a tool that stores a scheduled automation for the active Slack context. */
@@ -11663,13 +11746,21 @@ function createSlackScheduleCreateAutomationTool(context) {
11663
11746
  if (!sameDestination(existing, destination) || existing.createdBy.slackUserId !== actor.slackUserId) throwToolInputError("Scheduled automation operation identity is invalid.");
11664
11747
  return scheduleAutomationToolResult(context.conversationId, existing, actor.slackUserId);
11665
11748
  }
11666
- const identity = (await context.users.resolveActor())?.identity;
11749
+ const creator = await context.users.resolveActor();
11750
+ const identity = creator?.identity;
11667
11751
  if (!identity || identity.provider !== "slack" || identity.providerTenantId !== destination.teamId || identity.providerSubjectId !== actor.slackUserId) throwToolInputError("Scheduled automation creator identity is unavailable.");
11668
11752
  const nowMs = context.now?.() ?? Date.now();
11753
+ const defaultTimezone = input.schedule.timezone ?? await resolveCreatorScheduleTimezone({
11754
+ db,
11755
+ nowMs,
11756
+ slackUserId: actor.slackUserId,
11757
+ teamId: destination.teamId,
11758
+ ...creator.user ? { userId: creator.user.id } : void 0
11759
+ });
11669
11760
  let compiled;
11670
11761
  try {
11671
11762
  compiled = compileScheduleIntent({
11672
- defaultTimezone: getDefaultScheduleTimezone(),
11763
+ defaultTimezone,
11673
11764
  intent: input.schedule,
11674
11765
  nowMs
11675
11766
  });
@@ -18667,6 +18758,10 @@ function defaultGrantForProvider(input) {
18667
18758
  }
18668
18759
  };
18669
18760
  }
18761
+ function hasGenericCredentials(provider) {
18762
+ const manifest = pluginCatalogRuntime.getDefinition(provider)?.manifest;
18763
+ return Boolean(manifest?.credentials || manifest?.apiHeaders);
18764
+ }
18670
18765
  function oauthAuthorizationForProvider(provider) {
18671
18766
  const oauth = pluginCatalogRuntime.getOAuthConfig(provider);
18672
18767
  return oauth ? {
@@ -18689,6 +18784,8 @@ function assertLeaseTransformsOwnedByProvider(provider, lease) {
18689
18784
  *
18690
18785
  * GitHub GraphQL and other plugin-owned APIs may need body-aware grant choices;
18691
18786
  * providers without hooks use a simple read/write default based on HTTP method.
18787
+ * A hook plugin that also declares generic credentials can return no grant to
18788
+ * use that default for one request.
18692
18789
  */
18693
18790
  async function selectSandboxEgressGrant(input) {
18694
18791
  if (!hasEgressCredentialHooks(input.provider)) return defaultGrantForProvider(input);
@@ -18699,7 +18796,10 @@ async function selectSandboxEgressGrant(input) {
18699
18796
  method: input.method,
18700
18797
  upstreamUrl: input.upstreamUrl
18701
18798
  });
18702
- if (!pluginGrant) throw new Error(`Plugin "${input.provider}" grantForEgress must return a grant for sandbox egress`);
18799
+ if (!pluginGrant) {
18800
+ if (hasGenericCredentials(input.provider)) return defaultGrantForProvider(input);
18801
+ throw new Error(`Plugin "${input.provider}" grantForEgress must return a grant for sandbox egress`);
18802
+ }
18703
18803
  return {
18704
18804
  source: "plugin",
18705
18805
  grant: pluginGrant
@@ -21712,7 +21812,7 @@ function createAgentRunner(execute, options) {
21712
21812
  } } : void 0
21713
21813
  };
21714
21814
  if (run.instruction.storedAttachments?.length) {
21715
- const { loadInputImages } = await import("./images-BdG7zcNf.js").then((n) => n.n);
21815
+ const { loadInputImages } = await import("./images-D6Y3FJDQ.js").then((n) => n.n);
21716
21816
  const storage = nextRun.environment?.attachmentStorage;
21717
21817
  if (!storage) throw new Error("Attachment storage is unavailable.");
21718
21818
  nextRun.instruction = {
@@ -21763,4 +21863,4 @@ async function runAgentWithTimeout(agentRunner, run, timeoutMs) {
21763
21863
  }
21764
21864
  }
21765
21865
  //#endregion
21766
- export { resolveTaskOutcomes as $, startConversationWork as $t, requestAttachmentDeletion as A, postSlackMessage as An, appendAndEnqueueExclusiveInboundMessage as At, scheduledAutomationRunAttributes as B, shouldEmitDevAgentTrace as Bn, deadLetterAttempt as Bt, isExperimentalFeatureEnabled as C, escapeSlackMrkdwnText as Cn, ingestEvent as Ct, renderBlockText as D, slackMention as Dn, eventGuidance as Dt, renderAttachmentText as E, normalizeSlackStatusText as En, getEventCatalog as Et, resolveSlackChannelIdFromThreadId as F, buildSteeringPiMessage as Fn, clearConsumedConversationWake as Ft, saveScheduledAutomation as G, hasRunnableConversationWork as Gt, listScheduledAutomationsForTeam as H, setConfigDefaults as Hn, ensureConversationWake as Ht, getConversationInfo as I, RetryableDeliveryError as In, clearExpiredConversationLease as It, withScheduledAutomationLock as J, recordConversationRetry as Jt, saveScheduledAutomationInLock as K, listActiveConversationIds as Kt, listThreadReplies as L, actorFromRun as Ln, completeConversationStop as Lt, parseSlackThreadId as M, slackEntitySchema as Mn, beginConversationResume as Mt, readSlackRawMessageContext as N, slackExternalRefIdSchema as Nn, cancelHumanFacingPendingMessages as Nt, collectAttachmentGarbage as O, truncateStatusText as On, pluginEventCatalog as Ot, resolveSlackChannelIdFromMessage as P, createUserTokenStore as Pn, checkInConversationWork as Pt, effectiveTaskOutcomes as Q, requestConversationWork as Qt, editScheduledAutomation as R, toolInvocationDestination as Rn, completeConversationWork as Rt, getExperimentalFeatures as S, startOAuthFlow as Sn, processWorkspaceSnapshotJob as St, lookupSlackUserProfile as T, normalizeSlackReplyMarkdown as Tn, isEventMailboxMetadata as Tt, parseScheduledAutomationRow as U, getConversation as Ut, listScheduledAutomations as V, getConfigDefaults as Vn, drainConversationMailbox as Vt, readScheduledAutomation as W, getConversationWorkState as Wt, AutomationEditError as X, removeActiveConversation as Xt, editEventAutomation as Y, releaseConversationWork as Yt, eventAutomationTriggerAvailable as Z, requestAnotherSlice as Zt, resolvePluginOAuthAccount as _, parseSandboxEgressCredentialToken as _n, agentInvocationSchema as _t, executeCredentialedEgressRequest as a, isFinalAttempt as an, listDeletedEventAutomationsCreatedBy as at, unpublishedArtifactHeaders as b, parseOAuthStatePayload as bn, AgentInvocationLimitError as bt, deleteMcpAuthSessionsForUserProvider as c, maybePostAutomatedTurnLimitNotice as cn, setEventAutomationStatus as ct, getMcpAuthSession as d, normalizeSandboxEgressTracePropagationDomains as dn, readAutomationVersion as dt, stopConversationWork as en, collectEventAutomationMatchKeys as et, getMcpStoredOAuthCredentials as f, shouldPropagateSandboxEgressTrace as fn, sameDefinitionValue as ft, readStats as g, consumeSandboxEgressPermissionDeniedSignal as gn, agentBindingSchema as gt, latestProgressStatus as h, consumeSandboxEgressAuthRequiredSignal as hn, requireAutomationRevision as ht, createContextCompactor as i, hasRunnableConversationWork$1 as in, getEventAutomation as it, storeAttachment as j, removeReactionFromMessage as jn, appendAndEnqueueInboundMessage as jt, readLiveAttachment as k, addReactionToMessage as kn, ackMessages as kt, deleteMcpServerSessionId as l, recordFinishedTurnForAutomatedLimit as ln, automationDefinition as lt, PluginCredentialFailureError as m, clearSandboxEgressSignals as mn, automationRevision as mt, runAgentWithTimeout as n, CONVERSATION_WORK_STALE_ENQUEUE_MS as nn, eventAutomationBelongsToUser as nt, finalizeMcpAuthorization as o, isInvalidConversationRecordError as on, parseEventAutomationRow as ot, putMcpStoredOAuthCredentials as p, SANDBOX_EGRESS_PROXY_PATH as pn, AutomationConflictError as pt, scheduledRunId as q, recordAttemptFailure as qt, executeAgentRun as r, hasConversationStop as rn, findMatchingEventAutomations as rt, deleteMcpAuthSession as s, renderTaskInput as sn, saveEventAutomation as st, createAgentRunner as t, CONVERSATION_WORK_CHECK_IN_INTERVAL_MS as tn, deleteEventAutomation as tt, deleteMcpStoredOAuthCredentials as u, resolveSandboxEgressProviderForHost as un, listAutomationVersions as ut, publicArtifactHeaders as v, sandboxEgressSignalsResponseSchema as vn, createAgentInvocationSchema as vt, setExperimentalFeatures as w, formatSlackLink as wn, EVENT_WAIT_MS as wt, experimental_exports as x, resolveBaseUrl as xn, getMcpProviderErrorAttributes as xt, readPublicArtifact as y, formatProviderLabel as yn, AgentInvocationBusyError as yt, logScheduledAutomationRunSkipped as z, AuthorizationFlowDisabledError as zn, countPendingConversationMessages as zt };
21866
+ export { effectiveTaskOutcomes as $, requestConversationWork as $t, requestAttachmentDeletion as A, addReactionToMessage as An, ackMessages as At, logScheduledAutomationRunSkipped as B, AuthorizationFlowDisabledError as Bn, countPendingConversationMessages as Bt, isExperimentalFeatureEnabled as C, startOAuthFlow as Cn, processWorkspaceSnapshotJob as Ct, renderBlockText as D, normalizeSlackStatusText as Dn, getEventCatalog as Dt, renderAttachmentText as E, normalizeSlackReplyMarkdown as En, isEventMailboxMetadata as Et, resolveSlackChannelIdFromThreadId as F, createUserTokenStore as Fn, checkInConversationWork as Ft, readScheduledAutomation as G, getConversationWorkState as Gt, listScheduledAutomations as H, getConfigDefaults as Hn, drainConversationMailbox as Ht, getConversationInfo as I, buildSteeringPiMessage as In, clearConsumedConversationWake as It, scheduledRunId as J, recordAttemptFailure as Jt, saveScheduledAutomation as K, hasRunnableConversationWork as Kt, listThreadReplies as L, RetryableDeliveryError as Ln, clearExpiredConversationLease as Lt, parseSlackThreadId as M, removeReactionFromMessage as Mn, appendAndEnqueueInboundMessage as Mt, readSlackRawMessageContext as N, slackEntitySchema as Nn, beginConversationResume as Nt, collectAttachmentGarbage as O, slackMention as On, eventGuidance as Ot, resolveSlackChannelIdFromMessage as P, slackExternalRefIdSchema as Pn, cancelHumanFacingPendingMessages as Pt, eventAutomationTriggerAvailable as Q, requestAnotherSlice as Qt, editScheduledAutomation as R, actorFromRun as Rn, completeConversationStop as Rt, getExperimentalFeatures as S, resolveBaseUrl as Sn, getMcpProviderErrorAttributes as St, lookupSlackUserProfile as T, formatSlackLink as Tn, EVENT_WAIT_MS as Tt, listScheduledAutomationsForTeam as U, setConfigDefaults as Un, ensureConversationWake as Ut, scheduledAutomationRunAttributes as V, shouldEmitDevAgentTrace as Vn, deadLetterAttempt as Vt, parseScheduledAutomationRow as W, getConversation as Wt, editEventAutomation as X, releaseConversationWork as Xt, withScheduledAutomationLock as Y, recordConversationRetry as Yt, AutomationEditError as Z, removeActiveConversation as Zt, resolvePluginOAuthAccount as _, consumeSandboxEgressPermissionDeniedSignal as _n, agentBindingSchema as _t, executeCredentialedEgressRequest as a, hasRunnableConversationWork$1 as an, getEventAutomation as at, unpublishedArtifactHeaders as b, formatProviderLabel as bn, AgentInvocationBusyError as bt, deleteMcpAuthSessionsForUserProvider as c, renderTaskInput as cn, saveEventAutomation as ct, getMcpAuthSession as d, resolveSandboxEgressProviderForHost as dn, listAutomationVersions as dt, startConversationWork as en, resolveTaskOutcomes as et, getMcpStoredOAuthCredentials as f, normalizeSandboxEgressTracePropagationDomains as fn, readAutomationVersion as ft, readStats as g, consumeSandboxEgressAuthRequiredSignal as gn, requireAutomationRevision as gt, latestProgressStatus as h, clearSandboxEgressSignals as hn, automationRevision as ht, createContextCompactor as i, hasConversationStop as in, findMatchingEventAutomations as it, storeAttachment as j, postSlackMessage as jn, appendAndEnqueueExclusiveInboundMessage as jt, readLiveAttachment as k, truncateStatusText as kn, pluginEventCatalog as kt, deleteMcpServerSessionId as l, maybePostAutomatedTurnLimitNotice as ln, setEventAutomationStatus as lt, PluginCredentialFailureError as m, SANDBOX_EGRESS_PROXY_PATH as mn, AutomationConflictError as mt, runAgentWithTimeout as n, CONVERSATION_WORK_CHECK_IN_INTERVAL_MS as nn, deleteEventAutomation as nt, finalizeMcpAuthorization as o, isFinalAttempt as on, listDeletedEventAutomationsCreatedBy as ot, putMcpStoredOAuthCredentials as p, shouldPropagateSandboxEgressTrace as pn, sameDefinitionValue as pt, saveScheduledAutomationInLock as q, listActiveConversationIds as qt, executeAgentRun as r, CONVERSATION_WORK_STALE_ENQUEUE_MS as rn, eventAutomationBelongsToUser as rt, deleteMcpAuthSession as s, isInvalidConversationRecordError as sn, parseEventAutomationRow as st, createAgentRunner as t, stopConversationWork as tn, collectEventAutomationMatchKeys as tt, deleteMcpStoredOAuthCredentials as u, recordFinishedTurnForAutomatedLimit as un, automationDefinition as ut, publicArtifactHeaders as v, parseSandboxEgressCredentialToken as vn, agentInvocationSchema as vt, setExperimentalFeatures as w, escapeSlackMrkdwnText as wn, ingestEvent as wt, experimental_exports as x, parseOAuthStatePayload as xn, AgentInvocationLimitError as xt, readPublicArtifact as y, sandboxEgressSignalsResponseSchema as yn, createAgentInvocationSchema as yt, lookupSlackUser as z, toolInvocationDestination as zn, completeConversationWork as zt };
@@ -1,5 +1,5 @@
1
1
  import { A as forkConversationResponseSchema, C as conversationReportEventSchema, D as createConversationBodySchema, E as conversationSummaryReportSchema, K as resolveMessageCards, M as MAX_INPUT_IMAGE_BYTES, O as createConversationMessageBodySchema, P as INPUT_IMAGE_TYPES, S as conversationReportEventDataSchema, T as conversationStatsReportSchema, U as messageCardText, X as conversationTurnFailureCodeSchema, Z as conversationTurnFailureReasonSchema, _ as conversationParamsSchema, a as cancelConversationPendingMessagesBodySchema, b as conversationPendingMessageSchema, d as conversationDetailReportSchema, f as conversationEventHistorySchema, g as conversationFeedSchema, h as conversationFeedQuerySchema, i as archiveConversationResponseSchema, j as MAX_INPUT_IMAGES, k as forkConversationBodySchema, l as conversationAuxiliaryCostsSchema, m as conversationEventsQuerySchema, o as cancelConversationPendingMessagesResponseSchema, p as conversationEventPageSchema, r as archiveConversationBodySchema, s as conversationActivityPreviewSchema, t as acceptedConversationMessageSchema, u as conversationDetailQuerySchema, v as conversationPendingAuthorizationSchema, x as conversationPendingMessagesReportSchema, y as conversationPendingMessageDeliverySchema } from "../conversation-9Fxa1Zbq.js";
2
- import { C as eventAutomationSummarySchema, S as automationVersionSchema, _ as automationSummarySchema, a as automationExecutionSchema, b as automationVersionListSchema, d as automationParamsSchema, f as automationRunListSchema, g as automationSchedulePreviewSchema, h as automationScheduleIntentSchema, i as automationExecutionListSchema, l as automationListQuerySchema, m as automationRunWindowsSchema, n as automationEditSchema, o as automationExecutionStatusDaySchema, p as automationRunSchema, r as automationEventCatalogSchema, s as automationExecutionStatusSchema, t as automationEditErrorSchema, u as automationListSchema, v as automationUpdateSchema, w as scheduledAutomationSummarySchema, x as automationVersionParamsSchema, y as automationVersionActivateSchema } from "../automation-B9Kc1gcf.js";
2
+ import { C as eventAutomationSummarySchema, S as automationVersionSchema, _ as automationSummarySchema, a as automationExecutionSchema, b as automationVersionListSchema, d as automationParamsSchema, f as automationRunListSchema, g as automationSchedulePreviewSchema, h as automationScheduleIntentSchema, i as automationExecutionListSchema, l as automationListQuerySchema, m as automationRunWindowsSchema, n as automationEditSchema, o as automationExecutionStatusDaySchema, p as automationRunSchema, r as automationEventCatalogSchema, s as automationExecutionStatusSchema, t as automationEditErrorSchema, u as automationListSchema, v as automationUpdateSchema, w as scheduledAutomationSummarySchema, x as automationVersionParamsSchema, y as automationVersionActivateSchema } from "../automation-CrQGQ2MT.js";
3
3
  import { C as skillReportsSchema, S as skillReportSchema, _ as pluginPackageContentItemReportSchema, b as pluginsSchema, g as pluginOperationalReportSchema, h as pluginOperationalReportFeedSchema, m as healthReportSchema, t as webMessageId, v as pluginPackageContentReportSchema, x as runtimeInfoReportSchema, y as pluginSchema } from "../web-message-id-xPI_EFSC.js";
4
- import { A as codeChangeSummarySchema, C as locationParamsSchema, D as dailyConversationActivitySchema, F as codeRepositorySummarySchema, I as apiErrorSchema, M as codePersonReportSchema, N as codeRepositoryParamsSchema, O as codeActivityDaySchema, P as codeRepositoryReportSchema, S as locationDirectoryReportSchema, _ as actorProfileReportSchema, a as workspaceBodySchema, b as locationActivityDayReportSchema, c as workspaceRepoSchema, d as createdPersonalTokenSchema, f as personalTokenListSchema, g as actorDirectoryReportSchema, h as revokePersonalTokenResponseSchema, i as deleteWorkspaceResponseSchema, j as codeOverviewReportSchema, k as codeChangeSummaryReportSchema, l as workspaceSchema, m as personalTokenParamsSchema, n as statsReportSchema, o as workspaceListSchema, p as personalTokenMetadataSchema, r as baselineSnapshotSchema, s as workspaceParamsSchema, t as statSchema, u as createPersonalTokenBodySchema, v as personParamsSchema, x as locationDetailReportSchema, y as personalSpendReportSchema } from "../schema-CJiqDc5r.js";
4
+ import { A as codeChangeSummarySchema, C as locationParamsSchema, D as dailyConversationActivitySchema, F as codeRepositorySummarySchema, I as apiErrorSchema, M as codePersonReportSchema, N as codeRepositoryParamsSchema, O as codeActivityDaySchema, P as codeRepositoryReportSchema, S as locationDirectoryReportSchema, _ as actorProfileReportSchema, a as workspaceBodySchema, b as locationActivityDayReportSchema, c as workspaceRepoSchema, d as createdPersonalTokenSchema, f as personalTokenListSchema, g as actorDirectoryReportSchema, h as revokePersonalTokenResponseSchema, i as deleteWorkspaceResponseSchema, j as codeOverviewReportSchema, k as codeChangeSummaryReportSchema, l as workspaceSchema, m as personalTokenParamsSchema, n as statsReportSchema, o as workspaceListSchema, p as personalTokenMetadataSchema, r as baselineSnapshotSchema, s as workspaceParamsSchema, t as statSchema, u as createPersonalTokenBodySchema, v as personParamsSchema, x as locationDetailReportSchema, y as personalSpendReportSchema } from "../schema-C5bgOpRg.js";
5
5
  export { INPUT_IMAGE_TYPES, MAX_INPUT_IMAGES, MAX_INPUT_IMAGE_BYTES, acceptedConversationMessageSchema, actorDirectoryReportSchema, actorProfileReportSchema, apiErrorSchema, archiveConversationBodySchema, archiveConversationResponseSchema, automationEditErrorSchema, automationEditSchema, automationEventCatalogSchema, automationExecutionListSchema, automationExecutionSchema, automationExecutionStatusDaySchema, automationExecutionStatusSchema, automationListQuerySchema, automationListSchema, automationParamsSchema, automationRunListSchema, automationRunSchema, automationRunWindowsSchema, automationScheduleIntentSchema, automationSchedulePreviewSchema, automationSummarySchema, automationUpdateSchema, automationVersionActivateSchema, automationVersionListSchema, automationVersionParamsSchema, automationVersionSchema, baselineSnapshotSchema, cancelConversationPendingMessagesBodySchema, cancelConversationPendingMessagesResponseSchema, codeActivityDaySchema, codeChangeSummaryReportSchema, codeChangeSummarySchema, codeOverviewReportSchema, codePersonReportSchema, codeRepositoryParamsSchema, codeRepositoryReportSchema, codeRepositorySummarySchema, conversationActivityPreviewSchema, conversationAuxiliaryCostsSchema, conversationDetailQuerySchema, conversationDetailReportSchema, conversationEventHistorySchema, conversationEventPageSchema, conversationEventsQuerySchema, conversationFeedQuerySchema, conversationFeedSchema, conversationParamsSchema, conversationPendingAuthorizationSchema, conversationPendingMessageDeliverySchema, conversationPendingMessageSchema, conversationPendingMessagesReportSchema, conversationReportEventDataSchema, conversationReportEventSchema, conversationStatsReportSchema, conversationSummaryReportSchema, conversationTurnFailureCodeSchema, conversationTurnFailureReasonSchema, createConversationBodySchema, createConversationMessageBodySchema, createPersonalTokenBodySchema, createdPersonalTokenSchema, dailyConversationActivitySchema, deleteWorkspaceResponseSchema, eventAutomationSummarySchema, forkConversationBodySchema, forkConversationResponseSchema, healthReportSchema, locationActivityDayReportSchema, locationDetailReportSchema, locationDirectoryReportSchema, locationParamsSchema, messageCardText, personParamsSchema, personalSpendReportSchema, personalTokenListSchema, personalTokenMetadataSchema, personalTokenParamsSchema, pluginOperationalReportFeedSchema, pluginOperationalReportSchema, pluginPackageContentItemReportSchema, pluginPackageContentReportSchema, pluginSchema, pluginsSchema, resolveMessageCards, revokePersonalTokenResponseSchema, runtimeInfoReportSchema, scheduledAutomationSummarySchema, skillReportSchema, skillReportsSchema, statSchema, statsReportSchema, webMessageId, workspaceBodySchema, workspaceListSchema, workspaceParamsSchema, workspaceRepoSchema, workspaceSchema };
package/dist/api.js CHANGED
@@ -1,21 +1,21 @@
1
- import { $ as resolveTaskOutcomes, Et as getEventCatalog, G as saveScheduledAutomation, M as parseSlackThreadId, Nt as cancelHumanFacingPendingMessages, Ot as pluginEventCatalog, R as editScheduledAutomation, Ut as getConversation, W as readScheduledAutomation, X as AutomationEditError, Y as editEventAutomation, Z as eventAutomationTriggerAvailable, ct as setEventAutomationStatus, dt as readAutomationVersion, ft as sameDefinitionValue, g as readStats, ht as requireAutomationRevision, it as getEventAutomation, k as readLiveAttachment, lt as automationDefinition, mt as automationRevision, nt as eventAutomationBelongsToUser, pt as AutomationConflictError, st as saveEventAutomation } from "./agent-runner-uP7QRc4c.js";
2
- import { d as logException, p as logWarn } from "./logging-B4sKwmCG.js";
1
+ import { Dt as getEventCatalog, G as readScheduledAutomation, K as saveScheduledAutomation, M as parseSlackThreadId, Pt as cancelHumanFacingPendingMessages, Q as eventAutomationTriggerAvailable, R as editScheduledAutomation, Wt as getConversation, X as editEventAutomation, Z as AutomationEditError, at as getEventAutomation, ct as saveEventAutomation, et as resolveTaskOutcomes, ft as readAutomationVersion, g as readStats, gt as requireAutomationRevision, ht as automationRevision, k as readLiveAttachment, kt as pluginEventCatalog, lt as setEventAutomationStatus, mt as AutomationConflictError, pt as sameDefinitionValue, rt as eventAutomationBelongsToUser, ut as automationDefinition, z as lookupSlackUser } from "./agent-runner-DMAsnPb9.js";
2
+ import { d as logException, p as logWarn } from "./logging-rB_ngE_R.js";
3
3
  import { b as parseSlackMessageTs, h as parseSlackTeamId, p as parseSlackChannelId } from "./context-0Et9iVSB.js";
4
- import { At as conversationHasParticipantUser, C as WorkspaceValidationError, Dt as conversationArchivedForEmail, Et as conversationArchiveTimes, Ft as readLatestConversationBrief, Gt as listConversationAnnotations, It as readConversationEventPage, Kt as listConversationAnnotationsById, Lt as buildSentryConversationUrl, M as workspaceRepoCheckoutPath, Mt as conversationNotArchivedForUser, Nt as viewerConversationMembership, O as SANDBOX_RUNTIME, Ot as conversationArchivedForUser, Q as findUserByEmail, Qt as getConversationEventStore, S as updateWorkspace, Tt as readConversationAccessFromSql, W as getSlackClient, Y as withSlackRetries, _ as deleteWorkspace, b as listWorkspaces, cn as parseSessionSource, en as getConversationStore, et as resolveViewerUser, fn as agentTurnUsageSchema, g as createWorkspace, in as withConversationEventLock, jt as conversationNotArchivedForEmail, kt as conversationHasParticipantEmail, mn as resolveRootConversationId, nn as getSqlExecutor, on as locationFromRow, pn as hasAgentTurnUsage, tn as getDb, tt as updateViewerDisplayName, u as getPlugins, v as getWorkspace, wt as createPluginLogger, x as listWorkspacesByRepository } from "./agent-hooks-Da_H0jHv.js";
4
+ import { At as conversationHasParticipantUser, C as WorkspaceValidationError, Dt as conversationArchivedForEmail, Et as conversationArchiveTimes, Ft as readLatestConversationBrief, Gt as listConversationAnnotations, It as readConversationEventPage, Kt as listConversationAnnotationsById, Lt as buildSentryConversationUrl, M as workspaceRepoCheckoutPath, Mt as conversationNotArchivedForUser, Nt as viewerConversationMembership, O as SANDBOX_RUNTIME, Ot as conversationArchivedForUser, Q as findUserByEmail, Qt as getConversationEventStore, S as updateWorkspace, Tt as readConversationAccessFromSql, W as getSlackClient, Y as withSlackRetries, _ as deleteWorkspace, b as listWorkspaces, cn as parseSessionSource, en as getConversationStore, et as resolveViewerUser, fn as agentTurnUsageSchema, g as createWorkspace, in as withConversationEventLock, jt as conversationNotArchivedForEmail, kt as conversationHasParticipantEmail, mn as resolveRootConversationId, nn as getSqlExecutor, on as locationFromRow, pn as hasAgentTurnUsage, tn as getDb, tt as updateViewerDisplayName, u as getPlugins, v as getWorkspace, wt as createPluginLogger, x as listWorkspacesByRepository } from "./agent-hooks-otHGbhBx.js";
5
5
  import { n as juniorDestinations } from "./destinations-BeBiJeEM.js";
6
- import { C as juniorCodeChanges, D as juniorConversations, E as conversationReadColumns, O as juniorIdentities, _ as juniorConversationBriefs, b as juniorConversationEvents, h as juniorConversationParticipants, k as juniorUsers, w as juniorCodeRepositories, x as juniorApiTokens, y as juniorConversationMetrics } from "./executor-BW9XWgUQ.js";
6
+ import { C as juniorCodeChanges, D as juniorConversations, E as conversationReadColumns, O as juniorIdentities, _ as juniorConversationBriefs, b as juniorConversationEvents, h as juniorConversationParticipants, k as juniorUsers, w as juniorCodeRepositories, x as juniorApiTokens, y as juniorConversationMetrics } from "./executor-BNxfDS1V.js";
7
7
  import { A as forkConversationResponseSchema, D as createConversationBodySchema, N as readMessageAttachments, O as createConversationMessageBodySchema, P as INPUT_IMAGE_TYPES, T as conversationStatsReportSchema, _ as conversationParamsSchema, a as cancelConversationPendingMessagesBodySchema, c as conversationAttachmentParamsSchema, d as conversationDetailReportSchema, g as conversationFeedSchema, h as conversationFeedQuerySchema, i as archiveConversationResponseSchema, k as forkConversationBodySchema, m as conversationEventsQuerySchema, nt as contextProvenance, o as cancelConversationPendingMessagesResponseSchema, p as conversationEventPageSchema, r as archiveConversationBodySchema, t as acceptedConversationMessageSchema, u as conversationDetailQuerySchema, x as conversationPendingMessagesReportSchema } from "./conversation-9Fxa1Zbq.js";
8
- import { F as loadTurnProjection, vt as piMessageFromHistoryItem } from "./checkpoint-DaD7_Gsb.js";
9
- import { n as hash, t as create } from "./profile-BamYnmhO.js";
10
- import { t as getCachedSnapshot } from "./resolve-C9ETkt4T.js";
11
- import { a as getVercelConversationWorkQueue } from "./job-queue-BqXd0ZPV.js";
12
- import { F as getFirstRunAtMs, M as compileScheduleIntent, P as weekdaySchema, _ as automationSummarySchema, b as automationVersionListSchema, c as automationLifecycleSchema, d as automationParamsSchema, f as automationRunListSchema, g as automationSchedulePreviewSchema, h as automationScheduleIntentSchema, i as automationExecutionListSchema, j as ScheduleIntentError, l as automationListQuerySchema, n as automationEditSchema, r as automationEventCatalogSchema, t as automationEditErrorSchema, u as automationListSchema, v as automationUpdateSchema, x as automationVersionParamsSchema, y as automationVersionActivateSchema } from "./automation-B9Kc1gcf.js";
8
+ import { F as loadTurnProjection, vt as piMessageFromHistoryItem } from "./checkpoint-BlIIiHG5.js";
9
+ import { n as hash, t as create } from "./profile-D6apIG2N.js";
10
+ import { t as getCachedSnapshot } from "./resolve-sJtTzuBO.js";
11
+ import { a as getVercelConversationWorkQueue } from "./job-queue-Dq5_zt_l.js";
12
+ import { F as weekdaySchema, I as getFirstRunAtMs, M as compileScheduleIntent, _ as automationSummarySchema, b as automationVersionListSchema, c as automationLifecycleSchema, d as automationParamsSchema, f as automationRunListSchema, g as automationSchedulePreviewSchema, h as automationScheduleIntentSchema, i as automationExecutionListSchema, j as ScheduleIntentError, l as automationListQuerySchema, n as automationEditSchema, r as automationEventCatalogSchema, t as automationEditErrorSchema, u as automationListSchema, v as automationUpdateSchema, x as automationVersionParamsSchema, y as automationVersionActivateSchema } from "./automation-CrQGQ2MT.js";
13
13
  import { C as skillReportsSchema, a as fillUtcHours, b as pluginsSchema, c as sumUtcHoursIntoSixHours, d as trailingUtcSixHourWindow, f as utcDayKey, h as pluginOperationalReportFeedSchema, i as fillUtcDays, l as trailingUtcDayWindow, m as healthReportSchema, n as DAY_MS$1, o as fillUtcSixHours, p as utcHourKey, r as HOUR_MS$1, s as startOfUtcHour, u as trailingUtcHourWindow, x as runtimeInfoReportSchema } from "./web-message-id-xPI_EFSC.js";
14
- import { C as clearSlackPendingReactions, H as readHealthReport, M as legacyWebMailboxMetadataSchema, R as createVercelAttachmentStorage, _ as readViewerAutomationSummary, a as recordWebConversationActivity, b as resolveViewerTaskCandidate, d as resolveSlackConversationContextFromThreadId, f as ViewerTaskNotFoundError, g as readViewerAutomationRuns, h as readViewerAutomationExecutions, i as createConversationId, l as getProductionSlackAdapter, m as readConversationSourceTask, o as webActorFromEmail, p as deleteViewerTask, r as createAndEnqueueConversation, t as appendAndEnqueueWebMessage, u as formatSlackConversationRedactedLabel, v as readViewerAutomationVersions, w as lookupSlackUser, y as readViewerAutomations } from "./web-input-CfNxXtHm.js";
15
- import { A as conversationAggregateColumns, j as conversationRangeColumns, k as conversationActiveDaysColumn } from "./task-runner-C5XCIDSF.js";
16
- import { r as getWebAuthorization } from "./web-authorization-PPaoj2ns.js";
17
- import { t as decodeInputImages } from "./images-BdG7zcNf.js";
18
- import { C as locationParamsSchema, E as activitySixHours$1, I as apiErrorSchema, M as codePersonReportSchema, N as codeRepositoryParamsSchema, P as codeRepositoryReportSchema, S as locationDirectoryReportSchema, T as activityHours$1, _ as actorProfileReportSchema, a as workspaceBodySchema, d as createdPersonalTokenSchema, f as personalTokenListSchema, g as actorDirectoryReportSchema, h as revokePersonalTokenResponseSchema, i as deleteWorkspaceResponseSchema, j as codeOverviewReportSchema, l as workspaceSchema, m as personalTokenParamsSchema, n as statsReportSchema, o as workspaceListSchema, s as workspaceParamsSchema, u as createPersonalTokenBodySchema, v as personParamsSchema, w as activityDays$1, x as locationDetailReportSchema, y as personalSpendReportSchema } from "./schema-CJiqDc5r.js";
14
+ import { C as clearSlackPendingReactions, L as createVercelAttachmentStorage, V as readHealthReport, _ as readViewerAutomationSummary, a as recordWebConversationActivity, b as resolveViewerTaskCandidate, d as resolveSlackConversationContextFromThreadId, f as ViewerTaskNotFoundError, g as readViewerAutomationRuns, h as readViewerAutomationExecutions, i as createConversationId, j as legacyWebMailboxMetadataSchema, l as getProductionSlackAdapter, m as readConversationSourceTask, o as webActorFromEmail, p as deleteViewerTask, r as createAndEnqueueConversation, t as appendAndEnqueueWebMessage, u as formatSlackConversationRedactedLabel, v as readViewerAutomationVersions, y as readViewerAutomations } from "./web-input-C56ivZuH.js";
15
+ import { A as conversationAggregateColumns, j as conversationRangeColumns, k as conversationActiveDaysColumn } from "./task-runner-Bh8XONXT.js";
16
+ import { r as getWebAuthorization } from "./web-authorization-DDt4FZld.js";
17
+ import { t as decodeInputImages } from "./images-D6Y3FJDQ.js";
18
+ import { C as locationParamsSchema, E as activitySixHours$1, I as apiErrorSchema, M as codePersonReportSchema, N as codeRepositoryParamsSchema, P as codeRepositoryReportSchema, S as locationDirectoryReportSchema, T as activityHours$1, _ as actorProfileReportSchema, a as workspaceBodySchema, d as createdPersonalTokenSchema, f as personalTokenListSchema, g as actorDirectoryReportSchema, h as revokePersonalTokenResponseSchema, i as deleteWorkspaceResponseSchema, j as codeOverviewReportSchema, l as workspaceSchema, m as personalTokenParamsSchema, n as statsReportSchema, o as workspaceListSchema, s as workspaceParamsSchema, u as createPersonalTokenBodySchema, v as personParamsSchema, w as activityDays$1, x as locationDetailReportSchema, y as personalSpendReportSchema } from "./schema-C5bgOpRg.js";
19
19
  import { Hono } from "hono";
20
20
  import path from "node:path";
21
21
  import { z } from "zod";
@@ -3354,7 +3354,7 @@ async function readPeoplePluginReports(args) {
3354
3354
  reports: [],
3355
3355
  source: "plugins"
3356
3356
  });
3357
- const { getPluginProfileReports } = await import("./agent-hooks-Da_H0jHv.js").then((n) => n.t);
3357
+ const { getPluginProfileReports } = await import("./agent-hooks-otHGbhBx.js").then((n) => n.t);
3358
3358
  return pluginOperationalReportFeedSchema.parse({
3359
3359
  generatedAt: new Date(nowMs).toISOString(),
3360
3360
  reports: await getPluginProfileReports({
@@ -4317,7 +4317,7 @@ function readDescriptionText(home) {
4317
4317
  }
4318
4318
  /** Read discovered skill names for authenticated runtime diagnostics. */
4319
4319
  async function readSkillReports() {
4320
- const { discoverSkills } = await import("./skills-Dd8O9Aav.js").then((n) => n.o);
4320
+ const { discoverSkills } = await import("./skills-BVpr_Gnv.js").then((n) => n.o);
4321
4321
  const skills = await discoverSkills();
4322
4322
  return skillReportsSchema.parse(skills.map((skill) => ({
4323
4323
  name: skill.name,
@@ -4326,7 +4326,7 @@ async function readSkillReports() {
4326
4326
  }
4327
4327
  /** Read safe configured plugin metadata for authenticated runtime diagnostics. */
4328
4328
  async function readPlugins() {
4329
- const { pluginCatalogRuntime } = await import("./catalog-runtime-C7339Cfm.js").then((n) => n.t);
4329
+ const { pluginCatalogRuntime } = await import("./catalog-runtime-DlXuhrmk.js").then((n) => n.t);
4330
4330
  return pluginsSchema.parse(pluginCatalogRuntime.getProviders().map((plugin) => ({
4331
4331
  configKeys: plugin.manifest.configKeys ?? [],
4332
4332
  description: plugin.manifest.description,
@@ -4338,7 +4338,7 @@ async function readPlugins() {
4338
4338
  async function readRuntimeInfoReport() {
4339
4339
  const [{ homeDir }, { pluginCatalogRuntime }, plugins, skills] = await Promise.all([
4340
4340
  import("./package-discovery-BVvSnQBB.js").then((n) => n.r),
4341
- import("./catalog-runtime-C7339Cfm.js").then((n) => n.t),
4341
+ import("./catalog-runtime-DlXuhrmk.js").then((n) => n.t),
4342
4342
  readPlugins(),
4343
4343
  readSkillReports()
4344
4344
  ]);
@@ -4355,7 +4355,7 @@ async function readRuntimeInfoReport() {
4355
4355
  /** Read sanitized operational summaries contributed by plugins. */
4356
4356
  async function readPluginOperationalReportFeed() {
4357
4357
  const nowMs = Date.now();
4358
- const { getPluginOperationalReports } = await import("./agent-hooks-Da_H0jHv.js").then((n) => n.t);
4358
+ const { getPluginOperationalReports } = await import("./agent-hooks-otHGbhBx.js").then((n) => n.t);
4359
4359
  return pluginOperationalReportFeedSchema.parse({
4360
4360
  source: "plugins",
4361
4361
  generatedAt: new Date(nowMs).toISOString(),
package/dist/app.js CHANGED
@@ -1,29 +1,29 @@
1
- import { A as requestAttachmentDeletion, B as scheduledAutomationRunAttributes, C as isExperimentalFeatureEnabled, Ct as ingestEvent, Dn as slackMention, Dt as eventGuidance, Et as getEventCatalog, Gt as hasRunnableConversationWork, H as listScheduledAutomationsForTeam, Hn as setConfigDefaults, Ht as ensureConversationWake, It as clearExpiredConversationLease, J as withScheduledAutomationLock, K as saveScheduledAutomationInLock, Kt as listActiveConversationIds, M as parseSlackThreadId, Mn as slackEntitySchema, Nn as slackExternalRefIdSchema, O as collectAttachmentGarbage, Pn as createUserTokenStore, Q as effectiveTaskOutcomes, Qt as requestConversationWork, S as getExperimentalFeatures, Sn as startOAuthFlow, St as processWorkspaceSnapshotJob, T as lookupSlackUserProfile, Ut as getConversation, V as listScheduledAutomations, Vn as getConfigDefaults, W as readScheduledAutomation, Wt as getConversationWorkState, Xt as removeActiveConversation, _n as parseSandboxEgressCredentialToken, a as executeCredentialedEgressRequest, b as unpublishedArtifactHeaders, c as deleteMcpAuthSessionsForUserProvider, dn as normalizeSandboxEgressTracePropagationDomains, en as stopConversationWork, et as collectEventAutomationMatchKeys, fn as shouldPropagateSandboxEgressTrace, gn as consumeSandboxEgressPermissionDeniedSignal, hn as consumeSandboxEgressAuthRequiredSignal, in as hasRunnableConversationWork$1, jt as appendAndEnqueueInboundMessage, l as deleteMcpServerSessionId, mn as clearSandboxEgressSignals, nn as CONVERSATION_WORK_STALE_ENQUEUE_MS, on as isInvalidConversationRecordError, pn as SANDBOX_EGRESS_PROXY_PATH, q as scheduledRunId, r as executeAgentRun, rt as findMatchingEventAutomations, sn as renderTaskInput, t as createAgentRunner, u as deleteMcpStoredOAuthCredentials, un as resolveSandboxEgressProviderForHost, v as publicArtifactHeaders, w as setExperimentalFeatures, y as readPublicArtifact, yn as formatProviderLabel, z as logScheduledAutomationRunSkipped } from "./agent-runner-uP7QRc4c.js";
2
- import { C as withLogContext, O as JUNIOR_PLUGIN_TASK_CALLBACK_ROUTE, S as withContext, d as logException, f as logInfo, j as JUNIOR_WORKSPACE_SNAPSHOT_JOB_CALLBACK_ROUTE, p as logWarn, r as createRequestContext, v as setSpanAttributes, w as withSpan, y as setSpanStatus } from "./logging-B4sKwmCG.js";
1
+ import { $ as effectiveTaskOutcomes, $t as requestConversationWork, A as requestAttachmentDeletion, B as logScheduledAutomationRunSkipped, C as isExperimentalFeatureEnabled, Cn as startOAuthFlow, Ct as processWorkspaceSnapshotJob, Dt as getEventCatalog, Fn as createUserTokenStore, G as readScheduledAutomation, Gt as getConversationWorkState, H as listScheduledAutomations, Hn as getConfigDefaults, J as scheduledRunId, Kt as hasRunnableConversationWork, Lt as clearExpiredConversationLease, M as parseSlackThreadId, Mt as appendAndEnqueueInboundMessage, Nn as slackEntitySchema, O as collectAttachmentGarbage, On as slackMention, Ot as eventGuidance, Pn as slackExternalRefIdSchema, S as getExperimentalFeatures, T as lookupSlackUserProfile, U as listScheduledAutomationsForTeam, Un as setConfigDefaults, Ut as ensureConversationWake, V as scheduledAutomationRunAttributes, Wt as getConversation, Y as withScheduledAutomationLock, Zt as removeActiveConversation, _n as consumeSandboxEgressPermissionDeniedSignal, a as executeCredentialedEgressRequest, an as hasRunnableConversationWork$1, b as unpublishedArtifactHeaders, bn as formatProviderLabel, c as deleteMcpAuthSessionsForUserProvider, cn as renderTaskInput, dn as resolveSandboxEgressProviderForHost, fn as normalizeSandboxEgressTracePropagationDomains, gn as consumeSandboxEgressAuthRequiredSignal, hn as clearSandboxEgressSignals, it as findMatchingEventAutomations, l as deleteMcpServerSessionId, mn as SANDBOX_EGRESS_PROXY_PATH, pn as shouldPropagateSandboxEgressTrace, q as saveScheduledAutomationInLock, qt as listActiveConversationIds, r as executeAgentRun, rn as CONVERSATION_WORK_STALE_ENQUEUE_MS, sn as isInvalidConversationRecordError, t as createAgentRunner, tn as stopConversationWork, tt as collectEventAutomationMatchKeys, u as deleteMcpStoredOAuthCredentials, v as publicArtifactHeaders, vn as parseSandboxEgressCredentialToken, w as setExperimentalFeatures, wt as ingestEvent, y as readPublicArtifact } from "./agent-runner-DMAsnPb9.js";
2
+ import { C as withLogContext, O as JUNIOR_PLUGIN_TASK_CALLBACK_ROUTE, S as withContext, d as logException, f as logInfo, j as JUNIOR_WORKSPACE_SNAPSHOT_JOB_CALLBACK_ROUTE, p as logWarn, r as createRequestContext, v as setSpanAttributes, w as withSpan, y as setSpanStatus } from "./logging-rB_ngE_R.js";
3
3
  import { r as continueTrace } from "./sentry-CgWZM_kV.js";
4
- import { t as JUNIOR_VERSION } from "./version-CWkIGcLU.js";
5
- import { _ as snapshotRuntimeConfig, d as restoreRuntimeConfig, f as setBotModelConfig, g as setSlackReactionConfig, h as setRuntimeLimits, i as getChatConfig, m as setProfiles, n as botConfig, o as getSlackBotToken, p as setCrossActorMidRunMode, u as resetRuntimeConfig } from "./config-JR9wke1W.js";
4
+ import { t as JUNIOR_VERSION } from "./version-EQ4MWuUJ.js";
5
+ import { _ as snapshotRuntimeConfig, d as restoreRuntimeConfig, f as setBotModelConfig, g as setSlackReactionConfig, h as setRuntimeLimits, i as getChatConfig, m as setProfiles, n as botConfig, o as getSlackBotToken, p as setCrossActorMidRunMode, u as resetRuntimeConfig } from "./config-CxpPG6nR.js";
6
6
  import { _ as slackChannelIdSchema, g as parseSlackUserId, h as parseSlackTeamId, u as parseActorUserId, v as slackTeamIdSchema, x as slackMessageTsSchema, y as slackUserIdSchema } from "./context-0Et9iVSB.js";
7
- import { $ as readActorIdentity, F as bindScheduledAutomationCredentialSubject, Gt as listConversationAnnotations, Ht as resolveRootVisibility, I as bindSlackDirectCredentialSubject, K as isDmChannel, L as verifyEventAutomationCredentialSubject, P as bindEventAutomationCredentialSubject, Qt as getConversationEventStore, R as verifyScheduledAutomationCredentialSubject, Tt as readConversationAccessFromSql, W as getSlackClient, X as getWorkspaceTeamId, Z as runWithWorkspaceTeamId, _t as getDashboardConversationLink, a as getPluginRoutes, an as withConversationMutationLock, bt as setDashboardConversationLinkOptions, d as setPlugins, en as getConversationStore, f as validatePlugins, h as setBriefsConfig, hn as deleteProviderIdentityForSlackUser, ht as takeDueTimerWatches, i as getPluginApiRoutes, in as withConversationEventLock, lt as collectEventMatchKeys, nn as getSqlExecutor, pt as findMatchingWatches, st as cancelSubscriptions, tn as getDb, u as getPlugins, wt as createPluginLogger, xt as createPluginState, yt as getDashboardTaskLink, z as verifySlackDirectCredentialSubject } from "./agent-hooks-Da_H0jHv.js";
7
+ import { $ as readActorIdentity, F as bindScheduledAutomationCredentialSubject, Gt as listConversationAnnotations, Ht as resolveRootVisibility, I as bindSlackDirectCredentialSubject, K as isDmChannel, L as verifyEventAutomationCredentialSubject, P as bindEventAutomationCredentialSubject, Qt as getConversationEventStore, R as verifyScheduledAutomationCredentialSubject, Tt as readConversationAccessFromSql, W as getSlackClient, X as getWorkspaceTeamId, Z as runWithWorkspaceTeamId, _t as getDashboardConversationLink, a as getPluginRoutes, an as withConversationMutationLock, bt as setDashboardConversationLinkOptions, d as setPlugins, en as getConversationStore, f as validatePlugins, h as setBriefsConfig, hn as deleteProviderIdentityForSlackUser, ht as takeDueTimerWatches, i as getPluginApiRoutes, in as withConversationEventLock, lt as collectEventMatchKeys, nn as getSqlExecutor, pt as findMatchingWatches, st as cancelSubscriptions, tn as getDb, u as getPlugins, wt as createPluginLogger, xt as createPluginState, yt as getDashboardTaskLink, z as verifySlackDirectCredentialSubject } from "./agent-hooks-otHGbhBx.js";
8
8
  import { n as juniorDestinations } from "./destinations-BeBiJeEM.js";
9
- import { D as juniorConversations, _ as juniorConversationBriefs, a as juniorSchedulerRuns, b as juniorConversationEvents, m as juniorAgentInvocations, o as juniorSchedulerTasks, p as juniorAgentBindings } from "./executor-BW9XWgUQ.js";
9
+ import { D as juniorConversations, _ as juniorConversationBriefs, a as juniorSchedulerRuns, b as juniorConversationEvents, m as juniorAgentInvocations, o as juniorSchedulerTasks, p as juniorAgentBindings } from "./executor-BNxfDS1V.js";
10
10
  import { V as annotationCard } from "./conversation-9Fxa1Zbq.js";
11
- import { n as pluginCatalogRuntime } from "./catalog-runtime-C7339Cfm.js";
12
- import { J as appendConversationMessages, Z as projectConversationMessages, et as settleConversationTitleWork } from "./checkpoint-DaD7_Gsb.js";
13
- import { O as withLock$1, w as getStateAdapter } from "./profile-BamYnmhO.js";
14
- import { f as setSandboxResourceConfig, u as getSandboxResourceConfig } from "./resolve-C9ETkt4T.js";
15
- import { a as getVercelConversationWorkQueue, g as isConversationQueueMessageRejectedError, h as conversationQueueMessageSchema, i as verifyWorkspaceSnapshotJobMessage, o as resolveConversationWorkQueueTopic, s as verifyConversationQueueMessage, t as WORKSPACE_SNAPSHOT_JOB_QUEUE_TOPIC } from "./job-queue-BqXd0ZPV.js";
16
- import { D as scheduledRunSchema, I as getNextRunAtMs } from "./automation-B9Kc1gcf.js";
17
- import { n as validatePluginRegistrations, t as validatePluginEgressCredentialHooks } from "./validation-B9lMbisx.js";
11
+ import { n as pluginCatalogRuntime } from "./catalog-runtime-DlXuhrmk.js";
12
+ import { J as appendConversationMessages, Z as projectConversationMessages, et as settleConversationTitleWork } from "./checkpoint-BlIIiHG5.js";
13
+ import { O as withLock$1, w as getStateAdapter } from "./profile-D6apIG2N.js";
14
+ import { f as setSandboxResourceConfig, u as getSandboxResourceConfig } from "./resolve-sJtTzuBO.js";
15
+ import { a as getVercelConversationWorkQueue, g as isConversationQueueMessageRejectedError, h as conversationQueueMessageSchema, i as verifyWorkspaceSnapshotJobMessage, o as resolveConversationWorkQueueTopic, s as verifyConversationQueueMessage, t as WORKSPACE_SNAPSHOT_JOB_QUEUE_TOPIC } from "./job-queue-Dq5_zt_l.js";
16
+ import { D as scheduledRunSchema, L as getNextRunAtMs } from "./automation-CrQGQ2MT.js";
17
+ import { n as validatePluginRegistrations, t as validatePluginEgressCredentialHooks } from "./validation-BNPhuAvt.js";
18
18
  import { a as pluginRuntimeRegistrationsFromPluginSet, n as pluginCatalogConfigFromEnv, r as pluginCatalogConfigFromPluginSet, t as defineJuniorPlugins } from "./plugins-egKWjgue.js";
19
- import { A as withNormalizedThreadId, B as enqueueAgentDispatch, C as clearSlackPendingReactions, D as isSlackMessageStopped, E as verifySlackSignature, F as parseContent, I as getThreadStopDecision, L as renderSlackObjectCard, N as THREAD_OPTOUT_ACK, O as stopSlackThread, P as startProcessingReaction, R as createVercelAttachmentStorage, S as buildSlackInboundMessage, T as runWithSlackInstallation, V as GET$3, _ as readViewerAutomationSummary, a as recordWebConversationActivity, c as createProductionSlackWebhookServices, j as getAuthPausedConversationTurnId, k as normalizeIncomingSlackThreadId, l as getProductionSlackAdapter, n as conversationTurnIdForMessage, o as webActorFromEmail, s as createProductionConversationWorkOptions, t as appendAndEnqueueWebMessage, x as recordSkippedConversationMessage } from "./web-input-CfNxXtHm.js";
20
- import { O as recordAutomationExecution, _ as markDispatchFailed, a as confirmDispatchMailboxAppend, d as getPluginDispatchProjection, f as isTerminalDispatchStatus, l as getDispatchRecord, o as createOrGetDispatch, p as listPendingDispatchMailboxAppends, s as getDispatchConversationId, t as processPluginTask } from "./task-runner-C5XCIDSF.js";
21
- import { c as listPendingAgentInvocationMailboxAppends, r as enqueueAgentInvocation } from "./work-DNaoFrEe.js";
22
- import { s as coerceThreadConversationState } from "./thread-state-D3E29wZk.js";
23
- import { a as GET$4, i as publishAppHomeView, r as GET$5, t as receiveLocalOAuthCredential } from "./credential-sync-BWTA3LnL.js";
24
- import { a as registerVercelPluginTaskDevConsumer, n as createVercelPluginTaskCallback, s as queueCallback } from "./task-queue-DGQEOk1A.js";
25
- import { t as processConversationWork } from "./worker-xeJLxYwm.js";
26
- import { t as bindSpawnAgent } from "./spawn-DFdRspSD.js";
19
+ import { A as getAuthPausedConversationTurnId, B as GET$3, C as clearSlackPendingReactions, D as stopSlackThread, E as isSlackMessageStopped, F as getThreadStopDecision, I as renderSlackObjectCard, L as createVercelAttachmentStorage, M as THREAD_OPTOUT_ACK, N as startProcessingReaction, O as normalizeIncomingSlackThreadId, P as parseContent, S as buildSlackInboundMessage, T as verifySlackSignature, _ as readViewerAutomationSummary, a as recordWebConversationActivity, c as createProductionSlackWebhookServices, k as withNormalizedThreadId, l as getProductionSlackAdapter, n as conversationTurnIdForMessage, o as webActorFromEmail, s as createProductionConversationWorkOptions, t as appendAndEnqueueWebMessage, w as runWithSlackInstallation, x as recordSkippedConversationMessage, z as enqueueAgentDispatch } from "./web-input-C56ivZuH.js";
20
+ import { O as recordAutomationExecution, _ as markDispatchFailed, a as confirmDispatchMailboxAppend, d as getPluginDispatchProjection, f as isTerminalDispatchStatus, l as getDispatchRecord, o as createOrGetDispatch, p as listPendingDispatchMailboxAppends, s as getDispatchConversationId, t as processPluginTask } from "./task-runner-Bh8XONXT.js";
21
+ import { c as listPendingAgentInvocationMailboxAppends, r as enqueueAgentInvocation } from "./work-DJ7hb9Ul.js";
22
+ import { s as coerceThreadConversationState } from "./thread-state-BnQln4jO.js";
23
+ import { a as GET$4, i as publishAppHomeView, r as GET$5, t as receiveLocalOAuthCredential } from "./credential-sync-D9yGg3q5.js";
24
+ import { a as registerVercelPluginTaskDevConsumer, n as createVercelPluginTaskCallback, s as queueCallback } from "./task-queue-BAiZ7_CF.js";
25
+ import { t as processConversationWork } from "./worker-DiiV8Lba.js";
26
+ import { t as bindSpawnAgent } from "./spawn-CJhmyE4E.js";
27
27
  import { createRequire } from "node:module";
28
28
  import { Hono } from "hono";
29
29
  import { z } from "zod";
@@ -258,7 +258,7 @@ function getNextRunAtMs(task, scheduledForMs, afterMs = scheduledForMs) {
258
258
  */
259
259
  const localDateSchema = z.string().regex(/^\d{4}-\d{2}-\d{2}$/, "Use a local date in YYYY-MM-DD format.");
260
260
  const localTimeSchema = z.string().regex(/^([01]\d|2[0-3]):[0-5]\d$/, "Use local time in HH:MM format.");
261
- const timezoneSchema = z.string().min(1).max(80).describe("IANA timezone, for example America/Los_Angeles. Omit or use null for the scheduler default.").nullable().optional();
261
+ const timezoneSchema = z.string().min(1).max(80).describe("IANA timezone the user asked for, for example America/New_York. Omit or use null to use the creator's timezone on create, or to keep the saved timezone on update. Do not guess it from office locations.").nullable().optional();
262
262
  /** Weekday names in `Date#getDay` order. */
263
263
  const weekdaySchema = z.enum([
264
264
  "sunday",
@@ -367,6 +367,7 @@ function localDateAt(timestampMs, timezone) {
367
367
  parts.day
368
368
  ].map((value, index) => index === 0 ? String(value).padStart(4, "0") : String(value).padStart(2, "0")).join("-");
369
369
  }
370
+ /** Whether the runtime accepts this IANA timezone name. */
370
371
  function isValidTimeZone(timezone) {
371
372
  try {
372
373
  new Intl.DateTimeFormat("en-US", { timeZone: timezone }).format();
@@ -889,4 +890,4 @@ const automationEventCatalogSchema = z.array(pluginEventTypeSchema.safeExtend({
889
890
  const automationScheduleIntentSchema = scheduleIntentSchema;
890
891
  const automationSchedulePreviewSchema = scheduledAutomationSchema.pick({ schedule: true }).extend({ nextRunAtMs: z.number() }).strict();
891
892
  //#endregion
892
- export { eventAutomationSchema as A, eventAutomationSummarySchema as C, scheduledRunSchema as D, scheduledAutomationSchema as E, getFirstRunAtMs as F, getNextRunAtMs as I, getZonedDateTimeParts as L, compileScheduleIntent as M, scheduleIntentSchema as N, automationInstructionToolSchema as O, weekdaySchema as P, taskOutcomeInputSchema as R, automationVersionSchema as S, SCHEDULED_AUTOMATION_SYSTEM_ACTOR as T, automationSummarySchema as _, automationExecutionSchema as a, automationVersionListSchema as b, automationLifecycleSchema as c, automationParamsSchema as d, automationRunListSchema as f, automationSchedulePreviewSchema as g, automationScheduleIntentSchema as h, automationExecutionListSchema as i, ScheduleIntentError as j, automationTitleSchema as k, automationListQuerySchema as l, automationRunWindowsSchema as m, automationEditSchema as n, automationExecutionStatusDaySchema as o, automationRunSchema as p, automationEventCatalogSchema as r, automationExecutionStatusSchema as s, automationEditErrorSchema as t, automationListSchema as u, automationUpdateSchema as v, scheduledAutomationSummarySchema as w, automationVersionParamsSchema as x, automationVersionActivateSchema as y };
893
+ export { eventAutomationSchema as A, eventAutomationSummarySchema as C, scheduledRunSchema as D, scheduledAutomationSchema as E, weekdaySchema as F, getFirstRunAtMs as I, getNextRunAtMs as L, compileScheduleIntent as M, isValidTimeZone as N, automationInstructionToolSchema as O, scheduleIntentSchema as P, getZonedDateTimeParts as R, automationVersionSchema as S, SCHEDULED_AUTOMATION_SYSTEM_ACTOR as T, automationSummarySchema as _, automationExecutionSchema as a, automationVersionListSchema as b, automationLifecycleSchema as c, automationParamsSchema as d, automationRunListSchema as f, automationSchedulePreviewSchema as g, automationScheduleIntentSchema as h, automationExecutionListSchema as i, ScheduleIntentError as j, automationTitleSchema as k, automationListQuerySchema as l, automationRunWindowsSchema as m, automationEditSchema as n, automationExecutionStatusDaySchema as o, automationRunSchema as p, automationEventCatalogSchema as r, automationExecutionStatusSchema as s, automationEditErrorSchema as t, automationListSchema as u, automationUpdateSchema as v, scheduledAutomationSummarySchema as w, automationVersionParamsSchema as x, automationVersionActivateSchema as y, taskOutcomeInputSchema as z };
@@ -1,4 +1,4 @@
1
- import { r as completeObject } from "./client-Ch9Hg9NU.js";
1
+ import { r as completeObject } from "./client-CPMbTmJU.js";
2
2
  import { r as defaultModelId } from "./model-profile-BwU8mqwD.js";
3
3
  import { B as parseBriefInput, I as briefCodeChangeSchema, d as conversationDetailReportSchema, p as conversationEventPageSchema } from "./conversation-9Fxa1Zbq.js";
4
4
  import { n as briefEntriesFromReportEvents, s as generateBrief, t as BRIEF_PROMPT } from "./prompt-Ctwy6hSI.js";
@@ -269,7 +269,7 @@ async function parseRunOptions(argv) {
269
269
  * `DATABASE_URL` at import, and `briefs pull` must work with only a token.
270
270
  */
271
271
  async function configuredDefaultModelId() {
272
- const { botConfig } = await import("./config-JR9wke1W.js").then((n) => n.r);
272
+ const { botConfig } = await import("./config-CxpPG6nR.js").then((n) => n.r);
273
273
  return defaultModelId(botConfig);
274
274
  }
275
275
  function apiUrl(baseUrl, pathname) {
@@ -1,5 +1,5 @@
1
1
  import { t as __exportAll } from "./rolldown-runtime-B4FMCO8f.js";
2
- import { t as createPluginCatalogRuntime } from "./registry-CXNv9fDX.js";
2
+ import { t as createPluginCatalogRuntime } from "./registry-zfTzTHe6.js";
3
3
  //#region src/chat/plugins/catalog-runtime.ts
4
4
  var catalog_runtime_exports = /* @__PURE__ */ __exportAll({ pluginCatalogRuntime: () => pluginCatalogRuntime });
5
5
  const pluginCatalogRuntime = createPluginCatalogRuntime();
@@ -1,10 +1,10 @@
1
- import { d as unwrapCurrentInstruction, f as escapeXml, i as completeText, o as resolveGatewayModel } from "./client-Ch9Hg9NU.js";
2
- import { d as logException, o as getActiveTraceId, p as logWarn, t as buildTurnFailureResponse, v as setSpanAttributes } from "./logging-B4sKwmCG.js";
3
- import { n as botConfig } from "./config-JR9wke1W.js";
1
+ import { d as unwrapCurrentInstruction, f as escapeXml, i as completeText, o as resolveGatewayModel } from "./client-CPMbTmJU.js";
2
+ import { d as logException, o as getActiveTraceId, p as logWarn, t as buildTurnFailureResponse, v as setSpanAttributes } from "./logging-rB_ngE_R.js";
3
+ import { n as botConfig } from "./config-CxpPG6nR.js";
4
4
  import { b as parseSlackMessageTs, f as toStoredSlackActor } from "./context-0Et9iVSB.js";
5
- import { Jt as agentsInstructionsUpdatedEvent, Qt as getConversationEventStore, Xt as authenticationUnlinkedEvent, Yt as authenticationLinkedEvent, en as getConversationStore, in as withConversationEventLock, ln as addAgentTurnUsage, nn as getSqlExecutor, qt as JUNIOR_NATIVE_EVENT_NAMESPACE, rn as createSqlConversationEventStore, sn as bindProviderConversation } from "./agent-hooks-Da_H0jHv.js";
5
+ import { Jt as agentsInstructionsUpdatedEvent, Qt as getConversationEventStore, Xt as authenticationUnlinkedEvent, Yt as authenticationLinkedEvent, en as getConversationStore, in as withConversationEventLock, ln as addAgentTurnUsage, nn as getSqlExecutor, qt as JUNIOR_NATIVE_EVENT_NAMESPACE, rn as createSqlConversationEventStore, sn as bindProviderConversation } from "./agent-hooks-otHGbhBx.js";
6
6
  import { H as messageCardRef, J as agentHistoryItemSchema, it as instructionProvenanceFor, nt as contextProvenance, rt as instructionActors } from "./conversation-9Fxa1Zbq.js";
7
- import { D as fenceLock, O as withLock, T as MUTATION_LOCK_TTL_MS, k as sleep, w as getStateAdapter } from "./profile-BamYnmhO.js";
7
+ import { D as fenceLock, O as withLock, T as MUTATION_LOCK_TTL_MS, k as sleep, w as getStateAdapter } from "./profile-D6apIG2N.js";
8
8
  import { isDeepStrictEqual } from "node:util";
9
9
  import { z } from "zod";
10
10
  import { createHash } from "node:crypto";