"""Pure MCP server over stdio.""" from mcp.server.fastmcp import FastMCP import services from mcp_tools import MCP_TOOLS mcp = FastMCP("crypto-mcp") @mcp.tool() async def get_price(symbol: str): return await services.get_price(symbol) @mcp.tool() async def get_ohlcv(symbol: str, timeframe: str = "1h", limit: int = 100): return await services.get_ohlcv(symbol, timeframe, limit) @mcp.tool() async def get_indicator(symbol: str, indicator: str, timeframe: str = "1h", params: dict | None = None): return await services.get_indicator(symbol, indicator, timeframe, params or {}) @mcp.tool() async def get_market_snapshot(symbol: str): return await services.get_market_snapshot(symbol) @mcp.tool() async def get_top_movers(limit: int = 10): return await services.get_top_movers(limit) if __name__ == "__main__": mcp.run()