{"uid":"cap_JK8QnBkK3Ae3lez9yReQF","slug":"one-engine-array-flatten-t4-c8e090ce","name":"ONE Engine Array Flatten (T4)","description":"Low-cost pay-per-call utility APIs for autonomous agents using x402 on Base.","url":"https://one-search.one-engine.workers.dev/v3/array/flatten/t4?utm_source=zero.xyz","method":"POST","headers":{},"bodySchema":{"type":"object","required":["values"],"properties":{"size":{"type":"integer"},"other":{"type":"array","description":"Optional comparison array"},"offset":{"type":"integer"},"values":{"type":"array","description":"JSON array with at most 1000 items"}}},"responseSchema":{"type":"object","additionalProperties":true},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.0015","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.0015/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.0015","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.0015","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_JQYr-8N40_vVA7qjaFYNu","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.0015","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Flattens a nested JSON array into a single-level array, with optional comparison and offset parameters.","exampleAgentPrompt":"Flatten this nested JSON array for me — it has up to 500 items and I want the result starting at offset 10: [[1,2],[3,[4,5]],6].","exampleUseCases":[{"title":"Normalize nested API response arrays","prompt":"I'm getting a nested array back from another API — can you flatten it into a single-level list? Here's the data: [[\"a\",\"b\"],[\"c\",[\"d\",\"e\"]],\"f\"] with up to 200 items."},{"title":"Compare flattened output against reference","prompt":"Flatten this nested array [[1,[2,3]],[4,5]] and compare the result against my reference array [1,2,3,4,5] — I want to see if they match after flattening."},{"title":"Paginate through flattened array chunks","prompt":"Take this large nested array (up to 1000 items) and flatten it, but start at offset 50 so I can work through it in chunks: [[10,20],[30,[40,50]],60,70]."}],"resultDescription":"A JSON object containing the flattened (single-level) version of the input array, with any nested sub-arrays collapsed into a single sequence, optionally offset and compared against a provided reference array.","failureModes":["Input array exceeds 1000-item limit — request rejected or truncated","Malformed JSON in values field — 400 error","Invalid offset value (negative or out of bounds) — may return empty or error","Non-array value passed as 'values' field — schema validation error","Payment failure via x402 — 402 response before processing begins"],"whenToPreferThis":"Choose this endpoint when you need a cheap, pay-per-call utility to flatten nested JSON arrays at low cost ($0.0015 USDC) without standing up your own infrastructure. Ideal for autonomous agents that occasionally need to normalize array structures mid-workflow without a persistent backend dependency.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-02T12:44:08.253Z","isFirstParty":false,"canonicalSlug":"one-engine-array-flatten-t4-c8e090ce"}