Language

Choose a language

/build/rpc / assets / zk_compliance

listassetcomplianceroots

listassetcomplianceroots "asset_id_or_ticker" ( count ) List historical compliance root commitments for a KYC asset. Returns ordered history from the ring buffer with activation heights and txids. Arguments: 1. asset_id_or_ticker (string, required) Asset identifier (hex) or ticker 2. count (numeric, optional, default=32) Maximum number of entries to return (default: 32) Result: { (json object) "asset_id" : "hex", (string) Asset identifier "history" : [ (json array) Ordered compliance root history (oldest first) { (json object) "root_commit" : "hex", (string) 32-byte commitment (root‖height) "root_height" : n, (numeric) Extracted capture height "activation_height" : n, (numeric) Block height when this root became active "txid" : "hex" (string) Transaction that committed this root }, ... ] } Examples: > bitcoin-cli listassetcomplianceroots "GOLD" > bitcoin-cli listassetcomplianceroots "a3f747562969280eb3ddc96ff57e3692b7b55611d8c89785f52fc2d1535d22b3" 10

Signature

listassetcomplianceroots(asset_id_or_ticker: string, count?: number) → any

Code samples

curl --user "$RPC_USER:$RPC_PASS" \
  --data-binary '{"jsonrpc":"1.0","id":"docs","method":"listassetcomplianceroots","params":["\"<asset_id_or_ticker>\"",32]}' \
  -H 'content-type: text/plain;' \
  http://127.0.0.1:8332/

Parameters

NameTypeReq.Description
asset_id_or_tickerstringyesAsset identifier (hex) or ticker
countnumberMaximum number of entries to return (default: 32)

Result

Type:  any

{ (json object) "asset_id" : "hex", (string) Asset identifier "history" : [ (json array) Ordered compliance root history (oldest first) { (json object) "root_commit" : "hex", (string) 32-byte commitment (root‖height) "root_height" : n, (numeric) Extracted capture height "activation_height" : n, (numeric) Block height when this root became active "txid" : "hex" (string) Transaction that committed this root }, ... ] }

Source: services/core-node/bcore/src/wallet/rpc/assets.cpp:8673

C++ symbol: listassetcomplianceroots