Discover the price and target before any irreversible action.
X402 SANDBOX PILOT · NO FUNDS REQUIRED
Put one policy decision
before `pay_and_call`.
Keep the wallet, amount cap, confirmation and settlement path exactly where they are. Agent Reserve adds one upstream check for owner mandate, recipient status, required evidence and remaining budget.
Reference adapter only. No affiliation, endorsement or production integration is claimed.Calls the live stateless endpoint. The request is not stored; Agent Reserve holds no funds, accesses no wallet and executes no payment.
ONE OPTIONAL HOOK
Inspection stays first.
Payment stays last.
Apply owner-controlled policy and issue a single-use protected handoff only on eligible.
Only an eligible request may reach the wallet's existing controls.
DROP-IN REFERENCE
A small adapter, not a replacement payment stack.
The example uses ARP's public stateless MCP endpoint and the 2026-07-28 transport headers. It never receives a key, signs a transaction or calls the payment rail.
eligibleContinue to the wallet's existing confirmation pathescalatePause and ask the owner for an explicit decisionblockStop before any payment rail is invokedtimeout / malformedFail closed; do not call the payment toolasync function authorizeX402(request) {
const response = await fetch("https://agent-reserve-protocol.super-myna-7255.chatgpt.site/api/mcp", {
method: "POST",
headers: {
"content-type": "application/json",
"mcp-protocol-version": "2026-07-28",
"mcp-method": "tools/call",
"mcp-name": "evaluate_agent_spend_request"
},
body: JSON.stringify({
jsonrpc: "2.0",
id: crypto.randomUUID(),
method: "tools/call",
params: {
name: "evaluate_agent_spend_request",
arguments: request
}
})
});
if (!response.ok) throw new Error("authorization unavailable");
const rpc = await response.json();
if (!rpc.result?.structuredContent) throw new Error("invalid receipt");
return rpc.result.structuredContent;
}
const receipt = await authorizeX402({
mandateValid: true,
vendorStatus: "trusted",
receiptStatus: "pass",
amount: 48,
perRequestLimit: 100,
dailyRemaining: 250
});
if (receipt.decision !== "eligible") {
throw new Error("stop before payment");
}
// Only now continue to the wallet's existing confirmation path.
return pay_and_call(targetUrl);ACCEPTANCE TEST
One receipt is enough to evaluate fit.
Success means the adapter returns a valid decision receipt and the downstream payment path advances only on eligible. It does not mean security certification, production readiness or customer demand.
PUBLIC SANDBOX