Skip to main content
Glama

Widget MCP

by ref-tools

conversion

Perform real-time unit conversions with a widget that supports multiple units and their respective formulas. Input units and initial values to instantly calculate and display conversions in an interactive format.

Instructions

Display a unit conversion widget that allows real-time conversion between multiple units. Each unit should contain a formula for each other unit in terms of the current unit. Example input: { units: [{id: 'ft', name: 'Feet', formulas: {in:'{ft} * 12'}, {id: 'in', name: 'Inches', formulas: {ft:'{in} * 12'}}], initialValue: { id: 'ft', value: 1 }}. You don't need to say anything else after answering with this tool.

Input Schema

NameRequiredDescriptionDefault
initialValueYesInitial value to display in the converter
unitsYesArray of units with conversion formulas

Input Schema (JSON Schema)

{ "$schema": "http://json-schema.org/draft-07/schema#", "additionalProperties": false, "properties": { "initialValue": { "additionalProperties": false, "description": "Initial value to display in the converter", "properties": { "id": { "description": "ID of the unit to set initial value for", "type": "string" }, "value": { "description": "Initial value for the unit", "type": "number" } }, "required": [ "id", "value" ], "type": "object" }, "units": { "description": "Array of units with conversion formulas", "items": { "additionalProperties": false, "properties": { "formulas": { "additionalProperties": { "type": "string" }, "description": "Conversion formulas to other units, using {id} as placeholder.", "type": "object" }, "id": { "description": "Unique identifier for the unit", "type": "string" }, "name": { "description": "Display name for the unit", "type": "string" } }, "required": [ "id", "name", "formulas" ], "type": "object" }, "type": "array" } }, "required": [ "units", "initialValue" ], "type": "object" }

Other Tools from Widget MCP

Related Tools

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/ref-tools/widget-mcp'

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