Duration compare

duration-compare · version 1.0.0 · Dates & times (UTC, ISO 8601) · free, no key needed

Compare two SI duration amounts after converting both to nanoseconds.

Use when you need to: duration compare · compare two durations · compare duration amounts.

Supported

Not supported

Behavior

Input

Output

Limits

Example

Request input:

{
  "left": {
    "value": "1",
    "unit": "min"
  },
  "right": {
    "value": "59",
    "unit": "s"
  }
}

Response:

{
  "result": {
    "cmp": 1
  }
}

How to call it

MCP

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

{
  "id": "duration-compare",
  "version": "1.0.0",
  "input": {
    "left": {
      "value": "1",
      "unit": "min"
    },
    "right": {
      "value": "59",
      "unit": "s"
    }
  }
}

HTTP (no key)

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

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

CLI

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

Get the client at /clients/cli/.