{"uid":"cap_vyt1FghGCYJTi4T8fRYdd","slug":"402utils-json-transform-9d21e794","name":"402utils JSON Transform","description":"Reshape JSON declaratively — predictable, not a language. `mapping` mirrors the output shape; its leaf strings are dot-paths into `data` (a.b.0.c; negative index ok; 'contacts.*.email' projects over an array; '=text' escapes a literal). Objects/arrays nest; number/boolean/null are literals. Missing paths → null. Field rename/flatten/projection to fit a payload to a target schema. Distinct from /v1/jq (declarative vs query language).","url":"https://402utils.com/v1/json-transform","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"data":{"description":"The source document — any JSON value."},"mapping":{"description":"The output shape: an object/array whose leaf strings are dot-paths ('user.name'), '*' projections, or '=literal' escapes."}}},"responseSchema":null,"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.002","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.002/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.002","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.002","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_X0Ynn6i2fWx1nlCVo5e2q","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.002","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Declaratively reshapes a JSON document into a new structure using a dot-path mapping template, supporting field renaming, array projection, and schema flattening.","exampleAgentPrompt":"Take this JSON object — {\"user\":{\"first_name\":\"Alice\",\"contact\":{\"email\":\"alice@example.com\"}}} — and reshape it so that the output has a top-level 'name' field mapped from 'user.first_name' and an 'email' field mapped from 'user.contact.email'.","exampleUseCases":null,"resultDescription":"A new JSON value whose shape mirrors the provided mapping template, with leaf values populated from dot-path lookups into the source document. Missing paths yield null. Array wildcards project over all elements. Literal escape values ('=text') are passed through verbatim.","failureModes":["Invalid dot-path syntax in mapping results in null values rather than an error","Malformed JSON in data or mapping body returns a 400-level error","Deeply nested or very large documents may time out","Incorrect wildcard usage on non-array fields yields null instead of projected values","Missing required fields (data or mapping) returns a validation error"],"whenToPreferThis":"Use this endpoint when you need a declarative, no-code way to reshape JSON using a template that mirrors the desired output shape. Prefer it over /v1/jq when you want simple field renaming, flattening, or array projection without learning a query language. Ideal for normalizing webhook payloads, adapting API responses to a target schema, or remapping data in an automation pipeline without writing code.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-14T18:53:51.735Z","isFirstParty":false}