Skip to content

Commit ad6b177

Browse files
Replace Claude for Desktop with VS Code + Copilot in server quickstart (modelcontextprotocol#1557)
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 1c4c77a commit ad6b177

2 files changed

Lines changed: 41 additions & 105 deletions

File tree

docs/documents.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ children:
1010

1111
# Documents
1212

13-
- [Server Quickstart](./server-quickstart.md) – build a weather server from scratch and connect it to Claude for Desktop
13+
- [Server Quickstart](./server-quickstart.md) – build a weather server from scratch and connect it to VS Code
1414
- [Server](./server.md) – building MCP servers, transports, tools/resources/prompts, sampling, elicitation, tasks, and deployment patterns
1515
- [Client Quickstart](./client-quickstart.md) – build an LLM-powered chatbot that connects to an MCP server and calls its tools
1616
- [Client](./client.md) – using the high-level client, transports, OAuth helpers, handling server‑initiated requests, and tasks

docs/server-quickstart.md

Lines changed: 40 additions & 104 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,11 @@ title: Server Quickstart
44

55
# Quickstart: Build a weather server
66

7-
In this tutorial, we'll build a simple MCP weather server and connect it to a host, Claude for Desktop.
7+
In this tutorial, we'll build a simple MCP weather server and connect it to a host.
88

99
## What we'll be building
1010

11-
We'll build a server that exposes two tools: `get-alerts` and `get-forecast`. Then we'll connect the server to an MCP host (in this case, Claude for Desktop).
12-
13-
> [!NOTE]
14-
> Servers can connect to any client. We've chosen Claude for Desktop here for simplicity, but we also have a guide on [building your own client](./client.md) as well as a [list of other clients here](https://modelcontextprotocol.io/clients).
11+
We'll build a server that exposes two tools: `get-alerts` and `get-forecast`. Then we'll connect the server to an MCP host (in this case, VS Code with GitHub Copilot).
1512

1613
## Core MCP Concepts
1714

@@ -365,80 +362,49 @@ main().catch((error) => {
365362
366363
Make sure to run `npm run build` to build your server! This is a very important step in getting your server to connect.
367364

368-
Let's now test your server from an existing MCP host, Claude for Desktop.
369-
370-
## Testing your server with Claude for Desktop
371-
372-
> [!NOTE]
373-
> Claude for Desktop is not yet available on Linux. Linux users can proceed to the [Client guide](./client.md) to build an MCP client that connects to the server we just built.
374-
375-
First, make sure you have Claude for Desktop installed. [You can install the latest version here.](https://claude.ai/download) If you already have Claude for Desktop, **make sure it's updated to the latest version.**
365+
Let's now test your server from an existing MCP host.
376366

377-
We'll need to configure Claude for Desktop for whichever MCP servers you want to use. To do this, open your Claude for Desktop App configuration at `~/Library/Application Support/Claude/claude_desktop_config.json` in a text editor. Make sure to create the file if it doesn't exist.
367+
## Testing your server in VS Code
378368

379-
For example, if you have [VS Code](https://code.visualstudio.com/) installed:
369+
[VS Code](https://code.visualstudio.com/) with [GitHub Copilot](https://github.com/features/copilot) can discover and invoke MCP tools via agent mode. [Copilot Free](https://github.com/features/copilot/plans) is sufficient to follow along.
380370

381-
**macOS/Linux:**
382-
383-
```bash
384-
code ~/Library/Application\ Support/Claude/claude_desktop_config.json
385-
```
386-
387-
**Windows:**
371+
> [!NOTE]
372+
> Servers can connect to any client. We've chosen VS Code here for simplicity, but we also have a guide on [building your own client](./client-quickstart.md) as well as a [list of other clients here](https://modelcontextprotocol.io/clients).
388373
389-
```powershell
390-
code $env:AppData\Claude\claude_desktop_config.json
391-
```
374+
### Prerequisites
392375

393-
You'll then add your servers in the `mcpServers` key. The MCP UI elements will only show up in Claude for Desktop if at least one server is properly configured.
376+
1. Install [VS Code](https://code.visualstudio.com/) (version 1.99 or later).
377+
2. Install the **GitHub Copilot** extension from the VS Code Extensions marketplace.
378+
3. Sign in to your GitHub account when prompted.
394379

395-
In this case, we'll add our single weather server like so:
380+
### Configure the MCP server
396381

397-
**macOS/Linux:**
382+
Create a `.vscode/mcp.json` file in your `weather` project root:
398383

399384
```json
400385
{
401-
"mcpServers": {
386+
"servers": {
402387
"weather": {
388+
"type": "stdio",
403389
"command": "node",
404-
"args": ["/ABSOLUTE/PATH/TO/PARENT/FOLDER/weather/build/index.js"]
390+
"args": ["./build/index.js"]
405391
}
406392
}
407393
}
408394
```
409395

410-
**Windows:**
396+
VS Code may prompt you to trust the MCP server when it detects this file. If prompted, confirm to start the server.
411397

412-
```json
413-
{
414-
"mcpServers": {
415-
"weather": {
416-
"command": "node",
417-
"args": ["C:\\PATH\\TO\\PARENT\\FOLDER\\weather\\build\\index.js"]
418-
}
419-
}
420-
}
421-
```
422-
423-
This tells Claude for Desktop:
424-
425-
1. There's an MCP server named "weather"
426-
2. Launch it by running `node /ABSOLUTE/PATH/TO/PARENT/FOLDER/weather/build/index.js`
427-
428-
Save the file, and restart **Claude for Desktop**.
429-
430-
### Test with commands
398+
To verify, run **MCP: List Servers** from the Command Palette (`Ctrl+Shift+P` / `Cmd+Shift+P`). The `weather` server should show a running status.
431399

432-
Let's make sure Claude for Desktop is picking up the two tools we've exposed in our `weather` server. You can do this by looking for the "Add files, connectors, and more /" icon.
400+
### Use the tools
433401

434-
After clicking on the plus icon, hover over the "Connectors" menu. You should see the `weather` server listed.
435-
436-
If your server isn't being picked up by Claude for Desktop, proceed to the [Troubleshooting](#troubleshooting) section for debugging tips.
437-
438-
If the server has shown up in the "Connectors" menu, you can now test your server by running the following commands in Claude for Desktop:
439-
440-
- What's the weather in Sacramento?
441-
- What are the active weather alerts in Texas?
402+
1. Open **Copilot Chat** (`Ctrl+Alt+I` / `Ctrl+Cmd+I`).
403+
2. Select **Agent** mode from the mode selector at the top of the chat panel.
404+
3. Click the **Tools** button to confirm `get-alerts` and `get-forecast` appear.
405+
4. Try these prompts:
406+
- "What's the weather in Sacramento?"
407+
- "What are the active weather alerts in Texas?"
442408

443409
> [!NOTE]
444410
> Since this is the US National Weather Service, the queries will only work for US locations.
@@ -447,57 +413,30 @@ If the server has shown up in the "Connectors" menu, you can now test your serve
447413

448414
When you ask a question:
449415

450-
1. The client sends your question to Claude
451-
2. Claude analyzes the available tools and decides which one(s) to use
416+
1. The client sends your question to the LLM
417+
2. The LLM analyzes the available tools and decides which one(s) to use
452418
3. The client executes the chosen tool(s) through the MCP server
453-
4. The results are sent back to Claude
454-
5. Claude formulates a natural language response
455-
6. The response is displayed to you!
419+
4. The results are sent back to the LLM
420+
5. The LLM formulates a natural language response
421+
6. The response is displayed to you
456422

457423
## Troubleshooting
458424

459425
<details>
460-
<summary>Claude for Desktop integration issues</summary>
461-
462-
**Getting logs from Claude for Desktop**
463-
464-
Claude.app logging related to MCP is written to log files in `~/Library/Logs/Claude`:
426+
<summary>VS Code integration issues</summary>
465427

466-
- `mcp.log` will contain general logging about MCP connections and connection failures.
467-
- Files named `mcp-server-SERVERNAME.log` will contain error (stderr) logging from the named server.
428+
**Server not appearing or fails to start**
468429

469-
You can run the following command to list recent logs and follow along with any new ones:
430+
1. Verify you have VS Code 1.99 or later (`Help > About`) and that GitHub Copilot is installed.
431+
2. Verify the server builds without errors: run `npm run build` in the `weather` directory.
432+
3. Test it manually: run `node build/index.js` — the process should start and wait for input. Press `Ctrl+C` to exit.
433+
4. Check the server logs: in **MCP: List Servers**, select the server and choose **Show Output**.
434+
5. If the `node` command is not found, use the full path to the Node binary.
470435

471-
```bash
472-
# Check Claude's logs for errors
473-
tail -n 20 -f ~/Library/Logs/Claude/mcp*.log
474-
```
475-
476-
**Server not showing up in Claude**
477-
478-
1. Check your `claude_desktop_config.json` file syntax
479-
2. Make sure the path to your project is absolute and not relative
480-
3. Restart Claude for Desktop completely
481-
482-
> [!WARNING]
483-
> To properly restart Claude for Desktop, you must fully quit the application:
484-
>
485-
> - **Windows**: Right-click the Claude icon in the system tray (which may be hidden in the "hidden icons" menu) and select "Quit" or "Exit".
486-
> - **macOS**: Use Cmd+Q or select "Quit Claude" from the menu bar.
487-
>
488-
> Simply closing the window does not fully quit the application, and your MCP server configuration changes will not take effect.
489-
490-
**Tool calls failing silently**
436+
**Tools don't appear in Copilot Chat**
491437

492-
If Claude attempts to use the tools but they fail:
493-
494-
1. Check Claude's logs for errors
495-
2. Verify your server builds and runs without errors
496-
3. Try restarting Claude for Desktop
497-
498-
**None of this is working. What do I do?**
499-
500-
Please refer to our [debugging guide](https://modelcontextprotocol.io/legacy/tools/debugging) for better debugging tools and more detailed guidance.
438+
1. Confirm you're in **Agent** mode (not Ask or Edit mode).
439+
2. Run **MCP: Reset Cached Tools** from the Command Palette, then recheck the **Tools** list.
501440

502441
</details>
503442

@@ -524,9 +463,6 @@ This isn't an error - it just means there are no current weather alerts for that
524463

525464
</details>
526465

527-
> [!NOTE]
528-
> For more advanced troubleshooting, check out our guide on [Debugging MCP](https://modelcontextprotocol.io/legacy/tools/debugging).
529-
530466
## Next steps
531467

532468
Now that your server is running locally, here are some ways to go further:

0 commit comments

Comments
 (0)