XRPL.Ledger (xrpl v0.1.0)
XRPL.Ledger is a module to interact with ledgers on the XRP Ledger. A ledger version contains a header, a transaction tree, and a state tree, which contain account settings, trustlines, balances, transactions, and other data. Use these methods to retrieve ledger info.
Official RPC documentation: https://xrpl.org/ledger-methods.html
Summary
Functions
Retrieve information about the public ledger.
The ledger_closed method returns the unique identifiers of the most recently closed ledger. (This ledger is not necessarily validated and immutable yet.)
The ledger_current method returns the unique identifiers of the current in-progress ledger.
The ledger_data method retrieves contents of the specified ledger. You can iterate through several calls to retrieve the entire contents of a single ledger version.
Types
currency_without_amount()
Functions
ledger(opts \\ [])
@spec ledger(Keyword.t()) :: Tesla.Env.result()
Retrieve information about the public ledger.
Official documentation: https://xrpl.org/ledger.html
ledger!(opts \\ [])
ledger_closed()
@spec ledger_closed() :: Tesla.Env.result()
The ledger_closed method returns the unique identifiers of the most recently closed ledger. (This ledger is not necessarily validated and immutable yet.)
Official documentation: https://xrpl.org/ledger_closed.html
ledger_closed!()
ledger_current()
@spec ledger_current() :: Tesla.Env.result()
The ledger_current method returns the unique identifiers of the current in-progress ledger.
This command is mostly useful for testing, because the ledger returned is still in flux.
Official documentation: https://xrpl.org/ledger_current.html
ledger_current!()
ledger_data(opts \\ [])
@spec ledger_data(Keyword.t()) :: Tesla.Env.result()
The ledger_data method retrieves contents of the specified ledger. You can iterate through several calls to retrieve the entire contents of a single ledger version.
Official documentation: https://xrpl.org/ledger_data.html