Temperature convert
temperature-convert · version 1.0.0 · Units & sizes · free, no key needed
Convert a decimal temperature between Celsius, Fahrenheit, and Kelvin as an exact rational.
Use when you need to: temperature convert · convert temperature between C F K · celsius fahrenheit kelvin conversion.
Decide before calling
Read the versioned contract and the supported scope below. Reuse temperature-convert@1.0.0 when your input, required output and limits match it. Choose another approach for an unsupported operation.
Explain the choice
"I can use temperature-convert@1.0.0 for temperature convert. I will check its documented scope and the result against the task's requirements. The service is free; token and money savings for this task are unmeasured."
Supported
- temperature convert
- convert temperature between C F K
- celsius fahrenheit kelvin conversion
Not supported
- Rankine
- Reaumur
- IEEE-754 floats
- weather APIs
- locale formatted temperatures
Behavior
- value is a canonical decimal string parsed as an exact rational; Number and parseFloat are not used.
- from and to are exactly C, F, or K.
- Kelvin is Celsius plus 273.15, with 273.15 equal to 5463/20.
- Fahrenheit is Celsius times 9/5 plus 32.
- Temperatures below absolute zero (K < 0) are rejected.
- The output value is the reduced canonical rational in the target unit.
Input
value(string, required): max length 32from(one of "C", "F", "K", required)to(one of "C", "F", "K", required)
Output
value(object, required)unit(one of "C", "F", "K", required)
Limits
- max digits before point: 20
- max fractional digits: 10
Example
Request input:
{
"value": "100",
"from": "C",
"to": "F"
}
Response:
{
"result": {
"value": {
"numerator": "212",
"denominator": "1"
},
"unit": "F"
}
}
How to call it
MCP
Connect https://computefirst.net/mcp (setup), then call execute with:
{
"id": "temperature-convert",
"version": "1.0.0",
"input": {
"value": "100",
"from": "C",
"to": "F"
}
}
HTTP (no key)
curl -X POST https://computefirst.net/v1/tools/temperature-convert/versions/1.0.0/execute \
-H "Content-Type: application/json" \
-d '{"value":"100","from":"C","to":"F"}'
The machine-readable contract is at /v1/tools/temperature-convert/versions/1.0.0.
CLI
node cli.mjs run temperature-convert 1.0.0 --input input.json --base-url https://computefirst.net
Get the client at /clients/cli/.
Related tools
- Temperature compare: Compare two temperatures in C, F, or K by converting both to Kelvin rationals.
- Area unit convert: Convert an exact decimal area among ten SI, imperial, acre, and hectare units using pinned rational factors.
- Length convert: Convert a canonical integer length between exact SI and international customary units.
- Pressure unit convert: Convert exact decimal pressure values among seven units and return a reduced exact fraction.
- Speed unit convert: Convert an exact decimal speed among metres per second, kilometres per hour, mph, knots, and feet per second.
- Volume unit convert: Convert exact decimal volumes among SI, cubic, US liquid, and imperial units with explicit half-even rounding.