Skip to content

Commit e54bf2f

Browse files
jpelletier1openhands-agentDevinVinsonrbrenDebug Agent
authored
docs: add Onboarding Agent Canvas section (OpenHands#533)
* docs: add Onboarding Agent Canvas section with agent-canvas docs - Rename 'Onboarding OpenHands' group to 'Onboarding Agent Canvas' - Add agent-canvas docs (overview, setup, backends, llm-profiles, customize-and-settings, automations, self-hosting, development, troubleshooting) under Onboarding Agent Canvas - Move Hooks to Product Guides section - Update Quick Start to single 'Install OpenHands Agent Canvas' card with OpenHands Cloud as a bullet item Co-authored-by: openhands <openhands@all-hands.dev> * docs: refine Quick Start card and move Repository Customization - Remove bullet points from Agent Canvas card in Quick Start - Add OpenHands Cloud as a single bullet below the card - Move Repository Customization to Product Guides, after Automations Co-authored-by: openhands <openhands@all-hands.dev> * docs: refine Onboarding Agent Canvas nav and content - Rename 'Setup' page title to 'Install' - Add 'Setup a Pre-built Automation' group with placeholder sub-pages: GitHub PR Review Assistant, GitHub Repository Monitor, Slack Channel Monitor - Remove LLM Profiles and Model Configuration from nav - Add links to Skills and MCP Servers under Customize header in customize-and-settings - Remove stale llm-profiles link from Related Guides Co-authored-by: openhands <openhands@all-hands.dev> * docs: add backend setup sub-pages under Connect and Manage Backends - Convert flat backends entry to a nav group - Add placeholder sub-pages: Local, VM, Docker, OpenHands Cloud Co-authored-by: openhands <openhands@all-hands.dev> * docs: merge automations into prebuilt-automations; add pre-built overview - Move automations.mdx content into prebuilt-automations.mdx - Add intro section at top of prebuilt-automations linking to the three pre-built automation sub-pages (PR review, repo monitor, Slack) - Delete automations.mdx - Remove automations from Onboarding Agent Canvas nav Co-authored-by: openhands <openhands@all-hands.dev> * docs: add First Time Setup page to Onboarding Agent Canvas Co-authored-by: openhands <openhands@all-hands.dev> * Update links to pre-built automations and fill in missing guides * Add first-time setup wizard docs for Agent Canvas Covers all four onboarding steps with screenshots: - Step 1: Choose your agent (OpenHands, Claude Code, Codex, Gemini CLI via ACP) - Step 2: Check your backend (local default, link to backends guide) - Step 3: Set up your LLM (BYOK + OpenHands Cloud link) - Step 4: Start from a proven workflow (GitHub PR Review Copilot + pre-built automations) Co-authored-by: openhands <openhands@all-hands.dev> * add images * Updates to setup and backends * docs: add custom Agent Server image guide for Docker backend (OpenHands#541) * docs: add custom Agent Server image guide for Docker backend Replace the placeholder Docker backend page with a full walkthrough: build a custom Agent Server image (FROM ghcr.io/openhands/agent-server, add JDK + utilities), run it locally with a SESSION_API_KEY, and register it as a backend in Agent Canvas. Co-authored-by: openhands <openhands@all-hands.dev> * docs: use agent-server-java name, port 8001, add multi-backend section Co-authored-by: openhands <openhands@all-hands.dev> * docs: pin agent server version in FROM example Co-authored-by: openhands <openhands@all-hands.dev> * docs: use 1-python base tag with short pinning tip Co-authored-by: openhands <openhands@all-hands.dev> --------- Co-authored-by: openhands <openhands@all-hands.dev> * docs: update self-hosting and setup pages for --public mode - self-hosting.mdx: replace clone/npm-run-dev workflow with npx @openhands/agent-canvas --public one-liner. Remove nginx basic auth as the auth layer (--public handles it at the app level). Simplify security checklist and reverse proxy guidance. - setup.mdx: add --public flag to CLI table, add LOCAL_BACKEND_API_KEY to environment variables table. Co-authored-by: openhands <openhands@all-hands.dev> * docs: use agent-canvas CLI command in self-hosting guide Assumes the user has already installed via npm. Links to the install page for prerequisites. Co-authored-by: openhands <openhands@all-hands.dev> * docs: reframe "What Agent Canvas Includes" as "Why Agent Canvas" Replace the technical component list with four user-facing value props: agent flexibility, LLM flexibility, built-in automations, deployment flexibility. Co-authored-by: openhands <openhands@all-hands.dev> * docs: rework Key Concepts in Agent Canvas overview Replace six rows (UI, three backend flavors, Customize, Settings) with four focused concepts: Agent Canvas (UI + BE defined), Backend (any UI connects to any BE), Conversation, and Automation. Co-authored-by: openhands <openhands@all-hands.dev> * docs: rename Setup link to Install in overview for consistency The target page title is already "Install". Co-authored-by: openhands <openhands@all-hands.dev> * docs: rework product descriptions in Agent Canvas overview Co-authored-by: openhands <openhands@all-hands.dev> * docs: restructure Introduction page Reorder products: Agent Canvas first, then Cloud, Enterprise, SDK. Move CLI and Local GUI into a collapsible Legacy section. Co-authored-by: openhands <openhands@all-hands.dev> * docs: add ACP Agents page to Agent Canvas onboarding Ports the ACP_AGENTS guide from the agent-canvas repo into the docs: what ACP agents are, supported providers, authentication (subscription login vs API key), onboarding, switching agent/model, and custom servers. Adds the page to the Onboarding Agent Canvas nav after Customize & Settings. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> * docs: update Install page CLI flags and env vars Add missing --version and --info flags. Remove developer-only env vars (OH_AGENT_SERVER_GIT_REF, OH_AGENT_SERVER_LOCAL_PATH) — these belong in the Development guide, not the user-facing Install page. Co-authored-by: openhands <openhands@all-hands.dev> * docs: remove redundant "Change the Port" section Already covered by the --port flag in the CLI Flags table. Co-authored-by: openhands <openhands@all-hands.dev> * docs: replace Docker placeholder with real install instructions The all-in-one Docker image (ghcr.io/openhands/agent-canvas) is now available. Document the docker run command with volume mounts for persistence and projects, and show how to provide a custom API key. Co-authored-by: openhands <openhands@all-hands.dev> * docs: trim Docker section for conciseness Co-authored-by: openhands <openhands@all-hands.dev> * docs: restructure Install page with npm/Docker tabs Present npm and Docker as two parallel install paths with their own prerequisites, matching the tab pattern used in the CLI docs. Co-authored-by: openhands <openhands@all-hands.dev> * docs: remove auto-install note for uv prerequisite Co-authored-by: openhands <openhands@all-hands.dev> * docs: move CLI flags and env vars into install tabs npm tab gets CLI flags + env vars (including --public, --version, etc.). Docker tab gets its own env vars section (PORT, LOCAL_BACKEND_API_KEY, OH_SECRET_KEY) since the Docker entrypoint uses env vars, not CLI flags. Co-authored-by: openhands <openhands@all-hands.dev> * docs: move Agent Canvas to its own top-level tab Add a new "Agent Canvas" tab in the nav bar alongside SDK, CLI, Cloud, etc. Remove the "Onboarding Agent Canvas" group from the Documentation tab. Update introduction and quickstart pages to reference the new tab: - Introduction: update link text to "Get started with Agent Canvas" - Quickstart: replace single card with 2-col CardGroup (Agent Canvas + Cloud) Co-authored-by: openhands <openhands@all-hands.dev> * docs: rename Documentation tab to Home Co-authored-by: openhands <openhands@all-hands.dev> * docs: slim down development page to a repo pointer Replace the full Contribute / Development page with a lightweight pointer that shows clone + npm run dev and links to the repo's own DEVELOPMENT.md for everything else. Avoids duplication and staleness. Co-authored-by: openhands <openhands@all-hands.dev> * docs: replace overview intro with tagline in description Drop the redundant opening paragraph. The tagline now lives in the frontmatter description field where Mintlify surfaces it. Co-authored-by: openhands <openhands@all-hands.dev> * docs: rewrite customize-and-settings framing - Clarify Customize: skills give domain knowledge, MCP servers connect to external tools/data - Clarify Settings: configure how the agent runs (LLM, secrets, etc.), not "backend-synced behavior" - Rename "Backend-Synced Behavior" to "Settings Are Per Backend" Co-authored-by: openhands <openhands@all-hands.dev> * docs: per-backend note applies to both Customize and Settings Rename section to "Configuration Is Per Backend" and clarify that skills, MCP servers, secrets, and settings are all per-backend. Co-authored-by: openhands <openhands@all-hands.dev> * docs: move Use Cases from top-level tab into Home Use Cases is content about the products, not a product/interface itself. Move it into the Home tab as a sidebar group after Essential Guidelines. No redirects needed — page file paths are unchanged so URLs stay the same. Co-authored-by: openhands <openhands@all-hands.dev> * docs: fill in backend pages and consolidate self-hosting into VM - local.mdx: auto-created backend, when to use, --public for LAN access - vm.mdx: absorb self-hosting content — full walkthrough with --public, security, nginx + Let's Encrypt, connecting remotely - cloud.mdx: connect Agent Canvas to OpenHands Cloud as a backend - Remove self-hosting.mdx, add redirect to backend-setup/vm - Update all internal links from self-hosting to backend-setup/vm Co-authored-by: openhands <openhands@all-hands.dev> * docs: separate self-hosting (full stack) from VM backend (headless) Self-hosting = deploy the full Agent Canvas stack (UI + backend) on a machine you control. Covers --public, security, nginx + TLS, and connecting from another Agent Canvas instance or --frontend-only. VM Backend = run --backend-only on a remote machine and connect from your local Agent Canvas. Focused on headless backend deployment with SSH tunnel or reverse proxy. Also adds --backend-only and --frontend-only flags to setup.mdx CLI table and documents --frontend-only in local.mdx. Co-authored-by: openhands <openhands@all-hands.dev> * docs: rewrite Docker backend — official image first, custom images secondary The primary use case is running the official ghcr.io/openhands/agent-canvas image. Custom Dockerfiles are an advanced topic, moved to a short section at the end. Co-authored-by: openhands <openhands@all-hands.dev> * docs: remove custom image section from Docker backend page Co-authored-by: openhands <openhands@all-hands.dev> * docs: update Cloud backend flow — Login with OpenHands Cloud + Enterprise Co-authored-by: openhands <openhands@all-hands.dev> * docs: rewrite local backend around --backend-only + --frontend-only Local backend page now focuses on: - Starting one or more backends with --backend-only on different ports - Connecting via --frontend-only and Manage Backends - Tip about running full stack without flags for simple setups Co-authored-by: openhands <openhands@all-hands.dev> * docs: VM backend step 4 uses --frontend-only on local machine Co-authored-by: openhands <openhands@all-hands.dev> * docs: use --frontend-only consistently when connecting to a backend Updated Docker and self-hosting pages to show agent-canvas --frontend-only as the way to start the UI before adding a backend via Manage Backends. Co-authored-by: openhands <openhands@all-hands.dev> * docs: consolidate self-hosting into VM backend page One page covers the full VM/self-hosted workflow: 1. Provision and secure the machine 2. Install prerequisites 3. Start with --backend-only --public (tip: drop --backend-only for full stack) 4. Connect from local machine with --frontend-only 5. Optional nginx + TLS for direct HTTPS access 6. Security checklist Delete self-hosting.mdx, add redirect to backend-setup/vm. Update all internal links. Co-authored-by: openhands <openhands@all-hands.dev> --------- Co-authored-by: openhands <openhands@all-hands.dev> Co-authored-by: Devin <devinvinson@gmail.com> Co-authored-by: Robert Brennan <accounts@rbren.io> Co-authored-by: Debug Agent <debug@example.com> Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
1 parent 115714c commit e54bf2f

24 files changed

Lines changed: 1406 additions & 60 deletions

docs.json

Lines changed: 40 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
"navigation": {
2121
"tabs": [
2222
{
23-
"tab": "Documentation",
23+
"tab": "Home",
2424
"pages": [
2525
{
2626
"group": "Get Started",
@@ -40,16 +40,23 @@
4040
]
4141
},
4242
{
43-
"group": "Onboarding OpenHands",
43+
"group": "Use Cases",
4444
"pages": [
45-
"openhands/usage/customization/repository",
46-
"openhands/usage/customization/hooks"
45+
"openhands/usage/use-cases/overview",
46+
"openhands/usage/use-cases/vulnerability-remediation",
47+
"openhands/usage/use-cases/code-review",
48+
"openhands/usage/use-cases/qa-changes",
49+
"openhands/usage/use-cases/incident-triage",
50+
"openhands/usage/use-cases/cobol-modernization",
51+
"openhands/usage/use-cases/dependency-upgrades",
52+
"openhands/usage/use-cases/spark-migrations"
4753
]
4854
},
4955
{
5056
"group": "Product Guides",
5157
"pages": [
5258
"openhands/usage/key-features",
59+
"openhands/usage/customization/hooks",
5360
"overview/model-context-protocol",
5461
{
5562
"group": "Skills",
@@ -74,6 +81,7 @@
7481
"openhands/usage/automations/managing-automations"
7582
]
7683
},
84+
"openhands/usage/customization/repository",
7785
{
7886
"group": "Settings",
7987
"pages": [
@@ -190,21 +198,34 @@
190198
]
191199
},
192200
{
193-
"tab": "Use Cases",
201+
"tab": "Agent Canvas",
194202
"pages": [
195-
"openhands/usage/use-cases/overview",
203+
"openhands/usage/agent-canvas/overview",
204+
"openhands/usage/agent-canvas/setup",
205+
"openhands/usage/agent-canvas/first-time-setup",
196206
{
197-
"group": "Use Cases",
207+
"group": "Pre-built Automations",
198208
"pages": [
199-
"openhands/usage/use-cases/vulnerability-remediation",
200-
"openhands/usage/use-cases/code-review",
201-
"openhands/usage/use-cases/qa-changes",
202-
"openhands/usage/use-cases/incident-triage",
203-
"openhands/usage/use-cases/cobol-modernization",
204-
"openhands/usage/use-cases/dependency-upgrades",
205-
"openhands/usage/use-cases/spark-migrations"
209+
"openhands/usage/agent-canvas/prebuilt-automations",
210+
"openhands/usage/agent-canvas/prebuilt/github-pr-review",
211+
"openhands/usage/agent-canvas/prebuilt/github-repo-monitor",
212+
"openhands/usage/agent-canvas/prebuilt/slack-channel-monitor"
206213
]
207-
}
214+
},
215+
{
216+
"group": "Backends",
217+
"pages": [
218+
"openhands/usage/agent-canvas/backends",
219+
"openhands/usage/agent-canvas/backend-setup/local",
220+
"openhands/usage/agent-canvas/backend-setup/vm",
221+
"openhands/usage/agent-canvas/backend-setup/docker",
222+
"openhands/usage/agent-canvas/backend-setup/cloud"
223+
]
224+
},
225+
"openhands/usage/agent-canvas/customize-and-settings",
226+
"openhands/usage/agent-canvas/acp-agents",
227+
"openhands/usage/agent-canvas/development",
228+
"openhands/usage/agent-canvas/troubleshooting"
208229
]
209230
},
210231
{
@@ -525,6 +546,10 @@
525546
]
526547
},
527548
"redirects": [
549+
{
550+
"source": "/openhands/usage/agent-canvas/self-hosting",
551+
"destination": "/openhands/usage/agent-canvas/backend-setup/vm"
552+
},
528553
{
529554
"source": "/modules/:slug*",
530555
"destination": "/:slug*"
151 KB
Loading
147 KB
Loading
163 KB
Loading
296 KB
Loading
Lines changed: 94 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,94 @@
1+
---
2+
title: ACP Agents
3+
description: Drive Agent Canvas conversations with an external coding agent — Claude Code, Codex, or Gemini CLI — over the Agent Client Protocol.
4+
---
5+
6+
Agent Canvas can drive your conversations with the built-in **OpenHands** agent or with an external **ACP agent** — Claude Code, Codex, or Gemini CLI. This guide explains what ACP agents are, how to onboard one, and how to switch agents or models later.
7+
8+
## What is an ACP agent?
9+
10+
The [Agent Client Protocol (ACP)](https://agentclientprotocol.com/protocol/overview) is a standard for talking to coding agents over JSON-RPC on stdio. Instead of Agent Canvas calling an LLM directly, the Agent Server spawns the agent's own CLI as a subprocess and relays each turn to it. The external agent manages its own LLM, tools, and execution; Agent Canvas sends messages and renders what comes back.
11+
12+
```mermaid
13+
flowchart LR
14+
canvas["Agent Canvas<br/>(this UI)"]
15+
server["Agent Server"]
16+
acp["ACP subprocess<br/>(e.g. claude-agent-acp)"]
17+
llm["LLM provider<br/>(Anthropic / OpenAI / Google)"]
18+
canvas -- "PATCH /api/settings<br/>(agent_kind, acp_*)" --> server
19+
canvas -- "conversation turns" --> server
20+
server -- "spawn + JSON-RPC over stdio" --> acp
21+
acp -- "API calls" --> llm
22+
```
23+
24+
The Agent Server owns the subprocess and the credentials; Agent Canvas only records *which* agent to run and surfaces a form for the secrets it needs. The agent choice is stored per backend, so switching backends can switch agents.
25+
26+
## Supported providers
27+
28+
| Provider | Default command |
29+
|---|---|
30+
| **Claude Code** | `npx -y @agentclientprotocol/claude-agent-acp` |
31+
| **Codex** | `npx -y @zed-industries/codex-acp` |
32+
| **Gemini CLI** | `npx -y @google/gemini-cli --acp` |
33+
34+
The provider list is sourced from the OpenHands SDK registry (`openhands.sdk.settings.acp_providers`, mirrored into `@openhands/typescript-client`) and enriched with Canvas UI metadata. Adding or changing a provider happens upstream in the SDK.
35+
36+
## Authentication
37+
38+
<Info>
39+
ACP agents authenticate **two ways: a subscription login, or an API key** — and the onboarding fields are optional. If you're already signed in to the provider's CLI on the machine the agent runs on, it reuses that login automatically, so locally you often don't need a key at all. **The login takes priority over an API key:** while you're signed in, a key set in the environment isn't used — so the onboarding key fields do nothing and can be left blank.
40+
</Info>
41+
42+
A "subscription login" is the credential the provider's own CLI stores when you sign in once — a file in your home directory, or, for Claude Code on macOS, the system **Keychain**. When the Agent Server runs **on that same machine** (a local or self-hosted backend), the provider CLI finds that login automatically — no API key required. On a clean cloud sandbox there's no stored login, so an API key is needed instead.
43+
44+
| Provider | Subscription login (auto-detected) | API key |
45+
|---|---|---|
46+
| **Claude Code** | A Claude Code login (Pro/Max), from Claude Code's own credential store: the **macOS Keychain**, or `~/.claude/.credentials.json` on Linux | `ANTHROPIC_API_KEY` |
47+
| **Codex** | A ChatGPT login (`codex login`) cached at `~/.codex/auth.json` | `OPENAI_API_KEY` |
48+
| **Gemini CLI** | Your Google login (`gemini`/`gemini --acp`) cached at `~/.gemini/oauth_creds.json` | `GEMINI_API_KEY` |
49+
50+
All three collect an *optional* API key (plus base URL) in onboarding. As noted above, a subscription / OAuth login takes priority over an API key — when the provider's CLI is signed in, a key set in the environment is not used:
51+
52+
- **Codex**`codex login status` keeps reporting the ChatGPT login even with `OPENAI_API_KEY` set.
53+
- **Gemini CLI** — uses the OAuth auth type chosen at `gemini` login; `GEMINI_API_KEY` is only consulted if you switch the auth type. The free Google login is the common no-key path locally — sign in once and it just works.
54+
- **Claude Code** — with both present, `claude auth status` reports it is authenticated via the subscription (`claude.ai`), not the key. The login is auto-detected from the macOS Keychain (or `~/.claude/.credentials.json` on Linux); `CLAUDE_CONFIG_DIR` is **not** required for it — it only relocates Claude Code's config directory (settings/history, not the token) and signals the SDK to strip a conflicting `ANTHROPIC_API_KEY` / `ANTHROPIC_BASE_URL`.
55+
56+
The one exception is the **base URL** (`*_BASE_URL`): a custom value points the CLI at a different endpoint (a proxy or gateway) and *does* take effect even under a login — for Gemini it rides the ACP `gateway` param. It's an advanced override, not needed for normal use.
57+
58+
## Onboarding an ACP agent
59+
60+
First-time users get a four-step onboarding modal. To onboard an ACP agent:
61+
62+
1. **Choose agent** — pick Claude Code, Codex, or Gemini CLI instead of OpenHands. The choice is saved immediately to your backend's settings.
63+
2. **Check backend** — confirms Agent Canvas can reach the Agent Server.
64+
3. **Set up credentials** — enter the provider's API key (and, optionally, a custom base URL for a proxy or gateway). All three providers collect these here, and every field is optional.
65+
4. **Say hello** — creates your first conversation and closes the modal.
66+
67+
<Note>
68+
Every credential field is optional and the step is skippable. Leave a field blank to reuse a key already set on the backend, or to authenticate the agent through a subscription / OAuth login instead.
69+
</Note>
70+
71+
### How credentials reach the agent
72+
73+
Each credential you enter is saved as a **global secret** whose name is exactly the environment variable the Agent Server exports into the ACP subprocess (e.g. `ANTHROPIC_API_KEY`). Saving in onboarding is identical to adding the secret under **Settings → Secrets**, where you can edit or remove it anytime. Keeping the secret name equal to the env var is what makes a saved key actually reach the provider CLI.
74+
75+
## Switching agent or model later
76+
77+
Open **Settings → Agent** at any time:
78+
79+
- **Agent** — switch between **OpenHands** and **ACP**.
80+
- **Preset** — pick a built-in provider (Claude Code, Codex, Gemini CLI) or **Custom** to point at any other ACP server.
81+
- **Command** — the command line used to spawn the subprocess. Selecting a preset fills this in; editing it to match another preset re-detects that provider. API keys are *not* entered here — they live in the Secrets panel.
82+
- **Model** — choose a suggested model for the provider or enter a custom model override. Built-in providers save a concrete model rather than leaving it blank.
83+
84+
Saving writes an `agent_settings_diff` (`agent_kind`, `acp_server`, `acp_command`, `acp_model`) to `PATCH /api/settings`. A running conversation keeps the agent it started with; the new choice applies to conversations you start afterward.
85+
86+
## Custom ACP servers
87+
88+
Any stdio ACP server works: choose **Custom** in Settings → Agent and enter its launch command. Custom servers have no curated model list, so enter the model ID the server expects (if any) as a custom model. Pass credentials by adding the env vars the server reads as global secrets under **Settings → Secrets**.
89+
90+
## Related Guides
91+
92+
- [Customize and Settings](/openhands/usage/agent-canvas/customize-and-settings)
93+
- [LLM Profiles and Model Configuration](/openhands/usage/agent-canvas/llm-profiles)
94+
- [Connect and Manage Backends](/openhands/usage/agent-canvas/backends)
Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
---
2+
title: Cloud Backend
3+
description: Connect Agent Canvas to OpenHands Cloud for on-demand sandboxed execution.
4+
---
5+
6+
You can connect Agent Canvas to [OpenHands Cloud](/openhands/usage/cloud/openhands-cloud) as a backend. Conversations and automations then run in OpenHands Cloud's on-demand sandboxes instead of on your local machine.
7+
8+
## When to Use It
9+
10+
A Cloud backend is a good fit when you want to:
11+
12+
- Run agents without tying up local resources
13+
- Use OpenHands Cloud's managed sandboxes and integrations
14+
- Keep your local machine for development while offloading agent work
15+
16+
## Prerequisites
17+
18+
- An [OpenHands Cloud](https://app.all-hands.dev) account
19+
- Agent Canvas installed — see [Setup](/openhands/usage/agent-canvas/setup)
20+
21+
## Add a Cloud Backend
22+
23+
1. Open Agent Canvas and click the backend switcher in the top bar.
24+
2. Choose **Manage Backends****Add Backend**.
25+
3. Click **Login with OpenHands Cloud** and sign in with your account.
26+
27+
Once connected, select it as the active backend. Conversations will now run in OpenHands Cloud.
28+
29+
### OpenHands Enterprise
30+
31+
If your organization runs OpenHands Enterprise, click **Advanced** in the Add Backend flow and enter your enterprise host URL before signing in.
32+
33+
## What's Different with a Cloud Backend
34+
35+
- **Sandboxed execution** — each conversation runs in an isolated cloud sandbox rather than on your host filesystem.
36+
- **Cloud integrations** — GitHub, GitLab, Bitbucket, Slack, and other integrations configured in OpenHands Cloud are available.
37+
- **Settings are per-backend** — LLM configuration, secrets, and MCP servers saved against the Cloud backend are independent from your local backend settings.
38+
39+
## Related Guides
40+
41+
- [Connect and Manage Backends](/openhands/usage/agent-canvas/backends)
42+
- [OpenHands Cloud](/openhands/usage/cloud/openhands-cloud)
43+
- [Local Backend](/openhands/usage/agent-canvas/backend-setup/local)
Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
---
2+
title: Docker Backend
3+
description: Run Agent Canvas in a Docker container as a sandboxed backend.
4+
---
5+
6+
The official Docker image packages the full Agent Canvas stack — agent server, automation backend, and frontend — in a single container. The agent runs inside the container rather than directly on your host, giving you a sandboxed environment out of the box.
7+
8+
## Prerequisites
9+
10+
- [Docker](https://docs.docker.com/get-docker/) installed and running
11+
- Agent Canvas installed locally (if connecting from another instance) — see [Setup](/openhands/usage/agent-canvas/setup)
12+
13+
## Run the Official Image
14+
15+
Mount a persistence directory for settings, secrets, and conversation history, and a projects directory for workspace access:
16+
17+
```bash
18+
docker run -it --rm \
19+
-p 8000:8000 \
20+
-v ~/.openhands:/home/openhands/.openhands \
21+
-v ~/projects:/projects \
22+
ghcr.io/openhands/agent-canvas:latest
23+
```
24+
25+
Agent Canvas is now running at `http://localhost:8000`. The agent can access any project under the mounted `/projects` path.
26+
27+
### Environment Variables
28+
29+
Configuration is passed via `-e` flags on `docker run`:
30+
31+
| Variable | Purpose |
32+
|----------|---------|
33+
| `PORT` | Ingress port inside the container (default `8000`). Map it with `-p <host>:<PORT>`. |
34+
| `LOCAL_BACKEND_API_KEY` | API key for the server. Auto-generated and persisted if not set. |
35+
| `OH_SECRET_KEY` | Secret used to protect stored settings and secrets. |
36+
37+
<Warning>
38+
The agent server can execute arbitrary shell commands inside the container. If exposing it beyond localhost, set `LOCAL_BACKEND_API_KEY` to a strong secret.
39+
</Warning>
40+
41+
## Connect from the Frontend
42+
43+
Start the frontend separately and point it at the container:
44+
45+
```bash
46+
agent-canvas --frontend-only
47+
```
48+
49+
Then add the Docker backend:
50+
51+
1. Click the backend switcher → **Manage Backends****Add Backend**.
52+
2. Fill in:
53+
- **Name** — e.g. `docker-backend`
54+
- **Host / Base URL**`http://localhost:8000`
55+
- **API Key** — the `LOCAL_BACKEND_API_KEY` value (check container logs if auto-generated)
56+
3. Save and select it as the active backend.
57+
58+
## Related Guides
59+
60+
- [Connect and Manage Backends](/openhands/usage/agent-canvas/backends)
61+
- [Local Backend](/openhands/usage/agent-canvas/backend-setup/local)
62+
- [VM Backend](/openhands/usage/agent-canvas/backend-setup/vm)
63+
- [VM / Self-Hosted Backend](/openhands/usage/agent-canvas/backend-setup/vm)
Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
---
2+
title: Local Backend
3+
description: Run one or more local backends and connect to them from the Agent Canvas UI.
4+
---
5+
6+
Use `--backend-only` to start a local backend. Each backend runs an agent server and automation backend behind an ingress proxy on its own port.
7+
8+
## Start a Backend
9+
10+
```bash
11+
agent-canvas --backend-only
12+
```
13+
14+
This starts the agent server and automation backend on `127.0.0.1:8000`. No frontend is served.
15+
16+
## Running Multiple Backends
17+
18+
You can run several backends at the same time on different ports — for example, one per project or toolchain:
19+
20+
```bash
21+
agent-canvas --backend-only --port 8001
22+
agent-canvas --backend-only --port 8002
23+
agent-canvas --backend-only --port 8003
24+
```
25+
26+
Each instance gets its own agent server, automation backend, and ingress proxy.
27+
28+
## Connect the Frontend
29+
30+
Start the frontend separately:
31+
32+
```bash
33+
agent-canvas --frontend-only
34+
```
35+
36+
Then add your backends through **Manage Backends**:
37+
38+
1. Click the backend switcher → **Manage Backends****Add Backend**.
39+
2. Fill in the **Host / Base URL** (e.g. `http://localhost:8001`) and **API Key**.
40+
3. Repeat for each backend you started.
41+
42+
Switch between them from the backend selector depending on what you're working on.
43+
44+
<Tip>
45+
If you just want a quick single-machine setup, running `agent-canvas` without any flags starts the full stack (frontend + backend) on one port. The split approach above is useful when you want multiple backends or want to keep the frontend and backends on separate processes.
46+
</Tip>
47+
48+
## Related Guides
49+
50+
- [Connect and Manage Backends](/openhands/usage/agent-canvas/backends)
51+
- [VM Backend](/openhands/usage/agent-canvas/backend-setup/vm) — headless backend on a remote machine
52+
- [VM / Self-Hosted Backend](/openhands/usage/agent-canvas/backend-setup/vm) — backend on a remote machine
53+
- [Docker Backend](/openhands/usage/agent-canvas/backend-setup/docker) — run in a container

0 commit comments

Comments
 (0)