Skip to content

Commit f7fd757

Browse files
authored
Docs: clarify MCP tools configuration and usage (#989)
* Docs: clarify Copilot CLI is bundled with SDKs and update installation guidance * Docs: clarify MCP tools configuration and usage
1 parent da9921e commit f7fd757

File tree

3 files changed

+53
-7
lines changed

3 files changed

+53
-7
lines changed

README.md

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,10 @@ For a complete walkthrough, see the **[Getting Started Guide](./docs/getting-sta
3030

3131
Quick steps:
3232

33-
1. **Install the Copilot CLI:**
33+
1. **(Optional) Install the Copilot CLI**
3434

35-
Follow the [Copilot CLI installation guide](https://docs.github.com/en/copilot/how-tos/set-up/install-copilot-cli) to install the CLI, or ensure `copilot` is available in your PATH.
35+
For Node.js, Python, and .NET SDKs, the Copilot CLI is bundled automatically and no separate installation is required.
36+
For the Go SDK, install the CLI manually or ensure `copilot` is available in your PATH.
3637

3738
2. **Install your preferred SDK** using the commands above.
3839

@@ -81,7 +82,11 @@ See the **[Authentication documentation](./docs/auth/index.md)** for details on
8182

8283
### Do I need to install the Copilot CLI separately?
8384

84-
Yes, the Copilot CLI must be installed separately. The SDKs communicate with the Copilot CLI in server mode to provide agent capabilities.
85+
No — for Node.js, Python, and .NET SDKs, the Copilot CLI is bundled automatically as a dependency. You do not need to install it separately.
86+
87+
For Go SDK, you may still need to install the CLI manually.
88+
89+
Advanced: You can override the bundled CLI using `cliPath` or `cliUrl` if you want to use a custom CLI binary or connect to an external server.
8590

8691
### What tools are enabled by default?
8792

docs/features/mcp.md

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -156,6 +156,47 @@ await using var session = await client.CreateSessionAsync(new SessionConfig
156156
});
157157
```
158158

159+
## Tool Configuration
160+
161+
You can control which tools are available to an MCP server using the `tools` field.
162+
163+
### Allow all tools
164+
165+
Use `"*"` to enable all tools provided by the MCP server:
166+
167+
```typescript
168+
tools: ["*"]
169+
```
170+
171+
---
172+
173+
### Allow specific tools
174+
175+
Provide a list of tool names to restrict access:
176+
177+
```typescript
178+
tools: ["bash", "edit"]
179+
```
180+
181+
Only the listed tools will be available to the agent.
182+
183+
---
184+
185+
### Disable all tools
186+
187+
Use an empty array to disable all tools:
188+
189+
```typescript
190+
tools: []
191+
```
192+
193+
---
194+
195+
### Notes
196+
197+
- The `tools` field defines which tools are allowed.
198+
- There is no separate `allow` or `disallow` configuration — tool access is controlled directly through this list.
199+
159200
## Quick Start: Filesystem MCP Server
160201

161202
Here's a complete working example using the official [`@modelcontextprotocol/server-filesystem`](https://www.npmjs.com/package/@modelcontextprotocol/server-filesystem) MCP server:

docs/setup/local-cli.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
# Local CLI Setup
22

3-
Use the Copilot SDK with the CLI already signed in on your machine. This is the simplest configuration — zero auth code, zero infrastructure.
3+
Use the Copilot SDK with a Copilot CLI instance signed in on your machine. Depending on the SDK, this may be a bundled CLI (included automatically) or a system-installed CLI available in your PATH. This is the simplest configuration — zero auth code, zero infrastructure.
44

55
**Best for:** Personal projects, prototyping, local development, learning the SDK.
66

77
## How It Works
88

9-
When you install the Copilot CLI and sign in, your credentials are stored in the system keychain. The SDK automatically starts the CLI as a child process and uses those stored credentials.
9+
When a Copilot CLI instance is available (either bundled with the SDK or installed on your system) and signed in, credentials are stored in the system keychain. The SDK automatically starts the CLI as a child process and uses those stored credentials.
1010

1111
```mermaid
1212
flowchart LR
@@ -21,7 +21,7 @@ flowchart LR
2121
```
2222

2323
**Key characteristics:**
24-
- CLI is spawned automatically by the SDK (no setup needed)
24+
- CLI is spawned automatically by the SDK (using a bundled CLI or a system-installed CLI if available)
2525
- Authentication uses the signed-in user's credentials from the system keychain
2626
- Communication happens over stdio (stdin/stdout) — no network ports
2727
- Sessions are local to your machine
@@ -161,7 +161,7 @@ While defaults work great, you can customize the local setup:
161161

162162
```typescript
163163
const client = new CopilotClient({
164-
// Override CLI location (default: bundled with @github/copilot)
164+
// Override CLI location (by default, the SDK uses a bundled CLI or resolves one from your system)
165165
cliPath: "/usr/local/bin/copilot",
166166

167167
// Set log level for debugging

0 commit comments

Comments
 (0)