docs(mcp): add Claude Code one-liner setup to Cloud MCP page (#22220)
docs(netdata-ai/mcp): add Claude Code one-liner setup to Cloud MCP page Adds a "Claude Code (One-Line Setup)" subsection to the main Netdata Cloud MCP documentation page so Claude Code users can register the Cloud MCP server with a single `claude mcp add` command — without having to edit `.mcp.json` by hand. Covers the one-liner, where to obtain an API token with `scope:mcp`, the three scope flags (`user`/`local`/`project`) with guidance against committing raw tokens, the companion `list`/`get`/`remove` commands, and a restart hint. Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Shyam Sreevalsan committed
Apr 17, 2026 at 15:24 UTC
ea9e8658902241425181b8331bbcf3537d266814
1 file changed
+30
docs/netdata-ai/mcp/README.md
+30
@@ -82,6 +82,36 @@ For more details, see [API Tokens](/docs/netdata-cloud/authentication-and-author
82
83
### Connection Configuration
84
85
+#### Claude Code (One-Line Setup)
86
+
87
+If you're using [Claude Code](https://www.anthropic.com/claude-code), you can register the Netdata Cloud MCP server from any session with a single command — no JSON editing required:
88
+
89
+```bash
90
+claude mcp add --transport http --scope user netdata-cloud \
91
+ https://app.netdata.cloud/api/v1/mcp \
92
+ --header "Authorization: Bearer YOUR_NETDATA_CLOUD_API_TOKEN"
93
+```
94
+
95
+Replace `YOUR_NETDATA_CLOUD_API_TOKEN` with a token that has `scope:mcp` — see [Creating an API Token](#creating-an-api-token) above, or go directly to **User Settings → API Tokens** in [Netdata Cloud](https://app.netdata.cloud).
96
+
97
+**Scope flags:**
98
+
99
+- `--scope user` — available in all your projects on this machine (recommended for personal use)
100
+- `--scope local` — this project only, private to you (default when `--scope` is omitted)
101
+- `--scope project` — this project, checked into `.mcp.json` and shared with your team (do **not** use with a raw token; reference an environment variable instead)
102
+
103
+**Useful companion commands:**
104
+
105
+```bash
106
+claude mcp list # show all configured servers and their connection status
107
+claude mcp get netdata-cloud # show the configuration for this server
108
+claude mcp remove netdata-cloud -s user # remove the server (match the scope you added with)
109
+```
110
+
111
+Restart the Claude Code session after adding the server so the new tools load.
112
+
113
+For more Claude Code options — including connecting to a local Netdata Agent or Parent — see the [Claude Code guide](/docs/netdata-ai/mcp/mcp-clients/claude-code.md).
114
+
115
#### Generic MCP Client (HTTP Transport)
116
117
For any MCP client that supports Streamable HTTP transport: