Demo FastMCP Server
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Demo FastMCP Serveradd 5 and 7"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Demo FastMCP Server
로컬에서 FastMCP 서버 구조(tools / resources / prompts / lifespan)를 실험하기 위한 더미 프로젝트입니다.
툴만 추가하려면 → docs/ADD_TOOL.md
구조
src/demo_mcp/
├── server.py # FastMCP 인스턴스 + lifespan + 등록 진입점
├── config.py # 설정/시드 데이터
├── tools/ # @mcp.tool
│ ├── echo.py
│ ├── calculator.py
│ └── notes.py # lifespan context 예시
├── resources/ # @mcp.resource
│ ├── config.py
│ └── notes.py
└── prompts/ # @mcp.prompt
└── assistant.py
tests/
└── test_server.py # Client(mcp) 인메모리 테스트Related MCP server: mcp-server-demo
설치
uv sync --extra dev테스트
uv run pytest -q인메모리 Client(mcp)로 transport 없이 tools/resources/prompts를 검증합니다.
서버 실행
HTTP (기본):
uv run demo-mcp서버 URL: http://127.0.0.1:8000/mcp
환경변수로 바꿀 수 있습니다.
변수 | 기본값 | 설명 |
|
|
|
|
| 바인드 호스트 |
|
| 포트 |
|
| MCP 엔드포인트 경로 |
stdio:
DEMO_MCP_TRANSPORT=stdio uv run demo-mcpCursor MCP 연결 예시
HTTP (서버를 먼저 uv run demo-mcp로 실행한 뒤):
{
"mcpServers": {
"demo-mcp": {
"url": "http://127.0.0.1:8000/mcp"
}
}
}이미 .cursor/mcp.json에 위 설정이 들어 있습니다.
포함된 더미 기능
종류 | 이름 | 설명 |
tool |
| 단순 문자열 |
tool |
| 사칙연산 |
tool |
| lifespan store |
resource |
| 서비스 메타 |
resource |
| 시드 노트 |
prompt |
| 프롬프트 템플릿 |
mcp
Available Tools
7 toolsaddA
Add two numbers.
| Name | Required | Description | Default |
|---|---|---|---|
| a | Yes | First number | |
| b | Yes | Second number |
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, but the description 'Add two numbers' implies a pure, side-effect-free operation, which is the primary behavioral trait. It does not explicitly state return behavior, but the presence of an output schema covers that.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, clear sentence with no waste. It is appropriately concise for a simple arithmetic operation.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The tool is simple and an output schema exists, so return values need not be explained. The description sufficiently covers the operation, though it could benefit from a note about edge cases or precision.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema covers 100% of parameters with descriptions ('First number' and 'Second number'), so the description does not need to add much. The phrase 'two numbers' reinforces the schema but adds no new semantics beyond what is already present.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description uses a specific verb ('Add') and resource ('two numbers'), clearly defining the tool's function. It distinguishes itself from siblings like 'calculate' and 'echo' by specifying the exact operation.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The implied usage is for adding two numbers, but no explicit guidance is provided about when to use this tool versus 'calculate' or other alternatives. The context is clear but lacks exclusions or alternative recommendations.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
calculateC
Run a basic arithmetic operation.
| Name | Required | Description | Default |
|---|---|---|---|
| a | Yes | Left operand | |
| b | Yes | Right operand | |
| op | No | Arithmetic operator | + |
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description must disclose behavioral traits. It only states 'basic arithmetic operation' without explaining edge cases like division by zero, return type, or error handling.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single sentence with no redundant words, making it appropriately concise for a simple tool.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Despite having an output schema, the description lacks usage context and behavioral warnings. It does not differentiate from sibling 'add', nor address potential edge cases, making it incomplete for an agent to invoke correctly in all scenarios.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Input schema covers all parameters with descriptive text (100% coverage), including the enum for 'op' and defaults. The description adds no value beyond what the schema already provides.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Description states clear verb 'Run' with object 'basic arithmetic operation', making the purpose understandable. However, it does not distinguish from sibling tool 'add', which likely overlaps in functionality.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
No guidance is provided on when to use this tool versus alternatives. It does not mention that 'add' should be used for addition specifically, nor any exclusions or prerequisites.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
echoA
Echo the given message unchanged.
| Name | Required | Description | Default |
|---|---|---|---|
| message | Yes | Text to echo back |
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden of behavioral disclosure. 'Unchanged' explicitly conveys that no modification is performed, which is the core behavioral trait. Additional details are unnecessary for such a trivial operation.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, front-loaded sentence with zero redundancy or filler. Every word earns its place, making it optimally concise.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a tool with one simple parameter and an output schema, the description is fully sufficient. It conveys the exact behavior, and the schema covers the remaining details, leaving no meaningful gaps.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, with the parameter 'message' already described as 'Text to echo back'. The tool description adds no further semantic value beyond what the schema provides, aligning with the baseline of 3.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description uses a specific verb ('Echo') with a clear resource ('the given message') and scope ('unchanged'), making its purpose completely unambiguous. It clearly differentiates from sibling tools like 'add' or 'greet' by describing a distinct operation.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
No explicit guidance on when to use this tool versus alternatives is provided. However, the simple nature of the tool and its unique name make its usage context implicitly clear, so it meets the 'implied usage' threshold.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_noteA
Read a note from the process-local store.
| Name | Required | Description | Default |
|---|---|---|---|
| key | Yes | Note key to read |
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the burden of disclosing behavior. It conveys that the operation is a read against a local store, but does not mention what happens if the key is missing, return format details, or side-effects (though 'read' implies none). This is adequate for a simple read tool but lacks explicit edge-case disclosure.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single concise sentence that directly states the tool's purpose without wasted words. It is front-loaded and easy to parse.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The tool is simple with one fully documented parameter and an output schema, so the description need not explain return values. However, it lacks explicit guidance on when to choose this tool over related siblings, and does not address error behavior, making it only minimally complete.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100% (the 'key' parameter has a clear description). The tool description adds no further semantics beyond the schema, which matches the baseline for high coverage.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's action ('Read') and resource ('a note from the process-local store'), which distinguishes it from sibling tools like save_note and list_notes. It is specific and unambiguous.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies usage for reading a specific note by key, but does not explicitly compare to alternatives such as list_notes for listing all notes or save_note for writing. No exclusions or when-not-to-use guidance is provided.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
greetB
Return a simple greeting string.
| Name | Required | Description | Default |
|---|---|---|---|
| name | No | Name to greet | world |
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the full burden. 'Return a simple greeting string' does not disclose side effects, error behavior, or confirm read-only status, leaving assumptions about safety.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
A single, front-loaded sentence conveys the purpose with zero waste, earning a 5.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
While the tool is trivial with one optional param and an output schema, the description omits usage guidance and behavioral transparency. It is adequate but not complete; a 3 reflects the missing context.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The schema already documents the single param 'name' with a description, and coverage is 100%. The description adds no additional parameter semantics, so baseline 3 is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description uses the specific verb 'return' and names the resource 'greeting string', clearly indicating the tool's function. However, it does not explicitly distinguish it from sibling tools like echo, which also returns strings.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides no guidance on when to use this tool over alternatives. There is no mention of scenarios or exclusions, leaving the agent to infer from the name.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
list_notesA
List all notes currently held in lifespan store.
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
Output Schema
| Name | Required | Description |
|---|---|---|
No output parameters | ||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description carries the burden. It adds the context of 'lifespan store' indicating a transient, session-scoped store, and 'list' implies non-destructive read. However, it does not explicitly state side-effect-free behavior or sorting/pagination details, leaving some ambiguity.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, front-loaded sentence that conveys the essential action and scope without wasted words. It earns a top score for brevity and clarity.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool's simplicity (no params, output schema exists), the description sufficiently states what it does. It does not explain return format, but the output schema covers that. It lacks explicit alternatives, but for a basic list operation, the description is adequately complete.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The tool has zero parameters, so the description need not explain parameter semantics. The schema already confirms no inputs, and the description's mention of 'all notes' matches the zero-param design. Baseline of 4 is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the action ('List'), the resource ('all notes'), and the scope ('currently held in lifespan store'). It distinguishes itself from siblings like get_note (singular) and save_note by focusing on listing all items.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies usage for retrieving all notes, but it does not explicitly contrast with get_note or provide when-to-use guidance. The presence of siblings like get_note makes this an implied rather than explicit guideline.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
save_noteA
Save a note into the process-local store (lifespan context).
| Name | Required | Description | Default |
|---|---|---|---|
| key | Yes | Note key | |
| value | Yes | Note value |
Output Schema
| Name | Required | Description |
|---|---|---|
No output parameters | ||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden of behavioral disclosure. It discloses the key trait that the note is stored in a process-local, lifespan-scoped context, indicating in-memory, process-bound persistence. It does not mention overwrite behavior or failure modes, but the core storage semantics are clear.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, focused sentence with no wasted words. It front-loads the action and storage scope, making it immediate and clear.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a simple two-parameter save tool with an output schema, the description provides essential context about where data is stored and its lifetime. It could mention retrieval via get_note/list_notes, but that is indirectly implied and not necessary for invoking the tool correctly.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema has 100% description coverage for both parameters, defining them as key and value strings. The description adds no parameter-specific meaning beyond what the schema already provides, so it appropriately relies on the schema.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool saves a note into a process-local store with a specific verb and resource, and the store context distinguishes it from sibling retrieval tools like get_note and list_notes.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies usage for storing notes in the local process context but does not explicitly reference alternatives or when-not-to-use. The lifespan context hints at the appropriate scope, but no direct guidance is given.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
7 tool updates
v0.1.0- First observed
add - First observed
calculate - First observed
echo - First observed
get_note - First observed
greet - First observed
list_notes - First observed
save_note
TDQS
Scored across 7 tools
The note tools are clearly distinct, but 'add' and 'calculate' overlap since calculate can perform addition. 'echo' and 'greet' are both simple string-returning tools, though their purposes are slightly different.
Tool names mix single-word verbs (add, calculate, echo, greet) with verb_noun patterns (save_note, get_note, list_notes). This is readable but lacks a consistent convention across the set.
Seven tools is a reasonable count for a demo server, though a couple (echo, greet) are trivial and add little functional value. Still well within the typical 3-15 range.
The note tools cover save, read, and list but lack update and delete. The arithmetic tools are minimal (add and calculate). There are minor gaps, but for a demo server the coverage is acceptable.
Maintenance
Related MCP Connectors
MCP server for building and testing AI agents with multi-model experimentation and insights.
A simple MCP server built with FastMCP and python
An MCP server for deep research or task groups
MCP server for agentverse documentation, generated by doc2mcp.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceEducational example of an MCP server built with FastMCP, demonstrating how to expose tools, resources, and prompts for AI clients.-
- FlicenseNot gradedqualityDmaintenanceExample MCP server built with FastMCP, demonstrating tools, resources, and prompts for AI integration.13-
- FlicenseNot gradedqualityDmaintenanceA demonstration MCP server for exploring MCP prompts with 10 reusable development prompts.-
- AlicenseNot gradedqualityCmaintenanceA public-safe demo MCP server for learning how to package Tools, Resources, and Prompts, using fictional contract text and local demo rules only.MIT