{"uid":"cap_jygDL3c_J9i0Zv8xupYjv","slug":"one-engine-array-count-e77c7d60","name":"ONE Engine Array Count","description":"Low-cost pay-per-call utility APIs for autonomous agents using x402 on Base.","url":"https://one-search.one-engine.workers.dev/v1/array/count?utm_source=zero.xyz","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"values":{"type":"array","description":"Maximum 1000 items"}}},"responseSchema":{"type":"json","example":{"count":3}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.0009","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.0009/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.0009","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.0009","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_oZaOzTpNhNDeZJrzTMdXa","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.0009","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Counts the number of elements in a provided array, returning the total item count.","exampleAgentPrompt":"How many items are in this list? [\"apple\", \"banana\", \"cherry\"] — just give me the count.","exampleUseCases":[{"title":"Counting unique product SKUs","prompt":"I have a list of product IDs from this week's orders — can you count how many there are? Here's the array: [\"SKU001\", \"SKU002\", \"SKU003\", \"SKU004\", \"SKU005\"]"},{"title":"Validating batch submission size","prompt":"Before I submit this batch job, can you tell me how many items are in my queue? The array has entries like [\"job-1\", \"job-2\", ..., \"job-47\"] — I need the exact count to check it's under 1000."},{"title":"Counting survey responses","prompt":"I collected responses from participants and stored them as an array. Can you count how many responses I got? Here's the list: [\"yes\", \"no\", \"yes\", \"maybe\", \"yes\", \"no\"]"}],"resultDescription":"Returns a JSON object with a single 'count' field containing the integer number of elements in the provided array, e.g. {\"count\": 3}.","failureModes":["Array exceeds 1000 items — request will be rejected or truncated","Empty or missing 'values' field returns count of 0 or an error","Non-array input for 'values' field may cause a validation error","Payment failure via x402 protocol prevents the call from completing","Network timeout on Cloudflare Workers edge"],"whenToPreferThis":"Choose this endpoint when you need a lightweight, pay-per-call array count operation without standing up your own compute infrastructure. Ideal for autonomous agents that occasionally need to count items without access to a runtime environment. At $0.0009 USDC per call via x402, it is cost-effective for infrequent or agent-driven counting tasks where local computation is unavailable.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-02T12:43:55.114Z","isFirstParty":false,"canonicalSlug":"one-engine-array-count-e77c7d60"}