{"version":"1.0","name":"Repair malformed JSON and enforce its contract","description":"Apply only explicit deterministic syntax repairs to caller-supplied JSON, infer a Draft 2020-12 schema from the valid result, then validate a future JSON value.","network":"eip155:8453","asset":"USDC","paymentProtocol":"x402 v2 exact","buyerGuideUrl":"https://apiacre.com/buyers","catalogUrl":"https://apiacre.com/workflows.json","workflow":{"id":"repair-json-contract","title":"Repair malformed JSON and enforce its contract","description":"Apply only explicit deterministic syntax repairs to caller-supplied JSON, infer a Draft 2020-12 schema from the valid result, then validate a future JSON value.","documentationUrl":"https://apiacre.com/workflows/repair-json-contract","machineReadableUrl":"https://apiacre.com/workflows/repair-json-contract.json","totalPrice":"$0.04","totalAtomicUsdc":40000,"stepCount":3,"steps":[{"order":1,"service":"data.json-repair","title":"Deterministic JSON repair","purpose":"Repair common syntax defects and retain transformation hashes.","method":"POST","url":"https://apiacre.com/v1/data/json-repair","price":"$0.005","documentationUrl":"https://apiacre.com/services/data.json-repair","checkoutUrl":"https://apiacre.com/try/data.json-repair","workflowStartUrl":"https://apiacre.com/workflows/repair-json-contract/start/1","sampleUrl":"https://apiacre.com/samples/data.json-repair","inputTemplate":{"content":"$malformedJson","repairs":["markdown_fence","comments","single_quoted_strings","unquoted_keys","python_literals","trailing_commas"]},"useOutput":"Continue only if result.data.valid is true; inspect appliedRepairs and retain the input and output hashes."},{"order":2,"service":"data.schema","title":"Schema inference","purpose":"Infer a reusable contract from the repaired JSON value.","method":"POST","url":"https://apiacre.com/v1/data/schema","price":"$0.025","documentationUrl":"https://apiacre.com/services/data.schema","checkoutUrl":"https://apiacre.com/try/data.schema","workflowStartUrl":"https://apiacre.com/workflows/repair-json-contract/start/2","sampleUrl":"https://apiacre.com/samples/data.schema","inputTemplate":{"content":"$step1.result.data.content","format":"json","root_mode":"preserve"},"useOutput":"Pass result.data.schema to the validation step."},{"order":3,"service":"data.schema-validate","title":"JSON Schema validation","purpose":"Validate a future caller-supplied value against the inferred contract.","method":"POST","url":"https://apiacre.com/v1/data/schema-validate","price":"$0.01","documentationUrl":"https://apiacre.com/services/data.schema-validate","checkoutUrl":"https://apiacre.com/try/data.schema-validate","workflowStartUrl":"https://apiacre.com/workflows/repair-json-contract/start/3","sampleUrl":"https://apiacre.com/samples/data.schema-validate","inputTemplate":{"schema":"$step2.result.data.schema","instance":"$futureJsonValue","max_errors":25,"check_formats":true},"useOutput":"Require result.data.valid and inspect bounded JSON Pointer errors before accepting the future value."}]}}