Skip to main content
Glama
dolphinsboy

Test FastMCP

by dolphinsboy

multiply

Calculate the product of two integers. Multiply two numbers together to get their total result.

Instructions

Multiply two integers together.

Args: a: First integer b: Second integer

Returns: The product of a and b

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
aYes
bYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Implementation Reference

  • main.py:31-42 (handler)
    The multiply tool handler implementation, decorated with @mcp.tool to register it as an MCP tool. Takes two integer parameters (a and b) and returns their product. The function includes comprehensive docstring documentation for the tool schema.
    @mcp.tool
    def multiply(a: int, b: int) -> int:
        """Multiply two integers together.
        
        Args:
            a: First integer
            b: Second integer
            
        Returns:
            The product of a and b
        """
        return a * b
  • main.py:31-42 (registration)
    Registration of the multiply tool using FastMCP's @mcp.tool decorator on line 31. This decorator automatically registers the function as an MCP tool with its schema derived from the function signature and docstring.
    @mcp.tool
    def multiply(a: int, b: int) -> int:
        """Multiply two integers together.
        
        Args:
            a: First integer
            b: Second integer
            
        Returns:
            The product of a and b
        """
        return a * b
  • main.py:32-41 (schema)
    Schema definition for the multiply tool: accepts two integer parameters (a and b) and returns an integer. The type hints and docstring define the input/output schema for MCP tool validation.
    def multiply(a: int, b: int) -> int:
        """Multiply two integers together.
        
        Args:
            a: First integer
            b: Second integer
            
        Returns:
            The product of a and b
        """
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries full burden. While it states the basic operation, it doesn't disclose important behavioral traits like overflow handling, performance characteristics, error conditions, or whether it's idempotent. The description is minimal beyond stating the core function.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is perfectly structured and front-loaded with the core purpose, followed by clear parameter and return value sections. Every sentence earns its place with zero wasted words, making it easy to scan and understand.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's simplicity (basic arithmetic), 2 parameters, and the presence of an output schema (which handles return value documentation), the description is reasonably complete. It covers the essential what and how, though additional behavioral context would be beneficial for a production tool.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

With 0% schema description coverage, the description compensates by clearly explaining both parameters ('First integer' and 'Second integer'). It adds meaningful semantic context beyond the bare schema, though it doesn't specify constraints like range limits or special values.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the specific action ('Multiply two integers together') and identifies the resource (integers). It distinguishes from sibling tools (add, divide, subtract) by specifying multiplication rather than other arithmetic operations.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies usage for integer multiplication but doesn't explicitly state when to use this tool versus alternatives like 'add' or 'divide'. No guidance is provided about edge cases, limitations, or prerequisites for use.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/dolphinsboy/test-fast-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server