See the canonical spec:
.TypeScriptimport { Client, Wallet } from 'xrpl'; async function sendXrpPayment(): Promise<void> { const client = new Client('wss://honeycluster.dev'); await client.connect(); const wallet = Wallet.fromSeed('s...'); const prepared = await client.autofill({ TransactionType: 'Payment', Account: wallet.address, Destination: 'r...dest', Amount: '1000000', }); const signed = wallet.sign(prepared); const res = await client.submitAndWait(signed.tx_blob); console.log(res); await client.disconnect(); } sendXrpPayment().catch(console.error);
| Field | JSON Type | Internal Type | Required? | Description |
|---|---|---|---|---|
Amount | Currency Amount | Amount | API v1: Yes | Alias for DeliverMax. Specifies the amount of currency to deliver in API v1. |
CredentialIDs | Array of Strings | Vector256 | No | Array of ledger entry IDs for Credentials authorizing the deposit. Each ID must reference a Credential entry in the ledger. Requires the (not enabled). |
DeliverMax | Currency Amount | Amount | Yes | The maximum amount of destination currency to deliver. For , the transaction can deliver less than this amount and still succeed; other payments must deliver the exact amount. Introduced in . |
DeliverMin | Currency Amount | Amount | No | The minimum amount of destination currency the transaction should deliver. Only applicable for . |
Destination | String - Address | AccountID | Yes | The account receiving the payment. Must be a valid . |
DestinationTag | Number | UInt32 | No | An arbitrary tag identifying the payment's purpose or a hosted recipient. Typically a 32-bit unsigned integer. |
DomainID | String - Hash | UInt256 | No | Ledger entry ID of a permissioned domain. For cross-currency payments, restricts currency conversion to the specified . Both sender and recipient must have valid credentials for the domain. Ignored for same-currency payments. Requires the (not enabled). |
InvoiceID | String - Hexadecimal | UInt256 | No | A 256-bit hexadecimal value representing a specific reason or identifier for the payment. |
Paths | Array of Path Arrays | PathSet | No | An array of for the transaction. Automatically populated by the ledger for cross-currency payments. Must be omitted for XRP-to-XRP transactions. |
SendMax | Currency Amount | Amount | No | The maximum amount of source currency the transaction may cost, including , exchange rates, and . Excludes the . Required for cross-currency payments; must be omitted for XRP-to-XRP payments. |
For IOU payments, use issued-currency Amount and optionally Paths and SendMax.
Always use autofill to set fees and sequence safely when using the XRPL client library.