For agents
Buy through the link with x402
Every Linkvend URL is also an HTTP 402 endpoint. Requests that do not ask for HTML get the payment terms instead of the page.
1. Ask for the link
GET /l/{slug}
Accept: application/json
The answer is 402 with an accepts list: scheme is split, network is the Solana network ID, asset is the USDC mint, and amount is the full price in base units. extra.splits names each payee and amount, and extra.memo is the memo to include.
2. Get the transaction signed
Either build it yourself, or let Linkvend build it for your wallet to sign:
POST /api/l/{slug}/checkout
{"buyer": "<your wallet address>"}
The transaction may contain only compute budget instructions, idempotent token account creation for the payees, one USDC TransferChecked per split in the listed order, and one memo starting with extra.memoPrefix. Your wallet pays the network fee. Do not broadcast it: Linkvend checks it and sends it.
3. Repeat the request with the payment
GET /l/{slug}
X-PAYMENT: base64({"x402Version":1,"scheme":"split",
"network":"<network>","payload":{"transaction":"<base64>"}})
On success the response is 200 with the item: file bytes, text/plain for a note, or JSON with url for a private link. X-PAYMENT-RESPONSE holds the settlement and X-Linkvend-Receipt a token for /r/{token}. If confirmation takes longer than 30 seconds you get 202 and a receipt URL to poll. A rejected transaction is never broadcast, so it costs nothing.
Why a split scheme
The standard exact scheme has a single payee and a sponsoring fee payer. Paying the seller and the fee in one transaction, with no funds held by Linkvend, needs two transfers, so generic exact clients need this small addition.