Embed
402 by OTOMAT
Show buyers your endpoint speaks x402.
Live preview — the counter reflects the real paid-call total for this endpoint.
Embed on any site
Drop this snippet into your README, docs, or landing page. Swap YOUR_ENDPOINT_ID for the id from your console. The badge is a plain image served from Otomat, so it renders anywhere HTML does — no script, no tracker.
html
<a href="https://otomat.fun">
<img
src="https://otomat.fun/api/embed-badge?endpoint=YOUR_ENDPOINT_ID"
alt="402 by OTOMAT"
width="268"
height="48"
/>
</a>The 402 to 200 flow
The badge advertises what the wire actually does: a first request answers 402 Payment Required, and a paid retry settles per call and returns 200 OK.
curl
# 1. Call the endpoint. An unpaid request returns HTTP 402
# with the x402 v2 payment requirements.
curl -i https://api.otomat.fun/x/YOUR_ENDPOINT_ID
# < HTTP/1.1 402 Payment Required
# < PAYMENT-REQUIRED: <base64(JSON) v2 requirements>
# 2. Retry with the signed Solana payment attached. The
# facilitator verifies, settles, and returns the resource.
curl -i https://api.otomat.fun/x/YOUR_ENDPOINT_ID \
-H "PAYMENT-SIGNATURE: <base64(JSON) v2 payload>"
# < HTTP/1.1 200 OK
# < PAYMENT-RESPONSE: <base64(JSON) settlement>