# FastX402 Lab Semver Match

> FastX402 Lab Semver Match is a paid API for AI agents from lab.fastx402.tools, paid per call via x402, $0.002/call, status unknown (last checked 2026-10-17).

Filters a list of semantic versions against a semver range constraint, returning all matching versions plus the highest match

## Facts

- Endpoint: GET https://lab.fastx402.tools/semver-match?utm_source=zero.xyz
- Price: $0.002/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-17
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/fastx402-lab-semver-match-02bb1461
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_5qg6vs6OrlQsXfek6XxA-

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 fastx402-lab-semver-match-02bb1461
```

Example prompt: From this list of versions — 1.0.0, 1.2.3, 2.0.0, 2.4.0, 2.5.1, 3.0.0 — which ones satisfy the semver range ^2.4.0, and which is the highest match?

## When to prefer this

Choose this endpoint when you need to programmatically filter a batch of semantic version strings against a semver range at low cost without setting up any authentication or API keys. Ideal for AI agents performing dependency resolution, CI/CD version selection, or release compatibility checks where a quick pay-per-call model fits better than maintaining a subscription. Prefer this over rolling your own semver logic or calling a full package registry API when you just need range-matching results.

## Known failure modes

- Invalid semver range syntax returns an error or empty match set
- Malformed version strings in the list may be skipped or cause an error
- Exceeding 200 characters for versions or constraint may return a validation error
- Payment failure via x402 results in a 402 response with no result
- Pre-release version matching behavior may differ from expectations if range does not explicitly include pre-release identifiers

## How this service works

FastX402 Lab: small pay-per-call tools for AI agents, paid per request in USDC on Base over x402. No signup, no API key.

## Output

Returns a JSON object with: the constraint string used, total versions checked, count of matches, an array of all matching version strings, and the highest matching version string.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "versions",
      "constraint"
     ],
     "properties": {
      "versions": {
       "type": "string",
       "description": "Comma-separated semantic versions, e.g. 1.2.3,2.0.0-rc.1 (max 200)"
      },
      "constraint": {
       "type": "string",
       "description": "Semver range: ^, ~, >, >=, <, <=, =, x-ranges, hyphen ranges, space for AND, || for OR (max 200 chars)"
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object",
     "properties": {
      "count": {
       "type": "integer"
      },
      "checked": {
       "type": "integer"
      },
      "highest": {
       "type": "string"
      },
      "matches": {
       "type": "array",
       "items": {
        "type": "string"
       }
      },
      "constraint": {
       "type": "string"
      }
     }
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "count": 2,
  "checked": 6,
  "highest": "2.5.1",
  "matches": [
   "2.4.0",
   "2.5.1"
  ],
  "constraint": "^2.4.0"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/fastx402-lab-semver-match-02bb1461/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from lab.fastx402.tools](https://www.zero.xyz/host/lab.fastx402.tools/llms.txt)
