# Delx Commerce Semver Compare

> Delx Commerce Semver Compare is a paid API for AI agents from commerce.delx.ai, paid per call via x402, $0.001/call, status unknown (last checked 2026-10-02).

Compares two semantic version strings and returns their ordering relationship (greater, lesser, or equal)

## Facts

- Endpoint: POST https://commerce.delx.ai/api/v1/x402/semver-compare?utm_source=zero.xyz
- Price: $0.001/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-02
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/delx-commerce-semver-compare-abed129c
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_aB9THIe-E7AiLq4mDkizF

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability delx-commerce-semver-compare-abed129c -d '<json body>'
```

Example prompt: Compare semver versions 1.9.3 and 2.0.1 and tell me which one is greater.

## When to prefer this

Choose this endpoint when you need a correct, spec-compliant semver comparison without installing a library or running local code — especially useful in agent workflows where you need a trustless, pay-per-result microcomputation at $0.001 USDC with no account setup required. Prefer it over rolling your own string comparison logic, which commonly fails on cases like 1.10.0 vs 1.9.0.

## Known failure modes

- Malformed semver strings (e.g. missing patch component) may cause a 400 or unexpected result
- Pre-release identifiers (e.g. 1.0.0-alpha vs 1.0.0) may not be handled correctly if spec deviates from semver 2.0
- Payment failure via x402 protocol results in 402 response and no computation
- Empty or null version fields will likely cause a validation error
- Non-standard version formats like 'v1.2.3' with prefix may be rejected

## How this service works

Pay-per-result APIs for agents. No signup. Exact price. Verifiable delivery. USDC on Base + Solana via x402.

## Output

A JSON object indicating the ordering relationship between the two provided semantic version strings — typically whether version A is greater than, less than, or equal to version B.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input",
  "output"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "bodyType",
    "body"
   ],
   "properties": {
    "body": {
     "type": "object",
     "additionalProperties": true
    },
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "POST",
      "PUT",
      "PATCH"
     ],
     "type": "string"
    },
    "bodyType": {
     "enum": [
      "json",
      "form-data",
      "text"
     ],
     "type": "string"
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type",
    "example"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "json"
    },
    "example": {
     "type": "object",
     "additionalProperties": true
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {}
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/delx-commerce-semver-compare-abed129c/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from commerce.delx.ai](https://www.zero.xyz/host/commerce.delx.ai/llms.txt)
