ListAssetHistory

List all Taproot Assets and BTC transaction history in a wallet.

POST /api/list-asset-history

Headers

NameValue

Content-Type

application/json

Authorization

token

Request Body

NameTypeRequiredDescription

wallet_id

string

true

The end user's wallet id

occurred_after

int64

false

Occurred after this Unix timestamp

asset_id

string

false

asset id(hex form) for TAP assets, (for btc assets the asset_id is btc). If empty, all assets shall be returned

Response Body

NameTypeDescription

op_type

string

0 out; 1 in

pending

bool

false; true (indicating if the tx is included in block)

Request Demo

{
  "wallet_id": "10e21d53-82d3-43d6-99bc-03ea6945d902",
  "occurred_after":0
}

Response Demo

{
    "code": 0,
    "data": {
        "tx_histories": [
            {
                "timestamp": 1721854538,
                "tx_id": "b4e0d6a6fcb251378fd356504bede98ef769d7450e83b8be8333e98bc59014b8",
                "asset_id": "4ea437a417d3fe8bd735dacd3ad36bd6758dabcb7080f7528299d5a30e44e328",
                "amount": 100,
                "op_type": "0"
            },
            {
                "timestamp": 1721825649,
                "tx_id": "ca6197ee1302c0d483856e14337ece9373b3ec148adc6ec4f8aaf2c550a3b90f",
                "asset_id": "4ea437a417d3fe8bd735dacd3ad36bd6758dabcb7080f7528299d5a30e44e328",
                "amount": 700,
                "op_type": "1"
            },
            {
                "timestamp": 1721825438,
                "tx_id": "c95e629444449451582089c64e835316410dc9cd5539e2f44092a600b48c6f8a",
                "asset_id": "4ea437a417d3fe8bd735dacd3ad36bd6758dabcb7080f7528299d5a30e44e328",
                "amount": 800,
                "op_type": "1"
            },
            {
                "timestamp": 1721824876,
                "tx_id": "370fac49786be313f6bbe78aa7744c24bda911d3e6a71db8538afbcea5d9a9d2",
                "asset_id": "4ea437a417d3fe8bd735dacd3ad36bd6758dabcb7080f7528299d5a30e44e328",
                "amount": 3000,
                "op_type": "1"
            }
        ]
    },
    "message": "",
    "traceid": "98539813-a3f4-4846-a716-862c19ecf1fa"
}

Last updated