We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/jimthompson5802/mcp_testlab'
If you have feedback or need assistance with the MCP directory API, please join our Discord server
math_tools.py•615 B
from fastmcp import FastMCP
mcp = FastMCP("MathTools")
@mcp.tool()
def add(a: int, b: int) -> int:
"""Add two numbers.
Args:
a: The first integer to add.
b: The second integer to add.
Returns:
int: The sum of a and b.
"""
return a + b
@mcp.tool()
def multiply(a: int, b: int) -> int:
"""Multiply two numbers.
Args:
a: The first integer to multiply.
b: The second integer to multiply.
Returns:
int: The product of a and b.
"""
return a * b
if __name__ == "__main__":
mcp.run(transport="stdio", show_banner=False)