{"uid":"cap_qWTA5iUUrAXjh5Nf6UAh9","slug":"delx-batch-size-plan-085368f5","name":"Delx Batch Size Plan","description":"Recommend a batch size from item count, hard cap, and average item bytes — call when batching micro-calls under item and byte caps. Use before side effects when composing multi-step agent jobs—the same loyalty/workflow demand band agents already pay for on Bazaar, but fully local. Returns deterministic machine-readable JSON for $0.003 USDC via x402 on Base. Execution is first-party, local-only, stateless, and memory-only with no paid upstream, no input retention, and no claim of live chain tip,…","url":"https://api.delx.ai/api/v1/x402/batch-size-plan","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"max_batch":{"type":"number","description":"Hard maximum items per batch."},"max_bytes":{"type":"number","description":"Hard maximum bytes per batch."},"item_count":{"type":"number","description":"Number of items to batch."},"avg_item_bytes":{"type":"number","description":"Average bytes per item used for the byte-limited batch size."}}},"responseSchema":{"type":"json","example":{"schema":"delx/util-batch-size-plan/v1","max_batch":50,"item_count":1000,"estimated_batches":25,"byte_limited_batch":40,"recommended_batch_size":40}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.003","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.003/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.003","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.003","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_itlehXvS5d4LeYnq4c7_2","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.003","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Recommends an optimal batch size given item count, hard item cap, hard byte cap, and average item bytes","exampleAgentPrompt":"I need to batch 8000 items where each item is about 512 bytes — the hard cap is 1000 items per batch and 400000 bytes per batch. What batch size should I use?","exampleUseCases":[{"title":"Bulk webhook dispatch planning","prompt":"I'm sending 5000 webhook events where each payload is around 800 bytes. The downstream API only accepts 250 items per call and 150000 bytes per request. What batch size should I use?"},{"title":"LLM context chunking for document ingestion","prompt":"I need to split 12000 document chunks for indexing — each chunk averages 1200 bytes and the indexer caps at 500 items and 512000 bytes per batch. What's the right batch size to use?"},{"title":"Blockchain transaction batching","prompt":"I have 3000 token transfer items averaging 300 bytes each, and I can't exceed 200 items or 50000 bytes per batch call. Can you tell me the recommended batch size?"}],"resultDescription":"Returns a deterministic JSON object containing the recommended batch size (constrained by both item count and byte limits), the resulting number of batches, and the individual item-capped and byte-capped batch size values used to derive the recommendation.","failureModes":["Missing required fields (item_count, max_batch, max_bytes, avg_item_bytes) return a 400 validation error","Non-positive or zero values for counts or bytes may return an error or edge-case result","Payment failure or insufficient USDC balance returns a 402 response","avg_item_bytes larger than max_bytes results in a batch size of zero or one"],"whenToPreferThis":"Use this endpoint when you need a fast, stateless, deterministic batch size recommendation that respects both item count and byte size caps simultaneously. Prefer it over manual calculation in multi-step agent workflows where you need machine-readable JSON output before executing side-effecting batch operations. It is especially useful when both an item cap and a byte cap are active constraints, as naive item-only division may still violate byte limits.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-13T19:00:50.938Z","isFirstParty":false}