# agent402.tools OpenAPI Agent-Readiness Linter

> agent402.tools OpenAPI Agent-Readiness Linter is a paid API for AI agents from agent402.tools, paid per call via x402, $0.002/call, status unknown (last checked 2026-09-14).

Scores an OpenAPI 3.x or Swagger 2.x spec on LLM-agent-readiness, returning a 0–100 score, severity counts, and a structured list of violations with stable rule IDs

## Facts

- Endpoint: POST https://agent402.tools/api/openapi-lint
- Price: $0.002/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/agent402-tools-openapi-agent-readiness-linter-ee0335c9
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_R8A5b9VjUyDwSm87xbK6n

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 agent402-tools-openapi-agent-readiness-linter-ee0335c9 -d '<json body>'
```

Example prompt: Can you lint this OpenAPI spec for agent-readiness and tell me the score, what severity counts look like, and exactly which rules are being violated? Here's the spec: { ... }

## When to prefer this

Use this endpoint when you need to evaluate whether an API specification is suitable for consumption by LLM-driven agents — specifically when you want a structured, rule-based score rather than a generic JSON schema validator. It is purpose-built for agent-readiness concerns (missing descriptions, ambiguous parameters, unclear response schemas) rather than general OpenAPI conformance.

## Known failure modes

- Invalid or unparseable JSON/YAML spec returns a parse error
- Spec missing required OpenAPI/Swagger version field may be rejected
- Malformed input schema (non-object, empty body) returns a 400-level error
- Swagger 1.x or non-standard formats are not supported
- Network timeout on very large specs

## How this service works

Score an OpenAPI 3.x or Swagger 2.x spec on agent-readiness - i.e. does an LLM-driven caller have what it needs to call the API correctly without guessing. Returns a 0..100 score, severity counts, and a structured list of violations with stable rule codes. Checks: documented title/servers/paths, per-operation summary/description/operationId/tags, documented 2xx + error responses, param descriptions/schemas/examples, response descriptions, JSON response schemas.

## Output

Returns a 0–100 agent-readiness score, counts of violations by severity (error/warning/info), and a structured list of individual violations each with a stable rule ID, a description of the problem, and its location in the spec — giving a clear picture of what an LLM-driven caller would struggle with.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "spec": {
   "description": "OpenAPI/Swagger document (object or JSON string)"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "ok": true,
  "score": 97,
  "counts": {
   "info": 0,
   "error": 0,
   "warning": 1
  },
  "violations": [
   {
    "rule": "operation-missing-operationid",
    "message": "Operation has no operationId - agents can't refer to this call by a stable name.",
    "location": "GET /users",
    "severity": "warning"
   }
  ]
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/agent402-tools-openapi-agent-readiness-linter-ee0335c9/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from agent402.tools](https://www.zero.xyz/host/agent402.tools/llms.txt)
