Compare semantic versions
Compare two semantic versions (1.2.3, pre-releases like 2.0.0-rc.1 handled by the SemVer rules) and get which is newer, plus the next major, minor and patch versions of the first. Use to decide whether an upgrade is a major change.
Inputs
| Name | Type | Description |
|---|---|---|
a (required) | string | First version |
b (required) | string | Second version |
Request
Over HTTP, with a card key from /credits:
curl -H "Authorization: Bearer adt_…" "https://agent-data-tools.revmesh2074.workers.dev/semver?a=1.10.0&b=1.9.3"
Or one of your 25 free calls, no key:
curl "https://agent-data-tools.revmesh2074.workers.dev/semver?a=1.10.0&b=1.9.3&trial=1"
Without a key, the same URL answers 402 Payment Required with x402 and MPP terms, so an agent with a wallet pays per call in USDC (Base, Polygon, Arbitrum, Monad, World Chain or Tempo) and retries.
Example result
{
"a": "1.10.0",
"b": "1.9.3",
"comparison": 1,
"newer": "1.10.0",
"nextMajor": "2.0.0",
"nextMinor": "1.11.0",
"nextPatch": "1.10.1"
}
From an AI agent (MCP)
Add the MCP server to Claude, Cursor or any MCP client. This tool is semver, and the first 25 successful calls are free:
https://agent-data-tools.revmesh2074.workers.dev/mcp