> ## Documentation Index
> Fetch the complete documentation index at: https://docs.pwno.io/llms.txt
> Use this file to discover all available pages before exploring further.

# OpenCode

> Configure pwno-mcp for OpenCode with remote HTTP or local stdio.

OpenCode supports remote HTTP MCP servers and local stdio commands.

## Config locations

* Global: `~/.config/opencode/opencode.json`
* Project-local: `opencode.json`

<CodeGroup>
  ```json HTTP theme={null}
  {
    "$schema": "https://opencode.ai/config.json",
    "mcp": {
      "pwno-mcp": {
        "type": "remote",
        "url": "http://127.0.0.1:5500/mcp",
        "enabled": true
      }
    }
  }
  ```

  ```json stdio theme={null}
  {
    "$schema": "https://opencode.ai/config.json",
    "mcp": {
      "pwno-mcp": {
        "type": "local",
        "command": [
          "docker",
          "run",
          "--rm",
          "-i",
          "--cap-add=SYS_PTRACE",
          "--cap-add=SYS_ADMIN",
          "--security-opt",
          "seccomp=unconfined",
          "--security-opt",
          "apparmor=unconfined",
          "-v",
          "/ABSOLUTE/PATH/TO/YOUR/PROJECT/workspace:/workspace",
          "ghcr.io/pwno-io/pwno-mcp:latest",
          "--stdio"
        ],
        "enabled": true
      }
    }
  }
  ```
</CodeGroup>

## Helpful commands

* `opencode mcp add`
* `opencode mcp list`

<Check>
  After setup, run `opencode mcp list` and confirm `pwno-mcp` is enabled before opening your target project.
</Check>
