{"uid":"cap_9eevM-H2VqHxUb7TYjrNf","slug":"delx-shares-from-budget-effa35d2","name":"Delx Shares From Budget","description":"Shares purchasable for a budget at a given share price. Call when sizing prediction-market orders from cash budget. Returns shares and residual cash as deterministic JSON for $0.001 USDC via x402 on Base. First-party local math only—no RPC, live market feed, API keys, storage, or mediagen. Advisory only; the caller owns capital, risk, and production controls.","url":"https://api.delx.ai/api/v1/x402/shares-from-budget","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"price":{"type":"number","description":"Input field: price."},"budget":{"type":"integer","description":"Input field: budget."}}},"responseSchema":{"type":"json","example":{"price":0.25,"budget":50,"schema":"delx/util-shares-from-budget/v1","shares":200}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.001","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.001/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.001","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.001","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_r0TrZtlVDLu1x3OwYHt3M","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.001","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Calculates how many equal shares can be purchased from a given integer budget at a specified unit price","exampleAgentPrompt":"I have a budget of 50 and each share costs $0.25 — how many shares can I buy in total?","exampleUseCases":[{"title":"Agent API call budget planning","prompt":"I have a budget of 100 units and each API call costs $0.50 — how many calls can my agent make before running out?"},{"title":"Batch job quota estimation","prompt":"My processing budget is 200 and each batch job costs $0.10 per run — tell me how many batches I can schedule."},{"title":"Token purchase quantity check","prompt":"If I have a budget of 75 and each token costs $0.25, how many tokens can I buy?"}],"resultDescription":"Returns a JSON object containing the original price and budget inputs, a schema identifier ('delx/util-shares-from-budget/v1'), and the computed integer number of shares (floor division of budget by price).","failureModes":["Missing or non-numeric price field returns validation error","Missing or non-integer budget field returns validation error","Price of zero causes division-by-zero error","Negative budget or price values may return unexpected results","Budget smaller than price returns zero shares"],"whenToPreferThis":"Use this endpoint when an autonomous agent needs to quickly compute how many discrete units or shares can be purchased from a fixed integer budget at a known unit price, without performing the arithmetic internally. Especially useful when coordinating multi-step workflows where budget-to-quantity conversion is a bottleneck, or when the result needs to be logged with a standardized schema identifier for downstream processing.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-15T13:10:56.538Z","isFirstParty":false}