# OpenAPI Diff

> OpenAPI Diff is a paid API for AI agents from api.edifiedlab.com, paid per call via x402, $0.011/call, status unknown (last checked 2026-10-02).

Compares two OpenAPI specifications to detect breaking changes, added paths, and contract drift between versions.

## Facts

- Endpoint: POST https://api.edifiedlab.com/v1/tools/openapi/compare?utm_source=zero.xyz
- Price: $0.011/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-02
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/openapi-diff-65a6264a
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_W8MIpGZTzKIcUycVJCwHg

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 openapi-diff-65a6264a -d '<json body>'
```

Example prompt: Compare these two OpenAPI specs and tell me what breaking changes were introduced — here's the base spec and the revised spec I'm about to ship.

## When to prefer this

Use this endpoint when you need a dedicated, structured diff of two OpenAPI specifications focused on breaking changes and contract drift. Prefer this over a generic JSON diff tool when you need API-semantic awareness (e.g. distinguishing breaking vs non-breaking changes). Use the sibling 'Structured Data Tools' endpoint for general-purpose JSON diff without OpenAPI semantics.

## Known failure modes

- Invalid or malformed OpenAPI spec in either base or revised field — returns parsing error
- Spec exceeds 262,144 character limit — returns size error
- path_count exceeds maximum of 5000 — returns validation error
- Missing both base_spec/base_openapi or revised_spec/revised_openapi fields — returns missing input error
- Non-OpenAPI JSON/YAML structure submitted — returns schema mismatch error

## How this service works

Diff two OpenAPI specs: breaking changes, added paths, and contract drift.

## Output

A structured report detailing breaking changes (removed paths, changed parameters, modified response schemas), newly added paths, and overall contract drift between the base and revised OpenAPI specifications.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "base_spec": {
   "oneOf": [
    {
     "type": "string",
     "maxLength": 262144
    },
    {
     "type": "object"
    },
    {
     "type": "array"
    }
   ]
  },
  "path_count": {
   "type": "integer",
   "maximum": 5000
  },
  "base_openapi": {
   "oneOf": [
    {
     "type": "string",
     "maxLength": 262144
    },
    {
     "type": "object"
    },
    {
     "type": "array"
    }
   ]
  },
  "revised_spec": {
   "oneOf": [
    {
     "type": "string",
     "maxLength": 262144
    },
    {
     "type": "object"
    },
    {
     "type": "array"
    }
   ]
  },
  "revised_openapi": {
   "oneOf": [
    {
     "type": "string",
     "maxLength": 262144
    },
    {
     "type": "object"
    },
    {
     "type": "array"
    }
   ]
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/openapi-diff-65a6264a/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.edifiedlab.com](https://www.zero.xyz/host/api.edifiedlab.com/llms.txt)
