# my_tx_history
my_tx_history (from_id limit=10 max=false page_number)
The my_tx_history
method returns the blockchain transactions involving the AtomicDEX API node's coin address.
The coin that is used must have tx_history
set to true in its enable or electrum call.
# Arguments
Structure | Type | Description |
---|---|---|
coin | string | the name of the coin for the history request |
limit | number | limits the number of returned transactions; ignored if max = true |
max | bool | whether to return all available records; defaults to false |
from_id | string | AtomicDEX API will skip records until it reaches this ID, skipping the from_id as well; track the internal_id of the last displayed transaction to find the value of this field for the next page |
page_number | number | AtomicDEX API will return limit swaps from the selected page; This param will be ignored if from_uuid is set. |
# Response
Structure | Type | Description |
---|---|---|
transactions | array of objects | transactions data |
from_id | string | the from_id specified in the request; this value is null if from_id was not set |
skipped | number | the number of skipped records (i.e. the position of from_id in the list + 1); this value is 0 if from_id was not set |
limit | number | the limit that was set in the request; note that the actual number of transactions can differ from the specified limit (e.g. on the last page) |
total | number | the total number of transactions available |
page_number | number | the page_number that was set in the request |
total_pages | number | total pages available with the selected limit |
current_block | number | the number of the latest block of coin blockchain |
sync_status | object | provides the information that helps to track the progress of transaction history preloading at background |
sync_status.state | string | current state of sync; possible values: NotEnabled , NotStarted , InProgress , Error , Finished |
sync_status.additional_info | object | additional info that helps to track the progress; present for InProgress and Error states only |
sync_status.additional_info.blocks_left | number | present for ETH/ERC20 coins only; displays the number of blocks left to be processed for InProgress state |
sync_status.additional_info.transactions_left | number | present for UTXO coins only; displays the number of transactions left to be processed for InProgress state |
sync_status.additional_info.code | number | displays the error code for Error state |
sync_status.additional_info.message | number | displays the error message for Error state |
# 📌 Examples
# Command
curl --url "http://127.0.0.1:7783" --data "{
\"userpass\": \"$userpass\",
\"method\": \"my_tx_history\",
\"coin\": \"RICK\",
\"limit\": 1,
\"from_id\": \"1d5c1b67f8ebd3fc480e25a1d60791bece278f5d1245c5f9474c91a142fee8e1\"
}"
# Command (max = true)
curl --url "http://127.0.0.1:7783" --data "{
\"userpass\": \"$userpass\",
\"method\": \"my_tx_history\",
\"coin\": \"RICK\",
\"max\": true,
\"from_id\": \"1d5c1b67f8ebd3fc480e25a1d60791bece278f5d1245c5f9474c91a142fee8e1\"
}"