obfus.link

JSON Path Evaluator extracts values from any JSON document using JSONPath or jq syntax in a single tool. Path Suggestions analyses unknown structures and recommends ranked extraction expressions, letting agents discover paths without knowing the schema. Returns matches, canonical bracket-notation paths, and a tree overview giving depth, total keys, array items, and top-level keys.

Tier 2analyzers✓ TDD Verified

JSON Path Evaluator

Extract values from JSON with dual JSONPath + jq syntax and path suggestions

examples · $.store.book[?(@.price < 10)].title · $..price · $.store.book[0:2].title

How to use

  1. Paste your JSONDrop any JSON object or array into the document field. Both strings and pre-parsed objects work when calling via MCP.
  2. Pick syntaxJSONPath for web/JavaScript pipelines, jq for CLI/Unix pipelines. Equivalent expressions produce identical results.
  3. Write the expressionUse the syntax of your choice. The placeholder shows a canonical example for each.
  4. Toggle Suggest pathsWhen ON, the tool returns up to 10 ranked extraction expressions analysing your JSON's structure — useful when the schema is unknown.
  5. Run and inspectEach match shows its canonical path so you can find values that share a key in multiple places. Click a suggestion to use it.
Read technical article

MCP / API

Call json_path_evaluator directly from any MCP-compatible agent:

// MCP TypeScript SDK
const result = await client.callTool({
  name: "json_path_evaluator",
  arguments: {
    "json": "...",
    "expression": "...",
    "syntax": "jsonpath"
  }
});

// curl
curl -X POST https://obfus.link/mcp \
  -H "Authorization: Bearer <SPT>" \
  -H "Content-Type: application/json" \
  -d '{"method":"tools/call","params":{"name":"json_path_evaluator","arguments":{"json":"...","expression":"...","syntax":"jsonpath"}}}'

Related tools

JSON to Zod
Generate Zod schemas with JSDoc and branded types from any JSON
LLM to JSON Cleaner
Repair malformed JSON from LLM responses with confidence scoring
XML to JSON
Bidirectional XML ↔ JSON with attribute, namespace, and CDATA preservation

FAQ

What's the difference between JSONPath and jq?

JSONPath uses $ as the root anchor and dot-or-bracket child syntax: $.foo.bar, $.foo[*], $..price. jq uses dot-leading paths and square brackets for iteration: .foo.bar, .foo[], .[]. JSONPath dominates web/JavaScript code; jq dominates CLI/Unix pipelines. Both produce identical match arrays for equivalent expressions in this tool.

Which JSONPath features are supported?

The full JSONPath spec via jsonpath-plus: $ (root), .foo (child), [N] (index), [*] (wildcard), ['key'] (bracket child), ..foo (recursive descent), [?(@.x>10)] (filter expressions), [0:2] (slices), and [1,3,5] (unions). Filter expressions can reference @ to compare fields against literals or other fields. Script expressions like [(@.length-1)] are not enabled for security.

Which jq features are supported?

The full jq language via jq-web (WASM): pipes, select, map, reduce, arithmetic, string manipulation, type conversion, and every standard built-in. The WASM binary is lazy-loaded on the first jq invocation per process — JSONPath-only callers never pay the load cost.

How does Path Suggestions decide what to recommend?

Three strategies, ranked by matchCount: (1) top-level keys when the root is an object, or array index + wildcard when the root is an array; (2) recursive expressions for ID-like fields anywhere in the document (id, uuid, guid, token, hash, key, sku, slug); (3) for any array of objects with a common shape, the top 3 keys present in every item.

What does the Tree overview tell me?

depth = the maximum nesting level. totalKeys = every object key counted at every depth. totalArrayItems = every array element counted at every depth. topLevelKeys = the keys at the root when the root is an object. Together they describe the document's shape before you write an extraction expression — useful for agents reasoning about an unknown payload.

Can I use this tool via the MCP API?

Yes. The tool is registered on the obfus.link MCP server at https://obfus.link/mcp. Call it from any MCP-compatible agent with a Shared Payment Token. The MCP tool name matches the snake_case slug shown in the integration snippet.