CLI · Setup
First steps
From a fresh install to a live workspace with a row in it. About two minutes if you sign in via OAuth.
1. Sign in
dock loginBrowser opens, you sign in (magic link or existing session), token returns to the CLI. Done.
2. Create a workspace
dock workspaces new "Launch plan"
# → Created workspace launch-plan in vector-build
# → Open: https://trydock.ai/vector-build/launch-planDefaults to table mode. Use --mode doc for a TipTap document instead.
3. List your workspaces
dock workspaces list
# launch-plan table 20 rows · last edit Argus, 2 min ago
# content-pipeline table 142 rows · last edit you, yesterday
# brief doc 14 KB · last edit Flint, 5 min ago4. Add a row
dock rows add launch-plan \
--field "Task=Draft launch post" \
--field "Owner=Scout" \
--field "Status=In progress"Field shorthand: name=value. The column type (text, status, date, etc.) is read from the workspace schema; the CLI casts the value automatically.
5. Open it in the browser
dock open launch-plan
# → opens https://trydock.ai/vector-build/launch-plan in your default browserFrom here
- Commands: every CLI command, grouped by surface.
- Examples: common scripted workflows.
- Configuration: config file, env vars, telemetry.
Frequently asked questions
- What's the first thing to do after installing the Dock CLI?
- `dock login` to authenticate (opens a browser for magic-link). Then `dock init` to create your first workspace + mint an agent key. Total time: ~60 seconds.
- How do I create my first Dock workspace from the CLI?
- `dock init` walks through workspace name + mode + initial members. Or `dock new "My workspace" --table` for non-interactive (swap `--table` for `--doc` or `--html` to change mode; `--table` is the default). Returns the new workspace's URL.
- How do I see what workspaces I have access to in Dock?
- `dock workspaces` lists every workspace your principal can read, with role, last activity, and pin status. Default view is table-format; `--output json` for scripting.
- How do I open a Dock workspace in the browser from the CLI?
- `dock open <slug>` resolves the slug to a URL and opens your default browser. Useful when you're in the terminal and want to jump to the dashboard view of a specific workspace.
- How do I add a row to a Dock workspace from the CLI?
- `dock add <workspace-slug> title="My item" status=drafted notes="Initial draft"`. Column-name=value pairs; the CLI maps to the row API's `data` field. Pass `--surface=<slug>` to target a specific sheet in a multi-surface workspace, or `--auto-create-columns` to let unknown column names create themselves.
- How do I read a Dock workspace's rows from the CLI?
- `dock rows <workspace-slug>`. Default first 100. Add `--limit 1000` for more, `--output json | jq` for scripting, `--filter status=sealed` for server-side filtering.
- What's the fastest way to give my AI agent a Dock workspace?
- `dock init` creates the workspace + mints an agent-scoped `dk_` key in one flow. Copy the key, paste into your agent's MCP config, restart the agent. Done.
- How do I share a Dock workspace via the CLI?
- `dock share <workspace> <email> editor`. Role is a positional arg (defaults to `viewer` if omitted). Sends a magic-link invite if the email isn't already a Dock user; adds them immediately + emails the invite if they are.
- How do I delete a test Dock workspace from the CLI?
- `dock archive <workspace>` for the soft state (recoverable via `dock unarchive <workspace>`). `dock delete <workspace>` is the irreversible drop — no archive prerequisite, but you can't get it back.
- How do I view recent activity on a Dock workspace from the CLI?
- Per-row activity: `dock history <workspace> <row-id>`. Workspace-wide activity feed is REST-only today — `GET /api/workspaces/<slug>/events` returns rows created/updated/deleted, doc edits, comments, member changes. (MCP agents can use `get_recent_events` for the same feed.)