Apply a Workbench clone
apply_cloneApply the OpenCode Workbench profile to a local or SSH target: clones repo, installs missing components, and overwrites config; preview by omitting confirm.
Instructions
Apply the Workbench profile to a target: clone the repo and install missing components (OpenCode CLI, Node/pnpm, MCP servers, skills, plugins, optional Docker). It OVERWRITES <home>/.config/opencode/opencode.json, copies AGENTS.md, resets an existing profile repo to origin/main, and runs global installs that need write permission (plus SSH for mode:ssh) and can take minutes. Writes a names-only ~/.env.workbench (mode 600); never secret values. Consent-gated and idempotent: without confirm:true it returns the plan and changes nothing. Parameter semantics: components defaults to required+core; workspace defaults to ~/opencode-workbench; skipRepo skips the clone/update; profileUrl overrides the git remote; dryRun returns the plan. To preview only, use plan_clone.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| dryRun | No | Report only; make no changes. | |
| target | Yes | The machine to operate on: this host (local) or a remote host over SSH (ssh). | |
| confirm | No | Set true to actually install. When absent, the call returns a plan and makes no changes. | |
| skipRepo | No | Do not clone/update the profile repo on the target. | |
| workspace | No | Target directory for the profile repo. | |
| components | No | Component ids to include; defaults to required+core. | |
| profileUrl | No | Override profile git URL. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| plan | No | Presented when confirmation is required. | |
| model | Yes | Default model selected for the target (DeepSeek when its key is present, else the OpenCode Zen free floor). | |
| dryRun | Yes | True when the run made no changes. | |
| target | Yes | Label of the target. | |
| envPath | Yes | Path of the written ~/.env.workbench template. | |
| envVars | Yes | Environment variable names listed in the env template. | |
| skipped | Yes | Component ids skipped (already present or manual). | |
| degraded | Yes | Capabilities disabled because required credentials are absent; fill the named env vars to enable them. | |
| installed | Yes | Components installed, with exit codes and output. | |
| workspace | Yes | Directory where the profile repo was cloned. | |
| configPath | Yes | Path of the written opencode.json. | |
| providerMode | Yes | Which provider the model resolves to. | |
| requiresConfirmation | No | True when the call returned a plan without applying; re-call with confirm:true to install. |