The paid request endpoint: call a launched API through NODRA and pay with x402.
x402 v2
On this page
Call a paid API
GET/v1/{slug}/{path}x402 payment
Also POST, PUT, PATCH and DELETE, unless the API narrows its methods. Forwards the request to the provider's upstream URL with {path} and the query string appended, once a valid payment is attached. Without one, answers 402 with a quote.
Path parameters
Name
Type
Description
slug
string
The API's slug, 3 to 40 characters. Must be a live API.
path
string, optional
The provider's path. Segments . and .. are refused.
Query parameters
Passed to the provider unchanged. NODRA defines none.
Request headers
All other request headers are dropped before forwarding.
Header
Required
Description
PAYMENT-SIGNATURE
On the paid attempt
Base64 JSON: { x402Version, resource, accepted, payload: { transaction } }. NODRA reads accepted.extra.memo (the quote id) and payload.transaction (the base64 signed transaction).
Content-Type
With a body
Forwarded to the provider.
Accept
No
Forwarded to the provider.
Request body
Forwarded to the provider as raw bytes, up to 1 MiB. Not sent for GET. Send the same body on the paid attempt as on the first.