Mass convert

mass-convert · version 1.0.0 · Units & sizes · free, no key needed

Convert a canonical integer mass amount between exact nanogram-based units as a reduced rational.

Use when you need to: mass convert · convert mass units · convert grams kilograms pounds.

Supported

Not supported

Behavior

Input

Output

Limits

Example

Request input:

{
  "value": "500",
  "from": "mg",
  "to": "g"
}

Response:

{
  "result": {
    "numerator": "1",
    "denominator": "2"
  }
}

How to call it

MCP

Connect https://computefirst.net/mcp (setup), then call execute with:

{
  "id": "mass-convert",
  "version": "1.0.0",
  "input": {
    "value": "500",
    "from": "mg",
    "to": "g"
  }
}

HTTP (no key)

curl -X POST https://computefirst.net/v1/tools/mass-convert/versions/1.0.0/execute \
  -H "Content-Type: application/json" \
  -d '{"value":"500","from":"mg","to":"g"}'

The machine-readable contract is at /v1/tools/mass-convert/versions/1.0.0.

CLI

node cli.mjs run mass-convert 1.0.0 --input input.json --base-url https://computefirst.net

Get the client at /clients/cli/.