x402 paywall priced per call Built on run402

Priced API

An endpoint that asks to be paid.

Three dossiers sit behind one priced route. Call it with no payment and it answers HTTP 402 with its terms. Sign those terms, retry, and the same call returns the full text. No account, no key, no sign up: the payment is the login.

run402 pay https://paywall.run402.com/api/dossier --method POST --body '{"slug":"the-handshake"}'

The run402 CLI signs, retries and prints the payment id. Its default ceiling is ten cents a call, so this one needs no extra flag.

What is behind the paywall

Three short dossiers about running a priced route. Titles and teasers are free, because the catalogue route never selects the body column. Pick one and the command above follows it.

The refusal, live

This page just called the priced route with no payment and kept what came back. Everything below is read from that response, on this visit, by a browser holding no credential at all.

waiting POST /api/dossier
Settled on this deployment counting

Open your copy

A settled payment prints a payment id such as txp_9f2c.... Paste it here and the dossier it bought opens, on any device, without paying again.

Why there is no key on this page

Same origin, always

Every request this page makes is a relative path on the host that served it. There is no project key in the source, no authorization header, and no call to the platform API.

The tables are dark

Neither table is published on the REST API, so the column being sold cannot be selected from outside. One function reaches them, on the server, with adminDb().

Paid once, delivered once

The payment id is the primary key of the unlock row, so a replayed settlement returns the same dossier instead of charging twice or writing twice.