XRPL Integration

Integrate cross-chain swaps to, from, and within the XRP Ledger using Squid. XRPL support is powered by Squid Intents — Squid's intent-based execution protocol for fast, solver-driven cross-chain settlement.

Squid Intents must be enabled on your integrator ID. Reach out to the Squid team to request Squid Intents access before integrating with XRPL.


XRPL Parameters

Parameter
Value

Chain ID

xrpl-mainnet

Supported Destination Tokens

The following tokens are currently supported as destination tokens on XRPL via Squid Intents:

Token
Address

XRP

xrp

RLUSD

524c555344000000000000000000000000000000.rmxckbedwqr76quhesumdegf4b9xj8m5de

SOIL

534F494C00000000000000000000000000000000.rfmS3zqrQrka8wVyhXifEeyTwe8AMz2Yhw


Widget Integration

The fastest way to add XRPL swaps to your application is through the Squid Widget. You can prototype your widget configuration interactively using Widget Studioarrow-up-right.

Locking Destination to XRPL

To configure the widget so the destination is always XRPL, use the initialAssets, availableChains, and availableTokens configuration options:

This configuration:

  • Sets the default destination token to XRP on XRPL

  • Restricts the destination chain selector to XRPL only

  • Limits destination token choices to XRP, RLUSD, and SOIL

  • Leaves the source chain and token open for the user to select

For more widget customization options, see the Widget Customization Guide.


API Integration

Route to XRPL (EVM → XRPL)

To route from an EVM chain to XRPL, set toChain to xrpl-mainnet and toToken to one of the supported XRPL token addresses.

Transaction type: DEPOSIT_ADDRESS_CALLDATA — The route response will include a deposit address and calldata. Transfer the specified amount to the deposit address to initiate the swap.

Same-Chain Swap on XRPL (XRPL → XRPL)

You can also perform same-chain swaps between XRPL tokens.

Transaction type: DEPOSIT_ADDRESS_CALLDATA

Route from XRPL (XRPL → EVM)

To route from XRPL to an EVM chain, set fromChain to xrpl-mainnet.

Transaction type: DEPOSIT_ADDRESS_CALLDATA

Status Tracking

XRPL routes are powered by Squid Intents, which requires the quoteId for status polling. The quoteId is returned in the route response.

Important: A Squid Intent transaction will fail unless status is polled with the quoteId. See the Integrating Squid Intents guide for full status polling details.

API Code Examples


SDK Integration

The Squid SDK provides the same XRPL routing capabilities. After initializing the SDK with your integrator ID, use squid.route() with the same parameters as the API examples above, then execute using the returned transaction request.

For full SDK setup and execution details, see the SDK documentation.

SDK Code Examples


Transaction Types

All XRPL routes use the DEPOSIT_ADDRESS_CALLDATA transaction type. This applies to:

  • EVM → XRPL — Direct route, no DEX swap on source

  • XRPL → EVM — Direct route from XRPL to any EVM chain

  • XRPL → XRPL — Same-chain swaps between XRPL tokens

The route response will return a transactionRequest containing the deposit address and calldata. Transfer the specified amount to the deposit address to initiate the swap.

For a full reference of all transaction types across all chains, see the Transaction Types page.

Last updated