@github/copilot-sdk 1.0.29-preview.1 → 1.0.29-preview.3
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/README.md +436 -2
- package/dist/cjs/cliVersion.js +1 -1
- package/dist/cjs/client.js +26 -12
- package/dist/cjs/copilotRequestHandler.js +17 -7
- package/dist/cjs/generated/rpc.js +71 -2
- package/dist/cjs/session.js +48 -0
- package/dist/cliVersion.d.ts +1 -1
- package/dist/cliVersion.js +1 -1
- package/dist/client.d.ts +0 -1
- package/dist/client.js +26 -12
- package/dist/copilotRequestHandler.js +17 -7
- package/dist/generated/rpc.d.ts +471 -4
- package/dist/generated/rpc.js +71 -2
- package/dist/generated/session-events.d.ts +23 -1
- package/dist/index.d.ts +1 -1
- package/dist/session.d.ts +9 -2
- package/dist/session.js +48 -0
- package/dist/types.d.ts +26 -3
- package/docs/examples.md +7 -7
- package/package.json +13 -12
package/dist/generated/rpc.d.ts
CHANGED
|
@@ -1081,6 +1081,8 @@ export type CatalogCapability =
|
|
|
1081
1081
|
| "catalog-search-credential-required"
|
|
1082
1082
|
/** Captures the exact existing native session, account, host and connection for authenticated catalogue search, selection and planning. Requires catalog-search-credential-required; does not grant installation or create a session. */
|
|
1083
1083
|
| "catalog-search-session-bound"
|
|
1084
|
+
/** Understands initial-page official-product recommendations for a full task and product with fixed pageSize 10. Requires session-bound, credential-required catalogue support. No anonymous retry, broad-search fallback or continuation. Authentication uses the selected GitHub.com user credential; successful capability negotiation does not establish service acceptance. */
|
|
1085
|
+
| "catalog-recommend"
|
|
1084
1086
|
/** Understands effect-free preparation, exact human-confirmed apply and owned removal for fully resolved personal remote MCP choices without supplied inputs or configured secrets. Advertised only when the real producer and lower owned admission are linked; requires original connection and bound session authority for new work. */
|
|
1085
1087
|
| "mcp-confirmed-remote-installation"
|
|
1086
1088
|
/** Extends mcp-confirmed-remote-installation to declared non-secret header and URL values and receipt-owned header secrets for personal remote MCP choices. Requires mcp-confirmed-remote-installation and bound session authority. Secret values are written only to the reviewed backend after confirmation and are never returned; package and stdio choices remain unsupported. Advertised only when owned secret effects and owned secret activation are linked. */
|
|
@@ -1211,6 +1213,8 @@ export type CatalogInvalidRequestField =
|
|
|
1211
1213
|
"policySessionId"
|
|
1212
1214
|
/** The search query was empty or longer than permitted. */
|
|
1213
1215
|
| "query"
|
|
1216
|
+
/** The requested recommendation product was missing, blank or longer than permitted. */
|
|
1217
|
+
| "product"
|
|
1214
1218
|
/** The requested result count fell outside its permitted range. */
|
|
1215
1219
|
| "limit"
|
|
1216
1220
|
/** The requested candidate kinds were empty or contained a duplicate. */
|
|
@@ -1714,7 +1718,7 @@ export type CatalogSearchTotalCountRelation =
|
|
|
1714
1718
|
/** No exact/full-query or lower-bound guarantee is available. */
|
|
1715
1719
|
"unknown";
|
|
1716
1720
|
/**
|
|
1717
|
-
* Outcome of
|
|
1721
|
+
* Outcome of catalog.search or catalog.recommend: either bounded inert candidates, or one typed refusal. Never a partial success.
|
|
1718
1722
|
*
|
|
1719
1723
|
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
1720
1724
|
* via the `definition` "CatalogSearchResult".
|
|
@@ -5701,6 +5705,18 @@ export type SessionLimitPredictionUnavailableReason =
|
|
|
5701
5705
|
*/
|
|
5702
5706
|
/** @experimental */
|
|
5703
5707
|
export type SessionListEntry = LocalSessionMetadataValue | RemoteSessionMetadataValue;
|
|
5708
|
+
/**
|
|
5709
|
+
* Peer boundary evaluated in the process hosting the native session.
|
|
5710
|
+
*
|
|
5711
|
+
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
5712
|
+
* via the `definition` "SessionManagementScope".
|
|
5713
|
+
*/
|
|
5714
|
+
/** @experimental */
|
|
5715
|
+
export type SessionManagementScope =
|
|
5716
|
+
/** Eligible local peers sharing the resolved configuration directory. */
|
|
5717
|
+
"all"
|
|
5718
|
+
/** Only peers hosted in this native runtime process. */
|
|
5719
|
+
| "in-process";
|
|
5704
5720
|
/**
|
|
5705
5721
|
* Public-facing workspace metadata for this session, or null if the session has no associated workspace. Excludes runtime-internal fields (GitHub IDs, summary count, internal flags).
|
|
5706
5722
|
*
|
|
@@ -5874,7 +5890,7 @@ export type SessionsOpenProgressStep =
|
|
|
5874
5890
|
"load-session"
|
|
5875
5891
|
/** Validating that the local repository matches the remote session's repository. */
|
|
5876
5892
|
| "validate-repo"
|
|
5877
|
-
/** Checking the local working tree for uncommitted changes
|
|
5893
|
+
/** Checking the local working tree for uncommitted changes, which stay in place and are carried onto the checked-out branch. */
|
|
5878
5894
|
| "check-changes"
|
|
5879
5895
|
/** Checking out the branch associated with the remote session in the local working tree. */
|
|
5880
5896
|
| "checkout-branch"
|
|
@@ -8716,7 +8732,7 @@ export interface AgentsDiscoverRequest {
|
|
|
8716
8732
|
*/
|
|
8717
8733
|
agentDirectories?: string[];
|
|
8718
8734
|
/**
|
|
8719
|
-
* Optional list of project directory paths to scan for project-scoped agents. When omitted or empty,
|
|
8735
|
+
* Optional list of project directory paths to scan for project-scoped agents. When omitted or empty, no project is scanned: user-level and globally enabled plugin agents are still returned, but agents of a plugin enabled only in a repository's settings are not.
|
|
8720
8736
|
*/
|
|
8721
8737
|
projectPaths?: string[];
|
|
8722
8738
|
/**
|
|
@@ -9170,6 +9186,19 @@ export interface AutopilotObjectiveState {
|
|
|
9170
9186
|
*/
|
|
9171
9187
|
creditLimit?: AutopilotObjectiveCreditLimit;
|
|
9172
9188
|
}
|
|
9189
|
+
/**
|
|
9190
|
+
* Client-resolved preference for retaining autopilot mode after objective completion or pause.
|
|
9191
|
+
*
|
|
9192
|
+
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
9193
|
+
* via the `definition` "AutopilotObjectiveSetStayInAutopilotRequest".
|
|
9194
|
+
*/
|
|
9195
|
+
/** @experimental */
|
|
9196
|
+
export interface AutopilotObjectiveSetStayInAutopilotRequest {
|
|
9197
|
+
/**
|
|
9198
|
+
* Whether an objective's requested return to interactive mode is suppressed.
|
|
9199
|
+
*/
|
|
9200
|
+
value: boolean;
|
|
9201
|
+
}
|
|
9173
9202
|
/** @experimental */
|
|
9174
9203
|
export interface AutopilotOptions {
|
|
9175
9204
|
/**
|
|
@@ -11484,6 +11513,31 @@ export interface CatalogPolicyRejectedError {
|
|
|
11484
11513
|
*/
|
|
11485
11514
|
message: string;
|
|
11486
11515
|
}
|
|
11516
|
+
/**
|
|
11517
|
+
* Initial-page official-product recommendations for a complete task. The runtime fixes recommendationPolicy to official-product and pageSize to 10; callers cannot override the policy, request pagination or fall back to search.
|
|
11518
|
+
*
|
|
11519
|
+
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
11520
|
+
* via the `definition` "CatalogRecommendRequest".
|
|
11521
|
+
*/
|
|
11522
|
+
/** @experimental */
|
|
11523
|
+
export interface CatalogRecommendRequest {
|
|
11524
|
+
/**
|
|
11525
|
+
* Required contract, including catalog-recommend, catalog-search-session-bound and catalog-search-credential-required.
|
|
11526
|
+
*/
|
|
11527
|
+
contract: CatalogClientContract;
|
|
11528
|
+
/**
|
|
11529
|
+
* Existing attached local session whose account, host and connection own the candidate references. Never creates or resumes a session.
|
|
11530
|
+
*/
|
|
11531
|
+
policySessionId: string;
|
|
11532
|
+
/**
|
|
11533
|
+
* Full original task, including action, account, output and host requirements. Forwarded without trimming or rewriting and excluded from telemetry.
|
|
11534
|
+
*/
|
|
11535
|
+
query: string;
|
|
11536
|
+
/**
|
|
11537
|
+
* Requested product. Agent Finder resolves aliases and applies its versioned official-product approvals before limiting results.
|
|
11538
|
+
*/
|
|
11539
|
+
product: string;
|
|
11540
|
+
}
|
|
11487
11541
|
/**
|
|
11488
11542
|
* A computed Skill install plan. Nothing has been applied.
|
|
11489
11543
|
*
|
|
@@ -17740,6 +17794,43 @@ export interface ManagedPluginRetryEntry {
|
|
|
17740
17794
|
*/
|
|
17741
17795
|
error?: string;
|
|
17742
17796
|
}
|
|
17797
|
+
/**
|
|
17798
|
+
* An opted-in local session, reported by its live owner.
|
|
17799
|
+
*
|
|
17800
|
+
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
17801
|
+
* via the `definition` "ManagedSessionInfo".
|
|
17802
|
+
*/
|
|
17803
|
+
/** @experimental */
|
|
17804
|
+
export interface ManagedSessionInfo {
|
|
17805
|
+
/**
|
|
17806
|
+
* Live peer's session identifier.
|
|
17807
|
+
*/
|
|
17808
|
+
sessionId: string;
|
|
17809
|
+
/**
|
|
17810
|
+
* Human-readable peer name.
|
|
17811
|
+
*/
|
|
17812
|
+
name: string;
|
|
17813
|
+
/**
|
|
17814
|
+
* Peer's current working directory.
|
|
17815
|
+
*/
|
|
17816
|
+
cwd: string;
|
|
17817
|
+
/**
|
|
17818
|
+
* Peer's local session-state directory containing events.jsonl, when known.
|
|
17819
|
+
*/
|
|
17820
|
+
sessionStatePath?: string;
|
|
17821
|
+
/**
|
|
17822
|
+
* Either idle or busy. A busy session may still accept messages.
|
|
17823
|
+
*/
|
|
17824
|
+
state: string;
|
|
17825
|
+
/**
|
|
17826
|
+
* Peer's selected model, when known.
|
|
17827
|
+
*/
|
|
17828
|
+
model?: string;
|
|
17829
|
+
/**
|
|
17830
|
+
* The session that created this root through session management, if any.
|
|
17831
|
+
*/
|
|
17832
|
+
parentSessionId?: string;
|
|
17833
|
+
}
|
|
17743
17834
|
/**
|
|
17744
17835
|
* Lock state and provenance of one managed setting.
|
|
17745
17836
|
*
|
|
@@ -23901,6 +23992,24 @@ export interface PermissionRulesSet {
|
|
|
23901
23992
|
*/
|
|
23902
23993
|
denied: PermissionRule[];
|
|
23903
23994
|
}
|
|
23995
|
+
/**
|
|
23996
|
+
* Available permission modes, derived from current session policy.
|
|
23997
|
+
*
|
|
23998
|
+
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
23999
|
+
* via the `definition` "PermissionsCapabilities".
|
|
24000
|
+
*/
|
|
24001
|
+
/** @experimental */
|
|
24002
|
+
export interface PermissionsCapabilities {
|
|
24003
|
+
/**
|
|
24004
|
+
* Whether LLM-assisted approval is enabled for this session.
|
|
24005
|
+
*/
|
|
24006
|
+
assistedApproval: boolean;
|
|
24007
|
+
/**
|
|
24008
|
+
* Whether managed policy currently permits unconditional approval.
|
|
24009
|
+
* Stays true while managed policy is still resolving.
|
|
24010
|
+
*/
|
|
24011
|
+
bypassPermissions: boolean;
|
|
24012
|
+
}
|
|
23904
24013
|
/**
|
|
23905
24014
|
* No parameters.
|
|
23906
24015
|
*
|
|
@@ -25286,6 +25395,19 @@ export interface ProviderSessionToken {
|
|
|
25286
25395
|
*/
|
|
25287
25396
|
expiresAt?: string;
|
|
25288
25397
|
}
|
|
25398
|
+
/**
|
|
25399
|
+
* Credential-free provider configuration status for the selected model.
|
|
25400
|
+
*
|
|
25401
|
+
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
25402
|
+
* via the `definition` "ProviderStatus".
|
|
25403
|
+
*/
|
|
25404
|
+
/** @experimental */
|
|
25405
|
+
export interface ProviderStatus {
|
|
25406
|
+
/**
|
|
25407
|
+
* Whether the selected model uses a custom provider instead of requiring GitHub authentication.
|
|
25408
|
+
*/
|
|
25409
|
+
hasCustomProvider: boolean;
|
|
25410
|
+
}
|
|
25289
25411
|
/**
|
|
25290
25412
|
* Authoritative BYOK provider and model registry snapshot to apply atomically to the session.
|
|
25291
25413
|
*
|
|
@@ -29063,6 +29185,282 @@ export interface SessionManagedSettings {
|
|
|
29063
29185
|
*/
|
|
29064
29186
|
permissions?: SessionManagedPermissions;
|
|
29065
29187
|
}
|
|
29188
|
+
/**
|
|
29189
|
+
* Closes one live opted-in descendant without deleting its saved history or closing its children.
|
|
29190
|
+
*
|
|
29191
|
+
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
29192
|
+
* via the `definition` "SessionManagementCloseRequest".
|
|
29193
|
+
*/
|
|
29194
|
+
/** @experimental */
|
|
29195
|
+
export interface SessionManagementCloseRequest {
|
|
29196
|
+
/**
|
|
29197
|
+
* Live created descendant whose owning host should close it.
|
|
29198
|
+
*/
|
|
29199
|
+
targetSessionId: string;
|
|
29200
|
+
}
|
|
29201
|
+
/**
|
|
29202
|
+
* Completion of the existing non-deleting close lifecycle.
|
|
29203
|
+
*
|
|
29204
|
+
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
29205
|
+
* via the `definition` "SessionManagementCloseResult".
|
|
29206
|
+
*/
|
|
29207
|
+
/** @experimental */
|
|
29208
|
+
export interface SessionManagementCloseResult {
|
|
29209
|
+
/**
|
|
29210
|
+
* True after the owning host has completed the existing session-close lifecycle.
|
|
29211
|
+
*/
|
|
29212
|
+
closed: boolean;
|
|
29213
|
+
}
|
|
29214
|
+
/**
|
|
29215
|
+
* Updates the session's live policy without changing persistent host settings.
|
|
29216
|
+
*
|
|
29217
|
+
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
29218
|
+
* via the `definition` "SessionManagementConfigureRequest".
|
|
29219
|
+
*/
|
|
29220
|
+
/** @experimental */
|
|
29221
|
+
export interface SessionManagementConfigureRequest {
|
|
29222
|
+
/**
|
|
29223
|
+
* Expected workspace for host activation. Required when enabling an interactive CLI session.
|
|
29224
|
+
*/
|
|
29225
|
+
cwd?: string;
|
|
29226
|
+
/**
|
|
29227
|
+
* Enabling resets all session management operations to enabled, then applies overrides.
|
|
29228
|
+
*/
|
|
29229
|
+
enabled?: boolean;
|
|
29230
|
+
/**
|
|
29231
|
+
* Peer boundary. Preserved when the master switch changes.
|
|
29232
|
+
*/
|
|
29233
|
+
scope?: SessionManagementScope;
|
|
29234
|
+
/**
|
|
29235
|
+
* Individual tool overrides, applied after the master switch.
|
|
29236
|
+
*/
|
|
29237
|
+
tools?: SessionManagementToolOverrides;
|
|
29238
|
+
/**
|
|
29239
|
+
* Bind creation to this SDK connection's sessionManagement.create callback.
|
|
29240
|
+
*/
|
|
29241
|
+
hasCreateHandler?: boolean;
|
|
29242
|
+
}
|
|
29243
|
+
/**
|
|
29244
|
+
* Per-operation overrides for an enabled session management policy.
|
|
29245
|
+
*
|
|
29246
|
+
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
29247
|
+
* via the `definition` "SessionManagementToolOverrides".
|
|
29248
|
+
*/
|
|
29249
|
+
/** @experimental */
|
|
29250
|
+
export interface SessionManagementToolOverrides {
|
|
29251
|
+
/**
|
|
29252
|
+
* Allow discovering eligible peer sessions.
|
|
29253
|
+
*/
|
|
29254
|
+
list?: boolean;
|
|
29255
|
+
/**
|
|
29256
|
+
* Allow requesting an independent session from the owning host.
|
|
29257
|
+
*/
|
|
29258
|
+
create?: boolean;
|
|
29259
|
+
/**
|
|
29260
|
+
* Allow delivering peer text to another eligible session.
|
|
29261
|
+
*/
|
|
29262
|
+
message?: boolean;
|
|
29263
|
+
/**
|
|
29264
|
+
* Allow closing this session's live created descendants.
|
|
29265
|
+
*/
|
|
29266
|
+
close?: boolean;
|
|
29267
|
+
}
|
|
29268
|
+
/**
|
|
29269
|
+
* Host callback. The host owns workspace records, UI, approval routing and cleanup.
|
|
29270
|
+
*
|
|
29271
|
+
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
29272
|
+
* via the `definition` "SessionManagementCreateHostRequest".
|
|
29273
|
+
*/
|
|
29274
|
+
/** @experimental */
|
|
29275
|
+
export interface SessionManagementCreateHostRequest {
|
|
29276
|
+
/**
|
|
29277
|
+
* Target session identifier
|
|
29278
|
+
*/
|
|
29279
|
+
sessionId: string;
|
|
29280
|
+
/**
|
|
29281
|
+
* The originating session; the host must not escalate its permissions.
|
|
29282
|
+
*/
|
|
29283
|
+
parentSessionId: string;
|
|
29284
|
+
/**
|
|
29285
|
+
* Runtime-allocated identity. The host must create a fresh session with this exact ID.
|
|
29286
|
+
*/
|
|
29287
|
+
newSessionId: string;
|
|
29288
|
+
/**
|
|
29289
|
+
* The new session must use this workspace and configuration directory.
|
|
29290
|
+
*/
|
|
29291
|
+
cwd: string;
|
|
29292
|
+
/**
|
|
29293
|
+
* Parent's resolved configuration directory, which the host must preserve.
|
|
29294
|
+
*/
|
|
29295
|
+
configDir: string;
|
|
29296
|
+
/**
|
|
29297
|
+
* Must not be broadened by the creating host.
|
|
29298
|
+
*/
|
|
29299
|
+
permissionMode: PermissionMode;
|
|
29300
|
+
/**
|
|
29301
|
+
* Effective model to apply when creating the child.
|
|
29302
|
+
*/
|
|
29303
|
+
model?: string;
|
|
29304
|
+
/**
|
|
29305
|
+
* Provider owning the effective model, when specified.
|
|
29306
|
+
*/
|
|
29307
|
+
providerId?: string;
|
|
29308
|
+
/**
|
|
29309
|
+
* Effective reasoning effort, when specified.
|
|
29310
|
+
*/
|
|
29311
|
+
reasoningEffort?: string;
|
|
29312
|
+
/**
|
|
29313
|
+
* Effective model-supported context tier, when specified.
|
|
29314
|
+
*/
|
|
29315
|
+
contextTier?: ContextTier;
|
|
29316
|
+
/**
|
|
29317
|
+
* The host must preserve the parent's current model restrictions.
|
|
29318
|
+
*/
|
|
29319
|
+
allowedModels?: string[];
|
|
29320
|
+
/**
|
|
29321
|
+
* Optional short name supplied for the independent session.
|
|
29322
|
+
*/
|
|
29323
|
+
name?: string;
|
|
29324
|
+
}
|
|
29325
|
+
/**
|
|
29326
|
+
* Requests a separate session. Omitted launch options inherit the caller's current configuration.
|
|
29327
|
+
*
|
|
29328
|
+
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
29329
|
+
* via the `definition` "SessionManagementCreateRequest".
|
|
29330
|
+
*/
|
|
29331
|
+
/** @experimental */
|
|
29332
|
+
export interface SessionManagementCreateRequest {
|
|
29333
|
+
/**
|
|
29334
|
+
* Initial task, delivered as peer text after successful creation.
|
|
29335
|
+
*/
|
|
29336
|
+
prompt: string;
|
|
29337
|
+
/**
|
|
29338
|
+
* Optional short name for the independent session.
|
|
29339
|
+
*/
|
|
29340
|
+
name?: string;
|
|
29341
|
+
/**
|
|
29342
|
+
* Absolute working directory. Defaults to the parent's current directory.
|
|
29343
|
+
*/
|
|
29344
|
+
cwd?: string;
|
|
29345
|
+
/**
|
|
29346
|
+
* Optional model override; omission uses the parent's current model.
|
|
29347
|
+
*/
|
|
29348
|
+
model?: string;
|
|
29349
|
+
/**
|
|
29350
|
+
* Optional effort supported by the selected model.
|
|
29351
|
+
*/
|
|
29352
|
+
reasoningEffort?: string;
|
|
29353
|
+
/**
|
|
29354
|
+
* Uses the selected model's supported default or long-context tier, not an arbitrary token count.
|
|
29355
|
+
*/
|
|
29356
|
+
contextTier?: ContextTier;
|
|
29357
|
+
}
|
|
29358
|
+
/**
|
|
29359
|
+
* Identifies a session owned and supervised by the creating host.
|
|
29360
|
+
*
|
|
29361
|
+
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
29362
|
+
* via the `definition` "SessionManagementCreateResult".
|
|
29363
|
+
*/
|
|
29364
|
+
/** @experimental */
|
|
29365
|
+
export interface SessionManagementCreateResult {
|
|
29366
|
+
/**
|
|
29367
|
+
* Runtime-allocated identifier of the newly created session.
|
|
29368
|
+
*/
|
|
29369
|
+
sessionId: string;
|
|
29370
|
+
}
|
|
29371
|
+
/**
|
|
29372
|
+
* Lists opted-in local peers. The caller is omitted.
|
|
29373
|
+
*
|
|
29374
|
+
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
29375
|
+
* via the `definition` "SessionManagementListRequest".
|
|
29376
|
+
*/
|
|
29377
|
+
/** @experimental */
|
|
29378
|
+
export interface SessionManagementListRequest {
|
|
29379
|
+
/**
|
|
29380
|
+
* Optional exact working-directory filter.
|
|
29381
|
+
*/
|
|
29382
|
+
cwd?: string;
|
|
29383
|
+
}
|
|
29384
|
+
/**
|
|
29385
|
+
* Eligible live peers reported by their owning runtimes.
|
|
29386
|
+
*
|
|
29387
|
+
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
29388
|
+
* via the `definition` "SessionManagementListResult".
|
|
29389
|
+
*/
|
|
29390
|
+
/** @experimental */
|
|
29391
|
+
export interface SessionManagementListResult {
|
|
29392
|
+
/**
|
|
29393
|
+
* Matching peers, excluding the caller.
|
|
29394
|
+
*/
|
|
29395
|
+
sessions: ManagedSessionInfo[];
|
|
29396
|
+
}
|
|
29397
|
+
/**
|
|
29398
|
+
* Sends peer text, never human approval, to another opted-in session.
|
|
29399
|
+
*
|
|
29400
|
+
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
29401
|
+
* via the `definition` "SessionManagementMessageRequest".
|
|
29402
|
+
*/
|
|
29403
|
+
/** @experimental */
|
|
29404
|
+
export interface SessionManagementMessageRequest {
|
|
29405
|
+
/**
|
|
29406
|
+
* Eligible live peer that should receive the message.
|
|
29407
|
+
*/
|
|
29408
|
+
targetSessionId: string;
|
|
29409
|
+
/**
|
|
29410
|
+
* Nonempty UTF-8 text, at most 16 KiB.
|
|
29411
|
+
*/
|
|
29412
|
+
message: string;
|
|
29413
|
+
}
|
|
29414
|
+
/**
|
|
29415
|
+
* Acceptance is not a completed turn or a reply.
|
|
29416
|
+
*
|
|
29417
|
+
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
29418
|
+
* via the `definition` "SessionManagementMessageResult".
|
|
29419
|
+
*/
|
|
29420
|
+
/** @experimental */
|
|
29421
|
+
export interface SessionManagementMessageResult {
|
|
29422
|
+
/**
|
|
29423
|
+
* True when the destination has accepted the peer message.
|
|
29424
|
+
*/
|
|
29425
|
+
accepted: boolean;
|
|
29426
|
+
/**
|
|
29427
|
+
* Destination title captured by the receiving runtime at message admission.
|
|
29428
|
+
*/
|
|
29429
|
+
targetSessionName?: string;
|
|
29430
|
+
}
|
|
29431
|
+
/**
|
|
29432
|
+
* Opt-in policy for local session management.
|
|
29433
|
+
*
|
|
29434
|
+
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
|
|
29435
|
+
* via the `definition` "SessionManagementPolicy".
|
|
29436
|
+
*/
|
|
29437
|
+
/** @experimental */
|
|
29438
|
+
export interface SessionManagementPolicy {
|
|
29439
|
+
/**
|
|
29440
|
+
* Master switch. Off by default.
|
|
29441
|
+
*/
|
|
29442
|
+
enabled: boolean;
|
|
29443
|
+
/**
|
|
29444
|
+
* Discovery and direct access boundary. Defaults to all eligible local peers.
|
|
29445
|
+
*/
|
|
29446
|
+
scope: SessionManagementScope;
|
|
29447
|
+
/**
|
|
29448
|
+
* Allow listing opted-in sessions in this configuration directory.
|
|
29449
|
+
*/
|
|
29450
|
+
list: boolean;
|
|
29451
|
+
/**
|
|
29452
|
+
* Allow requesting a new session from the owning host.
|
|
29453
|
+
*/
|
|
29454
|
+
create: boolean;
|
|
29455
|
+
/**
|
|
29456
|
+
* Allow sending a peer message to another opted-in session.
|
|
29457
|
+
*/
|
|
29458
|
+
message: boolean;
|
|
29459
|
+
/**
|
|
29460
|
+
* Allow closing sessions created by this session or its descendants. On by default.
|
|
29461
|
+
*/
|
|
29462
|
+
close: boolean;
|
|
29463
|
+
}
|
|
29066
29464
|
/**
|
|
29067
29465
|
* Records which IDE the host is connected to, or clears it.
|
|
29068
29466
|
*
|
|
@@ -38445,9 +38843,17 @@ export declare function createServerRpc(connection: MessageConnection): {
|
|
|
38445
38843
|
*
|
|
38446
38844
|
* @param params A bounded catalog search. Both the query length and the result count are capped by the schema so a caller cannot request an unbounded scan.
|
|
38447
38845
|
*
|
|
38448
|
-
* @returns Outcome of
|
|
38846
|
+
* @returns Outcome of catalog.search or catalog.recommend: either bounded inert candidates, or one typed refusal. Never a partial success.
|
|
38449
38847
|
*/
|
|
38450
38848
|
search: (params: CatalogSearchRequest) => Promise<CatalogSearchResult>;
|
|
38849
|
+
/**
|
|
38850
|
+
* Requests the initial page of at most ten official-product recommendations for a complete task and product, bound to an existing attached local session. Requires catalog-recommend, catalog-search-session-bound and catalog-search-credential-required. Uses the selected GitHub.com user credential on the fixed Agent Finder recommendations route; successful capability negotiation does not establish service acceptance. Returns the existing inert catalog candidates and retained install references with the typed catalog refusal union. No anonymous retry, unfiltered search fallback or continuation is performed. Server-owned product approvals establish provenance, not task suitability. Read-only: nothing is installed, configured or persisted.
|
|
38851
|
+
*
|
|
38852
|
+
* @param params Initial-page official-product recommendations for a complete task. The runtime fixes recommendationPolicy to official-product and pageSize to 10; callers cannot override the policy, request pagination or fall back to search.
|
|
38853
|
+
*
|
|
38854
|
+
* @returns Outcome of catalog.search or catalog.recommend: either bounded inert candidates, or one typed refusal. Never a partial success.
|
|
38855
|
+
*/
|
|
38856
|
+
recommend: (params: CatalogRecommendRequest) => Promise<CatalogSearchResult>;
|
|
38451
38857
|
/**
|
|
38452
38858
|
* Retrieves one saved feed by its opaque ID, optionally filtered by trust tier. Requires catalog-feeds and catalog-search-credential-required, and uses the same authority, credential policy, optional session binding and candidate projection as catalog.search, so available entries are the same inert candidates, with the same installability, handles and display metadata, and install through the same confirmed flows. Entries keep the feed's order; an entry the runtime cannot present is returned as unavailable with a reason rather than failing the feed. No anonymous retry. Read-only: nothing is installed, configured, or persisted.
|
|
38453
38859
|
*
|
|
@@ -38805,6 +39211,49 @@ export declare function createServerRpc(connection: MessageConnection): {
|
|
|
38805
39211
|
};
|
|
38806
39212
|
/** Create typed session-scoped RPC methods. */
|
|
38807
39213
|
export declare function createSessionRpc(connection: MessageConnection, sessionId: string): {
|
|
39214
|
+
/** @experimental */
|
|
39215
|
+
management: {
|
|
39216
|
+
/**
|
|
39217
|
+
* Updates opt-in session management policy live. Enabling the master enables all tools before applying individual overrides. Opt-in is scoped to the session's configuration directory.
|
|
39218
|
+
*
|
|
39219
|
+
* @param params Updates the session's live policy without changing persistent host settings.
|
|
39220
|
+
*
|
|
39221
|
+
* @returns Opt-in policy for local session management.
|
|
39222
|
+
*/
|
|
39223
|
+
configure: (params: SessionManagementConfigureRequest) => Promise<SessionManagementPolicy>;
|
|
39224
|
+
/**
|
|
39225
|
+
* Lists other live, opted-in sessions in the same configuration directory. Requires the list tool to be enabled.
|
|
39226
|
+
*
|
|
39227
|
+
* @param params Lists opted-in local peers. The caller is omitted.
|
|
39228
|
+
*
|
|
39229
|
+
* @returns Eligible live peers reported by their owning runtimes.
|
|
39230
|
+
*/
|
|
39231
|
+
list: (params: SessionManagementListRequest) => Promise<SessionManagementListResult>;
|
|
39232
|
+
/**
|
|
39233
|
+
* Injects peer text into an opted-in session. Wakes an idle agent and safely queues delivery to a busy agent. Acceptance does not imply an answer or completed task.
|
|
39234
|
+
*
|
|
39235
|
+
* @param params Sends peer text, never human approval, to another opted-in session.
|
|
39236
|
+
*
|
|
39237
|
+
* @returns Acceptance is not a completed turn or a reply.
|
|
39238
|
+
*/
|
|
39239
|
+
message: (params: SessionManagementMessageRequest) => Promise<SessionManagementMessageResult>;
|
|
39240
|
+
/**
|
|
39241
|
+
* Asks the owning host to create and supervise a separate session, preserving permissions and model restrictions. Omitted model, reasoning effort, context tier and cwd inherit the caller's current values; explicit overrides use normal model validation and workspace trust. Records durable creation lineage before delivering the initial task as peer text. Returns the new session ID, not task completion. Requires the create tool and a host creation handler.
|
|
39242
|
+
*
|
|
39243
|
+
* @param params Requests a separate session. Omitted launch options inherit the caller's current configuration.
|
|
39244
|
+
*
|
|
39245
|
+
* @returns Identifies a session owned and supervised by the creating host.
|
|
39246
|
+
*/
|
|
39247
|
+
create: (params: SessionManagementCreateRequest) => Promise<SessionManagementCreateResult>;
|
|
39248
|
+
/**
|
|
39249
|
+
* Closes a live opted-in session created by the caller or one of its descendants, preserving saved history and leaving descendants open. Requires the close capability to be enabled. Self, ancestors, siblings and unrelated sessions cannot be closed.
|
|
39250
|
+
*
|
|
39251
|
+
* @param params Closes one live opted-in descendant without deleting its saved history or closing its children.
|
|
39252
|
+
*
|
|
39253
|
+
* @returns Completion of the existing non-deleting close lifecycle.
|
|
39254
|
+
*/
|
|
39255
|
+
close: (params: SessionManagementCloseRequest) => Promise<SessionManagementCloseResult>;
|
|
39256
|
+
};
|
|
38808
39257
|
/** @experimental */
|
|
38809
39258
|
providers: {
|
|
38810
39259
|
/**
|
|
@@ -39443,6 +39892,12 @@ export declare function createSessionRpc(connection: MessageConnection, sessionI
|
|
|
39443
39892
|
* @returns Canonical runtime state for the session's current autopilot objective.
|
|
39444
39893
|
*/
|
|
39445
39894
|
getState: () => Promise<AutopilotObjectiveGetStateResult>;
|
|
39895
|
+
/**
|
|
39896
|
+
* Sets whether completing or pausing this session's objective preserves autopilot mode. This in-memory preference defaults to false and must be reapplied when attaching a client.
|
|
39897
|
+
*
|
|
39898
|
+
* @param params Client-resolved preference for retaining autopilot mode after objective completion or pause.
|
|
39899
|
+
*/
|
|
39900
|
+
setStayInAutopilot: (params: AutopilotObjectiveSetStayInAutopilotRequest) => Promise<void>;
|
|
39446
39901
|
};
|
|
39447
39902
|
/** @experimental */
|
|
39448
39903
|
completions: {
|
|
@@ -40182,6 +40637,12 @@ export declare function createSessionRpc(connection: MessageConnection, sessionI
|
|
|
40182
40637
|
* @returns The selectable model entries and selection ids synthesized for the synchronized BYOK models.
|
|
40183
40638
|
*/
|
|
40184
40639
|
sync: (params: ProviderSyncRequest) => Promise<ProviderSyncResult>;
|
|
40640
|
+
/**
|
|
40641
|
+
* Returns credential-free provider configuration status for the selected model. This does not validate provider credentials or contact the provider.
|
|
40642
|
+
*
|
|
40643
|
+
* @returns Credential-free provider configuration status for the selected model.
|
|
40644
|
+
*/
|
|
40645
|
+
getStatus: () => Promise<ProviderStatus>;
|
|
40185
40646
|
/**
|
|
40186
40647
|
* Withdraws named host-managed models from the session's BYOK registry, leaving every other entry untouched. The scoped counterpart to `provider.sync`: a snapshot can only describe entries the caller knows about, so using it to remove one model silently withdraws rows registered by another source, such as a plugin calling `provider.add` at runtime. Naming what to remove leaves unrelated entries alone. Selection ids that are not registered are ignored, so withdrawal is idempotent. A provider is removed only when one of the withdrawn models was the last entry referencing it; a provider that simply has no models, which is the normal state while its rows are supplied by catalog discovery, is left in place.
|
|
40187
40648
|
*
|
|
@@ -40522,6 +40983,12 @@ export declare function createSessionRpc(connection: MessageConnection, sessionI
|
|
|
40522
40983
|
* @returns Current permission mode.
|
|
40523
40984
|
*/
|
|
40524
40985
|
getMode: () => Promise<PermissionsGetModeResult>;
|
|
40986
|
+
/**
|
|
40987
|
+
* Returns the approval modes currently available under the session's feature and managed permission policy. This read does not change permissions; mutations must still check their authoritative result because policy may change.
|
|
40988
|
+
*
|
|
40989
|
+
* @returns Available permission modes, derived from current session policy.
|
|
40990
|
+
*/
|
|
40991
|
+
getCapabilities: () => Promise<PermissionsCapabilities>;
|
|
40525
40992
|
/**
|
|
40526
40993
|
* Adds or removes session-scoped or location-scoped permission rules.
|
|
40527
40994
|
*
|