pub struct Asset {Show 20 fields
pub version: AssetVersion,
pub asset_genesis: Option<GenesisInfo>,
pub amount: u64,
pub lock_time: i32,
pub relative_lock_time: i32,
pub script_version: i32,
pub script_key: Vec<u8>,
pub script_key_is_local: bool,
pub asset_group: Option<AssetGroup>,
pub chain_anchor: Option<AnchorInfo>,
pub prev_witnesses: Vec<PrevWitness>,
pub split_commitment_root: Option<MssmtNode>,
pub is_spent: bool,
pub lease_owner: Vec<u8>,
pub lease_expiry: i64,
pub is_burn: bool,
pub script_key_declared_known: bool,
pub script_key_has_script_path: bool,
pub decimal_display: Option<DecimalDisplay>,
pub script_key_type: ScriptKeyType,
}Expand description
Represents a Taproot Asset.
Fields§
§version: AssetVersionThe version of the Taproot Asset.
asset_genesis: Option<GenesisInfo>The base genesis information of an asset. This information never changes.
amount: u64The total amount of the asset stored in this Taproot Asset UTXO.
lock_time: i32An optional locktime, as with Bitcoin transactions.
relative_lock_time: i32An optional relative lock time, same as Bitcoin transactions.
script_version: i32The version of the script, only version 0 is defined at present.
script_key: Vec<u8>The script key of the asset, which can be spent under Taproot semantics.
script_key_is_local: boolIndicates whether the script key is known to the wallet of the lnd node connected to the Taproot Asset daemon.
asset_group: Option<AssetGroup>The information related to the key group of an asset (if it exists).
chain_anchor: Option<AnchorInfo>Describes where in the chain the asset is currently anchored.
prev_witnesses: Vec<PrevWitness>Previous witnesses for the asset.
split_commitment_root: Option<MssmtNode>The root node of the MS-SMT storing split commitments, if present.
is_spent: boolIndicates whether the asset has been spent.
lease_owner: Vec<u8>If the asset has been leased, this is the owner (application ID) of the lease.
lease_expiry: i64If the asset has been leased, this is the expiry of the lease as a Unix timestamp in seconds.
is_burn: boolIndicates whether this transfer was an asset burn. If true, the number of assets in this output are destroyed and can no longer be spent.
script_key_declared_known: boolDeprecated, use script_key_type instead! Indicates whether this script key has either been derived by the local wallet or was explicitly declared to be known by using the DeclareScriptKey RPC. Knowing the key conceptually means the key belongs to the local wallet or is at least known by a software that operates on the local wallet. The flag is never serialized in proofs, so this is never explicitly set for keys foreign to the local wallet. Therefore, if this method returns true for a script key, it means the asset with the script key will be shown in the wallet balance.
script_key_has_script_path: boolDeprecated, use script_key_type instead! Indicates whether the script key is known to have a Tapscript spend path, meaning that the Taproot merkle root tweak is not empty. This will only ever be true if either script_key_is_local or script_key_internals_known is true as well, since the presence of a Tapscript spend path cannot be determined for script keys that aren’t known to the wallet of the local tapd node.
decimal_display: Option<DecimalDisplay>This field defines a decimal display value that may be present. If this field is null, it means the presence of a decimal display field is unknown in the current context.
script_key_type: ScriptKeyTypeThe type of the script key. This type is either user-declared when custom script keys are added, or automatically determined by the daemon for standard operations (e.g. BIP-86 keys, burn keys, tombstone keys, channel related keys).