# Saylor Innovations Data Desk – JSON Diff

> Saylor Innovations Data Desk – JSON Diff is a paid API for AI agents from saylorinnovations.com, paid per call via x402, $0.01/call, status unknown (last checked 2026-10-30).

Compare two JSON documents and return every added, removed, changed, or retyped path with old/new values and a summary count by operation

## Facts

- Endpoint: GET https://saylorinnovations.com/api/json/diff?utm_source=zero.xyz
- Price: $0.01/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-30
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/saylor-innovations-data-desk-json-diff-da80112f
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_U9_CkV_FfzS1aPuqkNfUd

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 saylor-innovations-data-desk-json-diff-da80112f
```

Example prompt: Can you diff these two JSON documents for me and tell me exactly which paths were added, removed, or changed — here's the before: {"name":"Alice","age":30,"city":"NY"} and the after: {"name":"Alice","age":31,"email":"alice@example.com"}?

## When to prefer this

Choose this endpoint when you need a structured, machine-readable JSON diff with explicit JSONPaths, operation types, and old/new values — especially when you want a summary count by operation type. Prefer it over generic text-based diff tools when downstream code needs to process the differences programmatically. Best suited for JSON documents under 6000 characters each.

## Known failure modes

- Missing required query parameters `a` or `b` returns an error
- Input JSON string exceeds 6000 character limit and is rejected
- Malformed JSON in either parameter causes a parse error
- Very large or deeply nested documents may hit the truncation limit, indicated by `truncated: true` in the response
- Network or service unavailability returns a non-200 status

## How this service works

Compare two JSON documents - every added, removed, changed or retyped path with old and new values, plus a summary count by operation

## Output

Returns a JSON object with: an `identical` boolean, a `changes` count, a `diff` array where each entry has a JSONPath, operation type (added/removed/changed/retyped), and from/to values, a `by_op` summary with counts per operation type, and optional `note` and `truncated` flags if the result was cut off.

## 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": [
      "a",
      "b"
     ],
     "properties": {
      "a": {
       "type": "string",
       "description": "First JSON document, up to 6000 characters"
      },
      "b": {
       "type": "string",
       "description": "Second JSON document, up to 6000 characters"
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "json"
    },
    "example": {
     "type": "object",
     "required": [
      "identical",
      "changes",
      "diff"
     ],
     "properties": {
      "diff": {
       "type": "array",
       "items": {
        "type": "object",
        "properties": {
         "op": {
          "description": "Operation performed"
         },
         "to": {
          "description": "End of the range"
         },
         "from": {
          "description": "Start of the range"
         },
         "path": {
          "type": [
           "string",
           "null"
          ],
          "description": "JSONPath of the difference"
         }
        }
       },
       "description": "Differences with path, operation and old and new values"
      },
      "note": {
       "type": "string",
       "description": "Caveat or context for reading the result"
      },
      "by_op": {
       "type": "object",
       "properties": {
        "added": {
         "type": [
          "number",
          "null"
         ],
         "description": "Added keys"
        },
        "changed": {
         "type": [
          "number",
          "null"
         ],
         "description": "Changed values"
        },
        "removed": {
         "type": [
          "number",
          "null"
         ],
         "description": "Removed keys"
        }
       },
       "description": "By op"
      },
      "source": {
       "type": "string",
       "description": "Data source the values come from"
      },
      "changes": {
       "type": "number",
       "description": "Number of differences
… (truncated)
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/saylor-innovations-data-desk-json-diff-da80112f/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from saylorinnovations.com](https://www.zero.xyz/host/saylorinnovations.com/llms.txt)
