> ## Documentation Index
> Fetch the complete documentation index at: https://agno-v2-service-account.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Server

> Start an example MCP server that uses the Streamable HTTP transport.

```python server.py theme={null}
"""Start an example MCP server that uses the Streamable HTTP transport."""

from mcp.server.fastmcp import FastMCP

# ---------------------------------------------------------------------------
# Create Agent
# ---------------------------------------------------------------------------


mcp = FastMCP("calendar_assistant")


@mcp.tool()
def get_events(day: str) -> str:
    return f"There are no events scheduled for {day}."


@mcp.tool()
def get_birthdays_this_week() -> str:
    return "It is your mom's birthday tomorrow"


# ---------------------------------------------------------------------------
# Run Agent
# ---------------------------------------------------------------------------

if __name__ == "__main__":
    mcp.run(transport="streamable-http")
```

## Run the Example

<Steps>
  <Snippet file="create-venv-step.mdx" />

  <Step title="Install dependencies">
    ```bash theme={null}
    uv pip install -U agno mcp
    ```
  </Step>

  <Step title="Run the example">
    Save the code above as `server.py`, then run:

    ```bash theme={null}
    python server.py
    ```
  </Step>
</Steps>

Full source: [cookbook/91\_tools/mcp/streamable\_http\_transport/server.py](https://github.com/agno-agi/agno/blob/main/cookbook/91_tools/mcp/streamable_http_transport/server.py)
