You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: examples/pdf-server/README.md
+5-5Lines changed: 5 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -153,18 +153,18 @@ bun examples/pdf-server/main.ts --stdio ./papers/
153
153
154
154
MCP clients may advertise **roots** — `file://` URIs pointing to directories on the client's file system. The server uses these to allow access to local files under those directories.
155
155
156
-
-**HTTP mode** (default): Client roots are **enabled** — the client is typically on the same machine, so the roots are safe.
157
-
-**Stdio mode** (`--stdio`): Client roots are **ignored** by default — the client may be remote, and its roots would be resolved against the server's filesystem. To opt in, pass `--use-client-roots`:
156
+
-**Stdio mode** (`--stdio`): Client roots are **always enabled** — the client is typically on the same machine (e.g. Claude Desktop), so the roots are safe.
157
+
-**HTTP mode** (default): Client roots are **ignored** by default — the client may be remote, and its roots would be resolved against the server's filesystem. To opt in, pass `--use-client-roots`:
158
158
159
159
```bash
160
-
# Trust that the stdio client is local and its roots are safe
161
-
bun examples/pdf-server/main.ts --stdio --use-client-roots
160
+
# Trust that the HTTP client is local and its roots are safe
161
+
bun examples/pdf-server/main.ts --use-client-roots
162
162
```
163
163
164
164
When roots are ignored the server logs:
165
165
166
166
```
167
-
[pdf-server] Client roots are ignored (default for security). Pass --use-client-roots to allow the client to expose local directories.
167
+
[pdf-server] Client roots are ignored (default for remote transports). Pass --use-client-roots to allow the client to expose local directories.
0 commit comments