From b1dfeca63fbe23a08213aeef934dce5186ad5182 Mon Sep 17 00:00:00 2001 From: Ehab Younes Date: Wed, 10 Jun 2026 12:39:38 +0000 Subject: [PATCH 1/2] docs: document URI handler format in README --- README.md | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) diff --git a/README.md b/README.md index a06202c88..18df51fba 100644 --- a/README.md +++ b/README.md @@ -51,3 +51,43 @@ Alternatively, manually install the VSIX from the All extension settings are under the `coder.*` namespace in the Settings UI. Paths in settings accept `~` and `${userHome}` from VS Code's [variables reference](https://code.visualstudio.com/docs/editor/variables-reference). + +## URI Handler + +The extension registers a URI handler that can open workspaces from outside +the editor, such as links on the Coder dashboard. The scheme matches the +editor (`vscode://`, `cursor://`, `windsurf://`, etc.), followed by the +extension ID and a path: + +```text +vscode://coder.coder-remote/open?owner=alice&workspace=dev&agent=main&folder=/home/coder/project +``` + +### `/open` + +Opens a workspace, starting it first if needed. + +| Parameter | Required | Description | +| ------------ | -------- | ---------------------------------------------------------------------------------------------------------- | +| `owner` | Yes | Username of the workspace owner. | +| `workspace` | Yes | Name of the workspace. | +| `agent` | No | Agent _name_ (not ID). If omitted or unmatched in a multi-agent workspace, a picker is shown. | +| `folder` | No | Absolute path inside the workspace to open. | +| `openRecent` | No | Open the most recently used folder for this workspace. True when present without a value or set to `true`. | +| `url` | No | Coder deployment URL. If omitted, the extension prompts for it (pre-filled with the current deployment). | +| `token` | No | Session token for authentication. If omitted, the existing session is used or a login flow is started. | + +### `/openDevContainer` + +Opens a dev container running inside a workspace. + +| Parameter | Required | Description | +| ---------------------- | -------- | ------------------------------------------------------------------------------ | +| `owner` | Yes | Username of the workspace owner. | +| `workspace` | Yes | Name of the workspace. | +| `agent` | Yes | Agent name the dev container runs on. | +| `devContainerName` | Yes | Name of the dev container. | +| `devContainerFolder` | Yes | Folder to open inside the dev container. | +| `localWorkspaceFolder` | No | Local path of the dev container project. Required if `localConfigFile` is set. | +| `localConfigFile` | No | Local path to the `devcontainer.json` file. | +| `url`, `token` | No | Same as `/open`. | From e85ca5d2a5dbf2469dd7313e07fa40eff0f003e9 Mon Sep 17 00:00:00 2001 From: Ehab Younes Date: Wed, 10 Jun 2026 12:53:50 +0000 Subject: [PATCH 2/2] docs: explain folder and openRecent defaults in URI handler docs --- README.md | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/README.md b/README.md index 18df51fba..b193dc81d 100644 --- a/README.md +++ b/README.md @@ -67,15 +67,15 @@ vscode://coder.coder-remote/open?owner=alice&workspace=dev&agent=main&folder=/ho Opens a workspace, starting it first if needed. -| Parameter | Required | Description | -| ------------ | -------- | ---------------------------------------------------------------------------------------------------------- | -| `owner` | Yes | Username of the workspace owner. | -| `workspace` | Yes | Name of the workspace. | -| `agent` | No | Agent _name_ (not ID). If omitted or unmatched in a multi-agent workspace, a picker is shown. | -| `folder` | No | Absolute path inside the workspace to open. | -| `openRecent` | No | Open the most recently used folder for this workspace. True when present without a value or set to `true`. | -| `url` | No | Coder deployment URL. If omitted, the extension prompts for it (pre-filled with the current deployment). | -| `token` | No | Session token for authentication. If omitted, the existing session is used or a login flow is started. | +| Parameter | Required | Description | +| ------------ | -------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `owner` | Yes | Username of the workspace owner. | +| `workspace` | Yes | Name of the workspace. | +| `agent` | No | Agent _name_ (not ID). If omitted or unmatched in a multi-agent workspace, a picker is shown. | +| `folder` | No | Absolute path inside the workspace to open. If omitted, a recently opened folder for this workspace is used (a picker is shown when there are several); with no recents, the window opens without a folder. | +| `openRecent` | No | Open the most recently used folder for this workspace, skipping the picker. True when present without a value or set to `true`. Ignored when `folder` is set. | +| `url` | No | Coder deployment URL. If omitted, the extension prompts for it (pre-filled with the current deployment). | +| `token` | No | Session token for authentication. If omitted, the existing session is used or a login flow is started. | ### `/openDevContainer`