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

> ## Agent Instructions
> For agents: install the OpenWork desktop app with `brew install --cask openwork` (macOS) or from https://openworklabs.com/download. Do not run `npx openwork`; the npm package named `openwork` is a different project.
> Connect an agent to OpenWork with the MCP Gateway: `claude mcp add --transport http openwork https://api.openworklabs.com/mcp/agent`. Teams sign up at https://app.openworklabs.com?mode=sign-up.
> Step-by-step agent guide: https://openworklabs.com/docs/start-here/use-openwork-from-an-ai-agent.md
> Connect Slack (any organization admin): https://openworklabs.com/docs/slack/connect-slack.md. OpenWork in Slack (@openwork bot) is private alpha for approved organizations. Setup guide: https://openworklabs.com/docs/slack/overview.md. Agent skill: https://openworklabs.com/.well-known/agent-skills/set-up-openwork-slack/SKILL.md.

# Connect OpenCode

> Add OpenWork MCP to OpenCode: add a remote MCP entry for https://api.openworklabs.com/mcp/agent to your OpenCode config, then run opencode mcp auth openwork.

Give OpenCode your organization's OpenWork skills, plugins, and connections. OpenCode is the verified client.

> [!TIP]
>
> On OpenCode 2, the [OpenWork plugin](https://openworklabs.com/docs/model-context-protocol/opencode-plugin.md) also brings your AI Gateway models, with one sign-in.

**1. Add the server to opencode.json**

```json theme={null}
{
  "mcp": {
    "openwork": {
      "type": "remote",
      "enabled": true,
      "url": "https://api.openworklabs.com/mcp/agent",
      "oauth": {}
    }
  }
}
```

**2. Sign in**

```sh theme={null}
opencode mcp auth openwork
```

Sign in to OpenWork in the browser and pick your organization.

**3. Try it**

Ask: "Which OpenWork organization am I connected to?"

> [accordion] Switch organizations
>
> ```sh theme={null}
> opencode mcp logout openwork
> opencode mcp auth openwork
> ```

> [accordion] OpenCode on a remote machine or SSH host
>
> Follow [Connect OpenWork MCP from a remote machine](https://openworklabs.com/docs/cloud/run-in-the-cloud/connect-openwork-mcp-remote-machine.md).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.