@sentry/junior 0.146.0 → 0.148.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-SLJADYE5.js → agent-hooks-VAUYT6PD.js} +10 -10
- package/dist/api/conversations/access.d.ts +2 -1
- package/dist/api/conversations/archive.d.ts +3 -5
- package/dist/api/conversations/create.d.ts +6 -0
- package/dist/api/conversations/detail.d.ts +2 -295
- package/dist/api/conversations/event-list.d.ts +2 -192
- package/dist/api/conversations/list.d.ts +4 -66
- package/dist/api/conversations/routes.d.ts +1 -1
- package/dist/api/conversations/stats.d.ts +0 -54
- package/dist/api/http.d.ts +2 -6
- package/dist/api/locations/detail.d.ts +3 -111
- package/dist/api/locations/list.d.ts +0 -45
- package/dist/api/locations/query.d.ts +2 -1
- package/dist/api/locations/routes.d.ts +1 -1
- package/dist/api/people/list.d.ts +0 -29
- package/dist/api/people/profile.d.ts +2 -106
- package/dist/api/people/profile.query.d.ts +2 -1
- package/dist/api/people/routes.d.ts +1 -1
- package/dist/api/people/shared.d.ts +1 -1
- package/dist/api/people/spend.d.ts +3 -4
- package/dist/api/personal-tokens/routes.d.ts +2 -2
- package/dist/api/route.d.ts +8 -14
- package/dist/api/schema/conversation.d.ts +64 -29
- package/dist/api/schema/location.d.ts +4 -0
- package/dist/api/schema/person.d.ts +7 -3
- package/dist/api/schema.d.ts +2 -2
- package/dist/api/schema.js +7 -1
- package/dist/api/stats.d.ts +0 -13
- package/dist/api/validation.d.ts +7 -0
- package/dist/api/viewer.d.ts +3 -0
- package/dist/api.d.ts +2 -1
- package/dist/api.js +630 -564
- package/dist/app.js +369 -309
- package/dist/{catalog-runtime-RQIMSDPR.js → catalog-runtime-WADOZVTB.js} +5 -5
- package/dist/chat/actor.d.ts +4 -1
- package/dist/chat/agent/prompt.d.ts +0 -2
- package/dist/chat/agent/request.d.ts +4 -5
- package/dist/chat/agent/resume.d.ts +1 -0
- package/dist/chat/agent/sandbox.d.ts +2 -2
- package/dist/chat/agent/tools.d.ts +0 -2
- package/dist/chat/agent-dispatch/context.d.ts +2 -2
- package/dist/chat/agent-dispatch/types.d.ts +2 -2
- package/dist/chat/agent-invocations/types.d.ts +52 -0
- package/dist/chat/api-turns/work.d.ts +103 -0
- package/dist/chat/capabilities/jr-rpc-command.d.ts +2 -2
- package/dist/chat/configuration/service.d.ts +5 -2
- package/dist/chat/configuration/sql.d.ts +9 -0
- package/dist/chat/configuration/types.d.ts +17 -13
- package/dist/chat/conversations/history.d.ts +63 -0
- package/dist/chat/conversations/projection.d.ts +10 -0
- package/dist/chat/conversations/provenance.d.ts +6 -0
- package/dist/chat/conversations/sql/actor-identity.d.ts +19 -0
- package/dist/chat/conversations/store.d.ts +1 -1
- package/dist/chat/credentials/unlink-provider.d.ts +2 -1
- package/dist/chat/credentials/user-token-store.d.ts +2 -0
- package/dist/chat/event-tasks/tool-support.d.ts +2 -0
- package/dist/chat/identities/sql.d.ts +8 -0
- package/dist/chat/logging.d.ts +2 -0
- package/dist/chat/mcp/auth-store.d.ts +0 -2
- package/dist/chat/mcp/oauth.d.ts +0 -2
- package/dist/chat/oauth-flow.d.ts +3 -1
- package/dist/chat/pi/client.d.ts +2 -0
- package/dist/chat/plugins/credential-hooks.d.ts +2 -0
- package/dist/chat/prompt.d.ts +0 -2
- package/dist/chat/resource-events/notification.d.ts +2 -1
- package/dist/chat/resource-events/store.d.ts +1 -1
- package/dist/chat/runtime/delivered-turn-state.d.ts +1 -4
- package/dist/chat/runtime/reply-executor.d.ts +1 -1
- package/dist/chat/runtime/slack-runtime.d.ts +2 -1
- package/dist/chat/runtime/thread-state.d.ts +8 -11
- package/dist/chat/runtime/turn-input.d.ts +4 -2
- package/dist/chat/runtime/turn-preparation.d.ts +11 -4
- package/dist/chat/sandbox/command-result.d.ts +2 -0
- package/dist/chat/sandbox/egress/schemas.d.ts +6 -0
- package/dist/chat/scheduled-tasks/tool-support.d.ts +7 -5
- package/dist/chat/scheduled-tasks/tools/create.d.ts +4 -2
- package/dist/chat/scheduled-tasks/tools/delete.d.ts +4 -2
- package/dist/chat/scheduled-tasks/tools/list.d.ts +4 -2
- package/dist/chat/scheduled-tasks/tools/run-now.d.ts +4 -2
- package/dist/chat/scheduled-tasks/tools/update.d.ts +4 -2
- package/dist/chat/services/mcp-auth-orchestration.d.ts +0 -3
- package/dist/chat/services/plugin-auth-orchestration.d.ts +2 -1
- package/dist/chat/services/provider-default-config.d.ts +2 -2
- package/dist/chat/services/subscribed-decision.d.ts +3 -0
- package/dist/chat/services/subscribed-reply-policy.d.ts +1 -0
- package/dist/chat/services/turn-result.d.ts +0 -3
- package/dist/chat/services/turn-router.d.ts +3 -0
- package/dist/chat/slack/assistant-thread/lifecycle.d.ts +0 -1
- package/dist/chat/slack/assistant-thread/title.d.ts +0 -3
- package/dist/chat/slack/channel.d.ts +26 -0
- package/dist/chat/slack/dispatch-turn.d.ts +2 -1
- package/dist/chat/slack/timestamp-param.d.ts +0 -2
- package/dist/chat/slack/{tools → tool-support}/canvas/api.d.ts +1 -1
- package/dist/chat/slack/tool-support/canvas/context.d.ts +11 -0
- package/dist/chat/slack/tool-support/channel-access.d.ts +42 -0
- package/dist/chat/slack/tool-support/channel-target.d.ts +27 -0
- package/dist/chat/slack/{tools → tool-support}/list/api.d.ts +8 -1
- package/dist/chat/slack/tool-support/list/params.d.ts +5 -0
- package/dist/chat/slack/tools/canvas/create.d.ts +3 -1
- package/dist/chat/slack/tools/canvas/edit.d.ts +2 -0
- package/dist/chat/slack/tools/canvas/read.d.ts +2 -0
- package/dist/chat/slack/tools/canvas/write.d.ts +2 -0
- package/dist/chat/slack/tools/{user-lookup.d.ts → channel-join.d.ts} +6 -5
- package/dist/chat/slack/tools/channel-list-messages.d.ts +5 -2
- package/dist/chat/slack/tools/conversation-message-search.d.ts +4 -8
- package/dist/chat/slack/tools/list/add-items.d.ts +4 -1
- package/dist/chat/slack/tools/list/create.d.ts +2 -0
- package/dist/chat/slack/tools/list/get-items.d.ts +5 -3
- package/dist/chat/slack/tools/list/update-item.d.ts +5 -1
- package/dist/chat/slack/tools/message-add-reaction.d.ts +3 -1
- package/dist/chat/slack/tools/public-search.d.ts +65 -2
- package/dist/chat/slack/tools/send-files.d.ts +3 -1
- package/dist/chat/slack/tools/thread-read.d.ts +4 -5
- package/dist/chat/slack/vision-cache.d.ts +5 -0
- package/dist/chat/source.d.ts +2 -0
- package/dist/chat/state/conversation.d.ts +4 -5
- package/dist/chat/task-execution/checkpoint.d.ts +1 -0
- package/dist/chat/task-execution/state.d.ts +9 -4
- package/dist/chat/task-execution/store.d.ts +3 -2
- package/dist/chat/task-execution/turn-cursor.d.ts +2 -0
- package/dist/chat/task-execution/worker.d.ts +2 -0
- package/dist/chat/tasks/read.d.ts +1 -1
- package/dist/chat/tool-support/structured-result.d.ts +1 -0
- package/dist/chat/tool-support/timed-out-tool-result.d.ts +11 -0
- package/dist/chat/tools/create-event-task.d.ts +2 -0
- package/dist/chat/tools/delete-event-task.d.ts +2 -0
- package/dist/chat/tools/handoff/tool.d.ts +2 -0
- package/dist/chat/tools/list-event-tasks.d.ts +2 -0
- package/dist/chat/tools/list-resource-event-subscriptions.d.ts +2 -0
- package/dist/chat/tools/runtime/report-progress.d.ts +2 -0
- package/dist/chat/tools/runtime/spawn-agent.d.ts +2 -0
- package/dist/chat/tools/search-conversation-events.d.ts +3 -1
- package/dist/chat/tools/search-resource-event-types.d.ts +2 -0
- package/dist/chat/tools/search-tools.d.ts +2 -0
- package/dist/chat/tools/skill/load-skill.d.ts +2 -0
- package/dist/chat/tools/skill/search-mcp-tools.d.ts +2 -0
- package/dist/chat/tools/stop-watching-resources.d.ts +2 -0
- package/dist/chat/tools/system-time.d.ts +2 -0
- package/dist/chat/tools/types.d.ts +11 -10
- package/dist/chat/tools/update-event-task.d.ts +2 -0
- package/dist/chat/tools/user-lookup.d.ts +29 -0
- package/dist/chat/tools/watch-resource-events.d.ts +4 -2
- package/dist/chat/tools/web/fetch-tool.d.ts +2 -0
- package/dist/chat/tools/web/image-generate.d.ts +2 -0
- package/dist/chat/tools/web/search.d.ts +2 -0
- package/dist/{chunk-GYEKOX7N.js → chunk-2B3PT3V2.js} +1 -1
- package/dist/{chunk-JLMVCNXL.js → chunk-45LOR4PU.js} +22 -4
- package/dist/{chunk-FGHADGIC.js → chunk-4AQZYNHM.js} +2 -2
- package/dist/{chunk-W65V465O.js → chunk-4EA2SFK2.js} +66 -4
- package/dist/{chunk-MKRIZ4VG.js → chunk-4GXJUYJV.js} +4 -2
- package/dist/{chunk-F7REGDKO.js → chunk-55F4QU2V.js} +2 -1
- package/dist/{chunk-M6ZWP4RI.js → chunk-7OEIXFC3.js} +2 -2
- package/dist/{chunk-MCFIXAV5.js → chunk-D3WPMGEX.js} +55 -37
- package/dist/{chunk-AISNSNDV.js → chunk-D6YX4NNN.js} +22 -10
- package/dist/chunk-DUY5CDAM.js +36 -0
- package/dist/{chunk-B63BF443.js → chunk-EAI67NTM.js} +9 -1
- package/dist/{chunk-FEKQHPVA.js → chunk-EINWQFXI.js} +9 -8
- package/dist/chunk-GDFF3BQG.js +136 -0
- package/dist/{chunk-X22KCSCO.js → chunk-GXYDVZKM.js} +7 -5
- package/dist/{chunk-X2WMBTS3.js → chunk-HLPLT3NY.js} +8 -5
- package/dist/{chunk-PB222GIA.js → chunk-HWQGBIH7.js} +1 -1
- package/dist/chunk-IL4EDBMV.js +566 -0
- package/dist/{chunk-HQE6EJS5.js → chunk-LAZGHEYU.js} +1 -1
- package/dist/{chunk-QG7OOKIN.js → chunk-LE5H7LMT.js} +1 -1
- package/dist/chunk-LNVEIJ2L.js +48 -0
- package/dist/{chunk-JUA6VU2Z.js → chunk-OJCP3C3J.js} +12 -23
- package/dist/{chunk-37JJDS4H.js → chunk-POSZWRGL.js} +1 -1
- package/dist/{chunk-TCEJ7XXM.js → chunk-QOWHHM3F.js} +1 -1
- package/dist/{chunk-H6U2U3EP.js → chunk-RRJV5UR5.js} +304 -65
- package/dist/{chunk-OFPYOC3M.js → chunk-ULAU5ZGU.js} +127 -120
- package/dist/{chunk-V6SRLKUB.js → chunk-V2FXMOEA.js} +2 -2
- package/dist/{chunk-GDQEU4I7.js → chunk-VCYSOXON.js} +296 -526
- package/dist/{chunk-BLETMLRX.js → chunk-VMNRXKAH.js} +1374 -989
- package/dist/{chunk-37EVZP66.js → chunk-VRHTNBA6.js} +167 -92
- package/dist/{chunk-FXDDDSPL.js → chunk-VY6W3T43.js} +4 -4
- package/dist/{chunk-ZDGHGY74.js → chunk-WCN4YSH7.js} +13 -6
- package/dist/{chunk-PH4Q3A6W.js → chunk-WOONT5ZP.js} +1 -1
- package/dist/{chunk-47OSH2ZO.js → chunk-XJ42NBP5.js} +395 -206
- package/dist/{chunk-SCGVWUZX.js → chunk-ZCHIC2GM.js} +92 -75
- package/dist/chunk-ZPL2RR7F.js +798 -0
- package/dist/cli/chat.js +33 -35
- package/dist/cli/check.js +6 -6
- package/dist/cli/plugins.js +13 -13
- package/dist/cli/snapshot-create.js +9 -9
- package/dist/cli/upgrade.js +7 -7
- package/dist/db/schema/agent-invocations.d.ts +20 -0
- package/dist/db/schema/conversation-annotations.d.ts +2 -2
- package/dist/db/schema/location-configurations.d.ts +127 -0
- package/dist/db/schema.d.ts +150 -3
- package/dist/{db-WWOMXWTT.js → db-XUKZRFFK.js} +7 -7
- package/dist/instrumentation.js +4 -4
- package/dist/nitro.js +2 -2
- package/dist/{oauth-callback-server-A6ZZX74U.js → oauth-callback-server-LPZMMGFI.js} +25 -26
- package/dist/{runner-KSGB2UAV.js → runner-DGKUTMPX.js} +22 -41
- package/dist/{skills-26QPWKVS.js → skills-P7YUFSXM.js} +6 -6
- package/dist/spawn-DSK3ZEVD.js +38 -0
- package/dist/{validation-OPSRGFGH.js → validation-S7U5M5NR.js} +6 -6
- package/dist/version.js +1 -1
- package/dist/{work-VMSW7STJ.js → work-GAA7TVAD.js} +18 -19
- package/dist/{worker-2JNFB7C7.js → worker-JXPJH3QB.js} +11 -10
- package/migrations/0024_misty_typhoid_mary.sql +12 -0
- package/migrations/meta/0024_snapshot.json +2275 -0
- package/migrations/meta/_journal.json +7 -0
- package/package.json +6 -5
- package/dist/api/health.d.ts +0 -7
- package/dist/api/personal-tokens/create.d.ts +0 -11
- package/dist/api/personal-tokens/list.d.ts +0 -12
- package/dist/api/personal-tokens/revoke.d.ts +0 -5
- package/dist/api/plugin-reports.d.ts +0 -63
- package/dist/api/plugins.d.ts +0 -8
- package/dist/api/runtime.d.ts +0 -24
- package/dist/api/skills.d.ts +0 -6
- package/dist/chat/slack/tools/canvas/context.d.ts +0 -18
- package/dist/chat/slack/tools/channel-access.d.ts +0 -30
- package/dist/chat/state/artifacts.d.ts +0 -30
- package/dist/chat/tool-support/turn-deadline-result.d.ts +0 -3
- package/dist/chunk-HLXXQI5Q.js +0 -238
- package/dist/chunk-LVW7BLLT.js +0 -115
- package/dist/chunk-Q6QZTTLS.js +0 -55
- package/dist/chunk-QSXZ42KX.js +0 -285
- package/dist/chunk-R776HKPK.js +0 -81
- package/dist/chunk-T5GXFFLA.js +0 -67
- package/dist/spawn-5LAJXZ2P.js +0 -39
- /package/dist/chat/slack/{tools → tool-support}/canvas/markdown.d.ts +0 -0
- /package/dist/chat/slack/{tools → tool-support}/channel-capabilities.d.ts +0 -0
- /package/dist/chat/slack/{tools → tool-support}/context.d.ts +0 -0
- /package/dist/chat/slack/{tools → tool-support}/slack-message-url.d.ts +0 -0
|
@@ -10,7 +10,6 @@ import type { OAuthClientProvider } from "@modelcontextprotocol/sdk/client/auth.
|
|
|
10
10
|
import type { Destination, Source } from "@sentry/junior-plugin-api";
|
|
11
11
|
import { type OAuthAuthorization } from "@/chat/oauth-authorization";
|
|
12
12
|
import { AuthorizationPauseError } from "@/chat/services/auth-pause";
|
|
13
|
-
import type { ThreadArtifactsState } from "@/chat/state/artifacts";
|
|
14
13
|
import type { ConversationPendingAuthState } from "@/chat/state/conversation";
|
|
15
14
|
import type { PluginDefinition } from "@/chat/plugins/types";
|
|
16
15
|
export declare class McpAuthorizationPauseError extends AuthorizationPauseError {
|
|
@@ -29,8 +28,6 @@ export interface McpAuthOrchestrationInput {
|
|
|
29
28
|
userMessage: string;
|
|
30
29
|
pendingAuth?: ConversationPendingAuthState;
|
|
31
30
|
getConfiguration: () => Record<string, unknown>;
|
|
32
|
-
getArtifactState: () => ThreadArtifactsState | undefined;
|
|
33
|
-
getMergedArtifactState: () => ThreadArtifactsState;
|
|
34
31
|
recordPendingAuth?: (pendingAuth: ConversationPendingAuthState | undefined) => void | Promise<void>;
|
|
35
32
|
/** When false, required auth hard-fails instead of pausing for an OAuth link. */
|
|
36
33
|
interactiveAuthEnabled?: boolean;
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
* signal emitted by the egress proxy — never inferred from bash command text,
|
|
11
11
|
* stdout patterns, or exit codes.
|
|
12
12
|
*/
|
|
13
|
-
import type { Destination, Source } from "@sentry/junior-plugin-api";
|
|
13
|
+
import type { Actor, Destination, Source } from "@sentry/junior-plugin-api";
|
|
14
14
|
import type { UserTokenStore } from "@/chat/credentials/user-token-store";
|
|
15
15
|
import { AuthorizationPauseError } from "@/chat/services/auth-pause";
|
|
16
16
|
import type { ConversationPendingAuthState } from "@/chat/state/conversation";
|
|
@@ -27,6 +27,7 @@ export interface PluginAuthOrchestrationInput {
|
|
|
27
27
|
conversationId?: string;
|
|
28
28
|
sessionId?: string;
|
|
29
29
|
actorId?: string;
|
|
30
|
+
actor?: Actor;
|
|
30
31
|
channelId?: string;
|
|
31
32
|
destination?: Destination;
|
|
32
33
|
source?: Source;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { LocationConfigurationService } from "@/chat/configuration/types";
|
|
2
2
|
/** Apply explicit provider-default config requests that do not need agent reasoning. */
|
|
3
3
|
export declare function maybeApplyProviderDefaultConfigRequest(args: {
|
|
4
|
-
|
|
4
|
+
locationConfiguration?: LocationConfigurationService;
|
|
5
5
|
actorId?: string;
|
|
6
6
|
text: string;
|
|
7
7
|
}): Promise<{
|
|
@@ -24,6 +24,7 @@ export interface SubscribedDecisionInput {
|
|
|
24
24
|
};
|
|
25
25
|
}
|
|
26
26
|
export interface SubscribedDecisionResult {
|
|
27
|
+
costUsd?: number;
|
|
27
28
|
shouldReply: boolean;
|
|
28
29
|
shouldUnsubscribe?: boolean;
|
|
29
30
|
reason: SubscribedReplyReason;
|
|
@@ -55,7 +56,9 @@ export declare function decideSubscribedThreadReply(args: {
|
|
|
55
56
|
system: string;
|
|
56
57
|
prompt: string;
|
|
57
58
|
metadata: Record<string, string>;
|
|
59
|
+
promptName?: string;
|
|
58
60
|
}) => Promise<{
|
|
61
|
+
costUsd?: number;
|
|
59
62
|
object: unknown;
|
|
60
63
|
}>;
|
|
61
64
|
logClassifierFailure: (error: unknown, input: SubscribedDecisionInput) => void;
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import type { PiMessage } from "@/chat/pi/messages";
|
|
2
2
|
import type { TurnRoute } from "@/chat/services/turn-router";
|
|
3
3
|
import type { AgentTurnUsage } from "@/chat/usage";
|
|
4
|
-
import type { ThreadArtifactsState } from "@/chat/state/artifacts";
|
|
5
4
|
import type { SandboxRef } from "@/chat/sandbox/ref";
|
|
6
5
|
export interface AgentTurnDiagnostics {
|
|
7
6
|
assistantMessageCount: number;
|
|
@@ -21,7 +20,6 @@ export interface AgentTurnDiagnostics {
|
|
|
21
20
|
export interface AgentRunResult {
|
|
22
21
|
/** Sanitized terminal text for diagnostics and failure fallback, not success delivery. */
|
|
23
22
|
text: string;
|
|
24
|
-
artifactStatePatch?: Partial<ThreadArtifactsState>;
|
|
25
23
|
sandboxRef?: SandboxRef;
|
|
26
24
|
piMessages?: PiMessage[];
|
|
27
25
|
diagnostics: AgentTurnDiagnostics;
|
|
@@ -29,7 +27,6 @@ export interface AgentRunResult {
|
|
|
29
27
|
export interface TurnResultInput {
|
|
30
28
|
newMessages: unknown[];
|
|
31
29
|
userInput: string;
|
|
32
|
-
artifactStatePatch: Partial<ThreadArtifactsState>;
|
|
33
30
|
toolCalls: string[];
|
|
34
31
|
sandboxRef?: SandboxRef;
|
|
35
32
|
piMessages?: PiMessage[];
|
|
@@ -17,6 +17,7 @@ declare function createTurnRouteSchema(profiles: Readonly<Record<string, Executi
|
|
|
17
17
|
}, z.core.$strip>;
|
|
18
18
|
export interface TurnRoute {
|
|
19
19
|
confidence?: number;
|
|
20
|
+
costUsd?: number;
|
|
20
21
|
profile: ModelProfile;
|
|
21
22
|
reasoningLevel: TurnReasoningLevel;
|
|
22
23
|
reason: string;
|
|
@@ -35,7 +36,9 @@ export declare function selectTurnRoute(args: {
|
|
|
35
36
|
thinkingLevel?: ProviderThinkingLevel;
|
|
36
37
|
system: string;
|
|
37
38
|
temperature: number;
|
|
39
|
+
promptName?: string;
|
|
38
40
|
}) => Promise<{
|
|
41
|
+
costUsd?: number;
|
|
39
42
|
object: unknown;
|
|
40
43
|
}>;
|
|
41
44
|
conversationContext?: string;
|
|
@@ -4,7 +4,6 @@ interface AssistantThreadLifecycleEvent {
|
|
|
4
4
|
threadTs: string;
|
|
5
5
|
sourceChannelId?: string;
|
|
6
6
|
getSlackAdapter: () => SlackAdapter;
|
|
7
|
-
onContextChannelResolved: (sourceChannelId: string) => Promise<void>;
|
|
8
7
|
}
|
|
9
8
|
/** Initialize a newly started Slack assistant thread. */
|
|
10
9
|
export declare function initializeAssistantThread(event: AssistantThreadLifecycleEvent): Promise<void>;
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import type { SlackAdapter } from "@chat-adapter/slack";
|
|
2
2
|
import { type ConversationMemoryService } from "@/chat/services/conversation-memory";
|
|
3
|
-
import type { ThreadArtifactsState } from "@/chat/state/artifacts";
|
|
4
3
|
import type { ThreadConversationState } from "@/chat/state/conversation";
|
|
5
4
|
/**
|
|
6
5
|
* Best-effort conversation title generation for all Slack conversations.
|
|
@@ -21,7 +20,6 @@ export declare function maybeUpdateAssistantTitle(args: {
|
|
|
21
20
|
threadTs: string;
|
|
22
21
|
};
|
|
23
22
|
assistantUserName: string;
|
|
24
|
-
artifacts: ThreadArtifactsState;
|
|
25
23
|
channelId?: string;
|
|
26
24
|
conversation: ThreadConversationState;
|
|
27
25
|
generateThreadTitle: ConversationMemoryService["generateThreadTitle"];
|
|
@@ -31,6 +29,5 @@ export declare function maybeUpdateAssistantTitle(args: {
|
|
|
31
29
|
runId?: string;
|
|
32
30
|
threadId?: string;
|
|
33
31
|
}): Promise<{
|
|
34
|
-
sourceMessageId: string;
|
|
35
32
|
title?: string;
|
|
36
33
|
} | undefined>;
|
|
@@ -50,3 +50,29 @@ export declare function listThreadReplies(input: {
|
|
|
50
50
|
maxPages?: number;
|
|
51
51
|
targetMessageTs?: string[];
|
|
52
52
|
}): Promise<SlackThreadReply[]>;
|
|
53
|
+
export interface SlackConversationInfo {
|
|
54
|
+
id: SlackChannelId;
|
|
55
|
+
name?: string;
|
|
56
|
+
isChannel: boolean;
|
|
57
|
+
isPrivate: boolean;
|
|
58
|
+
isIm: boolean;
|
|
59
|
+
isMpim: boolean;
|
|
60
|
+
isMember?: boolean;
|
|
61
|
+
}
|
|
62
|
+
/** Load conversation metadata used for cross-channel read access checks. */
|
|
63
|
+
export declare function getConversationInfo(channelId: SlackChannelId): Promise<SlackConversationInfo>;
|
|
64
|
+
/** Join a public channel so the bot can read history and threads there. */
|
|
65
|
+
export declare function joinPublicChannel(channelId: SlackChannelId): Promise<void>;
|
|
66
|
+
export interface SlackPublicChannelSummary {
|
|
67
|
+
id: SlackChannelId;
|
|
68
|
+
name?: string;
|
|
69
|
+
isMember?: boolean;
|
|
70
|
+
isArchived?: boolean;
|
|
71
|
+
}
|
|
72
|
+
/** List public channels the bot can see for name resolution. */
|
|
73
|
+
export declare function listPublicChannels(input?: {
|
|
74
|
+
limit?: number;
|
|
75
|
+
maxPages?: number;
|
|
76
|
+
}): Promise<SlackPublicChannelSummary[]>;
|
|
77
|
+
/** Resolve a public channel name (with or without leading #) to a channel id. */
|
|
78
|
+
export declare function resolvePublicChannelByName(channelName: string): Promise<SlackPublicChannelSummary | undefined>;
|
|
@@ -8,6 +8,7 @@ interface DispatchReplyToThread {
|
|
|
8
8
|
conversationId?: string;
|
|
9
9
|
destination: DispatchRecord["destination"];
|
|
10
10
|
execution: DispatchTurnContext;
|
|
11
|
+
publishExternally?: boolean;
|
|
11
12
|
onTurnDeliveryAccepted?: (messageId?: string) => void;
|
|
12
13
|
onTurnOutcome?: (result: DispatchTurnResult) => void;
|
|
13
14
|
shouldYield?: () => boolean;
|
|
@@ -16,7 +17,7 @@ interface DispatchReplyToThread {
|
|
|
16
17
|
}
|
|
17
18
|
/** Build the Slack provider adapter for agent-dispatched conversation turns. */
|
|
18
19
|
export declare function createSlackDispatchTurnRunner(options: {
|
|
19
|
-
|
|
20
|
+
getLocationConfiguration: (destination: DispatchRecord["destination"]) => DispatchTurnContext["locationConfiguration"];
|
|
20
21
|
getSlackAdapter: () => SlackAdapter;
|
|
21
22
|
replyToThread: DispatchReplyToThread;
|
|
22
23
|
}): (dispatch: DispatchRecord, hooks: {
|
|
@@ -16,8 +16,6 @@ type RequiredSlackTimestampParamResult = {
|
|
|
16
16
|
};
|
|
17
17
|
/** Define a model-facing Slack timestamp, normalizing numeric model args to strings. */
|
|
18
18
|
export declare function slackTimestampParam(description: string): z.ZodPreprocess<z.ZodString>;
|
|
19
|
-
/** Define an optional model-facing Slack timestamp string parameter. */
|
|
20
|
-
export declare function optionalSlackTimestampParam(description: string): z.ZodOptional<z.ZodPreprocess<z.ZodString>>;
|
|
21
19
|
/** Parse tool input into a branded Slack timestamp before provider calls. */
|
|
22
20
|
export declare function parseSlackTimestampParam(field: string, value: string | number | undefined): SlackTimestampParamResult;
|
|
23
21
|
/** Parse a required tool input timestamp into a branded Slack timestamp. */
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { type CanvasMarkdownNormalization } from "@/chat/slack/
|
|
1
|
+
import { type CanvasMarkdownNormalization } from "@/chat/slack/tool-support/canvas/markdown";
|
|
2
2
|
export { extractCanvasId } from "@/chat/slack/canvas-references";
|
|
3
3
|
export interface CanvasCreateInput {
|
|
4
4
|
title: string;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
/** Model-facing Slack canvas ID or docs URL parameter. */
|
|
3
|
+
export declare const slackCanvasRefParam: z.ZodString;
|
|
4
|
+
/** Resolve model-provided canvas references before Slack API calls. */
|
|
5
|
+
export declare function resolveCanvasTarget(canvas: string): {
|
|
6
|
+
ok: true;
|
|
7
|
+
canvasId: string;
|
|
8
|
+
} | {
|
|
9
|
+
ok: false;
|
|
10
|
+
error: string;
|
|
11
|
+
};
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import type { SlackChannelId, SlackTeamId } from "@/chat/slack/ids";
|
|
2
|
+
export type SlackChannelReadAccess = {
|
|
3
|
+
allowed: true;
|
|
4
|
+
channelName?: string;
|
|
5
|
+
isMember?: boolean;
|
|
6
|
+
isPublic?: boolean;
|
|
7
|
+
} | {
|
|
8
|
+
allowed: false;
|
|
9
|
+
error: string;
|
|
10
|
+
reason: SlackChannelReadDenialReason;
|
|
11
|
+
};
|
|
12
|
+
export type SlackChannelReadDenialReason = "private" | "not_found" | "not_in_channel" | "missing_scope" | "unknown";
|
|
13
|
+
/**
|
|
14
|
+
* Decide whether the model may read Slack content from a target channel.
|
|
15
|
+
*
|
|
16
|
+
* The current conversation is always readable. Any other channel first checks
|
|
17
|
+
* persisted visibility in the same workspace. Cross-channel reads require live
|
|
18
|
+
* `conversations.info` proof that the destination is public. Stale persisted
|
|
19
|
+
* public rows are not enough, so a channel that later becomes private fails
|
|
20
|
+
* closed. Channel-id prefixes alone cannot prove a channel public.
|
|
21
|
+
*/
|
|
22
|
+
export declare function checkSlackChannelReadAccess(args: {
|
|
23
|
+
currentChannelIds: Array<SlackChannelId | undefined>;
|
|
24
|
+
targetChannelId: SlackChannelId;
|
|
25
|
+
teamId: SlackTeamId;
|
|
26
|
+
}): Promise<SlackChannelReadAccess>;
|
|
27
|
+
/**
|
|
28
|
+
* Join one public channel when a read failed because the bot is not a member.
|
|
29
|
+
*
|
|
30
|
+
* Callers should try the read first, then use this helper on `not_in_channel`.
|
|
31
|
+
*/
|
|
32
|
+
export declare function joinPublicChannelForRead(args: {
|
|
33
|
+
channelName?: string;
|
|
34
|
+
targetChannelId: SlackChannelId;
|
|
35
|
+
}): Promise<{
|
|
36
|
+
ok: true;
|
|
37
|
+
channelName?: string;
|
|
38
|
+
} | {
|
|
39
|
+
ok: false;
|
|
40
|
+
error: string;
|
|
41
|
+
reason: SlackChannelReadDenialReason;
|
|
42
|
+
}>;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { type SlackChannelId } from "@/chat/slack/ids";
|
|
2
|
+
import { z } from "zod";
|
|
3
|
+
export interface ResolvedSlackChannelTarget {
|
|
4
|
+
channelId: SlackChannelId;
|
|
5
|
+
channelName?: string;
|
|
6
|
+
resolvedFromName: boolean;
|
|
7
|
+
}
|
|
8
|
+
/** Model-facing Slack channel ID or public channel name parameter. */
|
|
9
|
+
export declare const slackChannelRefParam: z.ZodString;
|
|
10
|
+
/**
|
|
11
|
+
* Resolve a channel reference from a tool param value.
|
|
12
|
+
*
|
|
13
|
+
* Exact channel ids are parsed directly. Anything else is treated as a public
|
|
14
|
+
* channel name (with or without a leading `#`) and resolved via Slack.
|
|
15
|
+
*/
|
|
16
|
+
export declare function resolveSlackChannelRef(input: {
|
|
17
|
+
field: string;
|
|
18
|
+
value: string;
|
|
19
|
+
}): Promise<ResolvedSlackChannelTarget>;
|
|
20
|
+
/**
|
|
21
|
+
* Resolve an optional channel reference, falling back to the active channel.
|
|
22
|
+
*/
|
|
23
|
+
export declare function resolveOptionalSlackChannelRef(input: {
|
|
24
|
+
field?: string;
|
|
25
|
+
value?: string;
|
|
26
|
+
defaultChannelId?: SlackChannelId;
|
|
27
|
+
}): Promise<ResolvedSlackChannelTarget>;
|
|
@@ -1,5 +1,10 @@
|
|
|
1
1
|
import type { SlackUserId } from "@/chat/slack/ids";
|
|
2
|
-
|
|
2
|
+
export interface ListColumnMap {
|
|
3
|
+
titleColumnId?: string;
|
|
4
|
+
completedColumnId?: string;
|
|
5
|
+
assigneeColumnId?: string;
|
|
6
|
+
dueDateColumnId?: string;
|
|
7
|
+
}
|
|
3
8
|
interface SlackListsSchemaColumnResponse {
|
|
4
9
|
id: string;
|
|
5
10
|
key: string;
|
|
@@ -19,6 +24,8 @@ export declare function createTodoList(name: string): Promise<{
|
|
|
19
24
|
listColumnMap: ListColumnMap;
|
|
20
25
|
permalink?: string;
|
|
21
26
|
}>;
|
|
27
|
+
/** Read a Slack list schema and map its standard columns. */
|
|
28
|
+
export declare function getListColumnMap(listId: string): Promise<ListColumnMap>;
|
|
22
29
|
/** Add one or more items to an existing Slack list. */
|
|
23
30
|
export declare function addListItems(input: {
|
|
24
31
|
listId: string;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { SlackToolContext } from "@/chat/slack/
|
|
1
|
+
import type { SlackToolContext } from "@/chat/slack/tool-support/context";
|
|
2
2
|
import type { ToolState } from "@/chat/tools/types";
|
|
3
3
|
/** Create a tool that provisions a new Slack canvas in the active channel. */
|
|
4
4
|
export declare function createSlackCanvasCreateTool(context: SlackToolContext, state: ToolState): Omit<import("../../../tools/definition").AnyToolDefinition, "inputSchema" | "outputSchema" | "prepareArguments" | "execute"> & {
|
|
@@ -12,6 +12,7 @@ export declare function createSlackCanvasCreateTool(context: SlackToolContext, s
|
|
|
12
12
|
[x: string]: unknown;
|
|
13
13
|
target?: string | undefined;
|
|
14
14
|
truncated?: boolean | undefined;
|
|
15
|
+
timed_out?: boolean | undefined;
|
|
15
16
|
continuation?: {
|
|
16
17
|
arguments: Record<string, unknown>;
|
|
17
18
|
reason?: string | undefined;
|
|
@@ -20,6 +21,7 @@ export declare function createSlackCanvasCreateTool(context: SlackToolContext, s
|
|
|
20
21
|
[x: string]: unknown;
|
|
21
22
|
target?: string | undefined;
|
|
22
23
|
truncated?: boolean | undefined;
|
|
24
|
+
timed_out?: boolean | undefined;
|
|
23
25
|
continuation?: {
|
|
24
26
|
arguments: Record<string, unknown>;
|
|
25
27
|
reason?: string | undefined;
|
|
@@ -13,6 +13,7 @@ export declare function createSlackCanvasEditTool(state: ToolState): Omit<import
|
|
|
13
13
|
execute?: ((input: unknown, options: import("../../../tools/definition").ToolExecuteOptions) => {
|
|
14
14
|
target?: string | undefined;
|
|
15
15
|
truncated?: boolean | undefined;
|
|
16
|
+
timed_out?: boolean | undefined;
|
|
16
17
|
continuation?: {
|
|
17
18
|
arguments: Record<string, unknown>;
|
|
18
19
|
reason?: string | undefined;
|
|
@@ -29,6 +30,7 @@ export declare function createSlackCanvasEditTool(state: ToolState): Omit<import
|
|
|
29
30
|
} | Promise<{
|
|
30
31
|
target?: string | undefined;
|
|
31
32
|
truncated?: boolean | undefined;
|
|
33
|
+
timed_out?: boolean | undefined;
|
|
32
34
|
continuation?: {
|
|
33
35
|
arguments: Record<string, unknown>;
|
|
34
36
|
reason?: string | undefined;
|
|
@@ -14,6 +14,7 @@ export declare function createSlackCanvasReadTool(): Omit<import("../../../tools
|
|
|
14
14
|
execute?: ((input: unknown, options: import("../../../tools/definition").ToolExecuteOptions) => {
|
|
15
15
|
target?: string | undefined;
|
|
16
16
|
truncated?: boolean | undefined;
|
|
17
|
+
timed_out?: boolean | undefined;
|
|
17
18
|
continuation?: {
|
|
18
19
|
arguments: Record<string, unknown>;
|
|
19
20
|
reason?: string | undefined;
|
|
@@ -31,6 +32,7 @@ export declare function createSlackCanvasReadTool(): Omit<import("../../../tools
|
|
|
31
32
|
} | Promise<{
|
|
32
33
|
target?: string | undefined;
|
|
33
34
|
truncated?: boolean | undefined;
|
|
35
|
+
timed_out?: boolean | undefined;
|
|
34
36
|
continuation?: {
|
|
35
37
|
arguments: Record<string, unknown>;
|
|
36
38
|
reason?: string | undefined;
|
|
@@ -11,6 +11,7 @@ export declare function createSlackCanvasWriteTool(state: ToolState): Omit<impor
|
|
|
11
11
|
[x: string]: unknown;
|
|
12
12
|
target?: string | undefined;
|
|
13
13
|
truncated?: boolean | undefined;
|
|
14
|
+
timed_out?: boolean | undefined;
|
|
14
15
|
continuation?: {
|
|
15
16
|
arguments: Record<string, unknown>;
|
|
16
17
|
reason?: string | undefined;
|
|
@@ -19,6 +20,7 @@ export declare function createSlackCanvasWriteTool(state: ToolState): Omit<impor
|
|
|
19
20
|
[x: string]: unknown;
|
|
20
21
|
target?: string | undefined;
|
|
21
22
|
truncated?: boolean | undefined;
|
|
23
|
+
timed_out?: boolean | undefined;
|
|
22
24
|
continuation?: {
|
|
23
25
|
arguments: Record<string, unknown>;
|
|
24
26
|
reason?: string | undefined;
|
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
/** Create
|
|
3
|
-
export declare function
|
|
1
|
+
import type { SlackToolContext } from "@/chat/slack/tool-support/context";
|
|
2
|
+
/** Create a tool that joins one public Slack channel. */
|
|
3
|
+
export declare function createSlackChannelJoinTool(context: SlackToolContext): Omit<import("../../tools/definition").AnyToolDefinition, "inputSchema" | "outputSchema" | "prepareArguments" | "execute"> & {
|
|
4
4
|
inputSchema: import("../../tools/definition").JsonSchemaObject;
|
|
5
5
|
outputSchema: import("../../tools/definition").JsonSchemaObject;
|
|
6
6
|
prepareArguments(args: unknown): {
|
|
7
|
-
|
|
8
|
-
value: string;
|
|
7
|
+
channel_id: string;
|
|
9
8
|
};
|
|
10
9
|
execute?: ((input: unknown, options: import("../../tools/definition").ToolExecuteOptions) => {
|
|
11
10
|
[x: string]: unknown;
|
|
12
11
|
target?: string | undefined;
|
|
13
12
|
truncated?: boolean | undefined;
|
|
13
|
+
timed_out?: boolean | undefined;
|
|
14
14
|
continuation?: {
|
|
15
15
|
arguments: Record<string, unknown>;
|
|
16
16
|
reason?: string | undefined;
|
|
@@ -19,6 +19,7 @@ export declare function createSlackUserLookupTool(teamId: SlackTeamId): Omit<imp
|
|
|
19
19
|
[x: string]: unknown;
|
|
20
20
|
target?: string | undefined;
|
|
21
21
|
truncated?: boolean | undefined;
|
|
22
|
+
timed_out?: boolean | undefined;
|
|
22
23
|
continuation?: {
|
|
23
24
|
arguments: Record<string, unknown>;
|
|
24
25
|
reason?: string | undefined;
|
|
@@ -1,9 +1,10 @@
|
|
|
1
|
-
import type { SlackToolContext } from "@/chat/slack/
|
|
2
|
-
/** Create the
|
|
1
|
+
import type { SlackToolContext } from "@/chat/slack/tool-support/context";
|
|
2
|
+
/** Create the channel history tool with optional cross-channel targets. */
|
|
3
3
|
export declare function createSlackChannelListMessagesTool(context: SlackToolContext): Omit<import("../../tools/definition").AnyToolDefinition, "inputSchema" | "outputSchema" | "prepareArguments" | "execute"> & {
|
|
4
4
|
inputSchema: import("../../tools/definition").JsonSchemaObject;
|
|
5
5
|
outputSchema: import("../../tools/definition").JsonSchemaObject;
|
|
6
6
|
prepareArguments(args: unknown): {
|
|
7
|
+
channel_id?: string | undefined;
|
|
7
8
|
limit?: number | undefined;
|
|
8
9
|
cursor?: string | undefined;
|
|
9
10
|
oldest?: string | undefined;
|
|
@@ -15,6 +16,7 @@ export declare function createSlackChannelListMessagesTool(context: SlackToolCon
|
|
|
15
16
|
[x: string]: unknown;
|
|
16
17
|
target?: string | undefined;
|
|
17
18
|
truncated?: boolean | undefined;
|
|
19
|
+
timed_out?: boolean | undefined;
|
|
18
20
|
continuation?: {
|
|
19
21
|
arguments: Record<string, unknown>;
|
|
20
22
|
reason?: string | undefined;
|
|
@@ -23,6 +25,7 @@ export declare function createSlackChannelListMessagesTool(context: SlackToolCon
|
|
|
23
25
|
[x: string]: unknown;
|
|
24
26
|
target?: string | undefined;
|
|
25
27
|
truncated?: boolean | undefined;
|
|
28
|
+
timed_out?: boolean | undefined;
|
|
26
29
|
continuation?: {
|
|
27
30
|
arguments: Record<string, unknown>;
|
|
28
31
|
reason?: string | undefined;
|
|
@@ -1,11 +1,6 @@
|
|
|
1
|
-
import type { ConversationMessageSearchScope
|
|
2
|
-
import { getSlackMessagePermalink } from "@/chat/slack/outbound";
|
|
3
|
-
interface ConversationMessageSearchToolDeps {
|
|
4
|
-
getPermalink?: typeof getSlackMessagePermalink;
|
|
5
|
-
store?: ConversationMessageSearchStore;
|
|
6
|
-
}
|
|
1
|
+
import type { ConversationMessageSearchScope } from "@/chat/conversations/message-search";
|
|
7
2
|
/** Create a tool that searches retained public messages in an authorized Slack workspace. */
|
|
8
|
-
export declare function createSlackConversationMessageSearchTool(scope: ConversationMessageSearchScope, currentConversationId: string
|
|
3
|
+
export declare function createSlackConversationMessageSearchTool(scope: ConversationMessageSearchScope, currentConversationId: string): Omit<import("../../tools/definition").AnyToolDefinition, "inputSchema" | "outputSchema" | "prepareArguments" | "execute"> & {
|
|
9
4
|
inputSchema: import("../../tools/definition").JsonSchemaObject;
|
|
10
5
|
outputSchema: import("../../tools/definition").JsonSchemaObject;
|
|
11
6
|
prepareArguments(args: unknown): {
|
|
@@ -29,6 +24,7 @@ export declare function createSlackConversationMessageSearchTool(scope: Conversa
|
|
|
29
24
|
}[];
|
|
30
25
|
target?: string | undefined;
|
|
31
26
|
truncated?: boolean | undefined;
|
|
27
|
+
timed_out?: boolean | undefined;
|
|
32
28
|
continuation?: {
|
|
33
29
|
arguments: Record<string, unknown>;
|
|
34
30
|
reason?: string | undefined;
|
|
@@ -51,6 +47,7 @@ export declare function createSlackConversationMessageSearchTool(scope: Conversa
|
|
|
51
47
|
}[];
|
|
52
48
|
target?: string | undefined;
|
|
53
49
|
truncated?: boolean | undefined;
|
|
50
|
+
timed_out?: boolean | undefined;
|
|
54
51
|
continuation?: {
|
|
55
52
|
arguments: Record<string, unknown>;
|
|
56
53
|
reason?: string | undefined;
|
|
@@ -59,4 +56,3 @@ export declare function createSlackConversationMessageSearchTool(scope: Conversa
|
|
|
59
56
|
query?: string | undefined;
|
|
60
57
|
}>) | undefined;
|
|
61
58
|
};
|
|
62
|
-
export {};
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import type { ToolState } from "@/chat/tools/types";
|
|
2
|
-
/** Create a tool that appends items to
|
|
2
|
+
/** Create a tool that appends items to an explicit Slack list. */
|
|
3
3
|
export declare function createSlackListAddItemsTool(state: ToolState): Omit<import("../../../tools/definition").AnyToolDefinition, "inputSchema" | "outputSchema" | "prepareArguments" | "execute"> & {
|
|
4
4
|
inputSchema: import("../../../tools/definition").JsonSchemaObject;
|
|
5
5
|
outputSchema: import("../../../tools/definition").JsonSchemaObject;
|
|
6
6
|
prepareArguments(args: unknown): {
|
|
7
|
+
list_id: string;
|
|
7
8
|
items: string[];
|
|
8
9
|
assignee_user_id?: string | undefined;
|
|
9
10
|
due_date?: string | undefined;
|
|
@@ -12,6 +13,7 @@ export declare function createSlackListAddItemsTool(state: ToolState): Omit<impo
|
|
|
12
13
|
[x: string]: unknown;
|
|
13
14
|
target?: string | undefined;
|
|
14
15
|
truncated?: boolean | undefined;
|
|
16
|
+
timed_out?: boolean | undefined;
|
|
15
17
|
continuation?: {
|
|
16
18
|
arguments: Record<string, unknown>;
|
|
17
19
|
reason?: string | undefined;
|
|
@@ -20,6 +22,7 @@ export declare function createSlackListAddItemsTool(state: ToolState): Omit<impo
|
|
|
20
22
|
[x: string]: unknown;
|
|
21
23
|
target?: string | undefined;
|
|
22
24
|
truncated?: boolean | undefined;
|
|
25
|
+
timed_out?: boolean | undefined;
|
|
23
26
|
continuation?: {
|
|
24
27
|
arguments: Record<string, unknown>;
|
|
25
28
|
reason?: string | undefined;
|
|
@@ -10,6 +10,7 @@ export declare function createSlackListCreateTool(state: ToolState): Omit<import
|
|
|
10
10
|
[x: string]: unknown;
|
|
11
11
|
target?: string | undefined;
|
|
12
12
|
truncated?: boolean | undefined;
|
|
13
|
+
timed_out?: boolean | undefined;
|
|
13
14
|
continuation?: {
|
|
14
15
|
arguments: Record<string, unknown>;
|
|
15
16
|
reason?: string | undefined;
|
|
@@ -18,6 +19,7 @@ export declare function createSlackListCreateTool(state: ToolState): Omit<import
|
|
|
18
19
|
[x: string]: unknown;
|
|
19
20
|
target?: string | undefined;
|
|
20
21
|
truncated?: boolean | undefined;
|
|
22
|
+
timed_out?: boolean | undefined;
|
|
21
23
|
continuation?: {
|
|
22
24
|
arguments: Record<string, unknown>;
|
|
23
25
|
reason?: string | undefined;
|
|
@@ -1,15 +1,16 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
export declare function createSlackListGetItemsTool(state: ToolState): Omit<import("../../../tools/definition").AnyToolDefinition, "inputSchema" | "outputSchema" | "prepareArguments" | "execute"> & {
|
|
1
|
+
/** Create a tool that reads items from an explicit Slack list. */
|
|
2
|
+
export declare function createSlackListGetItemsTool(): Omit<import("../../../tools/definition").AnyToolDefinition, "inputSchema" | "outputSchema" | "prepareArguments" | "execute"> & {
|
|
4
3
|
inputSchema: import("../../../tools/definition").JsonSchemaObject;
|
|
5
4
|
outputSchema: import("../../../tools/definition").JsonSchemaObject;
|
|
6
5
|
prepareArguments(args: unknown): {
|
|
6
|
+
list_id: string;
|
|
7
7
|
limit?: number | undefined;
|
|
8
8
|
};
|
|
9
9
|
execute?: ((input: unknown, options: import("../../../tools/definition").ToolExecuteOptions) => {
|
|
10
10
|
[x: string]: unknown;
|
|
11
11
|
target?: string | undefined;
|
|
12
12
|
truncated?: boolean | undefined;
|
|
13
|
+
timed_out?: boolean | undefined;
|
|
13
14
|
continuation?: {
|
|
14
15
|
arguments: Record<string, unknown>;
|
|
15
16
|
reason?: string | undefined;
|
|
@@ -18,6 +19,7 @@ export declare function createSlackListGetItemsTool(state: ToolState): Omit<impo
|
|
|
18
19
|
[x: string]: unknown;
|
|
19
20
|
target?: string | undefined;
|
|
20
21
|
truncated?: boolean | undefined;
|
|
22
|
+
timed_out?: boolean | undefined;
|
|
21
23
|
continuation?: {
|
|
22
24
|
arguments: Record<string, unknown>;
|
|
23
25
|
reason?: string | undefined;
|
|
@@ -1,13 +1,15 @@
|
|
|
1
1
|
import type { ToolState } from "@/chat/tools/types";
|
|
2
|
-
/** Create a tool that updates an item in
|
|
2
|
+
/** Create a tool that updates an item in an explicit Slack list. */
|
|
3
3
|
export declare function createSlackListUpdateItemTool(state: ToolState): Omit<import("../../../tools/definition").AnyToolDefinition, "inputSchema" | "outputSchema" | "prepareArguments" | "execute"> & {
|
|
4
4
|
inputSchema: import("../../../tools/definition").JsonSchemaObject;
|
|
5
5
|
outputSchema: import("../../../tools/definition").JsonSchemaObject;
|
|
6
6
|
prepareArguments(args: unknown): {
|
|
7
|
+
list_id: string;
|
|
7
8
|
item_id: string;
|
|
8
9
|
completed: boolean;
|
|
9
10
|
title?: string | undefined;
|
|
10
11
|
} | {
|
|
12
|
+
list_id: string;
|
|
11
13
|
item_id: string;
|
|
12
14
|
title: string;
|
|
13
15
|
completed?: boolean | undefined;
|
|
@@ -16,6 +18,7 @@ export declare function createSlackListUpdateItemTool(state: ToolState): Omit<im
|
|
|
16
18
|
[x: string]: unknown;
|
|
17
19
|
target?: string | undefined;
|
|
18
20
|
truncated?: boolean | undefined;
|
|
21
|
+
timed_out?: boolean | undefined;
|
|
19
22
|
continuation?: {
|
|
20
23
|
arguments: Record<string, unknown>;
|
|
21
24
|
reason?: string | undefined;
|
|
@@ -24,6 +27,7 @@ export declare function createSlackListUpdateItemTool(state: ToolState): Omit<im
|
|
|
24
27
|
[x: string]: unknown;
|
|
25
28
|
target?: string | undefined;
|
|
26
29
|
truncated?: boolean | undefined;
|
|
30
|
+
timed_out?: boolean | undefined;
|
|
27
31
|
continuation?: {
|
|
28
32
|
arguments: Record<string, unknown>;
|
|
29
33
|
reason?: string | undefined;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { SlackToolContext } from "@/chat/slack/
|
|
1
|
+
import type { SlackToolContext } from "@/chat/slack/tool-support/context";
|
|
2
2
|
import type { ToolState } from "@/chat/tools/types";
|
|
3
3
|
/** Create the tool that reacts to the current inbound Slack message. */
|
|
4
4
|
export declare function createSlackMessageAddReactionTool(context: SlackToolContext, state: ToolState): Omit<import("../../tools/definition").AnyToolDefinition, "inputSchema" | "outputSchema" | "prepareArguments" | "execute"> & {
|
|
@@ -11,6 +11,7 @@ export declare function createSlackMessageAddReactionTool(context: SlackToolCont
|
|
|
11
11
|
[x: string]: unknown;
|
|
12
12
|
target?: string | undefined;
|
|
13
13
|
truncated?: boolean | undefined;
|
|
14
|
+
timed_out?: boolean | undefined;
|
|
14
15
|
continuation?: {
|
|
15
16
|
arguments: Record<string, unknown>;
|
|
16
17
|
reason?: string | undefined;
|
|
@@ -19,6 +20,7 @@ export declare function createSlackMessageAddReactionTool(context: SlackToolCont
|
|
|
19
20
|
[x: string]: unknown;
|
|
20
21
|
target?: string | undefined;
|
|
21
22
|
truncated?: boolean | undefined;
|
|
23
|
+
timed_out?: boolean | undefined;
|
|
22
24
|
continuation?: {
|
|
23
25
|
arguments: Record<string, unknown>;
|
|
24
26
|
reason?: string | undefined;
|