File tree Expand file tree Collapse file tree 2 files changed +37
-1
lines changed
Expand file tree Collapse file tree 2 files changed +37
-1
lines changed Original file line number Diff line number Diff line change 1+ # Code Examples
2+
3+ This page demonstrates various MCP SDK examples using the snippet feature.
4+
5+ ## FastMCP Quickstart
6+
7+ Here's a complete quickstart example showing how to create a server with tools, resources, and prompts:
8+
9+ ``` python title="fastmcp_quickstart.py"
10+ -- 8 < -- " servers/fastmcp_quickstart.py"
11+ ```
12+
13+ ## Basic Tool Example
14+
15+ This example shows how to define simple tools:
16+
17+ ``` python title="basic_tool.py"
18+ -- 8 < -- " servers/basic_tool.py"
19+ ```
20+
21+ ## Usage
22+
23+ To run any of these examples:
24+
25+ 1 . Navigate to the ` examples/snippets ` directory
26+ 2 . Run the server using ` uv run mcp dev <filename> `
27+
28+ For example:
29+ ``` bash
30+ cd examples/snippets
31+ uv run mcp dev servers/basic_tool.py
32+ ```
Original file line number Diff line number Diff line change 1818 - Low-Level Server : low-level-server.md
1919 - Authorization : authorization.md
2020 - Testing : testing.md
21+ - Examples : examples.md
2122 - API Reference : api.md
2223
2324theme :
@@ -77,7 +78,10 @@ markdown_extensions:
7778 - pymdownx.critic
7879 - pymdownx.mark
7980 - pymdownx.superfences
80- - pymdownx.snippets
81+ - pymdownx.snippets :
82+ base_path :
83+ - examples/snippets
84+ - .
8185 - pymdownx.tilde
8286 - pymdownx.inlinehilite
8387 - pymdownx.highlight :
You can’t perform that action at this time.
0 commit comments