Language

Choose a language

/build/rpc / assets / raw_attach

decodeoutext

decodeoutext "tlv" Decode an output extension TLV (hex) into structured fields. Arguments: 1. tlv (string, required) TLV hex Result: { (json object) "type" : "str", (string) ASSET_TAG or ISSUER_REG "asset_id" : "hex", (string, optional) asset id "amount" : n, (numeric, optional) asset units (u64) "policy_bits" : n, (numeric, optional) policy bits "allowed_spk_families" : n, (numeric, optional) allowed families "unlock_fees_sats" : n, (numeric, optional) unlock threshold "ticker" : "str", (string, optional) ticker "decimals" : n (numeric, optional) decimals }

Signature

decodeoutext(tlv: string) → any

Code samples

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

Parameters

NameTypeReq.Description
tlvstringyesTLV hex

Result

Type:  any

{ (json object) "type" : "str", (string) ASSET_TAG or ISSUER_REG "asset_id" : "hex", (string, optional) asset id "amount" : n, (numeric, optional) asset units (u64) "policy_bits" : n, (numeric, optional) policy bits "allowed_spk_families" : n, (numeric, optional) allowed families "unlock_fees_sats" : n, (numeric, optional) unlock threshold "ticker" : "str", (string, optional) ticker "decimals" : n (numeric, optional) decimals }

Source: services/core-node/bcore/src/rpc/rawtransaction.cpp:2751

C++ symbol: decodeoutext