---
title: "Dock MCP and CLI reference · Dock · GNTC"
description: "Connect your own agent to Dock: the MCP endpoint, OAuth sign-in and scopes, personal access tokens, the dock command line, workspaces and per-app setup."
url: "https://dock.space/docs/agents"
---

# Dock MCP and CLI

Your own agent reads and writes the files in your Dock, over MCP or through the `dock` command line.

MCP endpoint

```
https://app.dock.space/v1/mcp
```

Transport

Streamable HTTP

Sign-in

OAuth in the browser, or `Authorization: Bearer` with a personal access token

Command line

macOS and Linux

Plan

Every plan, Free included

## MCP

### Sign in with OAuth

The first time the app connects, it opens Dock in your browser: sign in, choose one workspace and press **Authorize**. A connection covers that one workspace; to use another, connect again.

Scopes the endpoint asks for:

```
workspace:read pages:read pages:write decks:read decks:write sheets:read sheets:write docs:read docs:write databases:read databases:write comments:read comments:write proposals:read proposals:write apps:read apps:write assets:read assets:write files:read files:write canvases:read texts:read texts:write members:read grants:read collab:connect offline_access
```

### Personal access token

For an app without OAuth, a script or CI. In Dock, open **Settings → Access tokens**, name the token, pick how long it is valid, tick the scopes and press **Create token**. The token is shown once and works only in the workspace it was made in. Send it as a header:

```
Authorization: Bearer YOUR_TOKEN
```

### Per app

#### Claude Code

```
$ claude mcp add --transport http dock https://app.dock.space/v1/mcp
```

Then run `/mcp` in Claude Code and pick `dock` to sign in. [All steps](/agents/claude-code)

#### Codex

```
$ codex mcp add dock --url https://app.dock.space/v1/mcp
$ codex mcp login dock
```

`codex mcp login dock` opens the browser to sign in. [All steps](/agents/codex)

#### OpenCode

```
$ opencode mcp add dock --url https://app.dock.space/v1/mcp
$ opencode mcp auth dock
```

`opencode mcp auth dock` opens the browser to sign in. [All steps](/agents/opencode)

#### Antigravity

```
{
  "mcpServers": {
    "dock": {
      "serverUrl": "https://app.dock.space/v1/mcp"
    }
  }
}
```

Agent panel: **… → MCP Servers → Manage → View raw config**. Then click **Authenticate** next to dock. [All steps](/agents/antigravity)

#### GitHub Copilot CLI

Use the [command line](#cli): its docs do not say whether an MCP server added by hand can sign in. [All steps](/agents/copilot-cli)

#### Cursor

```
{
  "mcpServers": {
    "dock": {
      "url": "https://app.dock.space/v1/mcp",
      "headers": {
        "Authorization": "Bearer YOUR_TOKEN"
      }
    }
  }
}
```

In `~/.cursor/mcp.json`, with a [personal access token](#token): Cursor cannot sign in through the browser yet. [All steps](/agents/cursor)

#### VS Code

Command Palette: **MCP: Add Server**, choose **HTTP**, paste the endpoint. [All steps](/agents/vscode)

#### Zed

```
{
  "context_servers": {
    "dock": {
      "url": "https://app.dock.space/v1/mcp"
    }
  }
}
```

In `settings.json`, or **Settings → AI → MCP Servers → Add Server → Add Remote Server**. [All steps](/agents/zed)

#### Claude

**Customize → Connectors → + → Add custom connector**, paste the endpoint, then **Connect**. [All steps](/agents/claude)

#### ChatGPT

**chatgpt.com/plugins → + → Add custom MCP server**, paste the endpoint. Depends on your ChatGPT plan and workspace settings. [All steps](/agents/chatgpt)

#### Gemini Spark

**Settings → Connected Apps → Add custom app → Cloud MCP**, paste the endpoint, then **Connect**. Personal Google Accounts only. [All steps](/agents/gemini-spark)

#### Other apps

Add a remote MCP server over **Streamable HTTP** with the endpoint.

Claude Code and Codex can also install the [Dock plugin](/agents#plugin): the MCP server and slide skills in one step.

## Command line

### Install

```
$ curl -fsSL https://app.dock.space/install.sh | sh
```

### Sign in

```
$ dock login
```

It opens the browser; approve in GNTC Login. `dock whoami` shows who is signed in. In CI, set `DOCK_TOKEN` to a [personal access token](#token) instead.

### Workspace

```
$ dock workspace list
$ dock config set workspace WORKSPACE_ID
```

For one command, pass `--workspace ID` or set `DOCK_WORKSPACE`. The CLI uses the first of: `--workspace`, `DOCK_WORKSPACE`, the configured workspace, a personal access token's own workspace, `ws-default`.

### Profiles

`--profile NAME` (or `DOCK_PROFILE`) keeps separate credentials, API origin and workspace per profile. `dock profile list` lists them.

### Commands

`dock --help` lists every command, and `dock COMMAND --help` its flags. `--json` prints JSON. `dock mcp tools` and `dock mcp call` reach the MCP server's tools from the shell.

## Staying connected

An OAuth connection or a `dock login` stays connected while you keep using it. Once you stop, it ends on its own within 30 days.

-   MCP over OAuth: in Dock's Settings, under **Agents**, press **Remove**; the authorization is revoked at once. Deleting Dock only inside the other app may not disconnect it.
-   Command line: run `dock logout` on the computer that signed in, with the same `--profile` if you used one. Signing in again does not end the earlier connection.
-   Personal access token: it lasts until the expiry chosen when it was made, and one set to never expire does not end on its own. `dock logout` does not revoke it. Delete it in **Settings → Access tokens**.

## What an agent can do

Create, read, edit and export presentations, documents, spreadsheets, PDFs, pages and Pagebases, and generate images: see [how deep an agent can go](/agents#depth). A change can be sent as a [proposal](/agents#review) for you to adopt or reject.

Last updated 2026-11-24
