A unique identifier for the account, most commonly the account's address.
tx_type
String
ledger_index_min
Integer
[API v1][]: (Optional) Use to specify the earliest ledger to include transactions from. A value of -1 instructs the server to use the earliest validated ledger version available.
[API v2][]: Identical to v1, but also returns a lgrIdxMalformed error if a value is specified beyond the range of ledgers the server has.
ledger_index_max
Integer
[API v1][]: (Optional) Use to specify the most recent ledger to include transactions from. A value of -1 instructs the server to use the most recent validated ledger version available.
[API v2][]: Identical to v1, but also returns a lgrIdxMalformed error if a value is specified beyond the range of ledgers the server has.
ledger_hash
String
(Optional) Use to look for transactions from a single ledger only. (See [Specifying Ledgers][].)
ledger_index
String or Unsigned Integer
(Optional) Use to look for transactions from a single ledger only. (See [Specifying Ledgers][].)
binary
Boolean
[API v1][]: (Optional) Defaults to false. If set to true, returns transactions as hex strings instead of JSON.
[API v2][]: Identical to v1, but also returns an invalidParams error if you provide a non-boolean value.
forward
Boolean
[API v1][]: (Optional) Defaults to false. If set to true, returns values indexed with the oldest ledger first. Otherwise, the results are indexed with the newest ledger first. (Each page of results may not be internally ordered, but the pages are overall ordered.)
[API v2][]: Identical to v1, but also returns an invalidParams error if you provide a non-boolean value.
limit
Integer
(Optional) Default varies. Limit the number of transactions to retrieve. The server is not required to honor this value.
marker
[Marker][]
Value from a previous paginated response. Resume retrieving data where that response left off. This value is stable even if there is a change in the server's range of available ledgers.
You must use at least one of the following fields in your request: ledger_index, ledger_hash, ledger_index_min, or ledger_index_max.
[API v2]: If you specify either ledger_index or ledger_hash, including ledger_index_min and ledger_index_max returns an invalidParams error.
Iterating over queried data
As with other paginated methods, you can use the marker field to return multiple pages of data.
In the time between requests, "ledger_index_min": -1 and "ledger_index_max": -1 may change to refer to different ledger versions than they did before. The marker field can safely paginate even if there are changes in the ledger range from the request, so long as the marker does not indicate a point outside the range of ledgers specified in the request.
The response follows the [standard format][], with a successful result containing the following fields:
Field
Type
Description
account
String
Unique [Address][] identifying the related account
ledger_index_min
Integer - [Ledger Index][]
The ledger index of the earliest ledger actually searched for transactions.
ledger_index_max
Integer - [Ledger Index][]
The ledger index of the most recent ledger actually searched for transactions.
limit
Integer
The limit value used in the request. (This may differ from the actual limit value enforced by the server.)
marker
[Marker][]
Server-defined value indicating the response is paginated. Pass this to the next call to resume where this call left off.
transactions
Array
Array of transactions matching the request's criteria, as explained below.
validated
Boolean
If included and set to true, the information in this response comes from a validated ledger version. Otherwise, the information is subject to change.
Note: The server may respond with different values of ledger_index_min and ledger_index_max than you provided in the request, for example if it did not have the versions you specified on hand.
Each transaction object includes the following fields, depending on whether it was requested in JSON or hex string ("binary":true) format.
Field
Type
Description
ledger_index
Integer
The [ledger index][] of the ledger version that included this transaction.
meta
Object (JSON) or String (Binary)
If binary is True, then this is a hex string of the transaction metadata. Otherwise, the transaction metadata is included in JSON format.
tx
Object
(JSON mode only) JSON object defining the transaction
tx_blob
String
(Binary mode only) Unique hashed String representing the transaction.
validated
Boolean
Whether or not the transaction is included in a validated ledger. Any transaction not yet in a validated ledger is subject to change.
Possible Errors
Any of the [universal error types][].
invalidParams - One or more fields are specified incorrectly, or one or more required fields are missing.
actMalformed - The [Address][] specified in the account field of the request is not formatted properly.
lgrIdxMalformed - The ledger specified by the ledger_index_min or ledger_index_max does not exist, or if it does exist but the server does not have it.
lgrIdxsInvalid - Either the request specifies a ledger_index_max that is before the ledger_index_min, or the server does not have a validated ledger range because it is not synced with the network.
(Optional)Clio Only Return only transactions of a specific type, such as "Clawback", "AccountSet", "AccountDelete", et al. Case-insensitive. See Transaction Types.