{"uid":"cap_hPZRi3J2UDVtRJTR5X6eE","slug":"one-engine-stable-sort-top-10-array-utility-5831ebb0","name":"ONE Engine Stable Sort (Top 10) Array Utility","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/stable-sort/t10?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.03","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.03/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.03","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.03","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_xoTn9nFm2RZTfpjrN5Qz_","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.03","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Sorts a JSON array of up to 1000 items using a stable sort algorithm and returns the top 10 results, with optional comparison array support.","exampleAgentPrompt":"Sort this list of product scores [88, 45, 92, 67, 100, 55, 73, 91, 60, 84, 77] using a stable sort and give me the top 10 in order.","exampleUseCases":[{"title":"Ranking leaderboard scores","prompt":"I have an array of 200 player scores from today's game session — can you stable-sort them and give me the top 10 highest scores?"},{"title":"Filtering top product prices","prompt":"Here's a list of 500 product prices: [12.99, 5.49, 89.00, ...] — sort them stably and return the top 10 most expensive ones."},{"title":"Paginating sorted search results","prompt":"Sort these 300 relevance scores stably and give me the top 10 starting from position 20, so I can page through the results."}],"resultDescription":"Returns a JSON object containing the stably-sorted top 10 elements from the input array, respecting any offset for pagination and optionally compared against a secondary array.","failureModes":["Array exceeds 1000 items — request rejected","Missing required 'values' field — validation error","Payment not fulfilled via x402 — 402 Payment Required response","Malformed JSON array input — parsing error","Network timeout on Cloudflare Worker edge"],"whenToPreferThis":"Choose this endpoint when you need a deterministic, stable sort of a JSON array (up to 1000 items) and only want the top 10 results returned, especially in pay-per-call autonomous agent workflows on Base where low cost ($0.03 USDC) matters. Prefer it over general-purpose sorting when you want stable ordering guarantees with optional offset-based pagination and a lightweight utility API.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-02T12:44:14.691Z","isFirstParty":false,"canonicalSlug":"one-engine-stable-sort-top-10-array-utility-5831ebb0"}