XRP Ledger
XRP Ledger
"xrpl""ripple""XRP Ledger"
- Symbol
- XRP · 6 decimals
- Coin type
- 144
- CAIP-2
- xrpl:0
- Checks
- address · txid
Network
- CAIP-2
xrpl:0 - Magic
none - PoW
none - RPC
none - Explorerlivenet.xrpl.org
Access
- Create
create("xrpl") - Resolve
getChain("ripple") - CLI
chains info ripple - Tryplayground with a sample address
Address format
The XRP Ledger writes base58 over its own ordering of the same 58 characters, rpshnaf39wBUDNEGHJKLM4PQRST7VWXYZ2bcdeCg65jkm8oFqi1tuvAxyz, with r as zero. An address has to be decoded under those digits or the bytes come back wrong rather than rejected, which is worse.
A classic account is 25 Base58Check bytes under version 0x00, so it starts with r. An X-address folds a destination tag in: 35 bytes under the mainnet prefix 0x05 0x44, a flag byte of 0 or 1, and the tag bytes the flag doesn't use required to be zero, as XLS-5 says. The testnet prefix 0x04 0x93, which writes T…, is turned away. The Base58Check checksum is verified on both forms.
import { getChain } from "@agntn/chains";
const chain = getChain("xrp");
chain.assertAddress("rN7n7otQDd6FczFgLdSqtcsAUxDkw6fzRH"); // returned unchanged
chain.type; // "xrpl"
chain.caip2; // "xrpl:0"
Spellings
xrpl, xrp, ripple, XRP Ledger. The key is xrpl, the rest resolve through getChain.