greet
Generate personalized greetings by providing a name to create custom hello messages for any recipient.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |
Implementation Reference
- gemini-mcp-example/main.py:7-9 (handler)The greet tool handler function that takes a name parameter and returns a greeting string. Implements the core logic: return f"Hello {name}!"
@mcp.tool() def greet(name: str) -> str: return f"Hello {name}!" - gemini-mcp-example/main.py:7-7 (registration)Tool registration using the @mcp.tool() decorator from FastMCP. This registers the greet function as an MCP tool.
@mcp.tool()