@github/copilot-sdk-win32-x64 1.0.17-preview.3 → 1.0.17-preview.4
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/copilot-sdk/canvas.d.ts +6 -1
- package/copilot-sdk/docs/agent-author.md +29 -2
- package/copilot-sdk/extension.js +226 -19
- package/copilot-sdk/generated/rpc.d.ts +1101 -408
- package/copilot-sdk/generated/session-events.d.ts +239 -4
- package/copilot-sdk/index.d.ts +2 -2
- package/copilot-sdk/index.js +229 -21
- package/copilot-sdk/sessionFsProvider.d.ts +9 -1
- package/copilot-sdk/types.d.ts +67 -2
- package/package.json +1 -1
- package/prebuilds/win32-x64/copilot-runtime.exe +0 -0
- package/prebuilds/win32-x64/dpapi.node +0 -0
- package/prebuilds/win32-x64/msal-node-runtime.node +0 -0
- package/prebuilds/win32-x64/msalruntime.dll +0 -0
- package/prebuilds/win32-x64/runtime.node +2 -2
- package/ripgrep/bin/win32-x64/rg.exe +0 -0
- package/schemas/api.schema.json +1328 -125
- package/schemas/session-events.schema.json +418 -7
- package/tgrep/bin/win32-x64/tgrep.exe +0 -0
- package/prebuilds/win32-x64/OneAuthInterop.LICENSE.txt +0 -192
- package/prebuilds/win32-x64/OneAuthInterop.dll +0 -0
- package/prebuilds/win32-x64/OneAuthInterop.dll.stamp.json +0 -4
|
@@ -9,7 +9,7 @@ export type JsonValue = null | boolean | number | string | JsonValue[] | {
|
|
|
9
9
|
/**
|
|
10
10
|
* Union of all session event variants emitted by the Copilot CLI runtime.
|
|
11
11
|
*/
|
|
12
|
-
export type SessionEvent = StartEvent | ResumeEvent | RemoteSteerableChangedEvent | ErrorEvent | IdleEvent | TitleChangedEvent | ScheduleCreatedEvent | ScheduleCancelledEvent | ScheduleRearmedEvent | AutopilotObjectiveChangedEvent | InfoEvent | IndexedSearchEvent | WarningEvent | ModelChangeEvent | ModelDeselectedEvent | AutoTierRecommendationEvent | AutoTierSwitchFailedEvent | ModeChangedEvent | ModeNoticeDeliveredEvent | SessionLimitsChangedEvent | PermissionsChangedEvent | PlanChangedEvent | TodosChangedEvent | WorkspaceFileChangedEvent | HandoffEvent | TruncationEvent | SnapshotRewindEvent | ShutdownEvent | UsageCheckpointEvent | ContextChangedEvent | UsageInfoEvent | ContextClearedEvent | CompactionStartEvent | CompactionCompleteEvent | TaskCompleteEvent | CompletionReceiptEvent | FusionRouteStartedEvent | FusionRouteFailedEvent | FusionResolvedEvent | FusionCompletedEvent | PermissionRecoveryEvent | UserMessageEvent | PendingMessagesModifiedEvent | AssistantTurnStartEvent | AssistantIntentEvent | AssistantFusionPhaseStartedEvent | AssistantFusionPhaseActivityEvent | AssistantFusionPhaseCompletedEvent | AssistantFusionPhaseFailedEvent | AssistantServerToolProgressEvent | AssistantReasoningEvent | AssistantReasoningDeltaEvent | AssistantToolCallDeltaEvent | AssistantStreamingDeltaEvent | AssistantMessageEvent | AssistantMessageStartEvent | AssistantMessageDeltaEvent | AssistantTurnEndEvent | AssistantIdleEvent | AssistantUsageEvent | ModelCallFailureEvent | ModelCallFinishedEvent | AbortEvent | ToolUserRequestedEvent | ToolExecutionStartEvent | ToolExecutionPartialResultEvent | ToolExecutionProgressEvent | ToolExecutionCompleteEvent | ToolSearchActivatedEvent | SkillInvokedEvent | SubagentStartedEvent | SubagentConfiguredEvent | SubagentCompletedEvent | SubagentFailedEvent | SubagentSelectedEvent | SubagentDeselectedEvent | HookStartEvent | HookEndEvent | HookProgressEvent | BinaryAssetEvent | SystemMessageEvent | SystemNotificationEvent | PermissionRequestedEvent | PermissionCompletedEvent | PermissionCarriedForwardEvent | PermissionMessageAuthorizationEvent | PermissionMessageAuthorizationReadEvent | PermissionMessageAuthorizationDegradedEvent | PermissionAssentDetectedEvent | PermissionContextualAuthorizationEvent | UserInputRequestedEvent | UserInputCompletedEvent | ElicitationRequestedEvent | ElicitationCompletedEvent | SamplingRequestedEvent | SamplingCompletedEvent | McpOauthRequiredEvent | McpOauthCompletedEvent | McpHeadersRefreshRequiredEvent | McpHeadersRefreshCompletedEvent | CustomNotificationEvent | UIEphemeralQueryEvent | ExternalToolRequestedEvent | ExternalToolCompletedEvent | CommandQueuedEvent | CommandExecuteEvent | CommandCompletedEvent | AutoModeSwitchRequestedEvent | AutoModeSwitchCompletedEvent | SessionLimitsExhaustedRequestedEvent | SessionLimitsExhaustedCompletedEvent | AutoModeResolvedEvent | ManagedSettingsResolvedEvent | ManagedSettingsEnforcedEvent | CommandsChangedEvent | CapabilitiesChangedEvent | ExitPlanModeRequestedEvent | ExitPlanModeCompletedEvent | ToolsUpdatedEvent | BackgroundTasksChangedEvent | WorkflowRunUpdatedEvent | WorkflowRunStartedEvent | WorkflowRunSettledEvent | SkillsLoadedEvent | CustomAgentsUpdatedEvent | McpServersLoadedEvent | McpServerStatusChangedEvent | McpServerRemovedEvent | McpServerNeedsReconnectEvent | McpToolsListChangedEvent | McpResourcesListChangedEvent | McpPromptsListChangedEvent | ExtensionsLoadedEvent | CanvasOpenedEvent | CanvasRegistryChangedEvent | CanvasClosedEvent | CanvasUnavailableEvent | CanvasRecordedEvent | CanvasRemovedEvent | ExtensionsAttachmentsPushedEvent | McpAppToolCallCompleteEvent;
|
|
12
|
+
export type SessionEvent = StartEvent | ResumeEvent | RemoteSteerableChangedEvent | ErrorEvent | IdleEvent | TitleChangedEvent | ScheduleCreatedEvent | ScheduleCancelledEvent | ScheduleRearmedEvent | AutopilotObjectiveChangedEvent | InfoEvent | IndexedSearchEvent | WarningEvent | ModelChangeEvent | ModelDeselectedEvent | AutoTierRecommendationEvent | AutoTierSwitchFailedEvent | ModeChangedEvent | ModeNoticeDeliveredEvent | SessionLimitsChangedEvent | PermissionsChangedEvent | PlanChangedEvent | TodosChangedEvent | WorkspaceFileChangedEvent | HandoffEvent | TruncationEvent | SnapshotRewindEvent | ShutdownEvent | UsageCheckpointEvent | ContextChangedEvent | UsageInfoEvent | ContextClearedEvent | CompactionStartEvent | CompactionCompleteEvent | TaskCompleteEvent | CompletionReceiptEvent | FusionRouteStartedEvent | FusionRouteFailedEvent | FusionResolvedEvent | FusionCompletedEvent | PermissionRecoveryEvent | UserMessageEvent | PendingMessagesModifiedEvent | AssistantTurnStartEvent | AssistantIntentEvent | AssistantFusionPhaseStartedEvent | AssistantFusionPhaseActivityEvent | AssistantFusionPhaseCompletedEvent | AssistantFusionPhaseFailedEvent | AssistantServerToolProgressEvent | AssistantReasoningEvent | AssistantReasoningDeltaEvent | AssistantToolCallDeltaEvent | AssistantStreamingDeltaEvent | AssistantMessageEvent | AssistantMessageStartEvent | AssistantMessageDeltaEvent | AssistantTurnEndEvent | AssistantIdleEvent | AssistantUsageEvent | ModelCallFailureEvent | ModelCallFinishedEvent | AbortEvent | ToolUserRequestedEvent | ToolExecutionStartEvent | ToolExecutionPartialResultEvent | ToolShellOutputEvent | ToolExecutionProgressEvent | ToolExecutionCompleteEvent | ToolSearchActivatedEvent | SkillInvokedEvent | SubagentStartedEvent | SubagentConfiguredEvent | SubagentCompletedEvent | SubagentFailedEvent | SubagentSelectedEvent | SubagentDeselectedEvent | HookStartEvent | HookEndEvent | HookProgressEvent | BinaryAssetEvent | SystemMessageEvent | SystemNotificationEvent | PermissionRequestedEvent | PermissionCompletedEvent | PermissionCarriedForwardEvent | PermissionMessageAuthorizationEvent | PermissionMessageAuthorizationReadEvent | PermissionMessageAuthorizationDegradedEvent | PermissionAssentDetectedEvent | PermissionContextualAuthorizationEvent | UserInputRequestedEvent | UserInputCompletedEvent | ElicitationRequestedEvent | ElicitationCompletedEvent | SamplingRequestedEvent | SamplingCompletedEvent | McpOauthRequiredEvent | McpOauthCompletedEvent | McpHeadersRefreshRequiredEvent | McpHeadersRefreshCompletedEvent | CustomNotificationEvent | UIEphemeralQueryEvent | ExternalToolRequestedEvent | ExternalToolCompletedEvent | CommandQueuedEvent | CommandExecuteEvent | CommandCompletedEvent | AutoModeSwitchRequestedEvent | AutoModeSwitchCompletedEvent | SessionLimitsExhaustedRequestedEvent | SessionLimitsExhaustedCompletedEvent | AutoModeResolvedEvent | ManagedSettingsResolvedEvent | ManagedSettingsEnforcedEvent | CommandsChangedEvent | CapabilitiesChangedEvent | ExitPlanModeRequestedEvent | ExitPlanModeCompletedEvent | HumanResponseRecordedEvent | ToolsUpdatedEvent | BackgroundTasksChangedEvent | WorkflowRunUpdatedEvent | WorkflowRunStartedEvent | WorkflowRunSettledEvent | SkillsLoadedEvent | CustomAgentsUpdatedEvent | McpServersLoadedEvent | McpServerStatusChangedEvent | McpServerRemovedEvent | McpServerNeedsReconnectEvent | McpToolsListChangedEvent | McpResourcesListChangedEvent | McpPromptsListChangedEvent | ExtensionsLoadedEvent | CanvasOpenedEvent | CanvasRegistryChangedEvent | CanvasClosedEvent | CanvasUnavailableEvent | CanvasRecordedEvent | CanvasRemovedEvent | ExtensionsAttachmentsPushedEvent | McpAppToolCallCompleteEvent;
|
|
13
13
|
/**
|
|
14
14
|
* Routing preference used when the session model is `auto`. `fast` is an integrator-only latency preset and is not a first-party GitHub Copilot product preference.
|
|
15
15
|
*/
|
|
@@ -773,6 +773,27 @@ export type ToolExecutionStartToolDescriptionMetaUIVisibility =
|
|
|
773
773
|
"model"
|
|
774
774
|
/** Tool is callable by the MCP App view (iframe) via session.mcp.apps.callTool */
|
|
775
775
|
| "app";
|
|
776
|
+
/**
|
|
777
|
+
* Shell output source. Terminal output has no separate stdout/stderr attribution.
|
|
778
|
+
*/
|
|
779
|
+
export type ToolShellOutputStream =
|
|
780
|
+
/** Output from the shell command's standard output stream. This is the default when stream is omitted. */
|
|
781
|
+
"stdout"
|
|
782
|
+
/** Output from the shell command's standard error stream. */
|
|
783
|
+
| "stderr"
|
|
784
|
+
/** Inherently merged output that cannot be attributed separately to stdout or stderr. */
|
|
785
|
+
| "terminal";
|
|
786
|
+
/**
|
|
787
|
+
* Kind of file mutation committed by a built-in editing tool.
|
|
788
|
+
*/
|
|
789
|
+
/** @experimental */
|
|
790
|
+
export type ToolExecutionCompleteFileEditKind =
|
|
791
|
+
/** A file was created. */
|
|
792
|
+
"create"
|
|
793
|
+
/** A file was written by an edit operation. */
|
|
794
|
+
| "edit"
|
|
795
|
+
/** A file was deleted. */
|
|
796
|
+
| "delete" | (string & {});
|
|
776
797
|
/**
|
|
777
798
|
* A model-facing binary result as persisted: full inline data, a size-omitted marker, or a deduplicated asset reference
|
|
778
799
|
*/
|
|
@@ -1215,6 +1236,92 @@ export type ExitPlanModeAction =
|
|
|
1215
1236
|
| "autopilot"
|
|
1216
1237
|
/** Exit plan mode and continue with parallel autonomous workers. */
|
|
1217
1238
|
| "autopilot_fleet";
|
|
1239
|
+
/**
|
|
1240
|
+
* Controlled provenance for a typed runtime response. Only `human_response`, minted by a trusted direct-interaction ingress, is human authorization evidence.
|
|
1241
|
+
*/
|
|
1242
|
+
export type HumanResponseActor =
|
|
1243
|
+
/** A built-in trusted client submitted the response after direct human interaction. */
|
|
1244
|
+
"human_response"
|
|
1245
|
+
/** A host or SDK automation submitted the response without direct human interaction. */
|
|
1246
|
+
| "host_automation"
|
|
1247
|
+
/** The response came through a legacy or otherwise unattributed ingress. */
|
|
1248
|
+
| "unknown";
|
|
1249
|
+
/**
|
|
1250
|
+
* Exact runtime-owned question or reviewed plan paired with the typed response that settled it.
|
|
1251
|
+
*/
|
|
1252
|
+
export type HumanResponseRecordedResponse = {
|
|
1253
|
+
/**
|
|
1254
|
+
* Exact answer content accepted from the user.
|
|
1255
|
+
*/
|
|
1256
|
+
content: {
|
|
1257
|
+
[k: string]: ElicitationCompletedContent | undefined;
|
|
1258
|
+
};
|
|
1259
|
+
/**
|
|
1260
|
+
* Exact question displayed to the user.
|
|
1261
|
+
*/
|
|
1262
|
+
message: string;
|
|
1263
|
+
requestedSchema: ElicitationRequestedSchema;
|
|
1264
|
+
/**
|
|
1265
|
+
* Runtime-owned response kind discriminator.
|
|
1266
|
+
*/
|
|
1267
|
+
responseKind: "ask_user";
|
|
1268
|
+
} | {
|
|
1269
|
+
/**
|
|
1270
|
+
* Whether the displayed request allowed a free-form answer.
|
|
1271
|
+
*/
|
|
1272
|
+
allowFreeform?: boolean;
|
|
1273
|
+
/**
|
|
1274
|
+
* Exact selected or free-form answer submitted by the user.
|
|
1275
|
+
*/
|
|
1276
|
+
answer: string;
|
|
1277
|
+
/**
|
|
1278
|
+
* Exact choices displayed to the user, when the request offered choices.
|
|
1279
|
+
*/
|
|
1280
|
+
choices?: string[];
|
|
1281
|
+
/**
|
|
1282
|
+
* Exact question displayed to the user.
|
|
1283
|
+
*/
|
|
1284
|
+
question: string;
|
|
1285
|
+
/**
|
|
1286
|
+
* Runtime-owned response kind discriminator.
|
|
1287
|
+
*/
|
|
1288
|
+
responseKind: "user_input";
|
|
1289
|
+
/**
|
|
1290
|
+
* Whether the answer was typed as free-form text rather than selected from the displayed choices.
|
|
1291
|
+
*/
|
|
1292
|
+
wasFreeform: boolean;
|
|
1293
|
+
} | {
|
|
1294
|
+
/**
|
|
1295
|
+
* Actions offered by the plan review UI.
|
|
1296
|
+
*/
|
|
1297
|
+
actions: ExitPlanModeAction[];
|
|
1298
|
+
/**
|
|
1299
|
+
* Whether the user approved the reviewed plan.
|
|
1300
|
+
*/
|
|
1301
|
+
approved: boolean;
|
|
1302
|
+
/**
|
|
1303
|
+
* Whether the selected response requested edit auto-approval.
|
|
1304
|
+
*/
|
|
1305
|
+
autoApproveEdits?: boolean;
|
|
1306
|
+
/**
|
|
1307
|
+
* Exact feedback submitted with the plan decision, when present.
|
|
1308
|
+
*/
|
|
1309
|
+
feedback?: string;
|
|
1310
|
+
/**
|
|
1311
|
+
* Exact full plan content available from the review UI.
|
|
1312
|
+
*/
|
|
1313
|
+
planContent: string;
|
|
1314
|
+
recommendedAction: ExitPlanModeAction;
|
|
1315
|
+
/**
|
|
1316
|
+
* Runtime-owned response kind discriminator.
|
|
1317
|
+
*/
|
|
1318
|
+
responseKind: "exit_plan_mode";
|
|
1319
|
+
selectedAction?: ExitPlanModeAction;
|
|
1320
|
+
/**
|
|
1321
|
+
* Exact plan summary displayed to the user.
|
|
1322
|
+
*/
|
|
1323
|
+
summary: string;
|
|
1324
|
+
};
|
|
1218
1325
|
/**
|
|
1219
1326
|
* Terminal status a workflow run committed. A settled run is never `pending` or `running`, so those two members of the run-status domain are deliberately absent.
|
|
1220
1327
|
*/
|
|
@@ -1360,6 +1467,10 @@ export interface StartData {
|
|
|
1360
1467
|
* Reasoning effort level used for model calls, if applicable (e.g. "none", "low", "medium", "high", "xhigh", "max")
|
|
1361
1468
|
*/
|
|
1362
1469
|
reasoningEffort?: string;
|
|
1470
|
+
/**
|
|
1471
|
+
* Model that owns effort embedded in an authored model selection. Omitted for independent reasoning-effort overrides and legacy events.
|
|
1472
|
+
*/
|
|
1473
|
+
reasoningEffortModel?: string;
|
|
1363
1474
|
reasoningSummary?: ReasoningSummary;
|
|
1364
1475
|
/**
|
|
1365
1476
|
* Whether this session supports remote steering via GitHub
|
|
@@ -1512,6 +1623,10 @@ export interface ResumeData {
|
|
|
1512
1623
|
* Reasoning effort level used for model calls, if applicable (e.g. "none", "low", "medium", "high", "xhigh", "max")
|
|
1513
1624
|
*/
|
|
1514
1625
|
reasoningEffort?: string;
|
|
1626
|
+
/**
|
|
1627
|
+
* Model that owns effort embedded in an authored model selection. Omitted for independent reasoning-effort overrides and legacy events.
|
|
1628
|
+
*/
|
|
1629
|
+
reasoningEffortModel?: string;
|
|
1515
1630
|
reasoningSummary?: ReasoningSummary;
|
|
1516
1631
|
/**
|
|
1517
1632
|
* Whether this session supports remote steering via GitHub
|
|
@@ -2114,6 +2229,10 @@ export interface ModelChangeData {
|
|
|
2114
2229
|
* Reasoning effort level after the model change, if applicable
|
|
2115
2230
|
*/
|
|
2116
2231
|
reasoningEffort?: string | null;
|
|
2232
|
+
/**
|
|
2233
|
+
* Model that owns effort embedded in an authored model selection. Omitted for independent reasoning-effort overrides and legacy events.
|
|
2234
|
+
*/
|
|
2235
|
+
reasoningEffortModel?: string;
|
|
2117
2236
|
reasoningSummary?: ReasoningSummary;
|
|
2118
2237
|
source?: ModelChangeSource;
|
|
2119
2238
|
verbosity?: Verbosity;
|
|
@@ -5506,6 +5625,10 @@ export interface AssistantMessageReasoningBlocks {
|
|
|
5506
5625
|
* Provider-native reasoning items or content blocks preserved verbatim, in order. A single response can carry several, and provider signatures or identifiers may depend on their exact content and ordering.
|
|
5507
5626
|
*/
|
|
5508
5627
|
blocks?: JsonValue[];
|
|
5628
|
+
/**
|
|
5629
|
+
* Anthropic Messages assistant block ordering preserved when the legacy reasoning-only representation cannot reproduce it exactly. Thinking and text blocks remain verbatim; tool-use entries retain identity and a payload fingerprint when later signed reasoning depends on them, and are hydrated from the message's tool requests during replay.
|
|
5630
|
+
*/
|
|
5631
|
+
orderedBlocks?: JsonValue[];
|
|
5509
5632
|
/**
|
|
5510
5633
|
* Model provider that produced these reasoning blocks.
|
|
5511
5634
|
*/
|
|
@@ -6413,7 +6536,8 @@ export interface ToolExecutionStartToolDescriptionMetaUI {
|
|
|
6413
6536
|
visibility?: ToolExecutionStartToolDescriptionMetaUIVisibility[];
|
|
6414
6537
|
}
|
|
6415
6538
|
/**
|
|
6416
|
-
*
|
|
6539
|
+
* @deprecated
|
|
6540
|
+
* Session event "tool.execution_partial_result". Deprecated merged replacement snapshot of shell output. Use tool.shell_output for append-only, stream-tagged output instead.
|
|
6417
6541
|
*/
|
|
6418
6542
|
export interface ToolExecutionPartialResultEvent {
|
|
6419
6543
|
/**
|
|
@@ -6443,11 +6567,12 @@ export interface ToolExecutionPartialResultEvent {
|
|
|
6443
6567
|
type: "tool.execution_partial_result";
|
|
6444
6568
|
}
|
|
6445
6569
|
/**
|
|
6446
|
-
*
|
|
6570
|
+
* @deprecated
|
|
6571
|
+
* Deprecated merged replacement snapshot of shell output. Use tool.shell_output for append-only, stream-tagged output instead.
|
|
6447
6572
|
*/
|
|
6448
6573
|
export interface ToolExecutionPartialData {
|
|
6449
6574
|
/**
|
|
6450
|
-
*
|
|
6575
|
+
* Merged replacement snapshot from the running shell, not an append-only chunk
|
|
6451
6576
|
*/
|
|
6452
6577
|
partialOutput: string;
|
|
6453
6578
|
/**
|
|
@@ -6455,6 +6580,54 @@ export interface ToolExecutionPartialData {
|
|
|
6455
6580
|
*/
|
|
6456
6581
|
toolCallId: string;
|
|
6457
6582
|
}
|
|
6583
|
+
/**
|
|
6584
|
+
* Session event "tool.shell_output". Live, append-only shell output. Not persisted or replayed to late subscribers. Text is decoded and redacted per chunk; chunks need not contain complete lines.
|
|
6585
|
+
*/
|
|
6586
|
+
export interface ToolShellOutputEvent {
|
|
6587
|
+
/**
|
|
6588
|
+
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
|
|
6589
|
+
*/
|
|
6590
|
+
agentId?: string;
|
|
6591
|
+
data: ToolShellOutputData;
|
|
6592
|
+
/**
|
|
6593
|
+
* Always true for events that are transient and not persisted to the session event log on disk.
|
|
6594
|
+
*/
|
|
6595
|
+
ephemeral: true;
|
|
6596
|
+
/**
|
|
6597
|
+
* Unique event identifier (UUID v4), generated when the event is emitted
|
|
6598
|
+
*/
|
|
6599
|
+
id: string;
|
|
6600
|
+
/**
|
|
6601
|
+
* ID of the chronologically preceding event in the session, forming a linked chain. Null for the first event.
|
|
6602
|
+
*/
|
|
6603
|
+
parentId: string | null;
|
|
6604
|
+
/**
|
|
6605
|
+
* ISO 8601 timestamp when the event was created
|
|
6606
|
+
*/
|
|
6607
|
+
timestamp: string;
|
|
6608
|
+
/**
|
|
6609
|
+
* Type discriminator. Always "tool.shell_output".
|
|
6610
|
+
*/
|
|
6611
|
+
type: "tool.shell_output";
|
|
6612
|
+
}
|
|
6613
|
+
/**
|
|
6614
|
+
* Live, append-only shell output. Not persisted or replayed to late subscribers. Text is decoded and redacted per chunk; chunks need not contain complete lines.
|
|
6615
|
+
*/
|
|
6616
|
+
export interface ToolShellOutputData {
|
|
6617
|
+
/**
|
|
6618
|
+
* Zero-based publication sequence across all output streams for this tool call. Not a byte offset or an OS write-order guarantee.
|
|
6619
|
+
*/
|
|
6620
|
+
sequence: number;
|
|
6621
|
+
stream?: ToolShellOutputStream;
|
|
6622
|
+
/**
|
|
6623
|
+
* New output to append, without synthetic shell-result markers or stream-switch separators
|
|
6624
|
+
*/
|
|
6625
|
+
text: string;
|
|
6626
|
+
/**
|
|
6627
|
+
* Tool call ID that owns this shell output
|
|
6628
|
+
*/
|
|
6629
|
+
toolCallId: string;
|
|
6630
|
+
}
|
|
6458
6631
|
/**
|
|
6459
6632
|
* Session event "tool.execution_progress". Tool execution progress notification with status message
|
|
6460
6633
|
*/
|
|
@@ -6539,6 +6712,12 @@ export interface ToolExecutionCompleteEvent {
|
|
|
6539
6712
|
*/
|
|
6540
6713
|
export interface ToolExecutionCompleteData {
|
|
6541
6714
|
error?: ToolExecutionCompleteError;
|
|
6715
|
+
/**
|
|
6716
|
+
* Experimental. File mutations actually committed by a built-in file editing tool, in execution order. Present on successful edits and on partial failures when earlier mutations were committed. Paths are absolute in the session filesystem namespace.
|
|
6717
|
+
*
|
|
6718
|
+
* @experimental
|
|
6719
|
+
*/
|
|
6720
|
+
fileEdits?: ToolExecutionCompleteFileEdit[];
|
|
6542
6721
|
/**
|
|
6543
6722
|
* Experimental HydraFusion attribution for this tool completion.
|
|
6544
6723
|
*
|
|
@@ -6617,6 +6796,17 @@ export interface ToolExecutionCompleteError {
|
|
|
6617
6796
|
message: string;
|
|
6618
6797
|
remediation?: RemediationAction;
|
|
6619
6798
|
}
|
|
6799
|
+
/**
|
|
6800
|
+
* A file mutation that was actually committed by a built-in file editing tool.
|
|
6801
|
+
*/
|
|
6802
|
+
/** @experimental */
|
|
6803
|
+
export interface ToolExecutionCompleteFileEdit {
|
|
6804
|
+
kind: ToolExecutionCompleteFileEditKind;
|
|
6805
|
+
/**
|
|
6806
|
+
* Absolute path in the session filesystem namespace.
|
|
6807
|
+
*/
|
|
6808
|
+
path: string;
|
|
6809
|
+
}
|
|
6620
6810
|
/**
|
|
6621
6811
|
* Tool execution result on success
|
|
6622
6812
|
*/
|
|
@@ -11679,6 +11869,51 @@ export interface ExitPlanModeCompletedData {
|
|
|
11679
11869
|
requestId: string;
|
|
11680
11870
|
selectedAction?: ExitPlanModeAction;
|
|
11681
11871
|
}
|
|
11872
|
+
/**
|
|
11873
|
+
* Session event "human_response.recorded". Durable request-correlated evidence for a typed response to a runtime-owned question or plan review.
|
|
11874
|
+
*/
|
|
11875
|
+
export interface HumanResponseRecordedEvent {
|
|
11876
|
+
/**
|
|
11877
|
+
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
|
|
11878
|
+
*/
|
|
11879
|
+
agentId?: string;
|
|
11880
|
+
data: HumanResponseRecordedData;
|
|
11881
|
+
/**
|
|
11882
|
+
* When true, the event is transient and not persisted to the session event log on disk
|
|
11883
|
+
*/
|
|
11884
|
+
ephemeral?: boolean;
|
|
11885
|
+
/**
|
|
11886
|
+
* Unique event identifier (UUID v4), generated when the event is emitted
|
|
11887
|
+
*/
|
|
11888
|
+
id: string;
|
|
11889
|
+
/**
|
|
11890
|
+
* ID of the chronologically preceding event in the session, forming a linked chain. Null for the first event.
|
|
11891
|
+
*/
|
|
11892
|
+
parentId: string | null;
|
|
11893
|
+
/**
|
|
11894
|
+
* ISO 8601 timestamp when the event was created
|
|
11895
|
+
*/
|
|
11896
|
+
timestamp: string;
|
|
11897
|
+
/**
|
|
11898
|
+
* Type discriminator. Always "human_response.recorded".
|
|
11899
|
+
*/
|
|
11900
|
+
type: "human_response.recorded";
|
|
11901
|
+
}
|
|
11902
|
+
/**
|
|
11903
|
+
* Durable request-correlated evidence for a typed response to a runtime-owned question or plan review.
|
|
11904
|
+
*/
|
|
11905
|
+
export interface HumanResponseRecordedData {
|
|
11906
|
+
actor: HumanResponseActor;
|
|
11907
|
+
/**
|
|
11908
|
+
* Request ID of the runtime-owned question or plan review.
|
|
11909
|
+
*/
|
|
11910
|
+
requestId: string;
|
|
11911
|
+
response: HumanResponseRecordedResponse;
|
|
11912
|
+
/**
|
|
11913
|
+
* Tool call ID that opened the request, when present.
|
|
11914
|
+
*/
|
|
11915
|
+
toolCallId?: string;
|
|
11916
|
+
}
|
|
11682
11917
|
/**
|
|
11683
11918
|
* Session event "session.tools_updated". Payload of `session.tools_updated` identifying the model whose resolved tools were updated.
|
|
11684
11919
|
*/
|
package/copilot-sdk/index.d.ts
CHANGED
|
@@ -11,7 +11,7 @@ export { BuiltInTools, ToolSet } from "./toolSet.js";
|
|
|
11
11
|
export { CopilotSession, type AssistantMessageEvent } from "./session.js";
|
|
12
12
|
export { defineWorkflow, WorkflowResumeError, isWorkflowRunTerminal } from "./workflow.js";
|
|
13
13
|
export { Canvas, CanvasError, createCanvas, type CanvasAction, type CanvasDeclaration, type CanvasHostContext, type CanvasHostContextCapabilities, type CanvasJsonSchema, type CanvasOptions, } from "./canvas.js";
|
|
14
|
-
export { defineTool, approveAll, createAttributedPermissionResult, convertMcpCallToolResult, createSessionFsAdapter, CopilotRequestHandler, CopilotWebSocketHandler, CopilotWebSocketCloseStatus, CopilotWebSocketForwarder, SessionFsSqliteTransactionFailure, SYSTEM_MESSAGE_SECTIONS, } from "./types.js";
|
|
14
|
+
export { defineTool, approveAll, createAttributedPermissionResult, convertMcpCallToolResult, createSessionFsAdapter, CopilotRequestHandler, CopilotWebSocketHandler, CopilotWebSocketCloseStatus, CopilotWebSocketForwarder, SessionFsSqliteTransactionFailure, SessionFsWriteFailure, SYSTEM_MESSAGE_SECTIONS, } from "./types.js";
|
|
15
15
|
export type * from "./generated/session-events.js";
|
|
16
|
-
export type { AskUserVariant, CommandContext, CommandDefinition, CommandHandler, CanvasProviderIdentity, CloudSessionOptions, CloudSessionRepository, AuthIdentityMetadata, AuthInfoType, ConnectorAccountRequest, ConnectorAvailability, ConnectorCapabilities, ConnectorCatalogEntry, ConnectorCatalogResult, ConnectorCatalogStatus, ConnectorConnectRequest, ConnectorConnectResult, ConnectorContinueRequest, ConnectorDisconnectResult, ConnectorMcpStatus, ConnectorReconcileRequest, ConnectorRuntimeStatus, ConnectorSessionAccount, ConnectorSessionAccountResult, ConnectorStatus, AutoModeSwitchHandler, AutoModeSwitchRequest, AutoModeSwitchResponse, AgentStopHandler, AgentStopHookInput, AgentStopHookOutput, UserPromptTransformedHandler, UserPromptTransformedHookInput, UserPromptTransformedHookOutput, CopilotClientInfo, CopilotClientMode, CopilotClientOptions, InstallationConfirmationHandler, InstallationConfirmationRequest, InstallationConfirmationResponse, InstallationDecision, InstallationReview, McpInstallationReview, CopilotExpAssignmentResponse, StdioRuntimeConnection, InProcessRuntimeConnection, TcpRuntimeConnection, UriRuntimeConnection, ChildProcessRuntimeConnection, CustomAgentConfig, ElicitationFieldValue, ElicitationHandler, ElicitationParams, ElicitationContext, ElicitationResult, ElicitationSchema, ElicitationSchemaField, ExpConfigEntry, ExpFlagValue, ExitPlanModeHandler, ExitPlanModeRequest, ExitPlanModeResult, ExtensionLaunchProfile, ExtensionLaunchProvider, ExtensionLaunchProviderResolveRequest, ExtensionLaunchProviderResolveResult, ExtensionInfo, ForegroundSessionInfo, GetAuthStatusResponse, GetStatusResponse, GitHubMcpToolConfig, GitHubTelemetryNotification, GitHubTelemetryEvent, GitHubTelemetryClientInfo, GitHubTokenAcquireReason, GitHubTokenAcquireResult, GitHubTokenProvider, GitHubTokenProviderArgs, GitHubTokenProviderResult, InfiniteSessionConfig, LargeToolOutputConfig, MemoryConfiguration, UiInputOptions, MCPStdioServerConfig, MCPHTTPServerConfig, MCPServerConfig, DefaultAgentConfig, BearerTokenProvider, ExtensionContextAttachment, MessageOptions, ResponseSchema, MessageSource, ManagedSettings, ManagedSettingsPermissions, ModelBilling, ModelBillingTokenPrices, ModelBillingTokenPricesLongContext, AutoTier, CapiSessionOptions, CurrentModel, ModelSwitchAutoTierResult, ModelSwitchAutoTierStatus, ModelCapabilities, ModelCapabilitiesOverride, ModelInfo, ModelPolicy, NamedProviderConfig, PermissionHandler, PermissionRequest, PermissionRequestedData, PermissionRequestedEvent, PermissionRequestResult, AttributedPermissionResult, PermissionDecisionContext, PermissionDecisionOutcome, PermissionDecisionSource, PermissionDecisionSurface, PermissionResponseCapability, ProviderConfig, ProviderConfigModelProvider, ProviderModelConfig, ProviderTokenArgs, RemoteSessionMode, SandboxConfigSource, ResumeSessionConfig, TranscriptRecovery, SectionOverride, SectionOverrideAction, SectionTransformFn, SessionCapabilities, SessionConfig, SessionConfigBase, SessionEvent, SessionEventHandler, SessionEventPayload, SessionEventType, SessionLifecycleEvent, SessionLifecycleEventMetadata, SessionLifecycleEventType, SessionLifecycleHandler, SessionHooks, SessionCreatedEvent, SessionDeletedEvent, SessionUpdatedEvent, SessionForegroundEvent, SessionBackgroundEvent, SessionContext, SessionListFilter, SessionMetadata, SessionUiApi, SessionFsConfig, SessionFsProvider, SessionFsFileInfo, SessionFsSqliteQueryResult, SessionFsSqliteQueryType, SessionFsSqliteProvider, SessionFsSqliteStatement, SessionFsSqliteTransactionErrorClass, CopilotRequestContext, SystemMessageAppendConfig, SystemMessageConfig, SystemMessageCustomizeConfig, SystemMessageReplaceConfig, SystemMessageSection, TelemetryConfig, TraceContext, TraceContextProvider, Tool, ToolHandler, ToolInvocation, CurrentToolMetadata, ToolTelemetry, ToolResultObject, ToolSearchConfig, TypedSessionEventHandler, TypedSessionLifecycleHandler, ZodSchema, } from "./types.js";
|
|
16
|
+
export type { AskUserVariant, CommandContext, CommandDefinition, CommandHandler, CanvasProviderIdentity, CloudSessionOptions, CloudSessionRepository, AuthIdentityMetadata, AuthInfoType, ConnectorAccountRequest, ConnectorAvailability, ConnectorCapabilities, ConnectorCatalogEntry, ConnectorCatalogResult, ConnectorCatalogStatus, ConnectorConnectRequest, ConnectorConnectResult, ConnectorContinueRequest, ConnectorDisconnectResult, ConnectorMcpStatus, ConnectorReconcileRequest, ConnectorRuntimeStatus, ConnectorSessionAccount, ConnectorSessionAccountResult, ConnectorStatus, AutoModeSwitchHandler, AutoModeSwitchRequest, AutoModeSwitchResponse, AgentStopHandler, AgentStopHookInput, AgentStopHookOutput, SubagentStartHandler, SubagentStartHookInput, SubagentStartHookOutput, SubagentStopHandler, SubagentStopHookInput, SubagentStopHookOutput, UserPromptTransformedHandler, UserPromptTransformedHookInput, UserPromptTransformedHookOutput, CopilotClientInfo, CopilotClientMode, CopilotClientOptions, InstallationConfirmationHandler, InstallationConfirmationRequest, InstallationConfirmationResponse, InstallationDecision, InstallationReview, McpInstallationReview, CopilotExpAssignmentResponse, StdioRuntimeConnection, InProcessRuntimeConnection, TcpRuntimeConnection, UriRuntimeConnection, ChildProcessRuntimeConnection, CustomAgentConfig, ElicitationFieldValue, ElicitationHandler, ElicitationParams, ElicitationContext, ElicitationResult, ElicitationSchema, ElicitationSchemaField, ExpConfigEntry, ExpFlagValue, ExitPlanModeHandler, ExitPlanModeRequest, ExitPlanModeResult, ExtensionLaunchProfile, ExtensionLaunchProvider, ExtensionLaunchProviderResolveRequest, ExtensionLaunchProviderResolveResult, ExtensionInfo, ForegroundSessionInfo, GetAuthStatusResponse, GetStatusResponse, GitHubMcpToolConfig, GitHubTelemetryNotification, GitHubTelemetryEvent, GitHubTelemetryClientInfo, GitHubTokenAcquireReason, GitHubTokenAcquireResult, GitHubTokenProvider, GitHubTokenProviderArgs, GitHubTokenProviderResult, InfiniteSessionConfig, LargeToolOutputConfig, MemoryConfiguration, UiInputOptions, MCPStdioServerConfig, MCPHTTPServerConfig, MCPServerConfig, DefaultAgentConfig, BearerTokenProvider, ExtensionContextAttachment, MessageOptions, ResponseSchema, MessageSource, ManagedSettings, ManagedSettingsPermissions, ModelBilling, ModelBillingTokenPrices, ModelBillingTokenPricesLongContext, AutoTier, CapiSessionOptions, CurrentModel, ModelSwitchAutoTierResult, ModelSwitchAutoTierStatus, ModelCapabilities, ModelCapabilitiesOverride, ModelInfo, ModelPolicy, NamedProviderConfig, PermissionHandler, PermissionRequest, PermissionRequestedData, PermissionRequestedEvent, PermissionRequestResult, AttributedPermissionResult, PermissionDecisionContext, PermissionDecisionOutcome, PermissionDecisionSource, PermissionDecisionSurface, PermissionResponseCapability, ProviderConfig, ProviderConfigModelProvider, ProviderModelConfig, ProviderTokenArgs, RemoteSessionMode, SandboxConfigSource, ResumeSessionConfig, TranscriptRecovery, SectionOverride, SectionOverrideAction, SectionTransformFn, SessionCapabilities, SessionConfig, SessionConfigBase, SessionEvent, SessionEventHandler, SessionEventPayload, SessionEventType, SessionLifecycleEvent, SessionLifecycleEventMetadata, SessionLifecycleEventType, SessionLifecycleHandler, SessionHooks, SessionCreatedEvent, SessionDeletedEvent, SessionUpdatedEvent, SessionForegroundEvent, SessionBackgroundEvent, SessionContext, SessionListFilter, SessionMetadata, SessionUiApi, SessionFsConfig, SessionFsProvider, SessionFsFileInfo, SessionFsSqliteQueryResult, SessionFsSqliteQueryType, SessionFsSqliteProvider, SessionFsSqliteStatement, SessionFsSqliteTransactionErrorClass, CopilotRequestContext, SystemMessageAppendConfig, SystemMessageConfig, SystemMessageCustomizeConfig, SystemMessageReplaceConfig, SystemMessageSection, TelemetryConfig, TraceContext, TraceContextProvider, Tool, ToolHandler, ToolInvocation, CurrentToolMetadata, ToolTelemetry, ToolResultObject, ToolSearchConfig, TypedSessionEventHandler, TypedSessionLifecycleHandler, ZodSchema, } from "./types.js";
|
|
17
17
|
export type { JsonValue, WorkflowRunOptions, WorkflowResumeOptions, WorkflowLimitOverrides, WorkflowResumeErrorCode, SessionWorkflowApi, WorkflowAgentOptions, WorkflowContext, WorkflowDefinition, WorkflowHandle, WorkflowJsonSchema, WorkflowLimits, WorkflowMeta, WorkflowPipelineStage, WorkflowStepOptions, WorkflowRunResult, WorkflowRunStatus, WorkflowRunSummary, WorkflowListRunsOptions, WorkflowRunsPage, WorkflowRunDetail, WorkflowProgressPage, WorkflowProgressLine, WorkflowPhaseObservation, WorkflowPhaseStatus, WorkflowAgentSummary, } from "./workflow.js";
|