@github/copilot-sdk 1.0.15-preview.3 → 1.0.15-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.
@@ -168,7 +168,74 @@ function createServerRpc(connection) {
168
168
  *
169
169
  * @returns Outcome of an mcp.planInstall call: either a normalised plan, or one typed refusal. Nothing is written in either case.
170
170
  */
171
- planInstall: async (params) => connection.sendRequest("mcp.planInstall", params)
171
+ planInstall: async (params) => connection.sendRequest("mcp.planInstall", params),
172
+ /**
173
+ * Consumes a bound catalogue plan and retains one exact fully resolved personal remote MCP operation requiring no supplied values or configured secrets. Returns its runtime operation ID and original expiry before any confirmation, activation, writer initialisation or installation effect. Register the original connection, operation and selected-session binding before calling applyInstall. Missing lower owned admission is unavailable, never a raw-config fallback.
174
+ *
175
+ * @param params Side-effect-free preparation of one original bound remote MCP choice.
176
+ *
177
+ * @returns Management result with contract receipt, or a typed request/negotiation refusal.
178
+ */
179
+ prepareInstall: async (params) => connection.sendRequest("mcp.prepareInstall", params),
180
+ /**
181
+ * Consumes a retained prepared MCP operation once, revalidates its original authority, requests explicit human consent through installations.confirm on the original connection, then revalidates source and applies the sealed transaction. An uncertain result requires original-operation inspection or recovery, never replay.
182
+ *
183
+ * @param params Applies exactly one previously prepared operation on its original connection.
184
+ *
185
+ * @returns An installation result together with the exact honoured contract, or a negotiation refusal.
186
+ */
187
+ applyInstall: async (params) => connection.sendRequest("mcp.applyInstall", params),
188
+ /**
189
+ * Prepares a read-only removal plan for an exact owned receipt under the selected existing session. Returns the original operation ID before confirmation; neither planning nor abandonment changes configuration or shared OAuth credentials.
190
+ *
191
+ * @param params Read-only preparation of one owned removal under fresh selected-session authority.
192
+ *
193
+ * @returns Management result with contract receipt, or a typed request/negotiation refusal.
194
+ */
195
+ planUninstall: async (params) => connection.sendRequest("mcp.planUninstall", params),
196
+ /**
197
+ * Consumes the original owned-removal plan once and requests fresh exact human confirmation on its original connection. Drift is refused; unrelated manual configuration and shared OAuth credentials are preserved.
198
+ *
199
+ * @param params One-use application of the exact retained removal plan.
200
+ *
201
+ * @returns An installation result together with the exact honoured contract, or a negotiation refusal.
202
+ */
203
+ applyUninstall: async (params) => connection.sendRequest("mcp.applyUninstall", params),
204
+ /** @experimental */
205
+ installations: {
206
+ /**
207
+ * Reads receipt-owned MCP inventory for the selected account and host without activating servers or reconstructing missing ownership. Configuration ownership does not prove session-specific usability.
208
+ *
209
+ * @param params New-work inventory or recovery request under an explicitly selected existing session.
210
+ *
211
+ * @returns Management result with contract receipt, or a typed request/negotiation refusal.
212
+ */
213
+ list: async (params) => connection.sendRequest("mcp.installations.list", params),
214
+ /**
215
+ * Reconciles already-confirmed durable MCP transactions, then inspects owned inventory. Does not replay apply or reconstruct deleted ownership metadata; unresolved or unsafe evidence remains an explicit refusal.
216
+ *
217
+ * @param params New-work inventory or recovery request under an explicitly selected existing session.
218
+ *
219
+ * @returns Management result with contract receipt, or a typed request/negotiation refusal.
220
+ */
221
+ recover: async (params) => connection.sendRequest("mcp.installations.recover", params),
222
+ /**
223
+ * Inspects a known operation only on its original connection. Remains available after account or selected-session loss; does not acquire new authority or rebind an operation.
224
+ *
225
+ * @param params Existing-operation control. A new session selector is deliberately not accepted.
226
+ *
227
+ * @returns Management result with contract receipt, or a typed request/negotiation refusal.
228
+ */
229
+ status: async (params) => connection.sendRequest("mcp.installations.status", params),
230
+ /**
231
+ * Requests cancellation of a known operation on its original connection, including before apply or confirmation. Already-started effects retain their transaction lease and report an honest terminal or recovery outcome.
232
+ *
233
+ * @param params Existing-operation control. A new session selector is deliberately not accepted.
234
+ *
235
+ * @returns Management result with contract receipt, or a typed request/negotiation refusal.
236
+ */
237
+ cancel: async (params) => connection.sendRequest("mcp.installations.cancel", params)
238
+ }
172
239
  },
173
240
  /** @experimental */
174
241
  extensions: {
@@ -191,6 +258,115 @@ function createServerRpc(connection) {
191
258
  */
192
259
  disable: async (params) => connection.sendRequest("extensions.disable", params)
193
260
  },
261
+ /** @experimental */
262
+ skills: {
263
+ /**
264
+ * Plans installation of a verified Agent Finder Skill candidate without writing files. The returned review is safe to present to a user and installing always leaves the Skill disabled until separately enabled.
265
+ *
266
+ * @param params Side-effect-free planning of one verified Agent Finder Skill candidate.
267
+ *
268
+ * @returns Skill installation management result with the honoured contract, or a typed refusal.
269
+ */
270
+ planInstall: async (params) => connection.sendRequest("skills.planInstall", params),
271
+ /**
272
+ * Consumes one verified Skill installation plan, requests explicit human consent through installations.confirm on the original connection, then revalidates and installs the Skill disabled.
273
+ *
274
+ * @param params Applies exactly one retained verified Skill installation plan.
275
+ *
276
+ * @returns Skill installation result with the honoured contract, or a typed request/negotiation refusal.
277
+ */
278
+ applyInstall: async (params) => connection.sendRequest("skills.applyInstall", params),
279
+ /** @experimental */
280
+ installations: {
281
+ /**
282
+ * Lists owned verified Agent Finder Skill installations for the selected existing session. Listing is never gated by the Skill-install feature flag.
283
+ *
284
+ * @param params Inventory request under an explicitly selected existing session.
285
+ *
286
+ * @returns Skill installation management result with the honoured contract, or a typed refusal.
287
+ */
288
+ list: async (params) => connection.sendRequest("skills.installations.list", params),
289
+ /**
290
+ * Reconciles interrupted owned Skill installation work for the selected existing session, then inspects owned inventory. Recovery is never gated by the Skill-install feature flag.
291
+ *
292
+ * @param params Inventory request under an explicitly selected existing session.
293
+ *
294
+ * @returns Skill installation management result with the honoured contract, or a typed refusal.
295
+ */
296
+ recover: async (params) => connection.sendRequest("skills.installations.recover", params),
297
+ /**
298
+ * Inspects a known Skill installation operation on its original runtime connection. Status is never gated by the Skill-install feature flag.
299
+ *
300
+ * @param params Existing-operation control. A new session selector is deliberately not accepted.
301
+ *
302
+ * @returns Skill installation management result with the honoured contract, or a typed refusal.
303
+ */
304
+ status: async (params) => connection.sendRequest("skills.installations.status", params),
305
+ /**
306
+ * Requests cancellation of a known Skill installation operation before commit. Already-started durable work requires recovery instead of silent replay.
307
+ *
308
+ * @param params Existing-operation control. A new session selector is deliberately not accepted.
309
+ *
310
+ * @returns Skill installation management result with the honoured contract, or a typed refusal.
311
+ */
312
+ cancel: async (params) => connection.sendRequest("skills.installations.cancel", params),
313
+ /**
314
+ * Atomically persists enablement for one owned Agent Finder Skill and reconciles the selected bound session. Enablement is installation-scoped by receipt identity and is never gated by the Skill-install feature flag.
315
+ *
316
+ * @param params Persisted enablement update for one owned Skill installation.
317
+ *
318
+ * @returns Skill installation management result with the honoured contract, or a typed refusal.
319
+ */
320
+ setEnabled: async (params) => connection.sendRequest("skills.installations.setEnabled", params)
321
+ },
322
+ /**
323
+ * Prepares a read-only removal plan for an owned verified Agent Finder Skill installation. Uninstall planning is never gated by the Skill-install feature flag.
324
+ *
325
+ * @param params Read-only preparation of one owned Skill removal under fresh selected-session authority.
326
+ *
327
+ * @returns Skill installation management result with the honoured contract, or a typed refusal.
328
+ */
329
+ planUninstall: async (params) => connection.sendRequest("skills.planUninstall", params),
330
+ /**
331
+ * Consumes an owned Skill removal plan, requests explicit human consent through installations.confirm, refuses drift, and removes the exact owned files through quarantine.
332
+ *
333
+ * @param params One-use application of the exact retained Skill removal plan.
334
+ *
335
+ * @returns Skill installation result with the honoured contract, or a typed request/negotiation refusal.
336
+ */
337
+ applyUninstall: async (params) => connection.sendRequest("skills.applyUninstall", params),
338
+ /** @experimental */
339
+ config: {
340
+ /**
341
+ * Replaces the global list of disabled skills.
342
+ *
343
+ * @param params Skill names to mark as disabled in global configuration, replacing any previous list.
344
+ */
345
+ setDisabledSkills: async (params) => connection.sendRequest("skills.config.setDisabledSkills", params),
346
+ /**
347
+ * Atomically adds or removes one skill from the disabled list.
348
+ *
349
+ * @param params Adds or removes a single skill from the global disabled list, leaving every other entry untouched.
350
+ */
351
+ setSkillDisabled: async (params) => connection.sendRequest("skills.config.setSkillDisabled", params)
352
+ },
353
+ /**
354
+ * Discovers skills across global and project sources.
355
+ *
356
+ * @param params Optional project paths and additional skill directories to include in discovery.
357
+ *
358
+ * @returns Skills discovered across global and project sources.
359
+ */
360
+ discover: async (params) => connection.sendRequest("skills.discover", params),
361
+ /**
362
+ * Returns the canonical directories where a client may create skills that the runtime will recognize, including ones that do not exist yet. Project directories become active once created.
363
+ *
364
+ * @param params Optional project paths to enumerate.
365
+ *
366
+ * @returns Canonical locations where skills can be created so the runtime will recognize them.
367
+ */
368
+ getDiscoveryPaths: async (params) => connection.sendRequest("skills.getDiscoveryPaths", params)
369
+ },
194
370
  /**
195
371
  * Registers the calling SDK client as the per-entrypoint extension launch provider. Call before creating any sessions. When omitted, the runtime uses its built-in extension launcher.
196
372
  *
@@ -316,40 +492,6 @@ function createServerRpc(connection) {
316
492
  }
317
493
  },
318
494
  /** @experimental */
319
- skills: {
320
- /** @experimental */
321
- config: {
322
- /**
323
- * Replaces the global list of disabled skills.
324
- *
325
- * @param params Skill names to mark as disabled in global configuration, replacing any previous list.
326
- */
327
- setDisabledSkills: async (params) => connection.sendRequest("skills.config.setDisabledSkills", params),
328
- /**
329
- * Atomically adds or removes one skill from the disabled list.
330
- *
331
- * @param params Adds or removes a single skill from the global disabled list, leaving every other entry untouched.
332
- */
333
- setSkillDisabled: async (params) => connection.sendRequest("skills.config.setSkillDisabled", params)
334
- },
335
- /**
336
- * Discovers skills across global and project sources.
337
- *
338
- * @param params Optional project paths and additional skill directories to include in discovery.
339
- *
340
- * @returns Skills discovered across global and project sources.
341
- */
342
- discover: async (params) => connection.sendRequest("skills.discover", params),
343
- /**
344
- * Returns the canonical directories where a client may create skills that the runtime will recognize, including ones that do not exist yet. Project directories become active once created.
345
- *
346
- * @param params Optional project paths to enumerate.
347
- *
348
- * @returns Canonical locations where skills can be created so the runtime will recognize them.
349
- */
350
- getDiscoveryPaths: async (params) => connection.sendRequest("skills.getDiscoveryPaths", params)
351
- },
352
- /** @experimental */
353
495
  agents: {
354
496
  /**
355
497
  * Discovers custom agents across user, project, plugin, and remote sources.
@@ -754,6 +896,17 @@ function createInternalServerRpc(connection) {
754
896
  * @param params Params to attach or detach an in-process ExtensionController delegate.
755
897
  */
756
898
  configureSessionExtensions: async (params) => connection.sendRequest("sessions.configureSessionExtensions", params)
899
+ },
900
+ /** @experimental */
901
+ accounts: {
902
+ /**
903
+ * Acquire a Microsoft Entra access token through the runtime's OneAuth broker. Account-scoped because it uses the same native broker as the account stack: a trusted host application mints a scoped Entra token for its own use, most notably to authenticate to a remote MCP server whose authorization server is Entra ID (in place of the generic browser-OAuth flow).
904
+ *
905
+ * @param params OneAuth token request supplied by a trusted host application.
906
+ *
907
+ * @returns Result of a OneAuth token acquisition.
908
+ */
909
+ acquireEntraToken: async (params) => connection.sendRequest("accounts.acquireEntraToken", params)
757
910
  }
758
911
  };
759
912
  }
@@ -856,6 +1009,58 @@ function createSessionRpc(connection, sessionId) {
856
1009
  setCredentials: async (params) => connection.sendRequest("session.gitHubAuth.setCredentials", { sessionId, ...params })
857
1010
  },
858
1011
  /** @experimental */
1012
+ accounts: {
1013
+ /**
1014
+ * Enumerate a typed accounts collection: the signed-in accounts, or the providers offered for interactive login.
1015
+ *
1016
+ * @param params Enumerate request carrying the typed collection query.
1017
+ *
1018
+ * @returns The enumerated collection, keyed by the same selector as the query.
1019
+ */
1020
+ enumerate: async (params) => connection.sendRequest("session.accounts.enumerate", { sessionId, ...params }),
1021
+ /**
1022
+ * Read one typed accounts datum: the active account, a neutral status summary, or the last authentication errors.
1023
+ *
1024
+ * @param params Read request carrying the typed datum query.
1025
+ *
1026
+ * @returns The read result, keyed by the same selector as the query.
1027
+ */
1028
+ get: async (params) => connection.sendRequest("session.accounts.get", { sessionId, ...params }),
1029
+ /**
1030
+ * Apply one non-interactive accounts mutation: switch the active account, log an account out, or set credentials from a token.
1031
+ *
1032
+ * @param params Mutation request carrying the typed write command.
1033
+ *
1034
+ * @returns Result of a non-interactive accounts mutation.
1035
+ */
1036
+ set: async (params) => connection.sendRequest("session.accounts.set", { sessionId, ...params }),
1037
+ /** @experimental */
1038
+ login: {
1039
+ /**
1040
+ * Begin an interactive login flow for a provider kind (dispatch is kind-only) and return its opaque flow id and first step.
1041
+ *
1042
+ * @param params Begin an interactive login flow for a provider kind. Dispatch is kind-only.
1043
+ *
1044
+ * @returns A started login flow: its opaque id and first step.
1045
+ */
1046
+ begin: async (params) => connection.sendRequest("session.accounts.login.begin", { sessionId, ...params }),
1047
+ /**
1048
+ * Advance an in-flight login flow, optionally fulfilling an input-required step, and return the next step.
1049
+ *
1050
+ * @param params Advance an in-flight login flow, optionally fulfilling an input-required step.
1051
+ *
1052
+ * @returns One step in an interactive login flow. The consumer acts on the step and calls advance to proceed. Browser-open is encoded as two distinct steps by design: `open-url` is CONSUMER-driven (the provider surfaces the authorize URL and the consumer opens it — github.com/GHEC web), while `needs-interaction` is PROVIDER-driven (the provider opens the browser or broker UI itself and does not surface a URL — Entra).
1053
+ */
1054
+ advance: async (params) => connection.sendRequest("session.accounts.login.advance", { sessionId, ...params }),
1055
+ /**
1056
+ * Cancel an in-flight login flow and release its resources.
1057
+ *
1058
+ * @param params Cancel an in-flight login flow.
1059
+ */
1060
+ cancel: async (params) => connection.sendRequest("session.accounts.login.cancel", { sessionId, ...params })
1061
+ }
1062
+ },
1063
+ /** @experimental */
859
1064
  debug: {
860
1065
  /**
861
1066
  * Collects a session debug log bundle into a local archive or staging directory. Logs are redacted by default; redaction can be configured per caller-provided diagnostic entry. The runtime includes session-owned logs by default and accepts caller-provided diagnostic entries so host applications can add their own files without changing this API shape.
@@ -907,108 +1112,6 @@ function createSessionRpc(connection, sessionId) {
907
1112
  }
908
1113
  },
909
1114
  /** @experimental */
910
- factory: {
911
- /**
912
- * Runs a registered factory by name at the top level.
913
- *
914
- * @param params Parameters for invoking a registered factory.
915
- *
916
- * @returns Complete current or terminal factory run envelope.
917
- */
918
- run: async (params) => connection.sendRequest("session.factory.run", { sessionId, ...params }),
919
- /**
920
- * Resumes a factory run using its persisted name, arguments, journal, and accounting.
921
- *
922
- * @param params Parameters for resuming a factory run from its persisted identity.
923
- *
924
- * @returns Resolved persisted factory identity and resumed run envelope.
925
- */
926
- resume: async (params) => connection.sendRequest("session.factory.resume", { sessionId, ...params }),
927
- /**
928
- * Gets the current or settled envelope for a factory run.
929
- *
930
- * @param params Parameters for retrieving a factory run.
931
- *
932
- * @returns Complete current or terminal factory run envelope.
933
- */
934
- getRun: async (params) => connection.sendRequest("session.factory.getRun", { sessionId, ...params }),
935
- /**
936
- * Lists durable factory runs for this session in creation order.
937
- *
938
- * @param params Parameters for paging factory runs.
939
- *
940
- * @returns A page of factory runs in durable creation order.
941
- */
942
- listRuns: async (params) => connection.sendRequest("session.factory.listRuns", { sessionId, ...params }),
943
- /**
944
- * Gets durable and live observability detail for one factory run.
945
- *
946
- * @param params Parameters for retrieving a factory run.
947
- *
948
- * @returns Full factory run observability detail.
949
- */
950
- getRunDetail: async (params) => connection.sendRequest("session.factory.getRunDetail", { sessionId, ...params }),
951
- /**
952
- * Pages durable progress for one factory run.
953
- *
954
- * @param params Parameters for paging factory progress.
955
- *
956
- * @returns A bidirectional page of factory progress.
957
- */
958
- getRunProgress: async (params) => connection.sendRequest("session.factory.getRunProgress", { sessionId, ...params }),
959
- /**
960
- * Requests cancellation of a factory run and returns its run envelope.
961
- *
962
- * @param params Parameters for cancelling a factory run.
963
- *
964
- * @returns Complete current or terminal factory run envelope.
965
- */
966
- cancel: async (params) => connection.sendRequest("session.factory.cancel", { sessionId, ...params }),
967
- /**
968
- * Pauses a running factory and returns its settled run envelope.
969
- *
970
- * @param params Parameters for pausing a running factory.
971
- *
972
- * @returns Complete current or terminal factory run envelope.
973
- */
974
- pause: async (params) => connection.sendRequest("session.factory.pause", { sessionId, ...params }),
975
- /**
976
- * Records a batch of ordered factory progress lines.
977
- *
978
- * @param params Parameters for recording factory progress.
979
- *
980
- * @returns Acknowledgement that a factory request was accepted.
981
- */
982
- log: async (params) => connection.sendRequest("session.factory.log", { sessionId, ...params }),
983
- /**
984
- * Runs one factory-scoped subagent and returns its result.
985
- *
986
- * @param params Parameters for one factory-scoped subagent call.
987
- *
988
- * @returns Result of one factory-scoped subagent call.
989
- */
990
- agent: async (params) => connection.sendRequest("session.factory.agent", { sessionId, ...params }),
991
- /** @experimental */
992
- journal: {
993
- /**
994
- * Reads a memoized factory journal entry.
995
- *
996
- * @param params Parameters for reading a factory journal entry.
997
- *
998
- * @returns Result of reading a factory journal entry.
999
- */
1000
- get: async (params) => connection.sendRequest("session.factory.journal.get", { sessionId, ...params }),
1001
- /**
1002
- * Stores a memoized factory journal entry.
1003
- *
1004
- * @param params Parameters for storing a factory journal entry.
1005
- *
1006
- * @returns Acknowledgement that a factory request was accepted.
1007
- */
1008
- put: async (params) => connection.sendRequest("session.factory.journal.put", { sessionId, ...params })
1009
- }
1010
- },
1011
- /** @experimental */
1012
1115
  workflow: {
1013
1116
  /**
1014
1117
  * Runs a registered dynamic workflow by name at the top level.
@@ -1718,7 +1821,15 @@ function createSessionRpc(connection, sessionId) {
1718
1821
  */
1719
1822
  authenticationStateChanged: async (params) => connection.sendRequest("session.mcp.oauth.authenticationStateChanged", { sessionId, ...params }),
1720
1823
  /**
1721
- * Starts OAuth authentication for a remote MCP server.
1824
+ * Prepares an inert, expiring owned OAuth login bound to the original session requester and exact installation. Does not activate, connect, read credentials or open a browser.
1825
+ *
1826
+ * @param params Effect-free preparation bound to the existing local session, requester and installation, with frozen options.
1827
+ *
1828
+ * @returns An inert runtime-issued login handle. Preparation alone performs no activation or OAuth work.
1829
+ */
1830
+ prepareLogin: async (params) => connection.sendRequest("session.mcp.oauth.prepareLogin", { sessionId, ...params }),
1831
+ /**
1832
+ * Starts OAuth authentication for a remote MCP server. Owned servers require the original one-use prepareLogin handle and exact installation ID; manual servers retain the existing direct login behaviour.
1722
1833
  *
1723
1834
  * @param params Remote MCP server name and optional overrides controlling reauthentication, OAuth client display name, callback success-page copy, and static OAuth client selection.
1724
1835
  *
@@ -1733,6 +1844,14 @@ function createSessionRpc(connection, sessionId) {
1733
1844
  * @returns Passive MCP OAuth probe result. `authenticated` means the server accepted the probe request while an OAuth-origin access token was attached; it does not prove the server required or independently validated that token. The probe does not make a second unauthenticated request. Failed is an expected probe-domain outcome; JSON-RPC errors are reserved for API-call failures.
1734
1845
  */
1735
1846
  probe: async (params) => connection.sendRequest("session.mcp.oauth.probe", { sessionId, ...params }),
1847
+ /**
1848
+ * Cancels the exact owned OAuth login issued to this original session requester, without clearing shared credentials.
1849
+ *
1850
+ * @param params Targets only the original prepared/applying owned login on this exact session requester.
1851
+ *
1852
+ * @returns Honest terminal cancellation result; persistence or recovery failures remain RPC errors.
1853
+ */
1854
+ cancelLogin: async (params) => connection.sendRequest("session.mcp.oauth.cancelLogin", { sessionId, ...params }),
1736
1855
  /**
1737
1856
  * Responds to a pending MCP OAuth authorization request by its request id.
1738
1857
  *
@@ -2971,31 +3090,6 @@ function createInternalSessionRpc(connection, sessionId) {
2971
3090
  }
2972
3091
  },
2973
3092
  /** @experimental */
2974
- factory: {
2975
- /**
2976
- * Internal tool-originated factory invocation.
2977
- *
2978
- * @param params Internal parameters for invoking a registered factory from a tool.
2979
- *
2980
- * @returns Complete current or terminal factory run envelope.
2981
- */
2982
- runFromTool: async (params) => connection.sendRequest("session.factory.runFromTool", { sessionId, ...params }),
2983
- /**
2984
- * Internal tool-originated factory resume.
2985
- *
2986
- * @param params Internal parameters for resuming a factory run from a tool.
2987
- *
2988
- * @returns Resolved persisted factory identity and resumed run envelope.
2989
- */
2990
- resumeFromTool: async (params) => connection.sendRequest("session.factory.resumeFromTool", { sessionId, ...params }),
2991
- /**
2992
- * Atomically pauses an owned factory attempt at a durable checkpoint.
2993
- *
2994
- * @param params Parameters for an owned durable pause checkpoint.
2995
- */
2996
- pauseAtCheckpoint: async (params) => connection.sendRequest("session.factory.pauseAtCheckpoint", { sessionId, ...params })
2997
- },
2998
- /** @experimental */
2999
3093
  workflow: {
3000
3094
  /**
3001
3095
  * Internal tool-originated dynamic workflow invocation.
@@ -3223,16 +3317,6 @@ function registerClientSessionApiHandlers(connection, getHandlers) {
3223
3317
  if (!handler) throw new Error(`No providerToken handler registered for session: ${params.sessionId}`);
3224
3318
  return handler.getToken(params);
3225
3319
  });
3226
- connection.onRequest("factory.execute", async (params) => {
3227
- const handler = getHandlers(params.sessionId).factory;
3228
- if (!handler) throw new Error(`No factory handler registered for session: ${params.sessionId}`);
3229
- return handler.execute(params);
3230
- });
3231
- connection.onRequest("factory.abort", async (params) => {
3232
- const handler = getHandlers(params.sessionId).factory;
3233
- if (!handler) throw new Error(`No factory handler registered for session: ${params.sessionId}`);
3234
- return handler.abort(params);
3235
- });
3236
3320
  connection.onRequest("workflow.execute", async (params) => {
3237
3321
  const handler = getHandlers(params.sessionId).workflow;
3238
3322
  if (!handler) throw new Error(`No workflow handler registered for session: ${params.sessionId}`);
@@ -3355,6 +3439,11 @@ function registerClientGlobalApiHandlers(connection, handlers) {
3355
3439
  if (!handler) throw new Error("No gitHubToken client-global handler registered");
3356
3440
  return handler.getToken(params);
3357
3441
  });
3442
+ connection.onRequest("installations.confirm", async (params) => {
3443
+ const handler = handlers.installations;
3444
+ if (!handler) throw new Error("No installations client-global handler registered");
3445
+ return handler.confirm(params);
3446
+ });
3358
3447
  }
3359
3448
  export {
3360
3449
  createInternalServerRpc,