# OpenStock > OpenStock, by Mate: one wallet, endless upside. A REST API that lets AI agents, apps and consumer platforms offer cashback natively in their products and pay rewards into their users’ existing wallets, under their own brand. Discovery identifies eligible storefronts; an OpenStock-funded quote commits an exact cashback amount before checkout. Paid orders are reported with evidence, held for 30 days, and cleared cashback can settle to a configured partner account for allocation to users. Native tracked offers are also available. The shopping endpoints return discount codes generated at partnered stores, public codes with a measured probability of working, delivery estimates with provenance, and authorized shopper history. The API lives at https://api.openstock.sh. This site is the overview and live demo. The [canonical integration guide](https://api.openstock.sh/llms-full.txt) is the current contract and complete reference; use it instead of older copied evaluation documents. ## Guaranteed cashback and agent checkout 1. Resolve the actual US storefront with `POST /v1/cashback/stores` and read `checkout.recommended`: `funded` wherever a funded quote exists, which earns through merchant-API or browser checkout without a browser session. `match.by` says whether you matched a URL, a domain or a name; resolve the URL the agent will pay on before quoting. Amazon, Apple and non-US storefronts are excluded; marketplace seller pages remain purchases from the marketplace. 2. Commit the eligible merchandise subtotal with `POST /v1/cashback/quotes`, supplying the actual `storefront_url`, matching `store_id` and explicit `country: "US"`. Discovery previews use `basis: "quote_required"`; only the successful quote reserves backing and commits its exact USD cents. An eligible $100 subtotal at 8% commits $8; a $2,000 subtotal at 15% with a $100 cap commits $100. Tax, shipping and gift cards are excluded. 3. Let the agent buy in its browser or through the merchant API. OpenStock-funded quotes need no tracking cookies. Report the paid order, quote ID, actual payment time and retained evidence reference. The default checkout window is three days and can be requested up to seven days. 4. Hold cashback for 30 days, then settle cleared funds daily or on demand. `estimated: false` means the funded amount is committed, not that it is spendable during the hold. Refunds can reduce the held amount. OpenStock bears ordinary shortfalls and late merchant clawbacks after clearance. An `available` balance means cleared at OpenStock, not money already received by the partner. 5. OpenStock transfers funds to the receiving account you connected and verified. Match the receipt using the transfer and provider references, then credit the opaque user exactly once, keyed by `credit_key` (the transfer id). Receipt and allocation are acknowledged separately. A bank return after you have credited a user is re-sent by OpenStock on the same transfer; the credit is never unwound. The partner never fronts funds. Signed webhooks and replayable events keep ledgers in sync. OpenStock funds sponsored cashback itself. Eligible US storefronts without a native offer of their own earn the 8% funded rate, capped at $100 per order; a store with a native offer earns that offer's rate through the same funded quote. `POST /v1/cashback/coverage` names the top US retailers with their live status, path and rate; `POST /v1/cashback/catalog` enumerates the whole index with each entry's funded eligibility and cap. Always obtain the quote before presenting a guaranteed amount. ## Connect your existing wallet Onboarding on your side is one receiving account. Submit it with `POST /v1/settlement/destination`; OpenStock registers the recipient on its payout rail and sends a $1.00 verification deposit with a reference starting `OSV`. Confirm the reference and amount from your bank statement with `POST /v1/settlement/destination/verify`. That verifies the account, switches daily and on-demand settlement on, and is the live proof of bank delivery. The sandbox simulates the bank and prints its statement line, so the whole step can be rehearsed with a sandbox key. `GET /v1/settlement/readiness` reports, for the key's ledger, whether transfers can be requested, each remaining blocker with its owner, the connected account, a five-step onboarding checklist and what has been verified for real: for a live key, bank receipt is verified once the deposit is confirmed, and user wallet credit once a transfer carries your allocation, read from the live ledger. Live payouts are OpenStock-funded USD bank transfers. See the [integration guide](https://api.openstock.sh/llms-full.txt). ## Security and compliance OpenStock is built by Mate (Checkmate Intelligence, Inc.), a SOC 2 compliant company, with compliance monitored by Drata. The report scope includes cashback attribution, reward and wallet records, holds/reversals and payout orchestration through partner APIs including OpenStock. The report defines the audited boundary, tests, review period and exceptions. See the [public security scope](https://usemate.ai/knowledge-hub/privacy-faqs). - API traffic uses HTTPS to encrypt data in transit. - API routes require a bearer key with the corresponding scopes. Keys are stored as SHA-256 hashes and can be revoked. Keep credentials on your server, out of browser code, URLs and shared examples. - Wallet integrations use `cashback:read`, `cashback:write`, `wallets:read`, `transfers:read`, `transfers:write` and `events:read`. They do not require `shopping:read`, `shopping:write` or `shoppers:read`; restricted keys reject those separate capabilities. - Cashback uses opaque partner-scoped user IDs, order/evidence references and ledger/transfer data. Do not send emails, email hashes or public account handles for wallet identity. Optional, separately authorized shopper history uses a SHA-256 email hash; hashing does not make that personal data anonymous. - [Security and integration guidance](https://api.openstock.sh/llms-full.txt): scopes, wallet data processing, credential handling and production evidence. - [Terms and data processing agreement](https://usemate.ai/terms) - [Privacy policy](https://usemate.ai/privacy) ## Generated, not found There are two kinds of discount-code API. An information API tells you a code exists somewhere and leaves the shopper to find out at checkout whether it still works. A generation API creates the code. OpenStock is the second kind: at partnered merchants it is integrated with the store's checkout and creates a new single-use code at the moment of the request, and every code in every response says which kind it is (`source`: `generated`, `merchant_issued` or `observed`). A coupon feed can only ever return the third. We are not aware of another cross-merchant shopping API that generates a discount code at the store on request. ## Status and scale - [status.openstock.sh](https://status.openstock.sh): current status and observation history for the configured API and cashback checks, scheduled every five minutes. Coverage and stale observations are shown separately; older endpoint uptime does not establish cashback-path reliability. Machine-readable at https://status.openstock.sh/status.json. - Daily settlement uses a durable queue, with no fixed wallet-count ceiling per day. Payout and queue throughput, peak backlog and interruption recovery must be measured for the intended production volume. Sandbox simulations and local load tests do not establish production capacity or actual bank receipt. ## API docs - [Canonical integration guide](https://api.openstock.sh/llms-full.txt): product, funding, runnable sandbox lifecycle, agent checkout, connecting the receiving account, money states, transfer receipt and user allocation, scopes, privacy, integration readiness and the complete endpoint reference. Start here. - [OpenAPI 3.1 specification](https://api.openstock.sh/openapi.json) - [Interactive reference](https://api.openstock.sh/docs) - [Example history response](https://openstock.sh/examples/shopper-history.json): two purchases and one visit, labelled as an example. ## Try it - [Live demo](https://openstock.sh/demo): runnable shopping and cashback-discovery examples show their API requests and responses. The cashback API demo uses a dedicated test key and displays each request and response as it runs, from a funded quote and purchase report through simulated clearance, connecting and verifying a receiving account, transfer and receipt/allocation acknowledgment. Sandbox-only calls clearly skip the hold and simulate the bank. Its balances come from the sandbox API and are simulated funds; it neither places an order nor moves real money. See https://api.openstock.sh/llms-full.txt for the partner contract. Example codes are placeholders; run the requests for live ones. Keep offer conditions visible to the shopper, and use history only within your authorized integration. Enumerate the merchant index with `POST /v1/cashback/catalog`; continue until `next_cursor` is null. Each entry carries its funded eligibility and cap, and the page reports how many entries can be quoted. Use `POST /v1/cashback/coverage` for the named top-retailer list. Resolve each actual storefront and request a funded quote before promising cashback. Once the receiving account is verified, OpenStock sends real USD to it by bank transfer. The partner matches the bank receipt, posts the user credit in its own ledger keyed by the transfer id, then records receipt and allocation references through `/v1/transfers/acknowledge`. `GET /v1/settlement/readiness` reports what has been verified for the key's account without moving money.