Skip to content
1

1ClickAgent

Agents pay any site. One script tag.

Created on 29th April 2026

•

1

1ClickAgent

Agents pay any site. One script tag.

The problem 1ClickAgent solves

OneClickAgent is payment infrastructure for the agent economy. It solves the discovery and payment problem for autonomous AI agents: any website with a Locus checkout session becomes agent-payable in 30 seconds, with zero custom integration beyond a single <script> tag.

The core: a four-layer session discovery protocol (HTTP HEAD → meta tag scan → /.well-known/agent-checkout.json manifest → database fallback) backed by a real-time spending controls engine that enforces five policy dimensions before every payment — maxSingleTransaction, maxDailySpend, maxPerMerchantDaily, allowedCategories, blockedMerchants. Every decision, approved or rejected, is logged in an immutable audit trail.

For merchants: paste one script tag. The agentrelay.js SDK injects machine-readable metadata, registers the session as discoverable, and renders a "Pay with Agent" button. Any Locus session becomes agent-payable in 30 seconds.

For agents: POST /api/agent/pay with any URL. The runtime discovers the session, validates it, enforces spending policy, executes payment via Locus USDC on Base, polls for confirmation, and returns a signed receipt with the on-chain transaction hash.

Locus APIs used:

  • POST /checkout/sessions — creates checkout sessions
  • GET /checkout/sessions/{id} — validates session before payment
  • POST /checkout/agent/pay/{id} — executes autonomous agent payment
  • GET /checkout/agent/payments/{id} — polls payment status
  • GET /pay/balance — agent wallet balance + dashboard display
  • Webhook checkout.session.paid — fast-path receipt confirmation

Challenges I ran into

The hardest problem was universal session discovery — making any arbitrary website discoverable without requiring any custom backend integration. We solved this with a four-layer fallback protocol that works even on sites that have never heard of OneClickAgent.

The second challenge was spending policy enforcement without blocking legitimate payments. We built a policy engine that evaluates five dimensions in under 10ms and logs every decision with a reason code, so operators can audit why any payment was approved or rejected.

The third challenge was webhook-less confirmation — Locus webhooks may not always arrive in time during a demo. We built a polling fallback with exponential backoff so the agent always gets a definitive confirmation, then enriches the receipt if the webhook arrives later.

Tracks Applied (1)

Track: Checkout with Locus

OneClickAgent is built entirely on the CheckoutWithLocus stack. Merchants integrate via a single script tag that creates...Read More

Discussion

Builders also viewed

See more projects on Devfolio