Mass compare

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

Compare two mixed-unit canonical integer mass amounts using exact nanogram BigInt values.

Use when you need to: mass compare · compare mass quantities · compare grams and pounds.

Supported

Not supported

Behavior

Input

Output

Limits

Example

Request input:

{
  "left": {
    "value": "1",
    "unit": "lb"
  },
  "right": {
    "value": "16",
    "unit": "oz"
  }
}

Response:

{
  "result": {
    "cmp": 0
  }
}

How to call it

MCP

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

{
  "id": "mass-compare",
  "version": "1.0.0",
  "input": {
    "left": {
      "value": "1",
      "unit": "lb"
    },
    "right": {
      "value": "16",
      "unit": "oz"
    }
  }
}

HTTP (no key)

curl -X POST https://computefirst.net/v1/tools/mass-compare/versions/1.0.0/execute \
  -H "Content-Type: application/json" \
  -d '{"left":{"value":"1","unit":"lb"},"right":{"value":"16","unit":"oz"}}'

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

CLI

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

Get the client at /clients/cli/.