# Delx Commerce — Response Contract Diff

> Delx Commerce — Response Contract Diff is a paid API for AI agents from commerce.delx.ai, paid per call via x402, $0.003/call, status unknown (last checked 2026-10-01).

Compares an actual API response object against an expected response schema to identify missing fields, type mismatches, and unexpected fields.

## Facts

- Endpoint: POST https://commerce.delx.ai/api/v1/x402/response-contract-diff?utm_source=zero.xyz
- Price: $0.003/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-01
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/delx-commerce-response-contract-diff-cd34e51f
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_3gvhS5C8OdKeSAmjAfY-t

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-response-contract-diff-cd34e51f -d '<json body>'
```

Example prompt: Compare this actual response I got from an API against the expected schema and tell me which fields are missing, which have the wrong type, and whether they're compatible overall.

## When to prefer this

Use this endpoint when you need a lightweight, pay-per-call schema diff with no signup overhead — ideal for AI agents that need to verify API contract compliance on the fly, detect schema drift, or debug response mismatches in real time without setting up a full testing framework.

## Known failure modes

- Missing or malformed 'actual' or 'expected' fields returns a validation error
- Non-object inputs for actual/expected may cause parsing failure
- Payment not fulfilled via x402 returns a 402 Payment Required response
- Deeply nested schemas may only be compared at top-level scope, missing nested mismatches

## How this service works

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

## Output

Returns a JSON object with a compatibility boolean, list of missing fields, list of type mismatches, list of unexpected fields, the comparison scope (top-level structural comparison), and the schema identifier used (delx/util-response-contract-diff/v1).

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "actual": {
   "type": "object",
   "description": "Input field: actual."
  },
  "expected": {
   "type": "object",
   "description": "Input field: expected."
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "scope": "top-level structural comparison",
  "schema": "delx/util-response-contract-diff/v1",
  "compatible": false,
  "missing_fields": [
   "ready"
  ],
  "type_mismatches": [
   "id"
  ],
  "unexpected_fields": []
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/delx-commerce-response-contract-diff-cd34e51f/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)
