{"uid":"cap_TK5sp_5PxtJRLtK4H20n_","slug":"agent-data-tools-revmesh2074-workers-dev-json-schema-inferrer-from-6c981a1f","name":"JSON Schema Inferrer from Example JSON","description":"Infer a JSON Schema (draft 2020-12) from an example JSON value: types, nested object properties, required keys, array item shapes merged across all items, and string formats (date-time, date, email, uri, uuid). Use to document an API response or to validate later data against the same shape.","url":"https://agent-data-tools.revmesh2074.workers.dev/json/schema?utm_source=zero.xyz","method":"GET","headers":{},"bodySchema":{"type":"object","required":["json"],"properties":{"json":{"type":"string","description":"The example JSON"}}},"responseSchema":{"type":"object","properties":{"schema":{"type":"object","properties":{"type":{"type":"string"},"$schema":{"type":"string"},"required":{"type":"array","items":{"type":"string"}},"properties":{"type":"object","properties":{"id":{"type":"object","properties":{"type":{"type":"string"}}},"tags":{"type":"object","properties":{"type":{"type":"string"},"items":{"type":"object","properties":{"type":{"type":"string"}}}}},"email":{"type":"object","properties":{"type":{"type":"string"},"format":{"type":"string"}}},"created":{"type":"object","properties":{"type":{"type":"string"},"format":{"type":"string"}}}}}}}}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.01","displayCostAsset":"USD","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.01/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.01","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.01","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_l5oGzR3hRkEInHMdwdax7","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.01","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":"agent-data-tools.revmesh2074.workers.dev","brandSlug":"agent-data-tools-revmesh2074-workers-dev-x402","brandBaseUrl":"https://agent-data-tools.revmesh2074.workers.dev","brandDocsUrl":null,"whatItDoes":"Infers a JSON Schema (draft 2020-12) from an example JSON value, detecting types, nested properties, required keys, array shapes, and string formats.","exampleAgentPrompt":"Can you infer a JSON Schema from this example JSON for me? Here's the sample: {\"id\": \"abc-123\", \"email\": \"user@example.com\", \"created\": \"2024-01-15T10:30:00Z\", \"tags\": [\"admin\", \"user\"]}","exampleUseCases":[{"title":"Document an API response shape","prompt":"I got this JSON back from an API and I want to document its structure as a formal JSON Schema — can you generate one from this example: {\"userId\": \"d290f1ee\", \"name\": \"Jane\", \"email\": \"jane@example.com\", \"createdAt\": \"2024-03-01T00:00:00Z\", \"roles\": [\"editor\", \"viewer\"]}?"},{"title":"Validate future data against example shape","prompt":"I have this sample JSON payload from our webhook and I want a JSON Schema I can use to validate future incoming payloads against: {\"orderId\": \"ORD-9981\", \"amount\": 42.50, \"currency\": \"USD\", \"placedAt\": \"2024-06-10\", \"items\": [{\"sku\": \"ABC\", \"qty\": 2}]}."},{"title":"Auto-generate schema for onboarding docs","prompt":"We're writing developer documentation and need a JSON Schema for this example user profile response — can you derive it? Here's the example: {\"id\": 101, \"username\": \"jdoe\", \"email\": \"jdoe@corp.com\", \"active\": true, \"createdAt\": \"2023-11-20T08:00:00Z\"}."}],"resultDescription":"Returns a JSON Schema (draft 2020-12) object with inferred types for all fields, nested property definitions, a required array listing keys present in the example, merged array item shapes across all array elements, and string format annotations (date-time, date, email, uri, uuid) where detectable.","failureModes":["Invalid or malformed JSON input returns an error rather than a schema","Deeply nested or extremely large JSON may produce incomplete schemas","Ambiguous types (e.g. null values) may result in missing or overly permissive type annotations","Arrays with heterogeneous item types may produce a merged schema that is overly broad","String values that don't match known formats will have no format annotation"],"whenToPreferThis":"Choose this endpoint when you need to quickly generate a JSON Schema (draft 2020-12) from a concrete JSON example — especially useful for documenting API responses, bootstrapping data validation, or onboarding new developers to an API shape. Prefer it over manual schema authoring when the JSON structure is complex, nested, or contains arrays with multiple items to merge.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-12-03T06:40:21.596Z","isFirstParty":false,"canonicalSlug":"agent-data-tools-revmesh2074-workers-dev-json-schema-inferrer-from-6c981a1f"}