MCP: the add command uses --scope user
Without it Claude Code keeps the server for the one folder the command ran in, so sessions elsewhere don't see brokeless. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
1253f4e7fb
commit
dee883472a
2 files changed
+3
-3
No files matched your search
@@ -179,7 +179,7 @@ brokeless is an MCP server too, so an AI app like Claude Code can read your mone
|
||||
2. Run the command it shows on your computer:
|
||||
|
||||
```bash
|
||||
claude mcp add --transport http brokeless https://brokeless.mangavalk.com/api/mcp --header "Authorization: Bearer <token>"
|
||||
claude mcp add --scope user --transport http brokeless https://brokeless.mangavalk.com/api/mcp --header "Authorization: Bearer <token>"
|
||||
```
|
||||
|
||||
3. Start a new Claude Code session and ask, for example: "Which of my brokeless rules catch too much?"
|
||||
|
||||
@@ -16,7 +16,7 @@ export function McpTokens() {
|
||||
const load = () => createClient().from("mcp_tokens").select("id, label, created_at, last_used_at").order("created_at").then(({ data }) => setRows((data ?? []) as Row[]));
|
||||
useEffect(() => { load(); }, []);
|
||||
const url = typeof window === "undefined" ? "" : `${window.location.origin}/api/mcp`;
|
||||
const command = fresh ? `claude mcp add --transport http brokeless ${url} --header "Authorization: Bearer ${fresh}"` : "";
|
||||
const command = fresh ? `claude mcp add --scope user --transport http brokeless ${url} --header "Authorization: Bearer ${fresh}"` : "";
|
||||
|
||||
async function make() {
|
||||
setBusy(true);
|
||||
@@ -50,7 +50,7 @@ export function McpTokens() {
|
||||
{fresh && (
|
||||
<div className="space-y-2 rounded-xl border border-line p-3">
|
||||
<p className="text-sm font-medium">Your token. It shows only now: copy it before you leave this page.</p>
|
||||
<p className="text-xs text-muted">Add it to Claude Code by running this on your computer:</p>
|
||||
<p className="text-xs text-muted">Add it to Claude Code by running this on your computer. --scope user makes it work in every folder, not only the one you run it in.</p>
|
||||
<code className="block text-xs break-all rounded-lg bg-canvas p-3">{command}</code>
|
||||
<div className="flex gap-2">
|
||||
<button type="button" className="btn" onClick={() => copy(command)}>Copy command</button>
|
||||
|
||||
Reference in new issue
Block a user