/build/rpc / assets / icu
geticuinfo
geticuinfo "asset_id" Read ICU payload metadata from LevelDB for a given asset. Returns canonical_hash, witness_hash, visibility, and other metadata. For public assets (visibility=0), also returns the canonical_text and witness bundle. Arguments: 1. asset_id (string, required) Asset ID (32-byte hex) Result: { (json object) "asset_id" : "hex", (string) Asset ID "icu_ctxt_commit" : "hex", (string) SHA256 of stored ICU ciphertext "icu_plain_commit" : "hex", (string) SHA256 of canonical plaintext (from registry) "visibility" : n, (numeric) 0 = public, 1 = holder_only "compression" : n, (numeric) 0 = none, 1 = zstd "encryption_mode" : n, (numeric) 0 = plaintext, 1 = AES-GCM, 2 = XChaCha20 "size_bytes" : n, (numeric) Raw payload size "canonical_hash" : "hex", (string) SHA256(canonical_text) - computed from payload "witness_hash" : "hex", (string) SHA256(witness_bundle) - computed from payload "canonical_text" : "str", (string, optional) Canonical text (only if visibility=public and parseable) "witness_bundle" : "str" (string, optional) Witness bundle (only if visibility=public and parseable) } Examples: > bitcoin-cli geticuinfo "<asset_id>"
Signature
geticuinfo(asset_id: string) → any Code samples
curl --user "$RPC_USER:$RPC_PASS" \
--data-binary '{"jsonrpc":"1.0","id":"docs","method":"geticuinfo","params":["\"<asset_id>\""]}' \
-H 'content-type: text/plain;' \
http://127.0.0.1:8332/ Parameters
| Name | Type | Req. | Description |
|---|---|---|---|
| asset_id | string | yes | Asset ID (32-byte hex) |
Result
Type: any
{ (json object) "asset_id" : "hex", (string) Asset ID "icu_ctxt_commit" : "hex", (string) SHA256 of stored ICU ciphertext "icu_plain_commit" : "hex", (string) SHA256 of canonical plaintext (from registry) "visibility" : n, (numeric) 0 = public, 1 = holder_only "compression" : n, (numeric) 0 = none, 1 = zstd "encryption_mode" : n, (numeric) 0 = plaintext, 1 = AES-GCM, 2 = XChaCha20 "size_bytes" : n, (numeric) Raw payload size "canonical_hash" : "hex", (string) SHA256(canonical_text) - computed from payload "witness_hash" : "hex", (string) SHA256(witness_bundle) - computed from payload "canonical_text" : "str", (string, optional) Canonical text (only if visibility=public and parseable) "witness_bundle" : "str" (string, optional) Witness bundle (only if visibility=public and parseable) }
Source: services/core-node/bcore/src/rpc/rawtransaction.cpp:1293
C++ symbol: geticuinfo