Skip to main content
Glama
tech-sushant

Calculator MCP Server

by tech-sushant

multiply

Calculate the product of two numbers by multiplying them together using this mathematical operation tool.

Instructions

Multiply two numbers together

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
aYesFirst number to multiply
bYesSecond number to multiply

Implementation Reference

  • Handler for the 'multiply' tool that multiplies two numbers (a and b) and returns a formatted text result.
    case "multiply": { const { a, b } = args as { a: number; b: number }; const result = a * b; return { content: [ { type: "text", text: `${a} × ${b} = ${result}`, }, ], }; }
  • src/index.ts:56-73 (registration)
    Tool registration in the listTools handler, including name, description, and input schema for two numbers (a and b).
    { name: "multiply", description: "Multiply two numbers together", inputSchema: { type: "object", properties: { a: { type: "number", description: "First number to multiply", }, b: { type: "number", description: "Second number to multiply", }, }, required: ["a", "b"], }, },

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/tech-sushant/calculator-mcp'

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