AI agent payments and x402· 3 of 4

Settling on the XRP Ledger

A signed Payment in XRP or RLUSD, tied to one invoice, that expires fast.

4 minMedium

Key points

  • The exact scheme settles one signed Payment, in XRP or a token.
  • InvoiceID ties the payment to one invoice. LastLedgerSequence makes it expire.
  • The payer pays the fee. A Delegate field is not allowed.

The lesson

  1. On the XRP Ledger, an x402 payment is a normal Payment. The agent signs it. The facilitator sends it in.

  2. It can pay in XRP or in an issued token, such as the stablecoin RLUSD.

  3. Three rules keep it safe.

    • One invoice. When the server sends an invoice number, the payment carries its fingerprint. It cannot pay another invoice.
    • Short life. The payment expires after a set ledger. A late copy fails.
    • Exact amount. No partial payments, no currency swaps along the way.
  4. The payer pays the network fee, a few drops, as with any transaction.

  5. That way of paying is called the exact scheme. A second scheme, upto, is a draft. It would set a top price, then bill only what was used. It runs through a payment channel.

Check yourself3 questions
1. Which XRP Ledger transaction does the exact scheme use?
2. What stops one payment being reused for a second invoice?
3. How would the draft upto scheme settle on the XRP Ledger?
Next lessonRisks and where it stands