X402 Payments
X402 payment signing and proxying
Transparent X402 Payment Proxy
Fetch any URL with automatic X402 payment handling. If the target URL returns a 402 Payment Required response, AgnicPay automatically signs the payment and retries the request. You get the actual API response back.
This is the recommended endpoint for most use cases.
Authorization
X-Agnic-Token<token>API token from your dashboard
In: header
AuthorizationOAuth2 access token
In: header
Request Body
application/jsonOptionalRequest body to forward to the target URL
[key: string]anyQuery Parameters
urlTarget URL to fetch
"uri"methodstringHTTP method to use
"GET"Value in: "GET" | "POST" | "PUT" | "DELETE" | "PATCH"maxValueintegerMaximum payment in atomic units (e.g., 100000 = $0.10 USDC)
timeoutintegerRequest timeout in milliseconds
30000Maximum: 60000Successful response from target URL
Sign X402 Payment Proof
Sign an X402 payment proof for manual payment handling. Supports both "exact" (EIP-3009 TransferWithAuthorization) and "upto" (EIP-2612 Permit) payment schemes.
The easiest approach is to pass the full 402 response from the X402 API directly
as the paymentRequirements field.
Authorization
X-Agnic-Token<token>API token from your dashboard
In: header
AuthorizationOAuth2 access token
In: header
Request Body
application/jsonRequiredpaymentRequirementsFull 402 response from X402 API or manual payment requirements
requestDataPayment signed successfully