@github/copilot-sdk 1.0.6 → 1.0.7-preview.1
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/cjs/client.js +166 -38
- package/dist/cjs/copilotRequestHandler.js +9 -0
- package/dist/cjs/ffiRuntimeHost.js +282 -0
- package/dist/cjs/generated/rpc.js +63 -15
- package/dist/cjs/types.js +12 -0
- package/dist/client.d.ts +49 -0
- package/dist/client.js +156 -38
- package/dist/copilotRequestHandler.d.ts +3 -0
- package/dist/copilotRequestHandler.js +9 -0
- package/dist/ffiRuntimeHost.d.ts +40 -0
- package/dist/ffiRuntimeHost.js +248 -0
- package/dist/generated/rpc.d.ts +459 -9
- package/dist/generated/rpc.js +63 -15
- package/dist/generated/session-events.d.ts +174 -1
- package/dist/index.d.ts +1 -1
- package/dist/types.d.ts +60 -1
- package/dist/types.js +12 -0
- package/package.json +3 -2
package/dist/generated/rpc.d.ts
CHANGED
|
@@ -5791,24 +5791,27 @@ export interface McpAppsListToolsResult {
|
|
|
5791
5791
|
}[];
|
|
5792
5792
|
}
|
|
5793
5793
|
/**
|
|
5794
|
-
*
|
|
5794
|
+
* @deprecated
|
|
5795
|
+
* Deprecated/obsolete MCP Apps alias for `McpResourcesReadRequest`; use `session.mcp.resources.read` instead.
|
|
5795
5796
|
*
|
|
5796
5797
|
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
5797
5798
|
* via the `definition` "McpAppsReadResourceRequest".
|
|
5798
5799
|
*/
|
|
5799
5800
|
/** @experimental */
|
|
5801
|
+
/** @deprecated */
|
|
5800
5802
|
export interface McpAppsReadResourceRequest {
|
|
5801
5803
|
/**
|
|
5802
5804
|
* Name of the MCP server hosting the resource
|
|
5803
5805
|
*/
|
|
5804
5806
|
serverName: string;
|
|
5805
5807
|
/**
|
|
5806
|
-
* Resource URI
|
|
5808
|
+
* Resource URI
|
|
5807
5809
|
*/
|
|
5808
5810
|
uri: string;
|
|
5809
5811
|
}
|
|
5810
5812
|
/**
|
|
5811
|
-
*
|
|
5813
|
+
* @deprecated
|
|
5814
|
+
* Deprecated/obsolete MCP Apps alias for `McpResourcesReadResult`; use `session.mcp.resources.read` instead.
|
|
5812
5815
|
*
|
|
5813
5816
|
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
5814
5817
|
* via the `definition` "McpAppsReadResourceResult".
|
|
@@ -5821,7 +5824,8 @@ export interface McpAppsReadResourceResult {
|
|
|
5821
5824
|
contents: McpAppsResourceContent[];
|
|
5822
5825
|
}
|
|
5823
5826
|
/**
|
|
5824
|
-
*
|
|
5827
|
+
* @deprecated
|
|
5828
|
+
* Deprecated/obsolete MCP Apps alias for `McpResourceContent`; use `session.mcp.resources.read` instead.
|
|
5825
5829
|
*
|
|
5826
5830
|
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
5827
5831
|
* via the `definition` "McpAppsResourceContent".
|
|
@@ -5829,7 +5833,7 @@ export interface McpAppsReadResourceResult {
|
|
|
5829
5833
|
/** @experimental */
|
|
5830
5834
|
export interface McpAppsResourceContent {
|
|
5831
5835
|
/**
|
|
5832
|
-
* The resource URI
|
|
5836
|
+
* The resource URI
|
|
5833
5837
|
*/
|
|
5834
5838
|
uri: string;
|
|
5835
5839
|
/**
|
|
@@ -5845,7 +5849,7 @@ export interface McpAppsResourceContent {
|
|
|
5845
5849
|
*/
|
|
5846
5850
|
blob?: string;
|
|
5847
5851
|
/**
|
|
5848
|
-
* Resource-level metadata
|
|
5852
|
+
* Resource-level metadata
|
|
5849
5853
|
*/
|
|
5850
5854
|
_meta?: {
|
|
5851
5855
|
[k: string]: unknown | undefined;
|
|
@@ -6491,6 +6495,303 @@ export interface McpRemoveGitHubResult {
|
|
|
6491
6495
|
*/
|
|
6492
6496
|
removed: boolean;
|
|
6493
6497
|
}
|
|
6498
|
+
/**
|
|
6499
|
+
* An MCP resource descriptor (spec `Resource`): URI, name, and optional title, description, MIME type, size, icons, annotations, and metadata. Server-provided fields outside the standard descriptor shape are exposed under `additionalProperties`.
|
|
6500
|
+
*
|
|
6501
|
+
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
6502
|
+
* via the `definition` "McpResource".
|
|
6503
|
+
*/
|
|
6504
|
+
/** @experimental */
|
|
6505
|
+
export interface McpResource {
|
|
6506
|
+
/**
|
|
6507
|
+
* The resource URI (e.g. ui://... or file:///...)
|
|
6508
|
+
*/
|
|
6509
|
+
uri: string;
|
|
6510
|
+
/**
|
|
6511
|
+
* The programmatic name of the resource
|
|
6512
|
+
*/
|
|
6513
|
+
name: string;
|
|
6514
|
+
/**
|
|
6515
|
+
* Optional human-readable display title
|
|
6516
|
+
*/
|
|
6517
|
+
title?: string;
|
|
6518
|
+
/**
|
|
6519
|
+
* Optional description of what this resource represents
|
|
6520
|
+
*/
|
|
6521
|
+
description?: string;
|
|
6522
|
+
/**
|
|
6523
|
+
* MIME type of the resource, if known
|
|
6524
|
+
*/
|
|
6525
|
+
mimeType?: string;
|
|
6526
|
+
/**
|
|
6527
|
+
* Resource size in bytes, when known
|
|
6528
|
+
*/
|
|
6529
|
+
size?: number;
|
|
6530
|
+
/**
|
|
6531
|
+
* Icons associated with this resource
|
|
6532
|
+
*/
|
|
6533
|
+
icons?: McpResourceIcon[];
|
|
6534
|
+
annotations?: McpResourceAnnotations;
|
|
6535
|
+
/**
|
|
6536
|
+
* Resource-level metadata
|
|
6537
|
+
*/
|
|
6538
|
+
_meta?: {
|
|
6539
|
+
[k: string]: unknown | undefined;
|
|
6540
|
+
};
|
|
6541
|
+
/**
|
|
6542
|
+
* Server-provided non-standard descriptor fields preserved from the MCP response
|
|
6543
|
+
*/
|
|
6544
|
+
additionalProperties?: {
|
|
6545
|
+
[k: string]: unknown | undefined;
|
|
6546
|
+
};
|
|
6547
|
+
}
|
|
6548
|
+
/**
|
|
6549
|
+
* A resource icon descriptor plus preserved non-standard icon fields.
|
|
6550
|
+
*
|
|
6551
|
+
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
6552
|
+
* via the `definition` "McpResourceIcon".
|
|
6553
|
+
*/
|
|
6554
|
+
/** @experimental */
|
|
6555
|
+
export interface McpResourceIcon {
|
|
6556
|
+
/**
|
|
6557
|
+
* Icon URI
|
|
6558
|
+
*/
|
|
6559
|
+
src: string;
|
|
6560
|
+
/**
|
|
6561
|
+
* Icon MIME type, when known
|
|
6562
|
+
*/
|
|
6563
|
+
mimeType?: string;
|
|
6564
|
+
/**
|
|
6565
|
+
* Icon sizes hint
|
|
6566
|
+
*/
|
|
6567
|
+
sizes?: string;
|
|
6568
|
+
/**
|
|
6569
|
+
* Theme hint for this icon
|
|
6570
|
+
*/
|
|
6571
|
+
theme?: string;
|
|
6572
|
+
/**
|
|
6573
|
+
* Server-provided non-standard icon fields preserved from the MCP response
|
|
6574
|
+
*/
|
|
6575
|
+
additionalProperties?: {
|
|
6576
|
+
[k: string]: unknown | undefined;
|
|
6577
|
+
};
|
|
6578
|
+
}
|
|
6579
|
+
/**
|
|
6580
|
+
* Standard MCP resource annotations plus preserved non-standard annotation fields.
|
|
6581
|
+
*
|
|
6582
|
+
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
6583
|
+
* via the `definition` "McpResourceAnnotations".
|
|
6584
|
+
*/
|
|
6585
|
+
/** @experimental */
|
|
6586
|
+
export interface McpResourceAnnotations {
|
|
6587
|
+
/**
|
|
6588
|
+
* Intended audience roles for this resource
|
|
6589
|
+
*/
|
|
6590
|
+
audience?: string[];
|
|
6591
|
+
/**
|
|
6592
|
+
* Priority hint for model/client use
|
|
6593
|
+
*/
|
|
6594
|
+
priority?: number;
|
|
6595
|
+
/**
|
|
6596
|
+
* Last-modified timestamp hint
|
|
6597
|
+
*/
|
|
6598
|
+
lastModified?: string;
|
|
6599
|
+
/**
|
|
6600
|
+
* Server-provided non-standard annotation fields preserved from the MCP response
|
|
6601
|
+
*/
|
|
6602
|
+
additionalProperties?: {
|
|
6603
|
+
[k: string]: unknown | undefined;
|
|
6604
|
+
};
|
|
6605
|
+
}
|
|
6606
|
+
/**
|
|
6607
|
+
* MCP resource content with URI, optional MIME type, text or base64 blob, and resource metadata.
|
|
6608
|
+
*
|
|
6609
|
+
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
6610
|
+
* via the `definition` "McpResourceContent".
|
|
6611
|
+
*/
|
|
6612
|
+
/** @experimental */
|
|
6613
|
+
export interface McpResourceContent {
|
|
6614
|
+
/**
|
|
6615
|
+
* The resource URI
|
|
6616
|
+
*/
|
|
6617
|
+
uri: string;
|
|
6618
|
+
/**
|
|
6619
|
+
* MIME type of the content
|
|
6620
|
+
*/
|
|
6621
|
+
mimeType?: string;
|
|
6622
|
+
/**
|
|
6623
|
+
* Text content (e.g. HTML)
|
|
6624
|
+
*/
|
|
6625
|
+
text?: string;
|
|
6626
|
+
/**
|
|
6627
|
+
* Base64-encoded binary content
|
|
6628
|
+
*/
|
|
6629
|
+
blob?: string;
|
|
6630
|
+
/**
|
|
6631
|
+
* Resource-level metadata (CSP, permissions, etc.)
|
|
6632
|
+
*/
|
|
6633
|
+
_meta?: {
|
|
6634
|
+
[k: string]: unknown | undefined;
|
|
6635
|
+
};
|
|
6636
|
+
}
|
|
6637
|
+
/**
|
|
6638
|
+
* MCP server whose resources to enumerate.
|
|
6639
|
+
*
|
|
6640
|
+
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
6641
|
+
* via the `definition` "McpResourcesListRequest".
|
|
6642
|
+
*/
|
|
6643
|
+
/** @experimental */
|
|
6644
|
+
export interface McpResourcesListRequest {
|
|
6645
|
+
/**
|
|
6646
|
+
* Name of the MCP server whose resources to enumerate
|
|
6647
|
+
*/
|
|
6648
|
+
serverName: string;
|
|
6649
|
+
/**
|
|
6650
|
+
* Opaque MCP pagination cursor from a prior `nextCursor` value
|
|
6651
|
+
*/
|
|
6652
|
+
cursor?: string;
|
|
6653
|
+
}
|
|
6654
|
+
/**
|
|
6655
|
+
* One page of resources advertised by the named MCP server.
|
|
6656
|
+
*
|
|
6657
|
+
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
6658
|
+
* via the `definition` "McpResourcesListResult".
|
|
6659
|
+
*/
|
|
6660
|
+
/** @experimental */
|
|
6661
|
+
export interface McpResourcesListResult {
|
|
6662
|
+
/**
|
|
6663
|
+
* Resources advertised by the server (proxied MCP `resources/list`)
|
|
6664
|
+
*/
|
|
6665
|
+
resources: McpResource[];
|
|
6666
|
+
/**
|
|
6667
|
+
* Opaque cursor for the next page, if the server has more resources
|
|
6668
|
+
*/
|
|
6669
|
+
nextCursor?: string;
|
|
6670
|
+
}
|
|
6671
|
+
/**
|
|
6672
|
+
* MCP server whose resource templates to enumerate.
|
|
6673
|
+
*
|
|
6674
|
+
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
6675
|
+
* via the `definition` "McpResourcesListTemplatesRequest".
|
|
6676
|
+
*/
|
|
6677
|
+
/** @experimental */
|
|
6678
|
+
export interface McpResourcesListTemplatesRequest {
|
|
6679
|
+
/**
|
|
6680
|
+
* Name of the MCP server whose resource templates to enumerate
|
|
6681
|
+
*/
|
|
6682
|
+
serverName: string;
|
|
6683
|
+
/**
|
|
6684
|
+
* Opaque MCP pagination cursor from a prior `nextCursor` value
|
|
6685
|
+
*/
|
|
6686
|
+
cursor?: string;
|
|
6687
|
+
}
|
|
6688
|
+
/**
|
|
6689
|
+
* One page of resource templates advertised by the named MCP server.
|
|
6690
|
+
*
|
|
6691
|
+
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
6692
|
+
* via the `definition` "McpResourcesListTemplatesResult".
|
|
6693
|
+
*/
|
|
6694
|
+
/** @experimental */
|
|
6695
|
+
export interface McpResourcesListTemplatesResult {
|
|
6696
|
+
/**
|
|
6697
|
+
* Resource templates advertised by the server (proxied MCP `resources/templates/list`)
|
|
6698
|
+
*/
|
|
6699
|
+
resourceTemplates: McpResourceTemplate[];
|
|
6700
|
+
/**
|
|
6701
|
+
* Opaque cursor for the next page, if the server has more resource templates
|
|
6702
|
+
*/
|
|
6703
|
+
nextCursor?: string;
|
|
6704
|
+
}
|
|
6705
|
+
/**
|
|
6706
|
+
* An MCP resource template descriptor (spec `ResourceTemplate`): an RFC 6570 URI template, name, and optional title, description, MIME type, icons, annotations, and metadata. Server-provided fields outside the standard descriptor shape are exposed under `additionalProperties`.
|
|
6707
|
+
*
|
|
6708
|
+
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
6709
|
+
* via the `definition` "McpResourceTemplate".
|
|
6710
|
+
*/
|
|
6711
|
+
/** @experimental */
|
|
6712
|
+
export interface McpResourceTemplate {
|
|
6713
|
+
/**
|
|
6714
|
+
* An RFC 6570 URI template for constructing resource URIs
|
|
6715
|
+
*/
|
|
6716
|
+
uriTemplate: string;
|
|
6717
|
+
/**
|
|
6718
|
+
* The programmatic name of the resource template
|
|
6719
|
+
*/
|
|
6720
|
+
name: string;
|
|
6721
|
+
/**
|
|
6722
|
+
* Optional human-readable display title
|
|
6723
|
+
*/
|
|
6724
|
+
title?: string;
|
|
6725
|
+
/**
|
|
6726
|
+
* Optional description of what this template is for
|
|
6727
|
+
*/
|
|
6728
|
+
description?: string;
|
|
6729
|
+
/**
|
|
6730
|
+
* MIME type for resources matching this template, if uniform
|
|
6731
|
+
*/
|
|
6732
|
+
mimeType?: string;
|
|
6733
|
+
/**
|
|
6734
|
+
* Icons associated with resources matching this template
|
|
6735
|
+
*/
|
|
6736
|
+
icons?: McpResourceIcon[];
|
|
6737
|
+
annotations?: McpResourceAnnotations;
|
|
6738
|
+
/**
|
|
6739
|
+
* Resource-template-level metadata
|
|
6740
|
+
*/
|
|
6741
|
+
_meta?: {
|
|
6742
|
+
[k: string]: unknown | undefined;
|
|
6743
|
+
};
|
|
6744
|
+
/**
|
|
6745
|
+
* Server-provided non-standard descriptor fields preserved from the MCP response
|
|
6746
|
+
*/
|
|
6747
|
+
additionalProperties?: {
|
|
6748
|
+
[k: string]: unknown | undefined;
|
|
6749
|
+
};
|
|
6750
|
+
}
|
|
6751
|
+
/**
|
|
6752
|
+
* MCP server and resource URI to fetch.
|
|
6753
|
+
*
|
|
6754
|
+
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
6755
|
+
* via the `definition` "McpResourcesReadRequest".
|
|
6756
|
+
*/
|
|
6757
|
+
/** @experimental */
|
|
6758
|
+
export interface McpResourcesReadRequest {
|
|
6759
|
+
/**
|
|
6760
|
+
* Name of the MCP server hosting the resource
|
|
6761
|
+
*/
|
|
6762
|
+
serverName: string;
|
|
6763
|
+
/**
|
|
6764
|
+
* Resource URI
|
|
6765
|
+
*/
|
|
6766
|
+
uri: string;
|
|
6767
|
+
}
|
|
6768
|
+
/**
|
|
6769
|
+
* Resource contents returned by the MCP server.
|
|
6770
|
+
*
|
|
6771
|
+
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
6772
|
+
* via the `definition` "McpResourcesReadResult".
|
|
6773
|
+
*/
|
|
6774
|
+
/** @experimental */
|
|
6775
|
+
export interface McpResourcesReadResult {
|
|
6776
|
+
/**
|
|
6777
|
+
* Resource contents returned by the server
|
|
6778
|
+
*/
|
|
6779
|
+
contents: McpResourceContent[];
|
|
6780
|
+
}
|
|
6781
|
+
/**
|
|
6782
|
+
* Server name and optional replacement configuration for an individual MCP server restart. Omit `config` for a config-free restart-by-name of an already-configured server.
|
|
6783
|
+
*
|
|
6784
|
+
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
6785
|
+
* via the `definition` "McpRestartServerRequest".
|
|
6786
|
+
*/
|
|
6787
|
+
/** @experimental */
|
|
6788
|
+
export interface McpRestartServerRequest {
|
|
6789
|
+
/**
|
|
6790
|
+
* Name of the MCP server to restart
|
|
6791
|
+
*/
|
|
6792
|
+
serverName: string;
|
|
6793
|
+
config?: McpServerConfig;
|
|
6794
|
+
}
|
|
6494
6795
|
/**
|
|
6495
6796
|
* Outcome of an MCP sampling execution: success result, failure error, or cancellation.
|
|
6496
6797
|
*
|
|
@@ -6567,6 +6868,20 @@ export interface McpSetEnvValueModeParams {
|
|
|
6567
6868
|
export interface McpSetEnvValueModeResult {
|
|
6568
6869
|
mode: McpSetEnvValueModeDetails;
|
|
6569
6870
|
}
|
|
6871
|
+
/**
|
|
6872
|
+
* Server name and configuration for an individual MCP server start.
|
|
6873
|
+
*
|
|
6874
|
+
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
6875
|
+
* via the `definition` "McpStartServerRequest".
|
|
6876
|
+
*/
|
|
6877
|
+
/** @experimental */
|
|
6878
|
+
export interface McpStartServerRequest {
|
|
6879
|
+
/**
|
|
6880
|
+
* Name of the MCP server to start
|
|
6881
|
+
*/
|
|
6882
|
+
serverName: string;
|
|
6883
|
+
config: McpServerConfig;
|
|
6884
|
+
}
|
|
6570
6885
|
/**
|
|
6571
6886
|
* MCP server startup filtering result.
|
|
6572
6887
|
*
|
|
@@ -10468,6 +10783,81 @@ export interface SendAttachmentsToMessageParams {
|
|
|
10468
10783
|
*/
|
|
10469
10784
|
attachments: PushAttachment[];
|
|
10470
10785
|
}
|
|
10786
|
+
/**
|
|
10787
|
+
* A single user message to append to the session as part of a `session.sendMessages` turn
|
|
10788
|
+
*
|
|
10789
|
+
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
10790
|
+
* via the `definition` "SendMessageItem".
|
|
10791
|
+
*/
|
|
10792
|
+
/** @experimental */
|
|
10793
|
+
export interface SendMessageItem {
|
|
10794
|
+
/**
|
|
10795
|
+
* The user message text
|
|
10796
|
+
*/
|
|
10797
|
+
prompt: string;
|
|
10798
|
+
/**
|
|
10799
|
+
* If provided, this is shown in the timeline instead of `prompt`
|
|
10800
|
+
*/
|
|
10801
|
+
displayPrompt?: string;
|
|
10802
|
+
/**
|
|
10803
|
+
* Optional attachments (files, directories, selections, blobs, GitHub references) to include with this message
|
|
10804
|
+
*/
|
|
10805
|
+
attachments?: Attachment[];
|
|
10806
|
+
/**
|
|
10807
|
+
* If set, the request will fail if the named tool is not available when this message is among the user messages at the start of the current exchange
|
|
10808
|
+
*/
|
|
10809
|
+
requiredTool?: string;
|
|
10810
|
+
}
|
|
10811
|
+
/**
|
|
10812
|
+
* Parameters for sending zero or more user messages to the session in a single turn. Remote-backed (Mission Control) sessions do not support this method and will return an error.
|
|
10813
|
+
*
|
|
10814
|
+
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
10815
|
+
* via the `definition` "SendMessagesRequest".
|
|
10816
|
+
*/
|
|
10817
|
+
/** @experimental */
|
|
10818
|
+
export interface SendMessagesRequest {
|
|
10819
|
+
/**
|
|
10820
|
+
* The user messages to append to the conversation, in order. May be empty, in which case a single turn runs over the existing history with no new user message.
|
|
10821
|
+
*/
|
|
10822
|
+
messages: SendMessageItem[];
|
|
10823
|
+
mode?: SendMode;
|
|
10824
|
+
/**
|
|
10825
|
+
* If true, adds the messages to the front of the queue instead of the end
|
|
10826
|
+
*/
|
|
10827
|
+
prepend?: boolean;
|
|
10828
|
+
agentMode?: SendAgentMode;
|
|
10829
|
+
/**
|
|
10830
|
+
* Custom HTTP headers to include in outbound model requests for this turn. Merged with session-level provider headers; per-turn headers augment and overwrite session-level headers with the same key.
|
|
10831
|
+
*/
|
|
10832
|
+
requestHeaders?: {
|
|
10833
|
+
[k: string]: string | undefined;
|
|
10834
|
+
};
|
|
10835
|
+
/**
|
|
10836
|
+
* W3C Trace Context traceparent header for distributed tracing of this agent turn
|
|
10837
|
+
*/
|
|
10838
|
+
traceparent?: string;
|
|
10839
|
+
/**
|
|
10840
|
+
* W3C Trace Context tracestate header for distributed tracing
|
|
10841
|
+
*/
|
|
10842
|
+
tracestate?: string;
|
|
10843
|
+
/**
|
|
10844
|
+
* If true, await completion of the agentic loop for this turn before returning. Defaults to false (fire-and-forget). When true, the result still contains the same `messageIds`; the caller can rely on the agent having processed the messages before the call resolves.
|
|
10845
|
+
*/
|
|
10846
|
+
wait?: boolean;
|
|
10847
|
+
}
|
|
10848
|
+
/**
|
|
10849
|
+
* Result of sending zero or more user messages
|
|
10850
|
+
*
|
|
10851
|
+
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
10852
|
+
* via the `definition` "SendMessagesResult".
|
|
10853
|
+
*/
|
|
10854
|
+
/** @experimental */
|
|
10855
|
+
export interface SendMessagesResult {
|
|
10856
|
+
/**
|
|
10857
|
+
* Unique identifiers assigned to the messages, one per provided message in order. Empty when no messages were provided.
|
|
10858
|
+
*/
|
|
10859
|
+
messageIds: string[];
|
|
10860
|
+
}
|
|
10471
10861
|
/**
|
|
10472
10862
|
* Parameters for sending a user message to the session
|
|
10473
10863
|
*
|
|
@@ -15143,6 +15533,15 @@ export declare function createServerRpc(connection: MessageConnection): {
|
|
|
15143
15533
|
getDiscoveryPaths: (params: InstructionsGetDiscoveryPathsRequest) => Promise<InstructionDiscoveryPathList>;
|
|
15144
15534
|
};
|
|
15145
15535
|
/** @experimental */
|
|
15536
|
+
commands: {
|
|
15537
|
+
/**
|
|
15538
|
+
* Lists the well-known built-in slash commands that work as the first message in a new session (e.g. /plan, /env), without requiring an active session. Commands that depend on session state, authentication, or a synced session are omitted.
|
|
15539
|
+
*
|
|
15540
|
+
* @returns Slash commands available in the session, after applying any include/exclude filters.
|
|
15541
|
+
*/
|
|
15542
|
+
list: () => Promise<CommandList>;
|
|
15543
|
+
};
|
|
15544
|
+
/** @experimental */
|
|
15146
15545
|
user: {
|
|
15147
15546
|
/** @experimental */
|
|
15148
15547
|
settings: {
|
|
@@ -15422,6 +15821,16 @@ export declare function createSessionRpc(connection: MessageConnection, sessionI
|
|
|
15422
15821
|
* @experimental
|
|
15423
15822
|
*/
|
|
15424
15823
|
send: (params: SendRequest) => Promise<SendResult>;
|
|
15824
|
+
/**
|
|
15825
|
+
* Sends zero or more user messages to the session in a single turn and returns their message IDs. All provided messages are appended to the conversation in order, then exactly one agent turn runs over the resulting history. When the list is empty, one turn runs over the existing history with no new user message. Remote-backed (Mission Control) sessions do not support this method and will return an error.
|
|
15826
|
+
*
|
|
15827
|
+
* @param params Parameters for sending zero or more user messages to the session in a single turn. Remote-backed (Mission Control) sessions do not support this method and will return an error.
|
|
15828
|
+
*
|
|
15829
|
+
* @returns Result of sending zero or more user messages
|
|
15830
|
+
*
|
|
15831
|
+
* @experimental
|
|
15832
|
+
*/
|
|
15833
|
+
sendMessages: (params: SendMessagesRequest) => Promise<SendMessagesResult>;
|
|
15425
15834
|
/**
|
|
15426
15835
|
* Aborts the current agent turn.
|
|
15427
15836
|
*
|
|
@@ -15919,6 +16328,18 @@ export declare function createSessionRpc(connection: MessageConnection, sessionI
|
|
|
15919
16328
|
* @returns Indicates whether the auto-managed `github` MCP server was removed (false when nothing to remove).
|
|
15920
16329
|
*/
|
|
15921
16330
|
removeGitHub: () => Promise<McpRemoveGitHubResult>;
|
|
16331
|
+
/**
|
|
16332
|
+
* Starts an individual MCP server on the live session from a caller-supplied config. Session-scoped and ephemeral: the server is added to this session's running set only and is reaped when the session ends. Does NOT modify persistent user configuration (`mcp.config.*`), so it does not affect future sessions. The server surfaces through `session.mcp.list` and the `session.mcp_servers_loaded` / `session.mcp_server_status_changed` events like any other server.
|
|
16333
|
+
*
|
|
16334
|
+
* @param params Server name and configuration for an individual MCP server start.
|
|
16335
|
+
*/
|
|
16336
|
+
startServer: (params: McpStartServerRequest) => Promise<void>;
|
|
16337
|
+
/**
|
|
16338
|
+
* Restarts an individual MCP server on the live session (stops then starts). Omit `config` for a config-free restart-by-name of an already-configured server; supply `config` to restart with a replacement configuration. Session-scoped and ephemeral: does NOT modify persistent user configuration (`mcp.config.*`).
|
|
16339
|
+
*
|
|
16340
|
+
* @param params Server name and optional replacement configuration for an individual MCP server restart. Omit `config` for a config-free restart-by-name of an already-configured server.
|
|
16341
|
+
*/
|
|
16342
|
+
restartServer: (params: McpRestartServerRequest) => Promise<void>;
|
|
15922
16343
|
/**
|
|
15923
16344
|
* Stops an individual MCP server on the session's host.
|
|
15924
16345
|
*
|
|
@@ -15966,11 +16387,13 @@ export declare function createSessionRpc(connection: MessageConnection, sessionI
|
|
|
15966
16387
|
/** @experimental */
|
|
15967
16388
|
apps: {
|
|
15968
16389
|
/**
|
|
15969
|
-
*
|
|
16390
|
+
* Deprecated/obsolete alias for `session.mcp.resources.read`; retained for backwards compatibility with earlier MCP Apps host integrations.
|
|
15970
16391
|
*
|
|
15971
|
-
* @param params MCP
|
|
16392
|
+
* @param params Deprecated/obsolete MCP Apps alias for `McpResourcesReadRequest`; use `session.mcp.resources.read` instead.
|
|
15972
16393
|
*
|
|
15973
|
-
* @returns
|
|
16394
|
+
* @returns Deprecated/obsolete MCP Apps alias for `McpResourcesReadResult`; use `session.mcp.resources.read` instead.
|
|
16395
|
+
*
|
|
16396
|
+
* @deprecated
|
|
15974
16397
|
*/
|
|
15975
16398
|
readResource: (params: McpAppsReadResourceRequest) => Promise<McpAppsReadResourceResult>;
|
|
15976
16399
|
/**
|
|
@@ -16010,6 +16433,33 @@ export declare function createSessionRpc(connection: MessageConnection, sessionI
|
|
|
16010
16433
|
*/
|
|
16011
16434
|
diagnose: (params: McpAppsDiagnoseRequest) => Promise<McpAppsDiagnoseResult>;
|
|
16012
16435
|
};
|
|
16436
|
+
/** @experimental */
|
|
16437
|
+
resources: {
|
|
16438
|
+
/**
|
|
16439
|
+
* Fetch an MCP resource from a connected server by URI (proxies MCP `resources/read`).
|
|
16440
|
+
*
|
|
16441
|
+
* @param params MCP server and resource URI to fetch.
|
|
16442
|
+
*
|
|
16443
|
+
* @returns Resource contents returned by the MCP server.
|
|
16444
|
+
*/
|
|
16445
|
+
read: (params: McpResourcesReadRequest) => Promise<McpResourcesReadResult>;
|
|
16446
|
+
/**
|
|
16447
|
+
* Enumerate one page of resources a connected MCP server exposes (proxies MCP `resources/list`). Pass `cursor` to continue from a prior result's `nextCursor`.
|
|
16448
|
+
*
|
|
16449
|
+
* @param params MCP server whose resources to enumerate.
|
|
16450
|
+
*
|
|
16451
|
+
* @returns One page of resources advertised by the named MCP server.
|
|
16452
|
+
*/
|
|
16453
|
+
list: (params: McpResourcesListRequest) => Promise<McpResourcesListResult>;
|
|
16454
|
+
/**
|
|
16455
|
+
* Enumerate one page of resource templates a connected MCP server exposes (proxies MCP `resources/templates/list`). Pass `cursor` to continue from a prior result's `nextCursor`.
|
|
16456
|
+
*
|
|
16457
|
+
* @param params MCP server whose resource templates to enumerate.
|
|
16458
|
+
*
|
|
16459
|
+
* @returns One page of resource templates advertised by the named MCP server.
|
|
16460
|
+
*/
|
|
16461
|
+
listTemplates: (params: McpResourcesListTemplatesRequest) => Promise<McpResourcesListTemplatesResult>;
|
|
16462
|
+
};
|
|
16013
16463
|
};
|
|
16014
16464
|
/** @experimental */
|
|
16015
16465
|
plugins: {
|
package/dist/generated/rpc.js
CHANGED
|
@@ -293,6 +293,15 @@ function createServerRpc(connection) {
|
|
|
293
293
|
getDiscoveryPaths: async (params) => connection.sendRequest("instructions.getDiscoveryPaths", params)
|
|
294
294
|
},
|
|
295
295
|
/** @experimental */
|
|
296
|
+
commands: {
|
|
297
|
+
/**
|
|
298
|
+
* Lists the well-known built-in slash commands that work as the first message in a new session (e.g. /plan, /env), without requiring an active session. Commands that depend on session state, authentication, or a synced session are omitted.
|
|
299
|
+
*
|
|
300
|
+
* @returns Slash commands available in the session, after applying any include/exclude filters.
|
|
301
|
+
*/
|
|
302
|
+
list: async () => connection.sendRequest("commands.list", {})
|
|
303
|
+
},
|
|
304
|
+
/** @experimental */
|
|
296
305
|
user: {
|
|
297
306
|
/** @experimental */
|
|
298
307
|
settings: {
|
|
@@ -628,6 +637,16 @@ function createSessionRpc(connection, sessionId) {
|
|
|
628
637
|
* @experimental
|
|
629
638
|
*/
|
|
630
639
|
send: async (params) => connection.sendRequest("session.send", { sessionId, ...params }),
|
|
640
|
+
/**
|
|
641
|
+
* Sends zero or more user messages to the session in a single turn and returns their message IDs. All provided messages are appended to the conversation in order, then exactly one agent turn runs over the resulting history. When the list is empty, one turn runs over the existing history with no new user message. Remote-backed (Mission Control) sessions do not support this method and will return an error.
|
|
642
|
+
*
|
|
643
|
+
* @param params Parameters for sending zero or more user messages to the session in a single turn. Remote-backed (Mission Control) sessions do not support this method and will return an error.
|
|
644
|
+
*
|
|
645
|
+
* @returns Result of sending zero or more user messages
|
|
646
|
+
*
|
|
647
|
+
* @experimental
|
|
648
|
+
*/
|
|
649
|
+
sendMessages: async (params) => connection.sendRequest("session.sendMessages", { sessionId, ...params }),
|
|
631
650
|
/**
|
|
632
651
|
* Aborts the current agent turn.
|
|
633
652
|
*
|
|
@@ -1125,6 +1144,18 @@ function createSessionRpc(connection, sessionId) {
|
|
|
1125
1144
|
* @returns Indicates whether the auto-managed `github` MCP server was removed (false when nothing to remove).
|
|
1126
1145
|
*/
|
|
1127
1146
|
removeGitHub: async () => connection.sendRequest("session.mcp.removeGitHub", { sessionId }),
|
|
1147
|
+
/**
|
|
1148
|
+
* Starts an individual MCP server on the live session from a caller-supplied config. Session-scoped and ephemeral: the server is added to this session's running set only and is reaped when the session ends. Does NOT modify persistent user configuration (`mcp.config.*`), so it does not affect future sessions. The server surfaces through `session.mcp.list` and the `session.mcp_servers_loaded` / `session.mcp_server_status_changed` events like any other server.
|
|
1149
|
+
*
|
|
1150
|
+
* @param params Server name and configuration for an individual MCP server start.
|
|
1151
|
+
*/
|
|
1152
|
+
startServer: async (params) => connection.sendRequest("session.mcp.startServer", { sessionId, ...params }),
|
|
1153
|
+
/**
|
|
1154
|
+
* Restarts an individual MCP server on the live session (stops then starts). Omit `config` for a config-free restart-by-name of an already-configured server; supply `config` to restart with a replacement configuration. Session-scoped and ephemeral: does NOT modify persistent user configuration (`mcp.config.*`).
|
|
1155
|
+
*
|
|
1156
|
+
* @param params Server name and optional replacement configuration for an individual MCP server restart. Omit `config` for a config-free restart-by-name of an already-configured server.
|
|
1157
|
+
*/
|
|
1158
|
+
restartServer: async (params) => connection.sendRequest("session.mcp.restartServer", { sessionId, ...params }),
|
|
1128
1159
|
/**
|
|
1129
1160
|
* Stops an individual MCP server on the session's host.
|
|
1130
1161
|
*
|
|
@@ -1172,11 +1203,13 @@ function createSessionRpc(connection, sessionId) {
|
|
|
1172
1203
|
/** @experimental */
|
|
1173
1204
|
apps: {
|
|
1174
1205
|
/**
|
|
1175
|
-
*
|
|
1206
|
+
* Deprecated/obsolete alias for `session.mcp.resources.read`; retained for backwards compatibility with earlier MCP Apps host integrations.
|
|
1176
1207
|
*
|
|
1177
|
-
* @param params MCP
|
|
1208
|
+
* @param params Deprecated/obsolete MCP Apps alias for `McpResourcesReadRequest`; use `session.mcp.resources.read` instead.
|
|
1178
1209
|
*
|
|
1179
|
-
* @returns
|
|
1210
|
+
* @returns Deprecated/obsolete MCP Apps alias for `McpResourcesReadResult`; use `session.mcp.resources.read` instead.
|
|
1211
|
+
*
|
|
1212
|
+
* @deprecated
|
|
1180
1213
|
*/
|
|
1181
1214
|
readResource: async (params) => connection.sendRequest("session.mcp.apps.readResource", { sessionId, ...params }),
|
|
1182
1215
|
/**
|
|
@@ -1215,6 +1248,33 @@ function createSessionRpc(connection, sessionId) {
|
|
|
1215
1248
|
* @returns Diagnostic snapshot of MCP Apps wiring for the named server.
|
|
1216
1249
|
*/
|
|
1217
1250
|
diagnose: async (params) => connection.sendRequest("session.mcp.apps.diagnose", { sessionId, ...params })
|
|
1251
|
+
},
|
|
1252
|
+
/** @experimental */
|
|
1253
|
+
resources: {
|
|
1254
|
+
/**
|
|
1255
|
+
* Fetch an MCP resource from a connected server by URI (proxies MCP `resources/read`).
|
|
1256
|
+
*
|
|
1257
|
+
* @param params MCP server and resource URI to fetch.
|
|
1258
|
+
*
|
|
1259
|
+
* @returns Resource contents returned by the MCP server.
|
|
1260
|
+
*/
|
|
1261
|
+
read: async (params) => connection.sendRequest("session.mcp.resources.read", { sessionId, ...params }),
|
|
1262
|
+
/**
|
|
1263
|
+
* Enumerate one page of resources a connected MCP server exposes (proxies MCP `resources/list`). Pass `cursor` to continue from a prior result's `nextCursor`.
|
|
1264
|
+
*
|
|
1265
|
+
* @param params MCP server whose resources to enumerate.
|
|
1266
|
+
*
|
|
1267
|
+
* @returns One page of resources advertised by the named MCP server.
|
|
1268
|
+
*/
|
|
1269
|
+
list: async (params) => connection.sendRequest("session.mcp.resources.list", { sessionId, ...params }),
|
|
1270
|
+
/**
|
|
1271
|
+
* Enumerate one page of resource templates a connected MCP server exposes (proxies MCP `resources/templates/list`). Pass `cursor` to continue from a prior result's `nextCursor`.
|
|
1272
|
+
*
|
|
1273
|
+
* @param params MCP server whose resource templates to enumerate.
|
|
1274
|
+
*
|
|
1275
|
+
* @returns One page of resource templates advertised by the named MCP server.
|
|
1276
|
+
*/
|
|
1277
|
+
listTemplates: async (params) => connection.sendRequest("session.mcp.resources.listTemplates", { sessionId, ...params })
|
|
1218
1278
|
}
|
|
1219
1279
|
},
|
|
1220
1280
|
/** @experimental */
|
|
@@ -1944,18 +2004,6 @@ function createInternalSessionRpc(connection, sessionId) {
|
|
|
1944
2004
|
* @returns Result of configuring GitHub MCP.
|
|
1945
2005
|
*/
|
|
1946
2006
|
configureGitHub: async (params) => connection.sendRequest("session.mcp.configureGitHub", { sessionId, ...params }),
|
|
1947
|
-
/**
|
|
1948
|
-
* Starts an individual MCP server on the session's host.
|
|
1949
|
-
*
|
|
1950
|
-
* @param params Server name and opaque configuration for an individual MCP server start.
|
|
1951
|
-
*/
|
|
1952
|
-
startServer: async (params) => connection.sendRequest("session.mcp.startServer", { sessionId, ...params }),
|
|
1953
|
-
/**
|
|
1954
|
-
* Restarts an individual MCP server on the session's host (stops then starts).
|
|
1955
|
-
*
|
|
1956
|
-
* @param params Server name and opaque configuration for an individual MCP server restart.
|
|
1957
|
-
*/
|
|
1958
|
-
restartServer: async (params) => connection.sendRequest("session.mcp.restartServer", { sessionId, ...params }),
|
|
1959
2007
|
/**
|
|
1960
2008
|
* Registers a pre-connected external MCP client (e.g. IDE) on the session's host. The caller retains lifecycle ownership of the client and transport. Marked internal because the `client` and `transport` arguments are in-process MCP SDK instances that cannot be serialized across the JSON-RPC boundary; once the CLI moves on top of the SDK, external clients will be expressed as transport configs the runtime can construct itself.
|
|
1961
2009
|
*
|