echo
Takes an input text and returns it with 'echo: ' added at the beginning.
Instructions
Return the input prefixed with 'echo: '.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| text | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |
Implementation Reference
- src/mcp_server_starter/server.py:8-11 (handler)The 'echo' tool handler function, decorated with @mcp.tool(). Takes a string and returns it prefixed with 'echo: '.
@mcp.tool() def echo(text: str) -> str: """Return the input prefixed with 'echo: '.""" return f"echo: {text}" - src/mcp_server_starter/server.py:8-8 (registration)Registration of the 'echo' tool via the @mcp.tool() decorator on the FastMCP instance.
@mcp.tool() - src/mcp_server_starter/server.py:9-9 (schema)The echo tool's type signature: accepts a single string parameter 'text' and returns a string.
def echo(text: str) -> str: