{"uid":"cap_9ODkJL7LNjASMIT7QVQZA","slug":"one-engine-array-difference-9e9f59b5","name":"ONE Engine Array Difference","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/difference/t1?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.0005","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.0005/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.0005","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.0005","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_HIPakyRregD6CJo-F0PSo","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.0005","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Returns the set difference between two arrays, yielding elements in the first array that are not present in the second (comparison) array.","exampleAgentPrompt":"I have two lists of product IDs — [101, 202, 303, 404, 505] and [202, 404] — can you find which IDs from the first list are NOT in the second list?","exampleUseCases":[{"title":"Detect missing user IDs","prompt":"I have a list of user IDs who signed up this month and another list of users who completed onboarding — can you find which signed-up users have NOT completed onboarding yet? Here are the two arrays: signups = [1,2,3,4,5,6] and onboarded = [2,4,6]."},{"title":"Find unassigned tasks","prompt":"I have a full task list [\"task-A\",\"task-B\",\"task-C\",\"task-D\"] and a list of tasks already assigned to someone [\"task-B\",\"task-D\"]. Which tasks from my full list are still unassigned?"},{"title":"Identify new inventory items","prompt":"Compare my current inventory list [\"sku-001\",\"sku-002\",\"sku-003\",\"sku-007\"] against yesterday's list [\"sku-001\",\"sku-002\",\"sku-003\"] and tell me which SKUs are new additions."}],"resultDescription":"A JSON object containing an array of elements that appear in the primary `values` array but not in the `other` comparison array, representing the set-theoretic difference A \\ B.","failureModes":["Array exceeds 1000 items — request rejected","Malformed JSON array in `values` or `other` — validation error","Missing required `values` field — 400 Bad Request","Payment not included or insufficient — 402 Payment Required","Cloudflare Worker cold start or timeout — 503 or timeout error"],"whenToPreferThis":"Use this endpoint when an autonomous agent needs a fast, cheap, stateless computation to find the set difference between two arrays without spinning up local logic. Ideal for agentic pipelines on Base that already use x402 micropayments, where the per-call cost ($0.0005 USDC) is negligible and offloading array math keeps agent code simple. Prefer this over local computation when working in constrained runtime environments or when the operation needs to be auditable as a paid API call.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-24T18:43:07.274Z","isFirstParty":false,"canonicalSlug":"one-engine-array-difference-777bd7ed"}