Shows all transactions history for specified network (for specified chain)
CLI Example
Command syntax:
tx_history
-all
-net <net_name>
[-chain <chain_name>]
[-limit]
[-offset]
[-head]
[-tail]
Options:
-net - name of the Cellframe Network. The list of networks can be found in the <Config_dir> \ etc \ network folder or received by The Cellframe-Node-CLI using command - net list
-all - means all transactions
-chain - the name of Chain. The list of chains can be found in the directory <Config_dir> \ etc \ network \ <network_name> or by the Cellframe-Node-CLI using command - net list chains (optional)
-limit - number of elements being printed (optional)
-offset - number of the element from which printing will be started (optional)
-head - shows transactions list starting from the first one (optional)
-tail - shows transactions list startinf from the last one (optional)
Example:
Command:
cellframe-node-cli tx_history
-all
-net foobar
Response:
status: ACCEPTED
hash: 0xDB800118C3521C954D3B641FEC6FE92797C926A0B832003D9FF682E2E60C775C
token_ticker: BUZ
ret_code: 0
ret_code_str: DAP_LEDGER_TX_CHECK_OK
tx_created: Fri Feb 2 10:42:21 2024
items:
type: TX_ITEM_TYPE_IN_EMS
data:
ticker: BUZ
chain_id: 0
emission_hash: 0x9DA6B739524D0A2D43483CAA716D761BA81C22641D27CB51FADFD11B5D865F96
type: TX_ITEM_TYPE_OUT_COND
data:
ts_expires: never
subtype: DAP_CHAIN_TX_OUT_COND_SUBTYPE_FEE
value: 5.0
value_datoshi: 5000000000000000000
uid: 0x0000000000000000
type: TX_ITEM_TYPE_OUT
data:
value: 9999999999999999999999999999999999995.0
value_datoshi: 9999999999999999999999999999999999995000000000000000000
...
addr: ptV4n68gTebdUTcbpBuQWBcLBL5Y17NnXUrt15RtDaYiAQqHthDfijE9kM512Dgz6jypxifLc6iLEvC1buAtw7hF2pphvPHoGQkEmFSb
token: BUZ
type: TX_ITEM_TYPE_SIG
data:
sign_size: 3306
sign:
type: sig_dil
pkeyHash: 0xE7B586257FBF09C3CC99D17099B4BC18F9B398188E4D365107F030831178C6F3
signPkeySize: 1196
signSize: 2096
Chain main in network foobar contains 4 transactions.
Of which 4 were accepted into the ledger and 0 were rejected.
JSON-RPC Example
Command:
curl -X POST http://rpc.cellframe.net/connect -d '{"method":"tx_history", "params":["tx_history;-all;-net;foobar"], "id":"1"}'
Response:
{
"type": 2,
"result": "same as cli response",
"errors": null,
"id": 1
}