@sentry/junior 0.187.0 → 0.189.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{agent-hooks-XVAE2554.js → agent-hooks-6QRYH6PX.js} +11 -11
- package/dist/api/acp/conversations.d.ts +2 -2
- package/dist/api/conversations/list.d.ts +7 -0
- package/dist/api/people/shared.d.ts +54 -0
- package/dist/api.js +41 -52
- package/dist/app.d.ts +1 -1
- package/dist/app.js +1001 -338
- package/dist/{catalog-runtime-DWFAC562.js → catalog-runtime-IETJLJFG.js} +4 -4
- package/dist/chat/agent/resume.d.ts +0 -2
- package/dist/chat/agent/types.d.ts +9 -14
- package/dist/chat/agent-dispatch/work.d.ts +1 -10
- package/dist/chat/agent-invocations/spawn.d.ts +1 -1
- package/dist/chat/agent-invocations/types.d.ts +296 -24
- package/dist/chat/app/conversation-work.d.ts +16 -8
- package/dist/chat/conversation-privacy.d.ts +7 -7
- package/dist/chat/conversations/destination.d.ts +12 -0
- package/dist/chat/conversations/location.d.ts +3 -8
- package/dist/chat/conversations/projection.d.ts +2 -2
- package/dist/chat/conversations/sql/location.d.ts +13 -4
- package/dist/chat/{api-turns → conversations}/stop.d.ts +2 -2
- package/dist/chat/conversations/store.d.ts +8 -11
- package/dist/chat/conversations/structured-events.d.ts +1 -1
- package/dist/chat/{api-turns/authorization.d.ts → conversations/web-authorization.d.ts} +1 -0
- package/dist/chat/conversations/web-input.d.ts +98 -0
- package/dist/chat/conversations/web-mailbox.d.ts +12 -0
- package/dist/chat/providers/slack/runtime.d.ts +1 -0
- package/dist/chat/providers/slack/system-turn.d.ts +8 -0
- package/dist/chat/resource-events/actor.d.ts +13 -12
- package/dist/chat/resource-events/notification.d.ts +1 -1
- package/dist/chat/services/guardian-action-policy.d.ts +1 -1
- package/dist/chat/services/turn-session-routing.d.ts +5 -5
- package/dist/chat/task-execution/assistant-message.d.ts +32 -0
- package/dist/chat/task-execution/conversation-turn.d.ts +8 -0
- package/dist/chat/{api-turns → task-execution}/mailbox-input.d.ts +1 -2
- package/dist/chat/task-execution/mailbox-turn.d.ts +42 -0
- package/dist/chat/task-execution/paused-turn.d.ts +1 -1
- package/dist/chat/task-execution/slack-work.d.ts +0 -2
- package/dist/{chunk-WL3R2KTS.js → chunk-4RHJ3CXR.js} +90 -289
- package/dist/{chunk-U6ZQHRIP.js → chunk-5CXCGDIL.js} +1 -1
- package/dist/{chunk-HXR3FHTE.js → chunk-5VWAY27R.js} +7 -3
- package/dist/{chunk-D3GDGREI.js → chunk-6AUR6PWR.js} +3 -3
- package/dist/{chunk-EIWYZXSM.js → chunk-7R5JRPCY.js} +8 -6
- package/dist/{chunk-WRDW3A3D.js → chunk-AC7MDOJW.js} +5 -7
- package/dist/{chunk-URZ7UD4P.js → chunk-BYBSI5TI.js} +2 -2
- package/dist/{chunk-MUPPP7A7.js → chunk-CMWIMFM6.js} +4 -182
- package/dist/{chunk-WKIS4VRK.js → chunk-CUYFCI4G.js} +70 -39
- package/dist/chunk-DA2KGZZI.js +13 -0
- package/dist/{chunk-Q6OCUQ7W.js → chunk-DYXVAO2E.js} +1 -1
- package/dist/{chunk-QH3I7ZOK.js → chunk-E3PDZPGV.js} +1 -1
- package/dist/{chunk-NU775DLU.js → chunk-GP32KD2J.js} +4 -12
- package/dist/{chunk-STF4GSK4.js → chunk-KN32OWL2.js} +5 -5
- package/dist/chunk-LHKZKAZ4.js +285 -0
- package/dist/{chunk-D5BWM37G.js → chunk-MFSET7Q7.js} +51 -341
- package/dist/{chunk-DUE4EUNL.js → chunk-MI6ZBDTS.js} +6 -6
- package/dist/{chunk-27T5HZHO.js → chunk-MRXMFB4L.js} +6 -87
- package/dist/{chunk-4A2R3AQB.js → chunk-MVPLEPSI.js} +1 -1
- package/dist/{chunk-7LRRVMPH.js → chunk-NY2F7BZA.js} +1 -1
- package/dist/chunk-O35GZCKL.js +311 -0
- package/dist/{chunk-U3KMII5Y.js → chunk-OEIITG5F.js} +1 -1
- package/dist/{chunk-6FKNNUSN.js → chunk-PCPSX4ES.js} +209 -7
- package/dist/{chunk-6YCIYOVA.js → chunk-PY3EIEAF.js} +1 -1
- package/dist/{chunk-U5POFCKM.js → chunk-QNIOBNOY.js} +284 -123
- package/dist/{chunk-JCRXXEMC.js → chunk-S3SGZUOI.js} +1 -1
- package/dist/chunk-SR6OMO5C.js +703 -0
- package/dist/{chunk-TQHCZXN7.js → chunk-UCWO5MKP.js} +7 -7
- package/dist/{chunk-ITLYUKGZ.js → chunk-VKQWU4PO.js} +2 -2
- package/dist/{chunk-JZPDYKRG.js → chunk-WDHPN2GH.js} +3 -3
- package/dist/{chunk-P2VU5JNH.js → chunk-WMUAKAIF.js} +42 -42
- package/dist/{chunk-NIKLTFBP.js → chunk-WN6VLHOU.js} +12 -5
- package/dist/{chunk-VC343WHM.js → chunk-WWYUYKKV.js} +1 -1
- package/dist/{chunk-OM4SFFJK.js → chunk-WYDF6PGK.js} +3 -3
- package/dist/{chunk-KRYJ5VOD.js → chunk-YNZPOFF3.js} +16 -21
- package/dist/{chunk-Z6OHCDXP.js → chunk-YYSEH2WC.js} +2 -2
- package/dist/{chunk-BITZUBPJ.js → chunk-YYZNESC3.js} +8 -8
- package/dist/{chunk-2VUDJGB6.js → chunk-ZUPDSJUE.js} +2 -5
- package/dist/{chunk-X5SXFVZT.js → chunk-ZV6PFUA4.js} +1 -1
- package/dist/cli/chat.js +34 -33
- package/dist/cli/check.js +5 -5
- package/dist/cli/plugins.js +12 -12
- package/dist/cli/snapshot-create.js +9 -9
- package/dist/cli/upgrade.js +6 -6
- package/dist/db/schema/conversations.d.ts +62 -0
- package/dist/db/schema.d.ts +31 -0
- package/dist/{db-FBHAWVXU.js → db-LPJKR2EO.js} +6 -6
- package/dist/instrumentation.js +3 -3
- package/dist/nitro.js +6 -6
- package/dist/{oauth-callback-server-5HS5ULC6.js → oauth-callback-server-DMXF4TTQ.js} +30 -28
- package/dist/{runner-46W6NV6B.js → runner-L5DPVYCN.js} +24 -20
- package/dist/{skills-TG3QC4B6.js → skills-NXG3LBCK.js} +5 -5
- package/dist/spawn-VRUIGKWW.js +42 -0
- package/dist/task-runner-7YTBSPXW.js +36 -0
- package/dist/{validation-GMRIDBC5.js → validation-CH36LTOS.js} +5 -5
- package/dist/version.js +1 -1
- package/dist/{work-W4ULBJTU.js → work-HBC5Y5VZ.js} +22 -21
- package/dist/{worker-M6NVACS2.js → worker-5RDZHLXH.js} +10 -10
- package/migrations/0037_conversation_location.sql +23 -0
- package/migrations/meta/0037_snapshot.json +3192 -0
- package/migrations/meta/_journal.json +7 -0
- package/package.json +4 -4
- package/dist/chat/api-turns/assistant-message.d.ts +0 -12
- package/dist/chat/api-turns/cancellation.d.ts +0 -24
- package/dist/chat/api-turns/routing.d.ts +0 -51
- package/dist/chat/api-turns/work.d.ts +0 -99
- package/dist/chat/task-execution/slack-resource-event.d.ts +0 -47
- package/dist/chunk-4YD3DET6.js +0 -1503
- package/dist/chunk-6FGN7ZEG.js +0 -221
- package/dist/spawn-Y6YWBIJS.js +0 -41
- package/dist/task-runner-YSGBPN4U.js +0 -34
|
@@ -13,26 +13,26 @@ import {
|
|
|
13
13
|
getPlugins,
|
|
14
14
|
setPlugins,
|
|
15
15
|
validatePlugins
|
|
16
|
-
} from "./chunk-
|
|
16
|
+
} from "./chunk-MI6ZBDTS.js";
|
|
17
17
|
import "./chunk-3Y47VMHV.js";
|
|
18
|
-
import "./chunk-
|
|
19
|
-
import "./chunk-
|
|
20
|
-
import "./chunk-
|
|
21
|
-
import "./chunk-
|
|
18
|
+
import "./chunk-CUYFCI4G.js";
|
|
19
|
+
import "./chunk-5VWAY27R.js";
|
|
20
|
+
import "./chunk-WDHPN2GH.js";
|
|
21
|
+
import "./chunk-5CXCGDIL.js";
|
|
22
22
|
import "./chunk-GFBR4S3Q.js";
|
|
23
23
|
import "./chunk-VFUK3X5B.js";
|
|
24
|
-
import "./chunk-
|
|
24
|
+
import "./chunk-BYBSI5TI.js";
|
|
25
25
|
import "./chunk-D4YV5TDV.js";
|
|
26
|
-
import "./chunk-
|
|
27
|
-
import "./chunk-
|
|
28
|
-
import "./chunk-
|
|
26
|
+
import "./chunk-DYXVAO2E.js";
|
|
27
|
+
import "./chunk-E3PDZPGV.js";
|
|
28
|
+
import "./chunk-ZV6PFUA4.js";
|
|
29
29
|
import "./chunk-CEMMLV5L.js";
|
|
30
30
|
import "./chunk-N7TMSOZH.js";
|
|
31
31
|
import "./chunk-DWPN6SCH.js";
|
|
32
32
|
import "./chunk-TXKUKMVO.js";
|
|
33
|
-
import "./chunk-
|
|
33
|
+
import "./chunk-PY3EIEAF.js";
|
|
34
34
|
import "./chunk-PEQXYSSE.js";
|
|
35
|
-
import "./chunk-
|
|
35
|
+
import "./chunk-NY2F7BZA.js";
|
|
36
36
|
export {
|
|
37
37
|
PluginHookDeniedError,
|
|
38
38
|
applyPluginFormatMarkdown,
|
|
@@ -9,7 +9,7 @@ type ConversationMessage = {
|
|
|
9
9
|
role: "assistant" | "user";
|
|
10
10
|
text: string;
|
|
11
11
|
};
|
|
12
|
-
type
|
|
12
|
+
type PromptResult = {
|
|
13
13
|
afterCursor: number;
|
|
14
14
|
messageId: string;
|
|
15
15
|
status: "accepted";
|
|
@@ -50,7 +50,7 @@ export type AcpConversations = {
|
|
|
50
50
|
idempotencyKey: string;
|
|
51
51
|
text: string;
|
|
52
52
|
user: User;
|
|
53
|
-
}): Promise<
|
|
53
|
+
}): Promise<PromptResult>;
|
|
54
54
|
readMessages(conversationId: string): Promise<ConversationMessage[]>;
|
|
55
55
|
readTurn(args: {
|
|
56
56
|
afterCursor: number;
|
|
@@ -18,6 +18,13 @@ declare function conversationRows(db: JuniorDatabase, limit: number, status: "ac
|
|
|
18
18
|
originType: string | null;
|
|
19
19
|
originId: string | null;
|
|
20
20
|
originRunId: string | null;
|
|
21
|
+
location: {
|
|
22
|
+
id: string;
|
|
23
|
+
provider: "slack";
|
|
24
|
+
teamId: string;
|
|
25
|
+
channelId: string;
|
|
26
|
+
threadTs?: string | undefined;
|
|
27
|
+
} | null;
|
|
21
28
|
destinationId: string | null;
|
|
22
29
|
destination: {
|
|
23
30
|
platform: "slack";
|
|
@@ -128,6 +128,37 @@ export declare const peopleTreeConversation: import("drizzle-orm/pg-core").PgTab
|
|
|
128
128
|
identity: undefined;
|
|
129
129
|
generated: undefined;
|
|
130
130
|
}, {}, {}>;
|
|
131
|
+
location: import("drizzle-orm/pg-core").PgColumn<{
|
|
132
|
+
name: "location_json";
|
|
133
|
+
tableName: "junior_conversations";
|
|
134
|
+
dataType: "json";
|
|
135
|
+
columnType: "PgJsonb";
|
|
136
|
+
data: {
|
|
137
|
+
id: string;
|
|
138
|
+
provider: "slack";
|
|
139
|
+
teamId: string;
|
|
140
|
+
channelId: string;
|
|
141
|
+
threadTs?: string | undefined;
|
|
142
|
+
};
|
|
143
|
+
driverParam: unknown;
|
|
144
|
+
notNull: false;
|
|
145
|
+
hasDefault: false;
|
|
146
|
+
isPrimaryKey: false;
|
|
147
|
+
isAutoincrement: false;
|
|
148
|
+
hasRuntimeDefault: false;
|
|
149
|
+
enumValues: undefined;
|
|
150
|
+
baseColumn: never;
|
|
151
|
+
identity: undefined;
|
|
152
|
+
generated: undefined;
|
|
153
|
+
}, {}, {
|
|
154
|
+
$type: {
|
|
155
|
+
id: string;
|
|
156
|
+
provider: "slack";
|
|
157
|
+
teamId: string;
|
|
158
|
+
channelId: string;
|
|
159
|
+
threadTs?: string | undefined;
|
|
160
|
+
};
|
|
161
|
+
}>;
|
|
131
162
|
destinationId: import("drizzle-orm/pg-core").PgColumn<{
|
|
132
163
|
name: "destination_id";
|
|
133
164
|
tableName: "junior_conversations";
|
|
@@ -771,6 +802,29 @@ export declare const peopleTreeConversation: import("drizzle-orm/pg-core").PgTab
|
|
|
771
802
|
identity: undefined;
|
|
772
803
|
generated: undefined;
|
|
773
804
|
}, {}, {}>;
|
|
805
|
+
location: import("drizzle-orm/pg-core").PgColumn<{
|
|
806
|
+
name: "location_json";
|
|
807
|
+
tableName: "people_tree_conversation";
|
|
808
|
+
dataType: "json";
|
|
809
|
+
columnType: "PgJsonb";
|
|
810
|
+
data: {
|
|
811
|
+
id: string;
|
|
812
|
+
provider: "slack";
|
|
813
|
+
teamId: string;
|
|
814
|
+
channelId: string;
|
|
815
|
+
threadTs?: string | undefined;
|
|
816
|
+
};
|
|
817
|
+
driverParam: unknown;
|
|
818
|
+
notNull: false;
|
|
819
|
+
hasDefault: false;
|
|
820
|
+
isPrimaryKey: false;
|
|
821
|
+
isAutoincrement: false;
|
|
822
|
+
hasRuntimeDefault: false;
|
|
823
|
+
enumValues: undefined;
|
|
824
|
+
baseColumn: never;
|
|
825
|
+
identity: undefined;
|
|
826
|
+
generated: undefined;
|
|
827
|
+
}, {}, {}>;
|
|
774
828
|
destinationId: import("drizzle-orm/pg-core").PgColumn<{
|
|
775
829
|
name: "destination_id";
|
|
776
830
|
tableName: "people_tree_conversation";
|
package/dist/api.js
CHANGED
|
@@ -45,7 +45,7 @@ import {
|
|
|
45
45
|
workspaceSchema
|
|
46
46
|
} from "./chunk-PFAZSRGR.js";
|
|
47
47
|
import {
|
|
48
|
-
|
|
48
|
+
appendAndEnqueueWebMessage,
|
|
49
49
|
conversationArchiveTimes,
|
|
50
50
|
conversationArchivedForEmail,
|
|
51
51
|
conversationArchivedForUser,
|
|
@@ -53,23 +53,22 @@ import {
|
|
|
53
53
|
conversationHasParticipantUser,
|
|
54
54
|
conversationNotArchivedForEmail,
|
|
55
55
|
conversationNotArchivedForUser,
|
|
56
|
-
|
|
56
|
+
createAndEnqueueConversation,
|
|
57
57
|
createVercelAttachmentStorage,
|
|
58
58
|
formatSlackConversationRedactedLabel,
|
|
59
|
+
legacyWebMailboxMetadataSchema,
|
|
59
60
|
lookupSlackUser,
|
|
60
61
|
readConversationAccessFromSql,
|
|
61
62
|
readHealthReport,
|
|
62
63
|
resolveSlackConversationContextFromThreadId,
|
|
63
64
|
viewerConversationMembership,
|
|
64
65
|
webActorFromEmail
|
|
65
|
-
} from "./chunk-
|
|
66
|
+
} from "./chunk-SR6OMO5C.js";
|
|
66
67
|
import {
|
|
67
68
|
buildSentryConversationUrl,
|
|
68
69
|
buildSentryEventUrl,
|
|
69
70
|
getWebAuthorization
|
|
70
|
-
} from "./chunk-
|
|
71
|
-
import "./chunk-OM4SFFJK.js";
|
|
72
|
-
import "./chunk-EIWYZXSM.js";
|
|
71
|
+
} from "./chunk-VKQWU4PO.js";
|
|
73
72
|
import {
|
|
74
73
|
readTaskExecutionByConversationId,
|
|
75
74
|
readTaskExecutionDays,
|
|
@@ -77,9 +76,7 @@ import {
|
|
|
77
76
|
readTaskExecutionSummaries,
|
|
78
77
|
readTaskExecutions,
|
|
79
78
|
readTaskRuns
|
|
80
|
-
} from "./chunk-
|
|
81
|
-
import "./chunk-VC343WHM.js";
|
|
82
|
-
import "./chunk-27T5HZHO.js";
|
|
79
|
+
} from "./chunk-LHKZKAZ4.js";
|
|
83
80
|
import {
|
|
84
81
|
healthReportSchema,
|
|
85
82
|
pluginOperationalReportFeedSchema,
|
|
@@ -87,7 +84,6 @@ import {
|
|
|
87
84
|
runtimeInfoReportSchema,
|
|
88
85
|
skillReportsSchema
|
|
89
86
|
} from "./chunk-UTL3MHPC.js";
|
|
90
|
-
import "./chunk-STF4GSK4.js";
|
|
91
87
|
import {
|
|
92
88
|
deleteEventTask,
|
|
93
89
|
eventTaskBelongsToUser,
|
|
@@ -103,33 +99,30 @@ import {
|
|
|
103
99
|
readScheduledTask,
|
|
104
100
|
readStats,
|
|
105
101
|
saveScheduledTask
|
|
106
|
-
} from "./chunk-
|
|
102
|
+
} from "./chunk-CMWIMFM6.js";
|
|
107
103
|
import {
|
|
108
104
|
parseSlackThreadId
|
|
109
|
-
} from "./chunk-
|
|
110
|
-
import "./chunk-6FGN7ZEG.js";
|
|
105
|
+
} from "./chunk-MVPLEPSI.js";
|
|
111
106
|
import {
|
|
112
107
|
cancelHumanFacingPendingMessages,
|
|
113
108
|
getConversation
|
|
114
|
-
} from "./chunk-
|
|
115
|
-
import "./chunk-
|
|
109
|
+
} from "./chunk-WN6VLHOU.js";
|
|
110
|
+
import "./chunk-DA2KGZZI.js";
|
|
116
111
|
import {
|
|
117
112
|
agentTurnUsageSchema,
|
|
118
113
|
fallbackShortTitle,
|
|
119
114
|
hasAgentTurnUsage,
|
|
120
115
|
renderJuniorNativeConversationEvent
|
|
121
|
-
} from "./chunk-
|
|
122
|
-
import "./chunk-2LYHWMR4.js";
|
|
116
|
+
} from "./chunk-O35GZCKL.js";
|
|
123
117
|
import {
|
|
124
118
|
getCachedSnapshot
|
|
125
|
-
} from "./chunk-
|
|
119
|
+
} from "./chunk-6AUR6PWR.js";
|
|
126
120
|
import "./chunk-PDO5BLNM.js";
|
|
127
121
|
import {
|
|
128
122
|
getVercelConversationWorkQueue
|
|
129
123
|
} from "./chunk-DKIJ2RP5.js";
|
|
130
124
|
import "./chunk-JAL3CH4G.js";
|
|
131
125
|
import "./chunk-7H2VZTWN.js";
|
|
132
|
-
import "./chunk-JCRXXEMC.js";
|
|
133
126
|
import {
|
|
134
127
|
SANDBOX_RUNTIME,
|
|
135
128
|
WorkspaceValidationError,
|
|
@@ -149,7 +142,7 @@ import {
|
|
|
149
142
|
updateWorkspace,
|
|
150
143
|
withSlackRetries,
|
|
151
144
|
workspaceRepoCheckoutPath
|
|
152
|
-
} from "./chunk-
|
|
145
|
+
} from "./chunk-MI6ZBDTS.js";
|
|
153
146
|
import "./chunk-3Y47VMHV.js";
|
|
154
147
|
import {
|
|
155
148
|
getConversationStore,
|
|
@@ -158,7 +151,7 @@ import {
|
|
|
158
151
|
locationFromRow,
|
|
159
152
|
parseSessionSource,
|
|
160
153
|
resolveRootConversationId
|
|
161
|
-
} from "./chunk-
|
|
154
|
+
} from "./chunk-CUYFCI4G.js";
|
|
162
155
|
import {
|
|
163
156
|
conversationReadColumns,
|
|
164
157
|
juniorApiTokens,
|
|
@@ -170,23 +163,23 @@ import {
|
|
|
170
163
|
juniorIdentities,
|
|
171
164
|
juniorSchedulerTasks,
|
|
172
165
|
juniorUsers
|
|
173
|
-
} from "./chunk-
|
|
166
|
+
} from "./chunk-5VWAY27R.js";
|
|
174
167
|
import {
|
|
175
168
|
create,
|
|
176
169
|
hash
|
|
177
|
-
} from "./chunk-
|
|
178
|
-
import "./chunk-
|
|
170
|
+
} from "./chunk-WDHPN2GH.js";
|
|
171
|
+
import "./chunk-5CXCGDIL.js";
|
|
179
172
|
import {
|
|
180
173
|
decodeStoredConversationEvent
|
|
181
174
|
} from "./chunk-GFBR4S3Q.js";
|
|
182
175
|
import {
|
|
183
176
|
juniorDestinations
|
|
184
177
|
} from "./chunk-VFUK3X5B.js";
|
|
185
|
-
import "./chunk-
|
|
178
|
+
import "./chunk-BYBSI5TI.js";
|
|
186
179
|
import "./chunk-D4YV5TDV.js";
|
|
187
|
-
import "./chunk-
|
|
188
|
-
import "./chunk-
|
|
189
|
-
import "./chunk-
|
|
180
|
+
import "./chunk-DYXVAO2E.js";
|
|
181
|
+
import "./chunk-E3PDZPGV.js";
|
|
182
|
+
import "./chunk-ZV6PFUA4.js";
|
|
190
183
|
import "./chunk-CEMMLV5L.js";
|
|
191
184
|
import {
|
|
192
185
|
parseSlackChannelId,
|
|
@@ -198,9 +191,9 @@ import "./chunk-TXKUKMVO.js";
|
|
|
198
191
|
import {
|
|
199
192
|
logException,
|
|
200
193
|
logWarn
|
|
201
|
-
} from "./chunk-
|
|
194
|
+
} from "./chunk-PY3EIEAF.js";
|
|
202
195
|
import "./chunk-PEQXYSSE.js";
|
|
203
|
-
import "./chunk-
|
|
196
|
+
import "./chunk-NY2F7BZA.js";
|
|
204
197
|
|
|
205
198
|
// src/api.ts
|
|
206
199
|
import { Hono as Hono9 } from "hono";
|
|
@@ -392,7 +385,7 @@ function actorFromViewer(viewer) {
|
|
|
392
385
|
}
|
|
393
386
|
async function createConversationForViewer(viewer, body) {
|
|
394
387
|
try {
|
|
395
|
-
return await
|
|
388
|
+
return await createAndEnqueueConversation(
|
|
396
389
|
{
|
|
397
390
|
actor: actorFromViewer(viewer),
|
|
398
391
|
idempotencyKey: body.idempotencyKey,
|
|
@@ -416,9 +409,9 @@ async function appendConversationMessageForViewer(viewer, conversationId, body)
|
|
|
416
409
|
throwApiError(404, "Conversation not found.");
|
|
417
410
|
}
|
|
418
411
|
const destinationPlatform = conversation.destination?.platform;
|
|
419
|
-
const
|
|
420
|
-
if (!
|
|
421
|
-
throwApiError(409, "Conversation does not accept
|
|
412
|
+
const acceptsWebMessages = destinationPlatform === "local" && conversationId.startsWith("local:web:") || destinationPlatform === "slack";
|
|
413
|
+
if (!acceptsWebMessages) {
|
|
414
|
+
throwApiError(409, "Conversation does not accept web messages.");
|
|
422
415
|
}
|
|
423
416
|
const access = await readConversationAccessFromSql(
|
|
424
417
|
getDb(),
|
|
@@ -429,7 +422,7 @@ async function appendConversationMessageForViewer(viewer, conversationId, body)
|
|
|
429
422
|
throwApiError(403, "Only conversation participants can add messages.");
|
|
430
423
|
}
|
|
431
424
|
try {
|
|
432
|
-
return await
|
|
425
|
+
return await appendAndEnqueueWebMessage(
|
|
433
426
|
{
|
|
434
427
|
actor: actorFromViewer(viewer),
|
|
435
428
|
conversationId,
|
|
@@ -1873,7 +1866,11 @@ function conversationFromRow(row) {
|
|
|
1873
1866
|
...row.identityHandle ? { slackUserName: row.identityHandle } : void 0,
|
|
1874
1867
|
...row.identityTenantId ? { teamId: row.identityTenantId } : void 0
|
|
1875
1868
|
} : void 0;
|
|
1876
|
-
const location = locationFromRow(
|
|
1869
|
+
const location = locationFromRow(
|
|
1870
|
+
value.location,
|
|
1871
|
+
row.destination,
|
|
1872
|
+
sessionSource
|
|
1873
|
+
);
|
|
1877
1874
|
return {
|
|
1878
1875
|
schemaVersion: 1,
|
|
1879
1876
|
conversationId: value.conversationId,
|
|
@@ -2780,14 +2777,6 @@ async function cancelConversationPendingMessagesForViewer(viewer, conversationId
|
|
|
2780
2777
|
|
|
2781
2778
|
// src/api/conversations/pending-messages.ts
|
|
2782
2779
|
import { z as z4 } from "zod";
|
|
2783
|
-
var apiTurnMailboxMetadataSchema = z4.object({
|
|
2784
|
-
authorEmail: z4.string().email(),
|
|
2785
|
-
authorFullName: z4.string().min(1).optional(),
|
|
2786
|
-
authorUserId: z4.string().min(1),
|
|
2787
|
-
authorUserName: z4.string().min(1).optional(),
|
|
2788
|
-
kind: z4.literal("api_turn"),
|
|
2789
|
-
messageId: z4.string().min(1)
|
|
2790
|
-
}).strict();
|
|
2791
2780
|
var slackMailboxAuthorSchema = z4.object({
|
|
2792
2781
|
userId: z4.string(),
|
|
2793
2782
|
userName: z4.string().optional(),
|
|
@@ -2805,7 +2794,7 @@ var slackMailboxMetadataSchema = z4.object({
|
|
|
2805
2794
|
function isoFromMs(value) {
|
|
2806
2795
|
return new Date(value).toISOString();
|
|
2807
2796
|
}
|
|
2808
|
-
function
|
|
2797
|
+
function actorIdentityFromWebMetadata(metadata2) {
|
|
2809
2798
|
return {
|
|
2810
2799
|
email: metadata2.authorEmail.trim().toLowerCase(),
|
|
2811
2800
|
...metadata2.authorFullName ? { fullName: metadata2.authorFullName } : void 0
|
|
@@ -2828,7 +2817,7 @@ async function actorIdentityFromSlackMetadata(metadata2, teamId) {
|
|
|
2828
2817
|
}
|
|
2829
2818
|
async function projectPendingMessage(message2, canExposePayload) {
|
|
2830
2819
|
if (message2.source === "web") {
|
|
2831
|
-
const metadata2 =
|
|
2820
|
+
const metadata2 = legacyWebMailboxMetadataSchema.safeParse(
|
|
2832
2821
|
message2.input.metadata
|
|
2833
2822
|
);
|
|
2834
2823
|
if (!metadata2.success) return void 0;
|
|
@@ -2843,7 +2832,7 @@ async function projectPendingMessage(message2, canExposePayload) {
|
|
|
2843
2832
|
role: "user",
|
|
2844
2833
|
source: "web",
|
|
2845
2834
|
...canExposePayload ? {
|
|
2846
|
-
actorIdentity:
|
|
2835
|
+
actorIdentity: actorIdentityFromWebMetadata(metadata2.data),
|
|
2847
2836
|
text
|
|
2848
2837
|
} : { redacted: true }
|
|
2849
2838
|
};
|
|
@@ -4596,7 +4585,7 @@ async function readPeoplePluginReports(args) {
|
|
|
4596
4585
|
source: "plugins"
|
|
4597
4586
|
});
|
|
4598
4587
|
}
|
|
4599
|
-
const { getPluginProfileReports } = await import("./agent-hooks-
|
|
4588
|
+
const { getPluginProfileReports } = await import("./agent-hooks-6QRYH6PX.js");
|
|
4600
4589
|
return pluginOperationalReportFeedSchema.parse({
|
|
4601
4590
|
generatedAt: new Date(nowMs).toISOString(),
|
|
4602
4591
|
reports: await getPluginProfileReports({
|
|
@@ -5400,7 +5389,7 @@ function readDescriptionText(home) {
|
|
|
5400
5389
|
}
|
|
5401
5390
|
}
|
|
5402
5391
|
async function readSkillReports() {
|
|
5403
|
-
const { discoverSkills } = await import("./skills-
|
|
5392
|
+
const { discoverSkills } = await import("./skills-NXG3LBCK.js");
|
|
5404
5393
|
const skills = await discoverSkills();
|
|
5405
5394
|
return skillReportsSchema.parse(
|
|
5406
5395
|
skills.map((skill) => ({
|
|
@@ -5410,7 +5399,7 @@ async function readSkillReports() {
|
|
|
5410
5399
|
);
|
|
5411
5400
|
}
|
|
5412
5401
|
async function readPlugins() {
|
|
5413
|
-
const { pluginCatalogRuntime } = await import("./catalog-runtime-
|
|
5402
|
+
const { pluginCatalogRuntime } = await import("./catalog-runtime-IETJLJFG.js");
|
|
5414
5403
|
return pluginsSchema.parse(
|
|
5415
5404
|
pluginCatalogRuntime.getProviders().map((plugin) => ({
|
|
5416
5405
|
configKeys: plugin.manifest.configKeys ?? [],
|
|
@@ -5423,7 +5412,7 @@ async function readPlugins() {
|
|
|
5423
5412
|
async function readRuntimeInfoReport() {
|
|
5424
5413
|
const [{ homeDir }, { pluginCatalogRuntime }, plugins, skills] = await Promise.all([
|
|
5425
5414
|
import("./discovery-DWVDM7UK.js"),
|
|
5426
|
-
import("./catalog-runtime-
|
|
5415
|
+
import("./catalog-runtime-IETJLJFG.js"),
|
|
5427
5416
|
readPlugins(),
|
|
5428
5417
|
readSkillReports()
|
|
5429
5418
|
]);
|
|
@@ -5439,7 +5428,7 @@ async function readRuntimeInfoReport() {
|
|
|
5439
5428
|
}
|
|
5440
5429
|
async function readPluginOperationalReportFeed() {
|
|
5441
5430
|
const nowMs = Date.now();
|
|
5442
|
-
const { getPluginOperationalReports } = await import("./agent-hooks-
|
|
5431
|
+
const { getPluginOperationalReports } = await import("./agent-hooks-6QRYH6PX.js");
|
|
5443
5432
|
return pluginOperationalReportFeedSchema.parse({
|
|
5444
5433
|
source: "plugins",
|
|
5445
5434
|
generatedAt: new Date(nowMs).toISOString(),
|
package/dist/app.d.ts
CHANGED
|
@@ -62,7 +62,7 @@ export interface JuniorDashboardOptions {
|
|
|
62
62
|
componentGallery?: boolean;
|
|
63
63
|
/** Disable dashboard route mounting while preserving serializable config shape. */
|
|
64
64
|
disabled?: boolean;
|
|
65
|
-
/** Replace
|
|
65
|
+
/** Replace Conversation route responses with dashboard visual-QA fixtures. */
|
|
66
66
|
mockConversations?: boolean;
|
|
67
67
|
/** Browser session lifetime in seconds. */
|
|
68
68
|
sessionMaxAgeSeconds?: number;
|