{"uid":"cap_Zf7OYmIf6x5F5Gaajdmb4","slug":"agent402-schema-guard-965b853f","name":"Agent402 Schema Guard","description":"Bundled execution of the Schema guard workflow - Contract-test a JSON payload in one call: validate it against your schema, infer the schema the payload actually implies, diff the two to expose drift, and return a normalized pretty-print. One x402 payment runs 4 underlying tools (json-validate, json-schema-infer, json-diff, json-format); partial-success per step.","url":"https://agent402.tools/api/skill/schema-guard","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"schema":{"type":"string","description":"The expected JSON Schema (as a JSON string; defaults to none)"},"payload":{"type":"string","description":"The JSON payload to check (as a JSON string)"}}},"responseSchema":{"type":"json","example":{"args":{"schema":"{\"type\":\"object\",\"required\":[\"id\"]}","payload":"{\"id\":1,\"name\":\"Ada\"}"},"pack":"schema-guard","steps":[{"ok":true,"slug":"json-validate","result":{}},{"ok":true,"slug":"json-schema-infer","result":{}},{"ok":true,"slug":"json-diff","result":{}},{"ok":true,"slug":"json-format","result":{}}],"summary":"4/4 steps succeeded"}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.004","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.004/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.004","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.004","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_uN3XPeC6eyzrUXDjKJCyg","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.004","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Validates a JSON payload against a schema, infers the payload's implied schema, diffs the two to expose drift, and returns a normalized pretty-print — all in one call.","exampleAgentPrompt":"Can you contract-test this JSON payload against my schema — validate it, infer what schema the payload actually implies, show me the drift between the two, and return a normalized pretty-print? Here's the expected schema: {\"type\":\"object\",\"properties\":{\"id\":{\"type\":\"integer\"},\"name\":{\"type\":\"string\"}}} and the payload: {\"id\":\"abc\",\"name\":\"Alice\",\"extra\":true}.","exampleUseCases":null,"resultDescription":"Returns a bundled result containing: (1) validation outcome of the payload against the provided schema, (2) the inferred schema the payload actually implies, (3) a diff between the expected and inferred schemas highlighting drift, and (4) a normalized, pretty-printed version of the payload.","failureModes":["Malformed JSON string for payload — returns parse error","Malformed JSON Schema string — returns schema parse error","Missing payload field — returns 400 bad request","Schema and payload both missing — no meaningful diff possible","Payment failure — x402 payment not accepted, returns 402"],"whenToPreferThis":"Choose this endpoint when you need a single-call solution for JSON contract testing that combines validation, schema inference, drift detection, and normalization. Ideal for API development workflows, CI pipelines checking response conformance, or agents that need to verify a JSON payload against a spec without chaining multiple tools.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-15T07:00:35.942Z","isFirstParty":false}