diff --git a/docs/features/remote-sessions.md b/docs/features/remote-sessions.md index 5a15ca8258..f103b9cf6e 100644 --- a/docs/features/remote-sessions.md +++ b/docs/features/remote-sessions.md @@ -13,7 +13,7 @@ For running sessions on GitHub-hosted compute, see [Cloud Sessions](./cloud-sess ### Always-on (client-level) -Set `remote: true` when creating the client. Every session in a GitHub repo automatically gets a remote URL. +Set `enableRemoteSessions: true` when creating the client. Every session in a GitHub repo automatically gets a remote URL. @@ -23,7 +23,7 @@ Set `remote: true` when creating the client. Every session in a GitHub repo auto ```typescript import { CopilotClient } from "@github/copilot-sdk"; -const client = new CopilotClient({ remote: true }); +const client = new CopilotClient({ enableRemoteSessions: true }); const session = await client.createSession({ workingDirectory: "/path/to/github-repo", onPermissionRequest: async () => ({ allowed: true }), @@ -59,7 +59,7 @@ session.on(on_event) ```go -client, _ := copilot.NewClient(&copilot.ClientOptions{Remote: true}) +client := copilot.NewClient(&copilot.ClientOptions{EnableRemoteSessions: true}) session, _ := client.CreateSession(ctx, &copilot.SessionConfig{ WorkingDirectory: "/path/to/github-repo", OnPermissionRequest: func(req copilot.PermissionRequest, inv copilot.PermissionInvocation) (rpc.PermissionDecision, error) { @@ -78,7 +78,7 @@ session.On(func(event copilot.SessionEvent) { ```csharp -var client = new CopilotClient(new CopilotClientOptions { Remote = true }); +var client = new CopilotClient(new CopilotClientOptions { EnableRemoteSessions = true }); var session = await client.CreateSessionAsync(new SessionConfig { WorkingDirectory = "/path/to/github-repo", @@ -201,6 +201,6 @@ The remote URL can be rendered as a QR code for easy mobile access. The SDK prov ## Notes -* The `remote` client option only applies when the SDK spawns the CLI process. It is ignored when connecting to an external server via `cliUrl`. +* The `enableRemoteSessions` client option applies when the SDK starts the runtime, either as a child process or as an in-process host. It is ignored when connecting to an already-running runtime. * If the working directory is not a GitHub repository, remote setup is silently skipped (always-on mode) or returns an error (on-demand mode). * Remote sessions require authentication. Ensure `gitHubToken` or `useLoggedInUser` is configured.