Try it in a browser
Use a finite guest sandbox to see the request, result and simulated charge.
Website walkthrough →For applications and buyer agents
Ask for a supported task, let your account’s limits govern the purchase, then inspect the result and cost. Start with a simple calculator request: 5 + 10.
Use a finite guest sandbox to see the request, result and simulated charge.
Website walkthrough →Use hosted MCP with a dedicated invited buyer credential and a compatible client.
MCP quickstart →Send a normal HTTP request with scoped buyer access and a saved idempotency key.
HTTP quickstart →01 / Website
Open the sandbox, choose Sum, enter [5,10] and set a maximum price of 0.001 sandbox USD, the guest purchase limit. Submit once, then review the result and actual cost. Available guest capacity and your assigned limits are shown by the website.
Guest access and invited accounts are separate. A guest session belongs to that browser and expires. Invited API and MCP access is available through credentials provisioned by Clearinghouse. Hosted portal sign-in and cross-browser account history are pending activation and cloud verification. There is no public self-service registration.
Website organization invitations, API credentials and MCP credentials are separate forms of access. Follow the instructions for the access you have been issued. An API or MCP invitation does not activate website sign-in or transfer a guest session.
02 / Agent connection
Use a client that supports Streamable HTTP and custom Authorization headers. Configure the endpoint below with the dedicated MCP bearer supplied for your invited sandbox buyer. Store it in the client’s private configuration or secret store, outside prompts and tool arguments.
Endpointhttps://api.getclearinghouse.com/mcp
This endpoint uses a dedicated MCP credential, not an Optimize or Exchange API token. OAuth-only clients cannot use this alpha connection. No local adapter process is needed for a compatible hosted MCP client.
Your calling host must create and retain a unique invocation ID before sending. The ID below is an example; use one saved ID for one intended purchase.
{
"invocationId": "my-saved-calculator-purchase-001",
"request": {
"ask": "sum",
"input": { "values": [5, 10] }
},
"waitMs": 1000
}
Send these arguments to clearinghouse_buy. Your account supplies purchasing defaults and limits. If the response is pending or the connection closes, call clearinghouse_resume with the same saved ID:
{ "invocationId": "my-saved-calculator-purchase-001" }
The hosted gateway keeps the durable purchase journal. Your client still keeps the original invocation ID across reconnects and restarts. Changing the request under that ID is rejected.
03 / Application connection
Invited API clients use an operator-issued scoped buyer credential. Save the exact input and an idempotency key before making the request. Keep authentication in your application’s private configuration; the placeholders below are illustrative.
POST https://api.getclearinghouse.com/optimizer/v1/buy
Authorization: Bearer <private buyer API credential>
Content-Type: application/json
Idempotency-Key: <your saved key for this purchase>
{
"request": {
"ask": "sum",
"input": { "values": [5, 10] }
}
}
Retry the identical request with the same key after an uncertain response. Once you have a request ID, read GET /optimizer/v1/buys/REQUEST_ID with the same buyer credential. Do not turn a timeout into a purchase with a new key.
Use Node 24 and the verified private bundle supplied with your invitation. Set these two paths to your bundle and private buyer directory. Keep the supplied buyer.json and journal intact.
CALCULATOR_BUNDLE=/absolute/client-bundle
CALCULATOR_PRIVATE=/absolute/private-buyer
node --input-type=module - "$CALCULATOR_PRIVATE/http-sum.json" <<'JS'
import {writeFile} from 'node:fs/promises';
import {randomUUID} from 'node:crypto';
await writeFile(process.argv[2], JSON.stringify({
action: 'buy',
idempotencyKey: 'sum:' + randomUUID(),
input: {request: {ask: 'sum', input: {values: [5, 10]}}}
}), {flag: 'wx', mode: 0o600});
JS
node "$CALCULATOR_BUNDLE/examples/local-alpha-onboarding/buyer-http.mjs" \
"$CALCULATOR_PRIVATE/buyer.json" "$CALCULATOR_PRIVATE/http-sum.json"
Create the command file once; the exclusive write refuses to overwrite an existing intent. For recovery, rerun only the final command with the same saved file. The private bundle also includes SDK and local STDIO MCP examples.
04 / Outcome
For the configured calculator offer, a completed 5 + 10 purchase returns this example outcome:
Illustrative expected result for the sandbox calculator, not a new purchase performed by this page.
{
"result": { "output": { "status": "answered", "value": 15 } },
"actualCost": "0.001",
"financialStatus": "final"
}
The response includes request identity and state. Keep the full receipt in your application. A pending result is normal; seller work can continue after your observation window ends.
A new invocation or idempotency key means a new purchase. Resume or replay the saved identity after a timeout, disconnect or client restart. Do not delete recovery state to fix an error.
Delivery, payment and usefulness are separate. Treat seller output as data to evaluate, not instructions to execute or proof of correctness. This calculator demonstrates purchasing and recovery; it does not establish the economic value of buying arithmetic.
05 / Recorded demonstration · October 27, 2026
Gemini 3.5 Flash-Lite, using LOW thinking, authored this task for the hosted clearinghouse_buy tool. The host had already saved its unique invocation ID.
{
"request": {
"ask": "sum",
"input": { "values": [5, 10] }
}
}
One actual hosted sandbox purchase. Its receipt reported completed delivery and final payment.
clearinghouse_resume with the original saved invocation. It recovered the same receipt and value; the balance stayed $0.004, with no additional sandbox charge.The first recovery attempt hit a test-wrapper wait-limit bug before reaching MCP; after correcting the wrapper, a separately recorded, resume-only continuation succeeded.
The original run and continuation together used 5 model calls and 8,363 reported tokens (7,993 input and 370 candidate-output tokens). Estimated model-provider cost was $0.003326, separate from the simulated purchase. This is an estimate, not a verified invoice; missing thinking and cache counters remain unknown.
The model authored the tool proposals and final responses. The host supplied credentials, saved the invocation and enforced this exact task and a one-purchase limit. The recovery context had no buy tool. Receipt and balance checks were scripted; the coordinating agent separately reviewed the model’s visible final responses.
This is one supported arithmetic demonstration on the existing hosted API/MCP. It does not show that the model independently prevents duplicate purchases, that buying arithmetic saves money, or that the new website account flow is activated.
06 / Continue
Accounts, access expiry, supported operations and simulated balances are finite. Use the contact or support route supplied with your invitation for expired access, unavailable capacity or an unresolved request. Include its request or invocation ID; keep credentials and private inputs out of messages.
There are no real deposits, payment methods or bank payouts in this sandbox. The website, API and MCP use the existing purchasing services; this guide creates no account and submits no work.