https://pay.xenarch.com/l/<link_id>. You can share that URL as it is, open it from a button with the embed script, or render it inside a React app.
Hosted checkout
The buyer connects a wallet on the checkout page and pays in USDC on Base. By default the buyer pays by signature: an EIP-3009 authorization that a third-party x402 facilitator submits on Base, paying the gas. If no facilitator is healthy, or the buyer chooses it, the buyer sends a standard USDC transfer and pays about $0.001 of gas.Return to your site
Add areturn_url query parameter to the checkout URL, or set return_url in the link’s params. After a confirmed payment the checkout sends the buyer to that URL with three query parameters added:
Embed script
The embed script turns any element with adata-xenarch-link attribute into a pay button. It has no dependencies and needs no build step.
return_url set to the current page. After payment the buyer comes back with the query parameters above.
Two script URLs are published:
https://cdn.xenarch.dev/pay/v1.jsfollows non-breaking fixes.https://cdn.xenarch.dev/pay/v1.0.0.jsnever changes. Pin it if you need byte-stable behavior.
@xenarch/embed 1.0.0.
React component
@xenarch/react 1.0.0 exports XenarchCheckout. It needs react and react-dom 18 or later.
Props
Each event is
{ type, linkId, txHash? }, where type is one of xenarch:paid, xenarch:underpaid, xenarch:overpaid, xenarch:expired, xenarch:revoked or xenarch:close.
The component acts only on postMessage events from https://pay.xenarch.com whose linkId matches its own prop, and it passes on txHash only when it is a well-formed transaction hash. As with the return parameters, use a verified webhook to fulfill orders.
The package also exports buildHostedUrl, attachXenarchListener, isValidLinkId and HOSTED_ORIGIN for custom integrations.