Skip to main content

taproot_assets_rpc/opt/rustwide/workdir/generated/
taprpc.rs

1// This file is @generated by prost-build.
2/// Represents a Bitcoin transaction outpoint.
3#[derive(Clone, PartialEq, ::prost::Message)]
4pub struct OutPoint {
5    ///
6    /// Raw bytes representing the transaction id.
7    #[prost(bytes = "vec", tag = "1")]
8    pub txid: ::prost::alloc::vec::Vec<u8>,
9    ///
10    /// The index of the output on the transaction.
11    #[prost(uint32, tag = "2")]
12    pub output_index: u32,
13}
14/// A transaction outpoint annotated with TAP-level asset metadata. It uniquely
15/// identifies an asset anchored at a specific outpoint.
16#[derive(Clone, PartialEq, ::prost::Message)]
17pub struct AssetOutPoint {
18    /// The outpoint of the asset anchor, represented as a string in the
19    /// format "<txid>:<vout>". The <txid> is the transaction ID of the UTXO,
20    /// hex-encoded and byte-reversed (i.e., the internal little-endian
21    /// 32-byte value is reversed to big-endian hex format) to match standard
22    /// Bitcoin RPC and UI conventions.
23    #[prost(string, tag = "1")]
24    pub anchor_out_point: ::prost::alloc::string::String,
25    /// The asset ID of the asset anchored at the outpoint.
26    #[prost(bytes = "vec", tag = "2")]
27    pub asset_id: ::prost::alloc::vec::Vec<u8>,
28    /// The script key of the asset. This is the taproot output key that the
29    /// asset is locked to.
30    #[prost(bytes = "vec", tag = "3")]
31    pub script_key: ::prost::alloc::vec::Vec<u8>,
32}
33#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
34#[repr(i32)]
35pub enum SortDirection {
36    /// Sort results in descending order.
37    Desc = 0,
38    /// Sort results in ascending order.
39    Asc = 1,
40}
41impl SortDirection {
42    /// String value of the enum field names used in the ProtoBuf definition.
43    ///
44    /// The values are not transformed in any way and thus are considered stable
45    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
46    pub fn as_str_name(&self) -> &'static str {
47        match self {
48            Self::Desc => "SORT_DIRECTION_DESC",
49            Self::Asc => "SORT_DIRECTION_ASC",
50        }
51    }
52    /// Creates an enum from field names used in the ProtoBuf definition.
53    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
54        match value {
55            "SORT_DIRECTION_DESC" => Some(Self::Desc),
56            "SORT_DIRECTION_ASC" => Some(Self::Asc),
57            _ => None,
58        }
59    }
60}
61#[derive(Clone, PartialEq, ::prost::Message)]
62pub struct AssetMeta {
63    ///
64    /// The raw data of the asset meta data. Based on the type below, this may be
65    /// structured data such as a text file or PDF. The size of the data is limited
66    /// to 1MiB.
67    #[prost(bytes = "vec", tag = "1")]
68    pub data: ::prost::alloc::vec::Vec<u8>,
69    /// The type of the asset meta data.
70    #[prost(enumeration = "AssetMetaType", tag = "2")]
71    pub r#type: i32,
72    ///
73    /// The hash of the meta. This is the hash of the TLV serialization of the meta
74    /// itself.
75    #[prost(bytes = "vec", tag = "3")]
76    pub meta_hash: ::prost::alloc::vec::Vec<u8>,
77}
78#[derive(Clone, PartialEq, ::prost::Message)]
79pub struct ListAssetRequest {
80    /// Whether to include each asset's witness in the response. The witness
81    /// either contains the spending signatures or the split commitment witness,
82    /// which can both be large and usually aren't very useful on the command
83    /// line, so are omitted by default.
84    #[prost(bool, tag = "1")]
85    pub with_witness: bool,
86    /// Include assets that are marked as spent (which is always true for burn
87    /// or tombstone assets).
88    #[prost(bool, tag = "2")]
89    pub include_spent: bool,
90    /// Include assets that are leased (locked/reserved) by the daemon for a
91    /// pending transfer. Leased assets cannot be used by the daemon until the
92    /// pending transfer is confirmed or the lease expires.
93    #[prost(bool, tag = "3")]
94    pub include_leased: bool,
95    /// List assets that aren't confirmed yet. Only freshly minted assets will
96    /// show in the asset list with a block height of 0. All other forms of
97    /// unconfirmed assets will not appear in the list until the transaction is
98    /// confirmed (check either transfers or receives for unconfirmed outbound or
99    /// inbound assets).
100    #[prost(bool, tag = "4")]
101    pub include_unconfirmed_mints: bool,
102    /// Only return assets with amount greater or equal to this value.
103    #[prost(uint64, tag = "5")]
104    pub min_amount: u64,
105    /// Only return assets with amount less or equal to this value.
106    #[prost(uint64, tag = "6")]
107    pub max_amount: u64,
108    /// Only return assets that belong to the group with this key.
109    #[prost(bytes = "vec", tag = "7")]
110    pub group_key: ::prost::alloc::vec::Vec<u8>,
111    /// Return all assets that use this script key.
112    #[prost(message, optional, tag = "8")]
113    pub script_key: ::core::option::Option<ScriptKey>,
114    /// Return all assets that are currently anchored on this outpoint.
115    #[prost(message, optional, tag = "9")]
116    pub anchor_outpoint: ::core::option::Option<OutPoint>,
117    /// The script key type to filter the assets by. If not set, only assets with
118    /// a BIP-0086 script key will be returned (which is the equivalent of
119    /// setting script_key_type.explicit_type = SCRIPT_KEY_BIP86). If the type
120    /// is set to SCRIPT_KEY_BURN or SCRIPT_KEY_TOMBSTONE the include_spent flag
121    /// will automatically be set to true, because assets of that type are always
122    /// marked as spent.
123    #[prost(message, optional, tag = "10")]
124    pub script_key_type: ::core::option::Option<ScriptKeyTypeQuery>,
125}
126#[derive(Clone, PartialEq, ::prost::Message)]
127pub struct AnchorInfo {
128    /// The transaction that anchors the Taproot Asset commitment where the asset
129    ///   resides.
130    #[prost(bytes = "vec", tag = "1")]
131    pub anchor_tx: ::prost::alloc::vec::Vec<u8>,
132    /// The block hash the contains the anchor transaction above.
133    #[prost(string, tag = "3")]
134    pub anchor_block_hash: ::prost::alloc::string::String,
135    /// The outpoint (txid:vout) that stores the Taproot Asset commitment.
136    #[prost(string, tag = "4")]
137    pub anchor_outpoint: ::prost::alloc::string::String,
138    ///
139    /// The raw internal key that was used to create the anchor Taproot output key.
140    #[prost(bytes = "vec", tag = "5")]
141    pub internal_key: ::prost::alloc::vec::Vec<u8>,
142    ///
143    /// The Taproot merkle root hash of the anchor output the asset was committed
144    /// to. If there is no Tapscript sibling, this is equal to the Taproot Asset
145    /// root commitment hash.
146    #[prost(bytes = "vec", tag = "6")]
147    pub merkle_root: ::prost::alloc::vec::Vec<u8>,
148    ///
149    /// The serialized preimage of a Tapscript sibling, if there was one. If this
150    /// is empty, then the merkle_root hash is equal to the Taproot root hash of the
151    /// anchor output.
152    #[prost(bytes = "vec", tag = "7")]
153    pub tapscript_sibling: ::prost::alloc::vec::Vec<u8>,
154    /// The height of the block which contains the anchor transaction.
155    #[prost(uint32, tag = "8")]
156    pub block_height: u32,
157    /// The UTC Unix timestamp of the block containing the anchor transaction.
158    #[prost(int64, tag = "9")]
159    pub block_timestamp: i64,
160}
161#[derive(Clone, PartialEq, ::prost::Message)]
162pub struct GenesisInfo {
163    /// The first outpoint of the transaction that created the asset (txid:vout).
164    #[prost(string, tag = "1")]
165    pub genesis_point: ::prost::alloc::string::String,
166    /// The name of the asset.
167    #[prost(string, tag = "2")]
168    pub name: ::prost::alloc::string::String,
169    /// The hash of the meta data for this genesis asset.
170    #[prost(bytes = "vec", tag = "3")]
171    pub meta_hash: ::prost::alloc::vec::Vec<u8>,
172    /// The asset ID that uniquely identifies the asset.
173    #[prost(bytes = "vec", tag = "4")]
174    pub asset_id: ::prost::alloc::vec::Vec<u8>,
175    /// The type of the asset.
176    #[prost(enumeration = "AssetType", tag = "5")]
177    pub asset_type: i32,
178    ///
179    /// The index of the output that carries the unique Taproot Asset commitment in
180    /// the genesis transaction.
181    #[prost(uint32, tag = "6")]
182    pub output_index: u32,
183}
184///
185/// This message represents an external key used for deriving and managing
186/// hierarchical deterministic (HD) wallet addresses according to BIP-86.
187#[derive(Clone, PartialEq, ::prost::Message)]
188pub struct ExternalKey {
189    ///
190    /// This field specifies the extended public key derived at depth 3 of the
191    /// BIP-86 hierarchy (e.g., m/86'/0'/0'). This key serves as the parent key for
192    /// deriving child public keys and addresses.
193    #[prost(string, tag = "1")]
194    pub xpub: ::prost::alloc::string::String,
195    ///
196    /// This field specifies the fingerprint of the master key, derived from the
197    /// first 4 bytes of the hash160 of the master public key. It is used to
198    /// identify the master key in BIP-86 derivation schemes.
199    #[prost(bytes = "vec", tag = "2")]
200    pub master_fingerprint: ::prost::alloc::vec::Vec<u8>,
201    ///
202    /// This field specifies the extended BIP-86 derivation path used to derive a
203    /// child key from the XPub. Starting from the base path of the XPub
204    /// (e.g., m/86'/0'/0'), this path must contain exactly 5 components in total
205    /// (e.g., m/86'/0'/0'/0/0), with the additional components defining specific
206    /// child keys, such as individual addresses.
207    #[prost(string, tag = "3")]
208    pub derivation_path: ::prost::alloc::string::String,
209}
210#[derive(Clone, PartialEq, ::prost::Message)]
211pub struct GroupKeyRequest {
212    ///
213    /// The internal key for the asset group before any tweaks have been applied.
214    /// If this field is set then external_key must be empty, and vice versa.
215    #[prost(message, optional, tag = "1")]
216    pub raw_key: ::core::option::Option<KeyDescriptor>,
217    ///
218    /// The genesis of the group anchor asset, which is used to derive the single
219    /// tweak for the group key. For a new group key, this will be the genesis of
220    /// new_asset.
221    #[prost(message, optional, tag = "2")]
222    pub anchor_genesis: ::core::option::Option<GenesisInfo>,
223    ///
224    /// The optional root of a tapscript tree that will be used when constructing a
225    /// new asset group key. This enables future issuance authorized with a script
226    /// witness.
227    #[prost(bytes = "vec", tag = "3")]
228    pub tapscript_root: ::prost::alloc::vec::Vec<u8>,
229    ///
230    /// The serialized asset which we are requesting group membership for. A
231    /// successful request will produce a witness that authorizes this asset to be a
232    /// member of this asset group.
233    #[prost(bytes = "vec", tag = "4")]
234    pub new_asset: ::prost::alloc::vec::Vec<u8>,
235    ///
236    /// The external key is an optional field that allows specifying an
237    /// external signing key for the group virtual transaction during minting.
238    /// This key enables signing operations to be performed externally, outside
239    /// the daemon.
240    ///
241    /// If this field is set then raw_key must be empty, and vice versa.
242    #[prost(message, optional, tag = "5")]
243    pub external_key: ::core::option::Option<ExternalKey>,
244}
245#[derive(Clone, PartialEq, ::prost::Message)]
246pub struct TxOut {
247    /// The value of the output being spent.
248    #[prost(int64, tag = "1")]
249    pub value: i64,
250    /// The script of the output being spent.
251    #[prost(bytes = "vec", tag = "2")]
252    pub pk_script: ::prost::alloc::vec::Vec<u8>,
253}
254#[derive(Clone, PartialEq, ::prost::Message)]
255pub struct GroupVirtualTx {
256    ///
257    /// The virtual transaction that represents the genesis state transition of a
258    /// grouped asset.
259    #[prost(bytes = "vec", tag = "1")]
260    pub transaction: ::prost::alloc::vec::Vec<u8>,
261    ///
262    /// The transaction output that represents a grouped asset. The tweaked
263    /// group key is set as the PkScript of this output. This is used in combination
264    /// with Tx to produce an asset group witness.
265    #[prost(message, optional, tag = "2")]
266    pub prev_out: ::core::option::Option<TxOut>,
267    ///
268    /// The asset ID of the grouped asset in a GroupKeyRequest. This ID is
269    /// needed to construct a sign descriptor, as it is the single tweak for the
270    /// group internal key.
271    #[prost(bytes = "vec", tag = "3")]
272    pub genesis_id: ::prost::alloc::vec::Vec<u8>,
273    ///
274    /// The tweaked group key for a specific GroupKeyRequest. This is used to
275    /// construct a complete group key after producing an asset group witness.
276    #[prost(bytes = "vec", tag = "4")]
277    pub tweaked_key: ::prost::alloc::vec::Vec<u8>,
278}
279#[derive(Clone, PartialEq, ::prost::Message)]
280pub struct GroupWitness {
281    /// The asset ID of the pending asset that should be assigned this asset
282    /// group witness.
283    #[prost(bytes = "vec", tag = "1")]
284    pub genesis_id: ::prost::alloc::vec::Vec<u8>,
285    /// The serialized witness stack for the asset group.
286    #[prost(bytes = "vec", repeated, tag = "2")]
287    pub witness: ::prost::alloc::vec::Vec<::prost::alloc::vec::Vec<u8>>,
288}
289#[derive(Clone, PartialEq, ::prost::Message)]
290pub struct AssetGroup {
291    /// The raw group key which is a normal public key.
292    #[prost(bytes = "vec", tag = "1")]
293    pub raw_group_key: ::prost::alloc::vec::Vec<u8>,
294    ///
295    /// The tweaked group key, which is derived based on the genesis point and also
296    /// asset type.
297    #[prost(bytes = "vec", tag = "2")]
298    pub tweaked_group_key: ::prost::alloc::vec::Vec<u8>,
299    ///
300    /// A witness that authorizes a specific asset to be part of the asset group
301    /// specified by the above key.
302    #[prost(bytes = "vec", tag = "3")]
303    pub asset_witness: ::prost::alloc::vec::Vec<u8>,
304    ///
305    /// The root hash of a tapscript tree, which enables future issuance authorized
306    /// with a script witness.
307    #[prost(bytes = "vec", tag = "4")]
308    pub tapscript_root: ::prost::alloc::vec::Vec<u8>,
309}
310#[derive(Clone, PartialEq, ::prost::Message)]
311pub struct GroupKeyReveal {
312    /// The raw group key which is a normal public key.
313    #[prost(bytes = "vec", tag = "1")]
314    pub raw_group_key: ::prost::alloc::vec::Vec<u8>,
315    /// The tapscript root included in the tweaked group key, which may be empty.
316    #[prost(bytes = "vec", tag = "2")]
317    pub tapscript_root: ::prost::alloc::vec::Vec<u8>,
318}
319#[derive(Clone, PartialEq, ::prost::Message)]
320pub struct GenesisReveal {
321    /// The base genesis information in the genesis reveal.
322    #[prost(message, optional, tag = "1")]
323    pub genesis_base_reveal: ::core::option::Option<GenesisInfo>,
324}
325#[derive(Clone, Copy, PartialEq, ::prost::Message)]
326pub struct DecimalDisplay {
327    ///
328    /// Decimal display dictates the number of decimal places to shift the amount to
329    /// the left converting from Taproot Asset integer representation to a
330    /// UX-recognizable fractional quantity.
331    ///
332    /// For example, if the decimal_display value is 2 and there's 100 of those
333    /// assets, then a wallet would display the amount as "1.00". This field is
334    /// intended as information for wallets that display balances and has no impact
335    /// on the behavior of the daemon or any other part of the protocol. This value
336    /// is encoded in the MetaData field as a JSON field, therefore it is only
337    /// compatible with assets that have a JSON MetaData field.
338    #[prost(uint32, tag = "1")]
339    pub decimal_display: u32,
340}
341#[derive(Clone, PartialEq, ::prost::Message)]
342pub struct Asset {
343    /// The version of the Taproot Asset.
344    #[prost(enumeration = "AssetVersion", tag = "1")]
345    pub version: i32,
346    /// The base genesis information of an asset. This information never changes.
347    #[prost(message, optional, tag = "2")]
348    pub asset_genesis: ::core::option::Option<GenesisInfo>,
349    /// The total amount of the asset stored in this Taproot Asset UTXO.
350    #[prost(uint64, tag = "4")]
351    pub amount: u64,
352    /// An optional locktime, as with Bitcoin transactions.
353    #[prost(int32, tag = "5")]
354    pub lock_time: i32,
355    /// An optional relative lock time, same as Bitcoin transactions.
356    #[prost(int32, tag = "6")]
357    pub relative_lock_time: i32,
358    /// The version of the script, only version 0 is defined at present.
359    #[prost(int32, tag = "7")]
360    pub script_version: i32,
361    /// The script key of the asset, which can be spent under Taproot semantics.
362    #[prost(bytes = "vec", tag = "9")]
363    pub script_key: ::prost::alloc::vec::Vec<u8>,
364    /// Indicates whether the script key is known to the wallet of the lnd node
365    /// connected to the Taproot Asset daemon.
366    #[prost(bool, tag = "10")]
367    pub script_key_is_local: bool,
368    /// The information related to the key group of an asset (if it exists).
369    #[prost(message, optional, tag = "11")]
370    pub asset_group: ::core::option::Option<AssetGroup>,
371    /// Describes where in the chain the asset is currently anchored.
372    #[prost(message, optional, tag = "12")]
373    pub chain_anchor: ::core::option::Option<AnchorInfo>,
374    /// The asset's previous witnesses, which either contain the spending
375    /// witness stack (usually a signature) or the split commitment witness
376    /// (which is used to prove the split commitment of a split asset).
377    #[prost(message, repeated, tag = "13")]
378    pub prev_witnesses: ::prost::alloc::vec::Vec<PrevWitness>,
379    /// Indicates whether the asset has been spent.
380    #[prost(bool, tag = "14")]
381    pub is_spent: bool,
382    /// If the asset has been leased, this is the owner (application ID) of the
383    /// lease.
384    #[prost(bytes = "vec", tag = "15")]
385    pub lease_owner: ::prost::alloc::vec::Vec<u8>,
386    /// If the asset has been leased, this is the expiry of the lease as a Unix
387    /// timestamp in seconds.
388    #[prost(int64, tag = "16")]
389    pub lease_expiry: i64,
390    /// Indicates whether this transfer was an asset burn. If true, the number of
391    /// assets in this output are destroyed and can no longer be spent.
392    #[prost(bool, tag = "17")]
393    pub is_burn: bool,
394    /// Deprecated, use script_key_type instead!
395    /// Indicates whether this script key has either been derived by the local
396    /// wallet or was explicitly declared to be known by using the
397    /// DeclareScriptKey RPC. Knowing the key conceptually means the key belongs
398    /// to the local wallet or is at least known by a software that operates on
399    /// the local wallet. The flag is never serialized in proofs, so this is
400    /// never explicitly set for keys foreign to the local wallet. Therefore, if
401    /// this method returns true for a script key, it means the asset with the
402    /// script key will be shown in the wallet balance.
403    #[prost(bool, tag = "18")]
404    pub script_key_declared_known: bool,
405    /// Deprecated, use script_key_type instead!
406    /// Indicates whether the script key is known to have a Tapscript spend path,
407    /// meaning that the Taproot merkle root tweak is not empty. This will only
408    /// ever be true if either script_key_is_local or script_key_internals_known
409    /// is true as well, since the presence of a Tapscript spend path cannot be
410    /// determined for script keys that aren't known to the wallet of the local
411    /// tapd node.
412    #[prost(bool, tag = "19")]
413    pub script_key_has_script_path: bool,
414    /// This field defines a decimal display value that may be present. If this
415    /// field is null, it means the presence of a decimal display field is
416    /// unknown in the current context.
417    #[prost(message, optional, tag = "20")]
418    pub decimal_display: ::core::option::Option<DecimalDisplay>,
419    /// The type of the script key. This type is either user-declared when custom
420    /// script keys are added, or automatically determined by the daemon for
421    /// standard operations (e.g. BIP-86 keys, burn keys, tombstone keys, channel
422    /// related keys).
423    #[prost(enumeration = "ScriptKeyType", tag = "21")]
424    pub script_key_type: i32,
425}
426#[derive(Clone, PartialEq, ::prost::Message)]
427pub struct PrevWitness {
428    /// The previous input asset that this witness is for.
429    #[prost(message, optional, tag = "1")]
430    pub prev_id: ::core::option::Option<PrevInputAsset>,
431    /// The witness stack that is used to prove the asset owner's authorization
432    /// to spend an asset. This is only set if the asset is the root asset of an
433    /// asset split.
434    #[prost(bytes = "vec", repeated, tag = "2")]
435    pub tx_witness: ::prost::alloc::vec::Vec<::prost::alloc::vec::Vec<u8>>,
436    /// The split commitment that is used to prove the split commitment of a
437    /// split asset. This is only set if the asset is a split asset.
438    #[prost(message, optional, tag = "3")]
439    pub split_commitment: ::core::option::Option<SplitCommitment>,
440}
441#[derive(Clone, PartialEq, ::prost::Message)]
442pub struct SplitCommitment {
443    /// The root asset that contains the transaction witness that authorizes the
444    /// spend of the asset.
445    #[prost(message, optional, tag = "1")]
446    pub root_asset: ::core::option::Option<Asset>,
447}
448#[derive(Clone, PartialEq, ::prost::Message)]
449pub struct ListAssetResponse {
450    /// The list of assets found in the database matching the request query
451    /// parameters.
452    #[prost(message, repeated, tag = "1")]
453    pub assets: ::prost::alloc::vec::Vec<Asset>,
454    /// This is a count of unconfirmed outgoing transfers. Unconfirmed transfers
455    /// do not appear as assets in this endpoint response.
456    #[prost(uint64, tag = "2")]
457    pub unconfirmed_transfers: u64,
458    /// This is a count of freshly minted assets that haven't been confirmed on
459    /// chain yet. These assets will appear in the asset list with a block height
460    /// of 0 if include_unconfirmed_mints is set to true in the request.
461    #[prost(uint64, tag = "3")]
462    pub unconfirmed_mints: u64,
463}
464#[derive(Clone, Copy, PartialEq, ::prost::Message)]
465pub struct ListUtxosRequest {
466    /// Whether to include UTXOs that are marked as leased (locked/reserved) by
467    /// the wallet for a pending transfer. Leased UTXOs cannot be used by the
468    /// wallet until the pending transfer is confirmed or the lease expires.
469    #[prost(bool, tag = "1")]
470    pub include_leased: bool,
471    /// The script key type to filter the assets by. If not set, only assets with
472    /// a BIP-0086 script key will be returned (which is the equivalent of
473    /// setting script_key_type.explicit_type = SCRIPT_KEY_BIP86).
474    #[prost(message, optional, tag = "2")]
475    pub script_key_type: ::core::option::Option<ScriptKeyTypeQuery>,
476}
477#[derive(Clone, PartialEq, ::prost::Message)]
478pub struct ManagedUtxo {
479    /// The outpoint of the UTXO.
480    #[prost(string, tag = "1")]
481    pub out_point: ::prost::alloc::string::String,
482    /// The UTXO amount in satoshis.
483    #[prost(int64, tag = "2")]
484    pub amt_sat: i64,
485    /// The internal key used for the on-chain output.
486    #[prost(bytes = "vec", tag = "3")]
487    pub internal_key: ::prost::alloc::vec::Vec<u8>,
488    /// The Taproot Asset root commitment hash.
489    #[prost(bytes = "vec", tag = "4")]
490    pub taproot_asset_root: ::prost::alloc::vec::Vec<u8>,
491    ///
492    /// The Taproot merkle root hash committed to by the outpoint of this UTXO.
493    /// If there is no Tapscript sibling, this is equal to the Taproot Asset root
494    /// commitment hash.
495    #[prost(bytes = "vec", tag = "5")]
496    pub merkle_root: ::prost::alloc::vec::Vec<u8>,
497    /// The assets held at this UTXO.
498    #[prost(message, repeated, tag = "6")]
499    pub assets: ::prost::alloc::vec::Vec<Asset>,
500    /// The lease owner for this UTXO. If blank the UTXO isn't leased.
501    #[prost(bytes = "vec", tag = "7")]
502    pub lease_owner: ::prost::alloc::vec::Vec<u8>,
503    /// The expiry time as a unix time stamp for this lease. If blank the utxo
504    /// isn't leased.
505    #[prost(int64, tag = "8")]
506    pub lease_expiry_unix: i64,
507}
508#[derive(Clone, PartialEq, ::prost::Message)]
509pub struct ListUtxosResponse {
510    /// The set of UTXOs managed by the daemon.
511    #[prost(map = "string, message", tag = "1")]
512    pub managed_utxos: ::std::collections::HashMap<
513        ::prost::alloc::string::String,
514        ManagedUtxo,
515    >,
516}
517#[derive(Clone, Copy, PartialEq, ::prost::Message)]
518pub struct ListGroupsRequest {}
519#[derive(Clone, PartialEq, ::prost::Message)]
520pub struct AssetHumanReadable {
521    /// The ID of the asset.
522    #[prost(bytes = "vec", tag = "1")]
523    pub id: ::prost::alloc::vec::Vec<u8>,
524    /// The amount of the asset.
525    #[prost(uint64, tag = "2")]
526    pub amount: u64,
527    /// An optional locktime, as with Bitcoin transactions.
528    #[prost(int32, tag = "3")]
529    pub lock_time: i32,
530    /// An optional relative locktime, as with Bitcoin transactions.
531    #[prost(int32, tag = "4")]
532    pub relative_lock_time: i32,
533    /// The name of the asset.
534    #[prost(string, tag = "5")]
535    pub tag: ::prost::alloc::string::String,
536    /// The metadata hash of the asset.
537    #[prost(bytes = "vec", tag = "6")]
538    pub meta_hash: ::prost::alloc::vec::Vec<u8>,
539    /// The type of the asset.
540    #[prost(enumeration = "AssetType", tag = "7")]
541    pub r#type: i32,
542    /// The version of the asset.
543    #[prost(enumeration = "AssetVersion", tag = "8")]
544    pub version: i32,
545}
546#[derive(Clone, PartialEq, ::prost::Message)]
547pub struct GroupedAssets {
548    /// A list of assets with the same group key.
549    #[prost(message, repeated, tag = "1")]
550    pub assets: ::prost::alloc::vec::Vec<AssetHumanReadable>,
551}
552#[derive(Clone, PartialEq, ::prost::Message)]
553pub struct ListGroupsResponse {
554    /// The set of assets with a group key.
555    #[prost(map = "string, message", tag = "1")]
556    pub groups: ::std::collections::HashMap<
557        ::prost::alloc::string::String,
558        GroupedAssets,
559    >,
560}
561#[derive(Clone, PartialEq, ::prost::Message)]
562pub struct ListBalancesRequest {
563    /// If the query results should grouped by asset ids, then an optional asset
564    /// filter may be provided to query balance of a specific asset.
565    #[prost(bytes = "vec", tag = "3")]
566    pub asset_filter: ::prost::alloc::vec::Vec<u8>,
567    /// If the query results should be grouped by group keys, then an optional
568    /// group key filter may be provided to query the balance of a specific
569    /// asset group.
570    #[prost(bytes = "vec", tag = "4")]
571    pub group_key_filter: ::prost::alloc::vec::Vec<u8>,
572    /// An option to include previous leased assets in the balances.
573    #[prost(bool, tag = "5")]
574    pub include_leased: bool,
575    /// The script key type to filter the assets by. If not set, only assets with
576    /// a BIP-0086 script key will be returned (which is the equivalent of
577    /// setting script_key_type.explicit_type = SCRIPT_KEY_BIP86). If the type
578    /// is set to SCRIPT_KEY_BURN or SCRIPT_KEY_TOMBSTONE the include_spent flag
579    /// will automatically be set to true, because assets of that type are always
580    /// marked as spent.
581    #[prost(message, optional, tag = "6")]
582    pub script_key_type: ::core::option::Option<ScriptKeyTypeQuery>,
583    #[prost(oneof = "list_balances_request::GroupBy", tags = "1, 2")]
584    pub group_by: ::core::option::Option<list_balances_request::GroupBy>,
585}
586/// Nested message and enum types in `ListBalancesRequest`.
587pub mod list_balances_request {
588    #[derive(Clone, Copy, PartialEq, ::prost::Oneof)]
589    pub enum GroupBy {
590        /// Group results by asset IDs.
591        #[prost(bool, tag = "1")]
592        AssetId(bool),
593        /// Group results by group keys.
594        #[prost(bool, tag = "2")]
595        GroupKey(bool),
596    }
597}
598#[derive(Clone, PartialEq, ::prost::Message)]
599pub struct AssetBalance {
600    /// The base genesis information of an asset. This information never changes.
601    #[prost(message, optional, tag = "1")]
602    pub asset_genesis: ::core::option::Option<GenesisInfo>,
603    /// The balance of the asset owned by the target daemon.
604    #[prost(uint64, tag = "3")]
605    pub balance: u64,
606    /// The group key of the asset (if it belongs to a group).
607    #[prost(bytes = "vec", tag = "4")]
608    pub group_key: ::prost::alloc::vec::Vec<u8>,
609}
610#[derive(Clone, PartialEq, ::prost::Message)]
611pub struct AssetGroupBalance {
612    /// The group key or nil aggregating assets that don't have a group.
613    #[prost(bytes = "vec", tag = "1")]
614    pub group_key: ::prost::alloc::vec::Vec<u8>,
615    /// The total balance of the assets in the group.
616    #[prost(uint64, tag = "2")]
617    pub balance: u64,
618}
619#[derive(Clone, PartialEq, ::prost::Message)]
620pub struct ListBalancesResponse {
621    /// The map of asset balances, where the key is the asset ID and the value
622    /// is the balance of that asset owned by the target daemon. This is only
623    /// set if group_by.asset_id is true in the request.
624    #[prost(map = "string, message", tag = "1")]
625    pub asset_balances: ::std::collections::HashMap<
626        ::prost::alloc::string::String,
627        AssetBalance,
628    >,
629    /// The map of asset group balances, where the key is the group key
630    /// and the value is the balance of that group owned by the target daemon.
631    /// This is only set if group_by.group_key is true in the request.
632    #[prost(map = "string, message", tag = "2")]
633    pub asset_group_balances: ::std::collections::HashMap<
634        ::prost::alloc::string::String,
635        AssetGroupBalance,
636    >,
637    /// This is a count of unconfirmed outgoing transfers. Unconfirmed transfers
638    /// (and the change resulting from them) do not appear in the balance. The
639    /// balance only represents confirmed assets that are owned by the daemon.
640    #[prost(uint64, tag = "3")]
641    pub unconfirmed_transfers: u64,
642}
643#[derive(Clone, PartialEq, ::prost::Message)]
644pub struct ListTransfersRequest {
645    /// anchor_txid specifies the hexadecimal encoded txid string of the anchor
646    /// transaction for which to retrieve transfers. An empty value indicates
647    /// that this parameter should be disregarded in transfer selection.
648    #[prost(string, tag = "1")]
649    pub anchor_txid: ::prost::alloc::string::String,
650}
651#[derive(Clone, PartialEq, ::prost::Message)]
652pub struct ListTransfersResponse {
653    /// The unordered list of outgoing asset transfers.
654    #[prost(message, repeated, tag = "1")]
655    pub transfers: ::prost::alloc::vec::Vec<AssetTransfer>,
656}
657/// ChainHash represents a hash value, typically a double SHA-256 of some data.
658/// Common examples include block hashes and transaction hashes.
659///
660/// This versatile message type is used in various Bitcoin-related messages and
661/// structures, providing two different formats of the same hash to accommodate
662/// both developer and user needs.
663#[derive(Clone, PartialEq, ::prost::Message)]
664pub struct ChainHash {
665    /// The raw hash value in byte format.
666    ///
667    /// This format is optimized for programmatic use, particularly for Go
668    /// developers, enabling easy integration with other RPC calls or binary
669    /// operations.
670    #[prost(bytes = "vec", tag = "1")]
671    pub hash: ::prost::alloc::vec::Vec<u8>,
672    /// The byte-reversed hash value as a hexadecimal string.
673    ///
674    /// This format is intended for human interaction, making it easy to copy,
675    /// paste, and use in contexts like command-line arguments or configuration
676    /// files.
677    #[prost(string, tag = "2")]
678    pub hash_str: ::prost::alloc::string::String,
679}
680#[derive(Clone, PartialEq, ::prost::Message)]
681pub struct AssetTransfer {
682    /// The timestamp of the transfer in UTC Unix time seconds.
683    #[prost(int64, tag = "1")]
684    pub transfer_timestamp: i64,
685    /// The new transaction that commits to the set of Taproot Assets found at
686    /// the above new anchor point. Note that this is in raw byte format, not
687    /// the reversed hex string format that is used for displayed txids. When
688    /// listing assets on the CLI we purposefully use the display format so it
689    /// is easier to copy and paste into other tools.
690    #[prost(bytes = "vec", tag = "2")]
691    pub anchor_tx_hash: ::prost::alloc::vec::Vec<u8>,
692    /// The height hint of the anchor transaction. This is the height at which
693    /// the anchor transaction was published, so the actual inclusion height
694    /// will be greater than this value.
695    #[prost(uint32, tag = "3")]
696    pub anchor_tx_height_hint: u32,
697    /// The total fees paid by the anchor transaction in satoshis.
698    #[prost(int64, tag = "4")]
699    pub anchor_tx_chain_fees: i64,
700    /// Describes the set of spent assets.
701    #[prost(message, repeated, tag = "5")]
702    pub inputs: ::prost::alloc::vec::Vec<TransferInput>,
703    /// Describes the set of newly created asset outputs.
704    #[prost(message, repeated, tag = "6")]
705    pub outputs: ::prost::alloc::vec::Vec<TransferOutput>,
706    /// The block hash of the blockchain block that contains the anchor
707    /// transaction. If this value is unset, the anchor transaction is
708    /// unconfirmed.
709    #[prost(message, optional, tag = "7")]
710    pub anchor_tx_block_hash: ::core::option::Option<ChainHash>,
711    /// The block height of the blockchain block that contains the anchor
712    /// transaction. If the anchor transaction is still unconfirmed, this value
713    /// will be 0.
714    #[prost(uint32, tag = "8")]
715    pub anchor_tx_block_height: u32,
716    /// An optional short label for the transfer. This label can be used to track
717    /// the progress of the transfer via the logs or an event subscription.
718    /// Multiple transfers can share the same label.
719    #[prost(string, tag = "9")]
720    pub label: ::prost::alloc::string::String,
721    /// The L1 transaction that anchors the Taproot Asset commitment where the
722    /// asset resides.
723    #[prost(bytes = "vec", tag = "10")]
724    pub anchor_tx: ::prost::alloc::vec::Vec<u8>,
725}
726#[derive(Clone, PartialEq, ::prost::Message)]
727pub struct TransferInput {
728    /// The old/current location of the Taproot Asset commitment that was spent
729    /// as an input.
730    #[prost(string, tag = "1")]
731    pub anchor_point: ::prost::alloc::string::String,
732    /// The ID of the asset that was spent.
733    #[prost(bytes = "vec", tag = "2")]
734    pub asset_id: ::prost::alloc::vec::Vec<u8>,
735    /// The script key of the asset that was spent.
736    #[prost(bytes = "vec", tag = "3")]
737    pub script_key: ::prost::alloc::vec::Vec<u8>,
738    /// The amount of the asset that was spent.
739    #[prost(uint64, tag = "4")]
740    pub amount: u64,
741}
742#[derive(Clone, PartialEq, ::prost::Message)]
743pub struct TransferOutputAnchor {
744    /// The new location of the Taproot Asset commitment that was created on
745    /// chain.
746    #[prost(string, tag = "1")]
747    pub outpoint: ::prost::alloc::string::String,
748    /// The anchor transaction output's value in satoshis.
749    #[prost(int64, tag = "2")]
750    pub value: i64,
751    /// The anchor transaction output's internal key, which is the Taproot
752    /// internal key of the on-chain output.
753    #[prost(bytes = "vec", tag = "3")]
754    pub internal_key: ::prost::alloc::vec::Vec<u8>,
755    /// The Taproot Asset root commitment hash, which is the root of the
756    /// Taproot Asset commitment tree for the asset that was created.
757    #[prost(bytes = "vec", tag = "4")]
758    pub taproot_asset_root: ::prost::alloc::vec::Vec<u8>,
759    /// The Taproot merkle root hash committed to by the outpoint of this
760    /// output. If there is no Tapscript sibling, this is equal to the Taproot
761    /// Asset root commitment hash.
762    /// If there is a Tapscript sibling, this is the tap branch root hash of the
763    /// Taproot Asset root hash and the tapscript sibling.
764    #[prost(bytes = "vec", tag = "5")]
765    pub merkle_root: ::prost::alloc::vec::Vec<u8>,
766    /// The serialized preimage of a Tapscript sibling, if there was one. If this
767    /// is empty, then the merkle_root hash is equal to the Taproot root hash
768    /// of the anchor output.
769    #[prost(bytes = "vec", tag = "6")]
770    pub tapscript_sibling: ::prost::alloc::vec::Vec<u8>,
771    /// The number of passive assets that were committed to this output.
772    /// Passive assets are assets that are not actively spent, but are instead
773    /// passively carried along with the main asset and re-anchored in the
774    /// anchor output.
775    #[prost(uint32, tag = "7")]
776    pub num_passive_assets: u32,
777    /// The actual output's script, which is the P2TR script for the final
778    /// Taproot output key created by this transfer output.
779    #[prost(bytes = "vec", tag = "8")]
780    pub pk_script: ::prost::alloc::vec::Vec<u8>,
781}
782#[derive(Clone, PartialEq, ::prost::Message)]
783pub struct TransferOutput {
784    /// The transfer output's on-chain anchor information, which contains the
785    /// BTC-level output information that anchors the Taproot Asset commitment
786    /// for this output.
787    #[prost(message, optional, tag = "1")]
788    pub anchor: ::core::option::Option<TransferOutputAnchor>,
789    /// The script key of the asset that was created.
790    #[prost(bytes = "vec", tag = "2")]
791    pub script_key: ::prost::alloc::vec::Vec<u8>,
792    /// Indicates whether the script key is known to the wallet of the lnd node
793    /// connected to the Taproot Asset daemon. If true, the asset will be shown
794    /// in the wallet balance.
795    #[prost(bool, tag = "3")]
796    pub script_key_is_local: bool,
797    /// The amount of the asset that was created in this output.
798    #[prost(uint64, tag = "4")]
799    pub amount: u64,
800    /// The new individual transition proof (not a full proof file) that proves
801    /// the inclusion of the new asset within the new AnchorTx.
802    #[prost(bytes = "vec", tag = "5")]
803    pub new_proof_blob: ::prost::alloc::vec::Vec<u8>,
804    /// The split commitment root hash of the asset that was created in this
805    /// output. This is only set if the asset is a split root output, meaning
806    /// that the asset is a split root output that carries the change from a
807    /// split or a tombstone from a non-interactive full value send output.
808    #[prost(bytes = "vec", tag = "6")]
809    pub split_commit_root_hash: ::prost::alloc::vec::Vec<u8>,
810    /// The type of the output. This is used to distinguish between a simple
811    /// output that is not a split root and does not carry passive assets, and a
812    /// split root output that carries the change from a split or a tombstone
813    /// from a non-interactive full value send output.
814    #[prost(enumeration = "OutputType", tag = "7")]
815    pub output_type: i32,
816    /// The asset version of the output. This is used to determine how the asset
817    /// is encoded in the Taproot Asset commitment tree.
818    #[prost(enumeration = "AssetVersion", tag = "8")]
819    pub asset_version: i32,
820    /// The lock time of the output, which is an optional field that can be set
821    /// to delay the spending of the output until a certain time in the future.
822    #[prost(uint64, tag = "9")]
823    pub lock_time: u64,
824    /// The relative lock time of the output, which is an optional field that
825    /// can be set to delay the spending of the output relative to the block
826    /// height at which the output is confirmed.
827    #[prost(uint64, tag = "10")]
828    pub relative_lock_time: u64,
829    /// The delivery status of the proof associated with this output.
830    #[prost(enumeration = "ProofDeliveryStatus", tag = "11")]
831    pub proof_delivery_status: i32,
832    /// The asset ID of the asset that was created in this output.
833    #[prost(bytes = "vec", tag = "12")]
834    pub asset_id: ::prost::alloc::vec::Vec<u8>,
835    /// The proof courier address that was used to deliver the proof for this
836    /// output.
837    #[prost(string, tag = "13")]
838    pub proof_courier_addr: ::prost::alloc::string::String,
839    /// The Taproot Asset address that was used to create the output. This is
840    /// only set for new outputs for tapd versions that support the address V2
841    /// format. For older versions, this field will be empty.
842    #[prost(string, tag = "14")]
843    pub tap_addr: ::prost::alloc::string::String,
844}
845#[derive(Clone, Copy, PartialEq, ::prost::Message)]
846pub struct StopRequest {}
847#[derive(Clone, Copy, PartialEq, ::prost::Message)]
848pub struct StopResponse {}
849#[derive(Clone, PartialEq, ::prost::Message)]
850pub struct DebugLevelRequest {
851    /// If true, all the valid debug sub-systems will be returned.
852    #[prost(bool, tag = "1")]
853    pub show: bool,
854    /// If set, the debug level for the sub-system will be set to this value.
855    /// Can be one of: "trace", "debug", "info", "warn", "error", "critical",
856    /// "off", to set a global level, optionally followed by a comma-separated
857    /// list of sub-systems to set the level for. For example:
858    /// "debug,TADB=info,UNIV=warn".
859    #[prost(string, tag = "2")]
860    pub level_spec: ::prost::alloc::string::String,
861}
862#[derive(Clone, PartialEq, ::prost::Message)]
863pub struct DebugLevelResponse {
864    /// The list of available logging sub-systems that can be set to a specific
865    /// debug level.
866    #[prost(string, tag = "1")]
867    pub sub_systems: ::prost::alloc::string::String,
868}
869#[derive(Clone, PartialEq, ::prost::Message)]
870pub struct Addr {
871    /// The bech32 encoded Taproot Asset address.
872    #[prost(string, tag = "1")]
873    pub encoded: ::prost::alloc::string::String,
874    /// The asset ID that uniquely identifies the asset. This can be all zeroes
875    /// for V2 addresses that have a group key set.
876    #[prost(bytes = "vec", tag = "2")]
877    pub asset_id: ::prost::alloc::vec::Vec<u8>,
878    /// The type of the asset.
879    #[prost(enumeration = "AssetType", tag = "3")]
880    pub asset_type: i32,
881    /// The total amount of the asset stored in this Taproot Asset UTXO. The
882    /// amount is allowed to be unset for V2 addresses, where the sender will
883    /// post a fragment containing the asset IDs and amounts to the proof
884    /// courier's auth mailbox.
885    #[prost(uint64, tag = "4")]
886    pub amount: u64,
887    /// The group key of the asset group to receive assets for. If this field
888    /// is set, then any asset of the group can be sent to this address. Can only
889    /// be specified for V2 addresses. If this field is set, the asset_id
890    /// field must be empty.
891    #[prost(bytes = "vec", tag = "5")]
892    pub group_key: ::prost::alloc::vec::Vec<u8>,
893    ///
894    /// The specific script key the asset must commit to in order to transfer
895    /// ownership to the creator of the address.
896    #[prost(bytes = "vec", tag = "6")]
897    pub script_key: ::prost::alloc::vec::Vec<u8>,
898    /// The internal key used for the on-chain output.
899    #[prost(bytes = "vec", tag = "7")]
900    pub internal_key: ::prost::alloc::vec::Vec<u8>,
901    ///
902    /// The optional serialized tapscript sibling preimage to use for the receiving
903    /// asset. This is usually empty as it is only needed when there should be an
904    /// additional script path in the Taproot tree alongside the Taproot Asset
905    /// commitment of the asset.
906    #[prost(bytes = "vec", tag = "8")]
907    pub tapscript_sibling: ::prost::alloc::vec::Vec<u8>,
908    ///
909    /// The tweaked internal key that commits to the asset and represents the
910    /// on-chain output key the Bitcoin transaction must send to in order to
911    /// transfer assets described in this address.
912    #[prost(bytes = "vec", tag = "9")]
913    pub taproot_output_key: ::prost::alloc::vec::Vec<u8>,
914    /// The address of the proof courier service used in proof transfer. For V2
915    /// addresses the proof courier address is mandatory and must be a valid auth
916    /// mailbox address (authmailbox+universerpc://host:port).
917    #[prost(string, tag = "10")]
918    pub proof_courier_addr: ::prost::alloc::string::String,
919    /// The asset version of the address.
920    #[prost(enumeration = "AssetVersion", tag = "11")]
921    pub asset_version: i32,
922    /// The version of the address.
923    #[prost(enumeration = "AddrVersion", tag = "12")]
924    pub address_version: i32,
925}
926#[derive(Clone, Copy, PartialEq, ::prost::Message)]
927pub struct QueryAddrRequest {
928    ///
929    /// If set, then only addresses created after this Unix timestamp will be
930    /// returned.
931    #[prost(int64, tag = "1")]
932    pub created_after: i64,
933    ///
934    /// If set, then only addresses created before this Unix timestamp will be
935    /// returned.
936    #[prost(int64, tag = "2")]
937    pub created_before: i64,
938    /// The max number of addresses that should be returned.
939    #[prost(int32, tag = "3")]
940    pub limit: i32,
941    /// The offset from the addresses that should be returned.
942    #[prost(int32, tag = "4")]
943    pub offset: i32,
944}
945#[derive(Clone, PartialEq, ::prost::Message)]
946pub struct QueryAddrResponse {
947    /// The list of addresses that match the query parameters.
948    #[prost(message, repeated, tag = "1")]
949    pub addrs: ::prost::alloc::vec::Vec<Addr>,
950}
951#[derive(Clone, PartialEq, ::prost::Message)]
952pub struct NewAddrRequest {
953    ///
954    /// The asset ID to create the address for. This is required for V0 and V1
955    /// addresses. For V2 addresses, this field is optional and must be empty if the
956    /// group key is set.
957    #[prost(bytes = "vec", tag = "1")]
958    pub asset_id: ::prost::alloc::vec::Vec<u8>,
959    ///
960    /// The number of asset units to be sent to the address. This is required for V0
961    /// and V1 addresses. For V2 addresses, this field is optional and can be left
962    /// at 0 to indicate that the sender can choose the amount of assets to send.
963    #[prost(uint64, tag = "2")]
964    pub amt: u64,
965    ///
966    /// The optional script key that the receiving asset should be locked to. If no
967    /// script key is provided, a normal BIP-86 key will be derived from the
968    /// underlying wallet.
969    ///
970    /// NOTE: The script_key and internal_key fields should either both be set or
971    /// both be empty.
972    #[prost(message, optional, tag = "3")]
973    pub script_key: ::core::option::Option<ScriptKey>,
974    ///
975    /// The optional internal key of the receiving BTC level transaction output on
976    /// which the receiving asset transfers will be committed to. If no internal key
977    /// is provided, a key will be derived from the underlying wallet.
978    ///
979    /// NOTE: The script_key and internal_key fields should either both be set or
980    /// both be empty.
981    #[prost(message, optional, tag = "4")]
982    pub internal_key: ::core::option::Option<KeyDescriptor>,
983    ///
984    /// The optional serialized tapscript sibling preimage to use for the receiving
985    /// asset. This is usually empty as it is only needed when there should be an
986    /// additional script path in the Taproot tree alongside the Taproot Asset
987    /// commitment of the asset.
988    #[prost(bytes = "vec", tag = "5")]
989    pub tapscript_sibling: ::prost::alloc::vec::Vec<u8>,
990    ///
991    /// An optional proof courier address for use in proof transfer. If unspecified,
992    /// the daemon configured default address will be used.
993    #[prost(string, tag = "6")]
994    pub proof_courier_addr: ::prost::alloc::string::String,
995    ///
996    /// The asset version to use when sending/receiving to/from this address.
997    #[prost(enumeration = "AssetVersion", tag = "7")]
998    pub asset_version: i32,
999    ///
1000    /// The version of this address.
1001    #[prost(enumeration = "AddrVersion", tag = "8")]
1002    pub address_version: i32,
1003    ///
1004    /// The group key to receive assets for. This can only be specified for V2
1005    /// addresses. If this field is set, the asset_id field must be empty.
1006    #[prost(bytes = "vec", tag = "9")]
1007    pub group_key: ::prost::alloc::vec::Vec<u8>,
1008    ///
1009    /// If set, the daemon skips the connectivity check to the proof courier service
1010    /// when creating an address. Connection checks currently apply only to certain
1011    /// address schemes. Use this to create addresses while offline.
1012    #[prost(bool, tag = "10")]
1013    pub skip_proof_courier_conn_check: bool,
1014}
1015#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1016pub struct ScriptKeyTypeQuery {
1017    #[prost(oneof = "script_key_type_query::Type", tags = "1, 2")]
1018    pub r#type: ::core::option::Option<script_key_type_query::Type>,
1019}
1020/// Nested message and enum types in `ScriptKeyTypeQuery`.
1021pub mod script_key_type_query {
1022    #[derive(Clone, Copy, PartialEq, ::prost::Oneof)]
1023    pub enum Type {
1024        /// Query for assets of a specific script key type.
1025        #[prost(enumeration = "super::ScriptKeyType", tag = "1")]
1026        ExplicitType(i32),
1027        /// Query for assets with all script key types.
1028        #[prost(bool, tag = "2")]
1029        AllTypes(bool),
1030    }
1031}
1032#[derive(Clone, PartialEq, ::prost::Message)]
1033pub struct ScriptKey {
1034    ///
1035    /// The full Taproot output key the asset is locked to. This is either a BIP-86
1036    /// key if the tap_tweak below is empty, or a key with the tap tweak applied to
1037    /// it.
1038    #[prost(bytes = "vec", tag = "1")]
1039    pub pub_key: ::prost::alloc::vec::Vec<u8>,
1040    ///
1041    /// The key descriptor describing the internal key of the above Taproot key.
1042    #[prost(message, optional, tag = "2")]
1043    pub key_desc: ::core::option::Option<KeyDescriptor>,
1044    ///
1045    /// The optional Taproot tweak to apply to the above internal key. If this is
1046    /// empty then a BIP-86 style tweak is applied to the internal key.
1047    #[prost(bytes = "vec", tag = "3")]
1048    pub tap_tweak: ::prost::alloc::vec::Vec<u8>,
1049    ///
1050    /// The type of the script key. This type is either user-declared when custom
1051    /// script keys are added, or automatically determined by the daemon for
1052    /// standard operations (e.g. BIP-86 keys, burn keys, tombstone keys, channel
1053    /// related keys).
1054    #[prost(enumeration = "ScriptKeyType", tag = "4")]
1055    pub r#type: i32,
1056}
1057#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1058pub struct KeyLocator {
1059    ///
1060    /// The family of key being identified.
1061    #[prost(int32, tag = "1")]
1062    pub key_family: i32,
1063    ///
1064    /// The precise index of the key being identified.
1065    #[prost(int32, tag = "2")]
1066    pub key_index: i32,
1067}
1068#[derive(Clone, PartialEq, ::prost::Message)]
1069pub struct KeyDescriptor {
1070    ///
1071    /// The raw bytes of the key being identified.
1072    #[prost(bytes = "vec", tag = "1")]
1073    pub raw_key_bytes: ::prost::alloc::vec::Vec<u8>,
1074    ///
1075    /// The key locator that identifies which key to use for signing.
1076    #[prost(message, optional, tag = "2")]
1077    pub key_loc: ::core::option::Option<KeyLocator>,
1078}
1079#[derive(Clone, PartialEq, ::prost::Message)]
1080pub struct TapscriptFullTree {
1081    ///
1082    /// The complete, ordered list of all tap leaves of the tree.
1083    #[prost(message, repeated, tag = "1")]
1084    pub all_leaves: ::prost::alloc::vec::Vec<TapLeaf>,
1085}
1086#[derive(Clone, PartialEq, ::prost::Message)]
1087pub struct TapLeaf {
1088    /// The script of the tap leaf.
1089    #[prost(bytes = "vec", tag = "2")]
1090    pub script: ::prost::alloc::vec::Vec<u8>,
1091}
1092#[derive(Clone, PartialEq, ::prost::Message)]
1093pub struct TapBranch {
1094    /// The TapHash of the left child of the root hash of a Tapscript tree.
1095    #[prost(bytes = "vec", tag = "1")]
1096    pub left_taphash: ::prost::alloc::vec::Vec<u8>,
1097    /// The TapHash of the right child of the root hash of a Tapscript tree.
1098    #[prost(bytes = "vec", tag = "2")]
1099    pub right_taphash: ::prost::alloc::vec::Vec<u8>,
1100}
1101#[derive(Clone, PartialEq, ::prost::Message)]
1102pub struct DecodeAddrRequest {
1103    /// The bech32 encoded Taproot Asset address to decode.
1104    #[prost(string, tag = "1")]
1105    pub addr: ::prost::alloc::string::String,
1106}
1107#[derive(Clone, PartialEq, ::prost::Message)]
1108pub struct ProofFile {
1109    /// The raw proof file encoded as bytes. Must be a file and not just an
1110    /// individual mint/transfer proof.
1111    #[prost(bytes = "vec", tag = "1")]
1112    pub raw_proof_file: ::prost::alloc::vec::Vec<u8>,
1113    /// The genesis point of the proof file, which is the asset's genesis
1114    /// transaction outpoint.
1115    #[prost(string, tag = "2")]
1116    pub genesis_point: ::prost::alloc::string::String,
1117}
1118#[derive(Clone, PartialEq, ::prost::Message)]
1119pub struct DecodedProof {
1120    /// The index depth of the decoded proof, with 0 being the latest proof.
1121    #[prost(uint32, tag = "1")]
1122    pub proof_at_depth: u32,
1123    /// The total number of proofs contained in the decoded proof file (this will
1124    /// always be 1 if a single mint/transition proof was given as the raw_proof
1125    /// instead of a file).
1126    #[prost(uint32, tag = "2")]
1127    pub number_of_proofs: u32,
1128    /// The asset referenced in the proof.
1129    #[prost(message, optional, tag = "3")]
1130    pub asset: ::core::option::Option<Asset>,
1131    /// The reveal meta data associated with the proof, if available.
1132    #[prost(message, optional, tag = "4")]
1133    pub meta_reveal: ::core::option::Option<AssetMeta>,
1134    /// The merkle proof for AnchorTx used to prove its
1135    /// inclusion within BlockHeader.
1136    #[prost(bytes = "vec", tag = "5")]
1137    pub tx_merkle_proof: ::prost::alloc::vec::Vec<u8>,
1138    /// The TaprootProof proving the new inclusion of the
1139    /// resulting asset within AnchorTx.
1140    #[prost(bytes = "vec", tag = "6")]
1141    pub inclusion_proof: ::prost::alloc::vec::Vec<u8>,
1142    /// The set of TaprootProofs proving the exclusion of
1143    /// the resulting asset from all other Taproot outputs within AnchorTx.
1144    #[prost(bytes = "vec", repeated, tag = "7")]
1145    pub exclusion_proofs: ::prost::alloc::vec::Vec<::prost::alloc::vec::Vec<u8>>,
1146    /// An optional TaprootProof needed if this asset is
1147    /// the result of a split. SplitRootProof proves inclusion of the root
1148    /// asset of the split.
1149    #[prost(bytes = "vec", tag = "8")]
1150    pub split_root_proof: ::prost::alloc::vec::Vec<u8>,
1151    /// The number of additional nested full proofs for any inputs found within
1152    /// the resulting asset.
1153    #[prost(uint32, tag = "9")]
1154    pub num_additional_inputs: u32,
1155    /// ChallengeWitness is an optional virtual transaction witness that serves
1156    /// as an ownership proof for the asset. If this is non-nil, then it is a
1157    /// valid transfer witness for a 1-input, 1-output virtual transaction that
1158    /// spends the asset in this proof and sends it to the NUMS key, to prove
1159    /// that the creator of the proof is able to produce a valid signature to
1160    /// spend the asset.
1161    #[prost(bytes = "vec", repeated, tag = "10")]
1162    pub challenge_witness: ::prost::alloc::vec::Vec<::prost::alloc::vec::Vec<u8>>,
1163    /// Indicates whether the state transition this proof represents is a burn,
1164    /// meaning that the assets were provably destroyed and can no longer be
1165    /// spent.
1166    #[prost(bool, tag = "11")]
1167    pub is_burn: bool,
1168    /// GenesisReveal is an optional field that is the Genesis information for
1169    /// the asset. This is required for minting proofs.
1170    #[prost(message, optional, tag = "12")]
1171    pub genesis_reveal: ::core::option::Option<GenesisReveal>,
1172    /// GroupKeyReveal is an optional field that includes the information needed
1173    /// to derive the tweaked group key.
1174    #[prost(message, optional, tag = "13")]
1175    pub group_key_reveal: ::core::option::Option<GroupKeyReveal>,
1176    /// AltLeaves represent data used to construct an Asset commitment, that
1177    /// will be inserted in the input anchor Tap commitment. These data-carrying
1178    /// leaves are used for a purpose distinct from representing individual
1179    /// individual Taproot Assets.
1180    #[prost(bytes = "vec", tag = "14")]
1181    pub alt_leaves: ::prost::alloc::vec::Vec<u8>,
1182}
1183#[derive(Clone, PartialEq, ::prost::Message)]
1184pub struct VerifyProofResponse {
1185    /// Whether the proof file was valid or not.
1186    #[prost(bool, tag = "1")]
1187    pub valid: bool,
1188    /// The decoded last proof in the file if the proof file was valid.
1189    #[prost(message, optional, tag = "2")]
1190    pub decoded_proof: ::core::option::Option<DecodedProof>,
1191}
1192#[derive(Clone, PartialEq, ::prost::Message)]
1193pub struct DecodeProofRequest {
1194    /// The raw proof bytes to decode. This can be a full proof file or a single
1195    /// mint/transition proof. If it is a full proof file, the proof_at_depth
1196    /// field will be used to determine which individual proof within the file to
1197    /// decode.
1198    #[prost(bytes = "vec", tag = "1")]
1199    pub raw_proof: ::prost::alloc::vec::Vec<u8>,
1200    /// The index depth of the decoded proof, with 0 being the latest proof. This
1201    /// is ignored if the raw_proof is a single mint/transition proof and not a
1202    /// proof file.
1203    #[prost(uint32, tag = "2")]
1204    pub proof_at_depth: u32,
1205    /// An option to include previous witnesses in decoding.
1206    #[prost(bool, tag = "3")]
1207    pub with_prev_witnesses: bool,
1208    /// An option to attempt to retrieve the meta data associated with the proof.
1209    #[prost(bool, tag = "4")]
1210    pub with_meta_reveal: bool,
1211}
1212#[derive(Clone, PartialEq, ::prost::Message)]
1213pub struct DecodeProofResponse {
1214    /// The decoded, more human-readable proof.
1215    #[prost(message, optional, tag = "1")]
1216    pub decoded_proof: ::core::option::Option<DecodedProof>,
1217}
1218#[derive(Clone, PartialEq, ::prost::Message)]
1219pub struct ExportProofRequest {
1220    /// The asset ID of the asset to export the proof for.
1221    #[prost(bytes = "vec", tag = "1")]
1222    pub asset_id: ::prost::alloc::vec::Vec<u8>,
1223    /// The script key of the asset to export the proof for.
1224    #[prost(bytes = "vec", tag = "2")]
1225    pub script_key: ::prost::alloc::vec::Vec<u8>,
1226    /// The on-chain outpoint of the asset to export the proof for.
1227    #[prost(message, optional, tag = "3")]
1228    pub outpoint: ::core::option::Option<OutPoint>,
1229}
1230#[derive(Clone, PartialEq, ::prost::Message)]
1231pub struct UnpackProofFileRequest {
1232    /// The raw proof file encoded as bytes. Must be a file and not just an
1233    /// individual mint/transfer proof.
1234    #[prost(bytes = "vec", tag = "1")]
1235    pub raw_proof_file: ::prost::alloc::vec::Vec<u8>,
1236}
1237#[derive(Clone, PartialEq, ::prost::Message)]
1238pub struct UnpackProofFileResponse {
1239    /// The individual proofs contained in the proof file, ordered by their
1240    /// appearance within the file (issuance proof first, last known transfer
1241    /// last).
1242    #[prost(bytes = "vec", repeated, tag = "1")]
1243    pub raw_proofs: ::prost::alloc::vec::Vec<::prost::alloc::vec::Vec<u8>>,
1244}
1245#[derive(Clone, PartialEq, ::prost::Message)]
1246pub struct AddrEvent {
1247    /// The time the event was created in unix timestamp seconds.
1248    #[prost(uint64, tag = "1")]
1249    pub creation_time_unix_seconds: u64,
1250    /// The address the event was created for.
1251    #[prost(message, optional, tag = "2")]
1252    pub addr: ::core::option::Option<Addr>,
1253    /// The current status of the event.
1254    #[prost(enumeration = "AddrEventStatus", tag = "3")]
1255    pub status: i32,
1256    /// The outpoint that contains the inbound asset transfer.
1257    #[prost(string, tag = "4")]
1258    pub outpoint: ::prost::alloc::string::String,
1259    ///
1260    /// The amount in satoshis that were transferred on chain along with the asset.
1261    /// This amount is independent of the requested asset amount, which can be
1262    /// looked up on the address.
1263    #[prost(uint64, tag = "5")]
1264    pub utxo_amt_sat: u64,
1265    ///
1266    /// The taproot sibling hash that was used to send to the Taproot output.
1267    #[prost(bytes = "vec", tag = "6")]
1268    pub taproot_sibling: ::prost::alloc::vec::Vec<u8>,
1269    ///
1270    /// The height at which the on-chain output was confirmed. If this is zero, it
1271    /// means the output is unconfirmed.
1272    #[prost(uint32, tag = "7")]
1273    pub confirmation_height: u32,
1274    ///
1275    /// Indicates whether a proof file can be found for the address' asset ID and
1276    /// script key.
1277    #[prost(bool, tag = "8")]
1278    pub has_proof: bool,
1279}
1280#[derive(Clone, PartialEq, ::prost::Message)]
1281pub struct AddrReceivesRequest {
1282    /// Filter receives by a specific address. Leave empty to get all receives.
1283    #[prost(string, tag = "1")]
1284    pub filter_addr: ::prost::alloc::string::String,
1285    /// Filter receives by a specific status. Leave empty to get all receives.
1286    #[prost(enumeration = "AddrEventStatus", tag = "2")]
1287    pub filter_status: i32,
1288    /// Filter receives by creation time greater than or equal to this timestamp.
1289    /// If not set, no start time filtering is applied.
1290    #[prost(uint64, tag = "3")]
1291    pub start_timestamp: u64,
1292    /// Filter receives by creation time less than or equal to this timestamp.
1293    /// If not set, no end time filtering is applied.
1294    #[prost(uint64, tag = "4")]
1295    pub end_timestamp: u64,
1296    /// The number of events to skip.
1297    #[prost(int32, tag = "5")]
1298    pub offset: i32,
1299    /// The max number of events returned.
1300    #[prost(int32, tag = "6")]
1301    pub limit: i32,
1302    /// The direction of the page. Sorted by creation time.
1303    #[prost(enumeration = "SortDirection", tag = "7")]
1304    pub direction: i32,
1305}
1306#[derive(Clone, PartialEq, ::prost::Message)]
1307pub struct AddrReceivesResponse {
1308    /// The events that match the filter criteria.
1309    #[prost(message, repeated, tag = "1")]
1310    pub events: ::prost::alloc::vec::Vec<AddrEvent>,
1311}
1312#[derive(Clone, PartialEq, ::prost::Message)]
1313pub struct SendAssetRequest {
1314    /// The list of TAP addresses to send assets to. The amount to send to each
1315    /// address is determined by the amount specified in the address itself. For
1316    /// V2 addresses that are allowed to not specify an amount, use the
1317    /// addresses_with_amounts list to specify the amount to send to each
1318    /// address. The tap_addrs and addresses_with_amounts lists are mutually
1319    /// exclusive, meaning that if addresses_with_amounts is set, then tap_addrs
1320    /// must be empty, and vice versa.
1321    #[prost(string, repeated, tag = "1")]
1322    pub tap_addrs: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
1323    /// The optional fee rate to use for the minting transaction, in sat/kw.
1324    #[prost(uint32, tag = "2")]
1325    pub fee_rate: u32,
1326    /// An optional short label for the send transfer. This label can be used to
1327    /// track the progress of the transfer via the logs or an event subscription.
1328    /// Multiple transfers can share the same label.
1329    #[prost(string, tag = "3")]
1330    pub label: ::prost::alloc::string::String,
1331    /// A flag to skip the proof courier ping check. This is useful for
1332    /// testing purposes and for forced transfers when the proof courier
1333    /// is not immediately available.
1334    #[prost(bool, tag = "4")]
1335    pub skip_proof_courier_ping_check: bool,
1336    /// A list of addresses and the amounts of asset units to send to them. This
1337    /// must be used for V2 TAP addresses that don't specify an amount in the
1338    /// address itself and allow the sender to choose the amount to send. The
1339    /// tap_addrs and addresses_with_amounts lists are mutually exclusive,
1340    /// meaning that if addresses_with_amounts is set, then tap_addrs must be
1341    /// empty, and vice versa.
1342    #[prost(message, repeated, tag = "5")]
1343    pub addresses_with_amounts: ::prost::alloc::vec::Vec<AddressWithAmount>,
1344}
1345#[derive(Clone, PartialEq, ::prost::Message)]
1346pub struct AddressWithAmount {
1347    /// The TAP address to send assets to.
1348    #[prost(string, tag = "1")]
1349    pub tap_addr: ::prost::alloc::string::String,
1350    /// The amount of asset units to send to the address. This is only used for
1351    /// re-usable V2 addresses that don't specify an amount in the address itself
1352    /// and allow the sender to specify the amount on each send attempt. For V0
1353    /// or V1 addresses, this can be left empty (zero) as the amount is taken
1354    /// from the address itself.
1355    #[prost(uint64, tag = "2")]
1356    pub amount: u64,
1357}
1358#[derive(Clone, PartialEq, ::prost::Message)]
1359pub struct PrevInputAsset {
1360    /// The previous input's anchor point, which is the on-chain outpoint the
1361    /// asset was anchored to.
1362    #[prost(string, tag = "1")]
1363    pub anchor_point: ::prost::alloc::string::String,
1364    /// The asset ID of the asset that was spent as an input.
1365    #[prost(bytes = "vec", tag = "2")]
1366    pub asset_id: ::prost::alloc::vec::Vec<u8>,
1367    /// The script key of the asset that was spent as an input.
1368    #[prost(bytes = "vec", tag = "3")]
1369    pub script_key: ::prost::alloc::vec::Vec<u8>,
1370    /// The amount of the asset that was spent as an input.
1371    #[prost(uint64, tag = "4")]
1372    pub amount: u64,
1373}
1374#[derive(Clone, PartialEq, ::prost::Message)]
1375pub struct SendAssetResponse {
1376    /// The transfer that was created to send assets to one or more addresses.
1377    #[prost(message, optional, tag = "1")]
1378    pub transfer: ::core::option::Option<AssetTransfer>,
1379}
1380#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1381pub struct GetInfoRequest {}
1382#[derive(Clone, PartialEq, ::prost::Message)]
1383pub struct GetInfoResponse {
1384    /// The full version string of the Taproot Asset daemon.
1385    #[prost(string, tag = "1")]
1386    pub version: ::prost::alloc::string::String,
1387    /// The full version string of the LND node that this daemon is connected to.
1388    #[prost(string, tag = "2")]
1389    pub lnd_version: ::prost::alloc::string::String,
1390    /// The network this daemon is connected to, e.g. "mainnet", "testnet", or
1391    /// any other supported network.
1392    #[prost(string, tag = "3")]
1393    pub network: ::prost::alloc::string::String,
1394    /// The public key of the LND node that this daemon is connected to.
1395    #[prost(string, tag = "4")]
1396    pub lnd_identity_pubkey: ::prost::alloc::string::String,
1397    /// The alias of the LND node that this daemon is connected to.
1398    #[prost(string, tag = "5")]
1399    pub node_alias: ::prost::alloc::string::String,
1400    /// The current block height as seen by the LND node this daemon is
1401    /// connected to.
1402    #[prost(uint32, tag = "6")]
1403    pub block_height: u32,
1404    /// The current block hash as seen by the LND node this daemon is connected
1405    /// to.
1406    #[prost(string, tag = "7")]
1407    pub block_hash: ::prost::alloc::string::String,
1408    /// Whether the LND node this daemon is connected to is synced to the
1409    /// Bitcoin chain.
1410    #[prost(bool, tag = "8")]
1411    pub sync_to_chain: bool,
1412}
1413#[derive(Clone, PartialEq, ::prost::Message)]
1414pub struct FetchAssetMetaRequest {
1415    #[prost(oneof = "fetch_asset_meta_request::Asset", tags = "1, 2, 3, 4")]
1416    pub asset: ::core::option::Option<fetch_asset_meta_request::Asset>,
1417}
1418/// Nested message and enum types in `FetchAssetMetaRequest`.
1419pub mod fetch_asset_meta_request {
1420    #[derive(Clone, PartialEq, ::prost::Oneof)]
1421    pub enum Asset {
1422        /// The asset ID of the asset to fetch the meta for.
1423        #[prost(bytes, tag = "1")]
1424        AssetId(::prost::alloc::vec::Vec<u8>),
1425        /// The 32-byte meta hash of the asset meta.
1426        #[prost(bytes, tag = "2")]
1427        MetaHash(::prost::alloc::vec::Vec<u8>),
1428        /// The hex encoded asset ID of the asset to fetch the meta for.
1429        #[prost(string, tag = "3")]
1430        AssetIdStr(::prost::alloc::string::String),
1431        /// The hex encoded meta hash of the asset meta.
1432        #[prost(string, tag = "4")]
1433        MetaHashStr(::prost::alloc::string::String),
1434    }
1435}
1436#[derive(Clone, PartialEq, ::prost::Message)]
1437pub struct FetchAssetMetaResponse {
1438    ///
1439    /// The raw data of the asset meta data. Based on the type below, this may be
1440    /// structured data such as a text file or PDF. The size of the data is limited
1441    /// to 1MiB.
1442    #[prost(bytes = "vec", tag = "1")]
1443    pub data: ::prost::alloc::vec::Vec<u8>,
1444    /// The type of the asset meta data.
1445    #[prost(enumeration = "AssetMetaType", tag = "2")]
1446    pub r#type: i32,
1447    ///
1448    /// The hash of the meta. This is the hash of the TLV serialization of the meta
1449    /// itself.
1450    #[prost(bytes = "vec", tag = "3")]
1451    pub meta_hash: ::prost::alloc::vec::Vec<u8>,
1452    ///
1453    /// A map of unknown odd TLV types that were encountered during asset meta data
1454    /// decoding.
1455    #[prost(map = "uint64, bytes", tag = "4")]
1456    pub unknown_odd_types: ::std::collections::HashMap<
1457        u64,
1458        ::prost::alloc::vec::Vec<u8>,
1459    >,
1460    ///
1461    /// The decimal display value of the asset. This is used to determine the number
1462    /// of decimal places to display when presenting the asset amount to the user.
1463    #[prost(uint32, tag = "5")]
1464    pub decimal_display: u32,
1465    ///
1466    /// Boolean flag indicating whether the asset-group issuer publishes
1467    /// universe-supply commitments to the canonical universe set.
1468    #[prost(bool, tag = "6")]
1469    pub universe_commitments: bool,
1470    ///
1471    /// List of canonical universe URLs where the asset-group issuer publishes
1472    /// asset-related proofs.
1473    #[prost(string, repeated, tag = "7")]
1474    pub canonical_universe_urls: ::prost::alloc::vec::Vec<
1475        ::prost::alloc::string::String,
1476    >,
1477    ///
1478    /// The public key that is used to verify universe supply commitment related
1479    /// on-chain outputs and proofs.
1480    #[prost(bytes = "vec", tag = "8")]
1481    pub delegation_key: ::prost::alloc::vec::Vec<u8>,
1482}
1483#[derive(Clone, PartialEq, ::prost::Message)]
1484pub struct BurnAssetRequest {
1485    /// The number of asset units to burn. This must be greater than zero.
1486    #[prost(uint64, tag = "3")]
1487    pub amount_to_burn: u64,
1488    /// A safety check to ensure the user is aware of the destructive nature of
1489    /// the burn. This needs to be set to the value "assets will be destroyed"
1490    /// for the burn to succeed.
1491    #[prost(string, tag = "4")]
1492    pub confirmation_text: ::prost::alloc::string::String,
1493    /// A note that may contain user defined metadata related to this burn.
1494    #[prost(string, tag = "5")]
1495    pub note: ::prost::alloc::string::String,
1496    #[prost(oneof = "burn_asset_request::Asset", tags = "1, 2")]
1497    pub asset: ::core::option::Option<burn_asset_request::Asset>,
1498}
1499/// Nested message and enum types in `BurnAssetRequest`.
1500pub mod burn_asset_request {
1501    #[derive(Clone, PartialEq, ::prost::Oneof)]
1502    pub enum Asset {
1503        /// The asset ID of the asset to burn units of.
1504        #[prost(bytes, tag = "1")]
1505        AssetId(::prost::alloc::vec::Vec<u8>),
1506        /// The hex encoded asset ID of the asset to burn units of.
1507        #[prost(string, tag = "2")]
1508        AssetIdStr(::prost::alloc::string::String),
1509    }
1510}
1511#[derive(Clone, PartialEq, ::prost::Message)]
1512pub struct BurnAssetResponse {
1513    /// The asset transfer that contains the asset burn as an output.
1514    #[prost(message, optional, tag = "1")]
1515    pub burn_transfer: ::core::option::Option<AssetTransfer>,
1516    /// The burn transition proof for the asset burn output.
1517    #[prost(message, optional, tag = "2")]
1518    pub burn_proof: ::core::option::Option<DecodedProof>,
1519}
1520#[derive(Clone, PartialEq, ::prost::Message)]
1521pub struct ListBurnsRequest {
1522    /// The asset id of the burnt asset.
1523    #[prost(bytes = "vec", tag = "1")]
1524    pub asset_id: ::prost::alloc::vec::Vec<u8>,
1525    /// The tweaked group key of the group this asset belongs to.
1526    #[prost(bytes = "vec", tag = "3")]
1527    pub tweaked_group_key: ::prost::alloc::vec::Vec<u8>,
1528    /// The txid of the transaction that the burn was anchored to.
1529    #[prost(bytes = "vec", tag = "4")]
1530    pub anchor_txid: ::prost::alloc::vec::Vec<u8>,
1531}
1532#[derive(Clone, PartialEq, ::prost::Message)]
1533pub struct AssetBurn {
1534    /// A note that may contain user defined metadata related to this burn.
1535    #[prost(string, tag = "1")]
1536    pub note: ::prost::alloc::string::String,
1537    /// The asset id of the burnt asset.
1538    #[prost(bytes = "vec", tag = "2")]
1539    pub asset_id: ::prost::alloc::vec::Vec<u8>,
1540    /// The tweaked group key of the group this asset belongs to.
1541    #[prost(bytes = "vec", tag = "3")]
1542    pub tweaked_group_key: ::prost::alloc::vec::Vec<u8>,
1543    /// The amount of burnt assets.
1544    #[prost(uint64, tag = "4")]
1545    pub amount: u64,
1546    /// The txid of the transaction that the burn was anchored to.
1547    #[prost(bytes = "vec", tag = "5")]
1548    pub anchor_txid: ::prost::alloc::vec::Vec<u8>,
1549}
1550#[derive(Clone, PartialEq, ::prost::Message)]
1551pub struct ListBurnsResponse {
1552    /// The list of asset burns that match the query parameters.
1553    #[prost(message, repeated, tag = "1")]
1554    pub burns: ::prost::alloc::vec::Vec<AssetBurn>,
1555}
1556#[derive(Clone, PartialEq, ::prost::Message)]
1557pub struct SubscribeReceiveEventsRequest {
1558    /// Filter receives by a specific address. Leave empty to get all receive
1559    /// events for all addresses.
1560    #[prost(string, tag = "1")]
1561    pub filter_addr: ::prost::alloc::string::String,
1562    /// The start time as a Unix timestamp in microseconds. If not set (default
1563    /// value 0), the daemon will start streaming events from the current time.
1564    #[prost(int64, tag = "2")]
1565    pub start_timestamp: i64,
1566}
1567#[derive(Clone, PartialEq, ::prost::Message)]
1568pub struct ReceiveEvent {
1569    /// Event creation timestamp (Unix timestamp in microseconds).
1570    #[prost(int64, tag = "1")]
1571    pub timestamp: i64,
1572    /// The address that received the asset.
1573    #[prost(message, optional, tag = "2")]
1574    pub address: ::core::option::Option<Addr>,
1575    /// The outpoint of the transaction that was used to receive the asset.
1576    #[prost(string, tag = "3")]
1577    pub outpoint: ::prost::alloc::string::String,
1578    /// The status of the event. If error below is set, then the status is the
1579    /// state that lead to the error during its execution.
1580    #[prost(enumeration = "AddrEventStatus", tag = "4")]
1581    pub status: i32,
1582    /// The height of the block the asset receive transaction was mined in. This
1583    /// is only set if the status is ADDR_EVENT_STATUS_TRANSACTION_CONFIRMED or
1584    /// later.
1585    #[prost(uint32, tag = "5")]
1586    pub confirmation_height: u32,
1587    /// An optional error, indicating that executing the status above failed.
1588    #[prost(string, tag = "6")]
1589    pub error: ::prost::alloc::string::String,
1590}
1591#[derive(Clone, PartialEq, ::prost::Message)]
1592pub struct SubscribeSendEventsRequest {
1593    /// Filter send events by a specific recipient script key. Leave empty to get
1594    /// all receive events for all parcels.
1595    #[prost(bytes = "vec", tag = "1")]
1596    pub filter_script_key: ::prost::alloc::vec::Vec<u8>,
1597    /// Filter send events by a specific label. Leave empty to not filter by
1598    /// transfer label.
1599    #[prost(string, tag = "2")]
1600    pub filter_label: ::prost::alloc::string::String,
1601    /// The start time as a Unix timestamp in microseconds. If not set (default
1602    /// value 0), the daemon will start streaming events from the current time.
1603    #[prost(int64, tag = "3")]
1604    pub start_timestamp: i64,
1605}
1606#[derive(Clone, PartialEq, ::prost::Message)]
1607pub struct SendEvent {
1608    /// Execute timestamp (Unix timestamp in microseconds).
1609    #[prost(int64, tag = "1")]
1610    pub timestamp: i64,
1611    /// The send state that was executed successfully. If error below is set,
1612    /// then the send_state is the state that lead to the error during its
1613    /// execution.
1614    #[prost(string, tag = "2")]
1615    pub send_state: ::prost::alloc::string::String,
1616    /// The type of the outbound send parcel.
1617    #[prost(enumeration = "ParcelType", tag = "3")]
1618    pub parcel_type: i32,
1619    /// The list of addresses the parcel sends to (recipient addresses only, not
1620    /// including change going back to own wallet). This is only set for parcels
1621    /// of type PARCEL_TYPE_ADDRESS.
1622    #[prost(message, repeated, tag = "4")]
1623    pub addresses: ::prost::alloc::vec::Vec<Addr>,
1624    /// The virtual packets that are part of the parcel.
1625    #[prost(bytes = "vec", repeated, tag = "5")]
1626    pub virtual_packets: ::prost::alloc::vec::Vec<::prost::alloc::vec::Vec<u8>>,
1627    /// The passive virtual packets that are carried along with the parcel. This
1628    /// is empty if there were no other assets in the input commitment that is
1629    /// being spent with the "active" virtual packets above.
1630    #[prost(bytes = "vec", repeated, tag = "6")]
1631    pub passive_virtual_packets: ::prost::alloc::vec::Vec<::prost::alloc::vec::Vec<u8>>,
1632    /// The Bitcoin on-chain anchor transaction that commits the sent assets
1633    /// on-chain. This is only set after the send state SEND_STATE_ANCHOR_SIGN.
1634    #[prost(message, optional, tag = "7")]
1635    pub anchor_transaction: ::core::option::Option<AnchorTransaction>,
1636    /// The final transfer as it will be stored in the database. This is only set
1637    /// after the send state SEND_STATE_LOG_COMMITMENT.
1638    #[prost(message, optional, tag = "8")]
1639    pub transfer: ::core::option::Option<AssetTransfer>,
1640    /// An optional error, indicating that executing the send_state failed.
1641    #[prost(string, tag = "9")]
1642    pub error: ::prost::alloc::string::String,
1643    /// The label of the transfer.
1644    #[prost(string, tag = "10")]
1645    pub transfer_label: ::prost::alloc::string::String,
1646    /// The next send state that will be executed.
1647    #[prost(string, tag = "11")]
1648    pub next_send_state: ::prost::alloc::string::String,
1649}
1650#[derive(Clone, PartialEq, ::prost::Message)]
1651pub struct AnchorTransaction {
1652    /// The on-chain anchor transaction PSBT packet that was created by the
1653    /// daemon.
1654    #[prost(bytes = "vec", tag = "1")]
1655    pub anchor_psbt: ::prost::alloc::vec::Vec<u8>,
1656    ///
1657    /// The index of the (added) change output or -1 if no change was left over.
1658    #[prost(int32, tag = "2")]
1659    pub change_output_index: i32,
1660    ///
1661    /// The total number of satoshis in on-chain fees paid by the anchor
1662    /// transaction.
1663    #[prost(int64, tag = "3")]
1664    pub chain_fees_sats: i64,
1665    ///
1666    /// The fee rate in sat/kWU that was targeted by the anchor transaction.
1667    #[prost(int32, tag = "4")]
1668    pub target_fee_rate_sat_kw: i32,
1669    ///
1670    /// The list of UTXO lock leases that were acquired for the inputs in the funded
1671    /// PSBT packet from lnd. Only inputs added to the PSBT by this RPC are locked,
1672    /// inputs that were already present in the PSBT are not locked.
1673    #[prost(message, repeated, tag = "5")]
1674    pub lnd_locked_utxos: ::prost::alloc::vec::Vec<OutPoint>,
1675    ///
1676    /// The final, signed anchor transaction that was broadcast to the network.
1677    #[prost(bytes = "vec", tag = "6")]
1678    pub final_tx: ::prost::alloc::vec::Vec<u8>,
1679}
1680#[derive(Clone, PartialEq, ::prost::Message)]
1681pub struct RegisterTransferRequest {
1682    /// The asset ID of the asset to register the transfer for.
1683    #[prost(bytes = "vec", tag = "1")]
1684    pub asset_id: ::prost::alloc::vec::Vec<u8>,
1685    /// The optional group key of the asset to register the transfer for.
1686    #[prost(bytes = "vec", tag = "2")]
1687    pub group_key: ::prost::alloc::vec::Vec<u8>,
1688    /// The script key of the asset to register the transfer for.
1689    #[prost(bytes = "vec", tag = "3")]
1690    pub script_key: ::prost::alloc::vec::Vec<u8>,
1691    /// The outpoint of the transaction that was used to receive the asset.
1692    #[prost(message, optional, tag = "4")]
1693    pub outpoint: ::core::option::Option<OutPoint>,
1694}
1695#[derive(Clone, PartialEq, ::prost::Message)]
1696pub struct RegisterTransferResponse {
1697    /// The asset transfer that was registered.
1698    #[prost(message, optional, tag = "1")]
1699    pub registered_asset: ::core::option::Option<Asset>,
1700}
1701#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1702#[repr(i32)]
1703pub enum AssetType {
1704    ///
1705    /// Indicates that an asset is capable of being split/merged, with each of the
1706    /// units being fungible, even across a key asset ID boundary (assuming the
1707    /// key group is the same).
1708    Normal = 0,
1709    ///
1710    /// Indicates that an asset is a collectible, meaning that each of the other
1711    /// items under the same key group are not fully fungible with each other.
1712    /// Collectibles also cannot be split or merged.
1713    Collectible = 1,
1714}
1715impl AssetType {
1716    /// String value of the enum field names used in the ProtoBuf definition.
1717    ///
1718    /// The values are not transformed in any way and thus are considered stable
1719    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1720    pub fn as_str_name(&self) -> &'static str {
1721        match self {
1722            Self::Normal => "NORMAL",
1723            Self::Collectible => "COLLECTIBLE",
1724        }
1725    }
1726    /// Creates an enum from field names used in the ProtoBuf definition.
1727    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1728        match value {
1729            "NORMAL" => Some(Self::Normal),
1730            "COLLECTIBLE" => Some(Self::Collectible),
1731            _ => None,
1732        }
1733    }
1734}
1735#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1736#[repr(i32)]
1737pub enum AssetMetaType {
1738    ///
1739    /// Opaque is used for asset meta blobs that have no true structure and instead
1740    /// should be interpreted as opaque blobs.
1741    MetaTypeOpaque = 0,
1742    ///
1743    /// JSON is used for asset meta blobs that are to be interpreted as valid JSON
1744    /// strings.
1745    MetaTypeJson = 1,
1746}
1747impl AssetMetaType {
1748    /// String value of the enum field names used in the ProtoBuf definition.
1749    ///
1750    /// The values are not transformed in any way and thus are considered stable
1751    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1752    pub fn as_str_name(&self) -> &'static str {
1753        match self {
1754            Self::MetaTypeOpaque => "META_TYPE_OPAQUE",
1755            Self::MetaTypeJson => "META_TYPE_JSON",
1756        }
1757    }
1758    /// Creates an enum from field names used in the ProtoBuf definition.
1759    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1760        match value {
1761            "META_TYPE_OPAQUE" => Some(Self::MetaTypeOpaque),
1762            "META_TYPE_JSON" => Some(Self::MetaTypeJson),
1763            _ => None,
1764        }
1765    }
1766}
1767#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1768#[repr(i32)]
1769pub enum AssetVersion {
1770    /// ASSET_VERSION_V0 is the default asset version. This version will include
1771    /// the witness vector in the leaf for a tap commitment.
1772    V0 = 0,
1773    /// ASSET_VERSION_V1 is the asset version that leaves out the witness vector
1774    /// from the MS-SMT leaf encoding.
1775    V1 = 1,
1776}
1777impl AssetVersion {
1778    /// String value of the enum field names used in the ProtoBuf definition.
1779    ///
1780    /// The values are not transformed in any way and thus are considered stable
1781    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1782    pub fn as_str_name(&self) -> &'static str {
1783        match self {
1784            Self::V0 => "ASSET_VERSION_V0",
1785            Self::V1 => "ASSET_VERSION_V1",
1786        }
1787    }
1788    /// Creates an enum from field names used in the ProtoBuf definition.
1789    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1790        match value {
1791            "ASSET_VERSION_V0" => Some(Self::V0),
1792            "ASSET_VERSION_V1" => Some(Self::V1),
1793            _ => None,
1794        }
1795    }
1796}
1797#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1798#[repr(i32)]
1799pub enum OutputType {
1800    /// OUTPUT_TYPE_SIMPLE is a plain full-value or split output that is not a
1801    /// split root and does not carry passive assets. In case of a split, the
1802    /// asset of this output has a split commitment.
1803    Simple = 0,
1804    /// OUTPUT_TYPE_SPLIT_ROOT is a split root output that carries the change
1805    /// from a split or a tombstone from a non-interactive full value send
1806    /// output. In either case, the asset of this output has a tx witness.
1807    SplitRoot = 1,
1808}
1809impl OutputType {
1810    /// String value of the enum field names used in the ProtoBuf definition.
1811    ///
1812    /// The values are not transformed in any way and thus are considered stable
1813    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1814    pub fn as_str_name(&self) -> &'static str {
1815        match self {
1816            Self::Simple => "OUTPUT_TYPE_SIMPLE",
1817            Self::SplitRoot => "OUTPUT_TYPE_SPLIT_ROOT",
1818        }
1819    }
1820    /// Creates an enum from field names used in the ProtoBuf definition.
1821    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1822        match value {
1823            "OUTPUT_TYPE_SIMPLE" => Some(Self::Simple),
1824            "OUTPUT_TYPE_SPLIT_ROOT" => Some(Self::SplitRoot),
1825            _ => None,
1826        }
1827    }
1828}
1829/// ProofDeliveryStatus is an enum that describes the status of the delivery of
1830/// a proof associated with an asset transfer output.
1831#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1832#[repr(i32)]
1833pub enum ProofDeliveryStatus {
1834    /// Delivery is not applicable; the proof will not be delivered.
1835    NotApplicable = 0,
1836    /// The proof has been successfully delivered.
1837    Complete = 1,
1838    /// The proof is pending delivery. This status indicates that the proof has
1839    /// not yet been delivered successfully. One or more attempts at proof
1840    /// delivery may have been made.
1841    Pending = 2,
1842}
1843impl ProofDeliveryStatus {
1844    /// String value of the enum field names used in the ProtoBuf definition.
1845    ///
1846    /// The values are not transformed in any way and thus are considered stable
1847    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1848    pub fn as_str_name(&self) -> &'static str {
1849        match self {
1850            Self::NotApplicable => "PROOF_DELIVERY_STATUS_NOT_APPLICABLE",
1851            Self::Complete => "PROOF_DELIVERY_STATUS_COMPLETE",
1852            Self::Pending => "PROOF_DELIVERY_STATUS_PENDING",
1853        }
1854    }
1855    /// Creates an enum from field names used in the ProtoBuf definition.
1856    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1857        match value {
1858            "PROOF_DELIVERY_STATUS_NOT_APPLICABLE" => Some(Self::NotApplicable),
1859            "PROOF_DELIVERY_STATUS_COMPLETE" => Some(Self::Complete),
1860            "PROOF_DELIVERY_STATUS_PENDING" => Some(Self::Pending),
1861            _ => None,
1862        }
1863    }
1864}
1865#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1866#[repr(i32)]
1867pub enum AddrVersion {
1868    /// ADDR_VERSION_UNSPECIFIED is the default value for an address version in
1869    /// an RPC message. It is unmarshalled to the latest address version.
1870    Unspecified = 0,
1871    /// ADDR_VERSION_V0 is the initial address version.
1872    V0 = 1,
1873    /// ADDR_VERSION_V1 is the address version that uses V2 Taproot Asset
1874    /// commitments.
1875    V1 = 2,
1876    /// ADDR_VERSION_V2 is the address version that supports sending grouped
1877    /// assets and require the new auth mailbox proof courier address format.
1878    V2 = 3,
1879}
1880impl AddrVersion {
1881    /// String value of the enum field names used in the ProtoBuf definition.
1882    ///
1883    /// The values are not transformed in any way and thus are considered stable
1884    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1885    pub fn as_str_name(&self) -> &'static str {
1886        match self {
1887            Self::Unspecified => "ADDR_VERSION_UNSPECIFIED",
1888            Self::V0 => "ADDR_VERSION_V0",
1889            Self::V1 => "ADDR_VERSION_V1",
1890            Self::V2 => "ADDR_VERSION_V2",
1891        }
1892    }
1893    /// Creates an enum from field names used in the ProtoBuf definition.
1894    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1895        match value {
1896            "ADDR_VERSION_UNSPECIFIED" => Some(Self::Unspecified),
1897            "ADDR_VERSION_V0" => Some(Self::V0),
1898            "ADDR_VERSION_V1" => Some(Self::V1),
1899            "ADDR_VERSION_V2" => Some(Self::V2),
1900            _ => None,
1901        }
1902    }
1903}
1904#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1905#[repr(i32)]
1906pub enum ScriptKeyType {
1907    ///
1908    /// The type of script key is not known. This should only be stored for assets
1909    /// where we don't know the internal key of the script key (e.g. for imported
1910    /// proofs).
1911    ScriptKeyUnknown = 0,
1912    ///
1913    /// The script key is a normal BIP-86 key. This means that the internal key is
1914    /// turned into a Taproot output key by applying a BIP-86 tweak to it.
1915    ScriptKeyBip86 = 1,
1916    ///
1917    /// The script key is a key that contains a script path that is defined by the
1918    /// user and is therefore external to the tapd wallet. Spending this key
1919    /// requires providing a specific witness and must be signed through the vPSBT
1920    /// signing flow.
1921    ScriptKeyScriptPathExternal = 2,
1922    ///
1923    /// The script key is a specific un-spendable key that indicates a burnt asset.
1924    /// Assets with this key type can never be spent again, as a burn key is a
1925    /// tweaked NUMS key that nobody knows the private key for.
1926    ScriptKeyBurn = 3,
1927    ///
1928    /// The script key is a specific un-spendable key that indicates a tombstone
1929    /// output. This is only the case for zero-value assets that result from a
1930    /// non-interactive (TAP address) send where no change was left over.
1931    ScriptKeyTombstone = 4,
1932    ///
1933    /// The script key is used for an asset that resides within a Taproot Asset
1934    /// Channel. That means the script key is either a funding key (OP_TRUE), a
1935    /// commitment output key (to_local, to_remote, htlc), or a HTLC second-level
1936    /// transaction output key. Keys related to channels are not shown in asset
1937    /// balances (unless specifically requested) and are never used for coin
1938    /// selection.
1939    ScriptKeyChannel = 5,
1940    ///
1941    /// The script key is derived using the asset ID and a single leaf that contains
1942    /// an un-spendable Pedersen commitment key
1943    /// `(OP_CHECKSIG <NUMS_key + asset_id * G>)`. This can be used to create
1944    /// unique script keys for each virtual packet in the fragment, to avoid proof
1945    /// collisions in the universe, where the script keys should be spendable by
1946    /// a hardware wallet that only supports miniscript policies for signing P2TR
1947    /// outputs.
1948    ScriptKeyUniquePedersen = 6,
1949}
1950impl ScriptKeyType {
1951    /// String value of the enum field names used in the ProtoBuf definition.
1952    ///
1953    /// The values are not transformed in any way and thus are considered stable
1954    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1955    pub fn as_str_name(&self) -> &'static str {
1956        match self {
1957            Self::ScriptKeyUnknown => "SCRIPT_KEY_UNKNOWN",
1958            Self::ScriptKeyBip86 => "SCRIPT_KEY_BIP86",
1959            Self::ScriptKeyScriptPathExternal => "SCRIPT_KEY_SCRIPT_PATH_EXTERNAL",
1960            Self::ScriptKeyBurn => "SCRIPT_KEY_BURN",
1961            Self::ScriptKeyTombstone => "SCRIPT_KEY_TOMBSTONE",
1962            Self::ScriptKeyChannel => "SCRIPT_KEY_CHANNEL",
1963            Self::ScriptKeyUniquePedersen => "SCRIPT_KEY_UNIQUE_PEDERSEN",
1964        }
1965    }
1966    /// Creates an enum from field names used in the ProtoBuf definition.
1967    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1968        match value {
1969            "SCRIPT_KEY_UNKNOWN" => Some(Self::ScriptKeyUnknown),
1970            "SCRIPT_KEY_BIP86" => Some(Self::ScriptKeyBip86),
1971            "SCRIPT_KEY_SCRIPT_PATH_EXTERNAL" => Some(Self::ScriptKeyScriptPathExternal),
1972            "SCRIPT_KEY_BURN" => Some(Self::ScriptKeyBurn),
1973            "SCRIPT_KEY_TOMBSTONE" => Some(Self::ScriptKeyTombstone),
1974            "SCRIPT_KEY_CHANNEL" => Some(Self::ScriptKeyChannel),
1975            "SCRIPT_KEY_UNIQUE_PEDERSEN" => Some(Self::ScriptKeyUniquePedersen),
1976            _ => None,
1977        }
1978    }
1979}
1980#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1981#[repr(i32)]
1982pub enum AddrEventStatus {
1983    Unknown = 0,
1984    TransactionDetected = 1,
1985    TransactionConfirmed = 2,
1986    ProofReceived = 3,
1987    Completed = 4,
1988}
1989impl AddrEventStatus {
1990    /// String value of the enum field names used in the ProtoBuf definition.
1991    ///
1992    /// The values are not transformed in any way and thus are considered stable
1993    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1994    pub fn as_str_name(&self) -> &'static str {
1995        match self {
1996            Self::Unknown => "ADDR_EVENT_STATUS_UNKNOWN",
1997            Self::TransactionDetected => "ADDR_EVENT_STATUS_TRANSACTION_DETECTED",
1998            Self::TransactionConfirmed => "ADDR_EVENT_STATUS_TRANSACTION_CONFIRMED",
1999            Self::ProofReceived => "ADDR_EVENT_STATUS_PROOF_RECEIVED",
2000            Self::Completed => "ADDR_EVENT_STATUS_COMPLETED",
2001        }
2002    }
2003    /// Creates an enum from field names used in the ProtoBuf definition.
2004    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2005        match value {
2006            "ADDR_EVENT_STATUS_UNKNOWN" => Some(Self::Unknown),
2007            "ADDR_EVENT_STATUS_TRANSACTION_DETECTED" => Some(Self::TransactionDetected),
2008            "ADDR_EVENT_STATUS_TRANSACTION_CONFIRMED" => Some(Self::TransactionConfirmed),
2009            "ADDR_EVENT_STATUS_PROOF_RECEIVED" => Some(Self::ProofReceived),
2010            "ADDR_EVENT_STATUS_COMPLETED" => Some(Self::Completed),
2011            _ => None,
2012        }
2013    }
2014}
2015#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2016#[repr(i32)]
2017pub enum SendState {
2018    /// Input coin selection to pick out which asset inputs should be spent is
2019    /// executed during this state.
2020    VirtualInputSelect = 0,
2021    /// The virtual transaction is signed during this state.
2022    VirtualSign = 1,
2023    /// The Bitcoin anchor transaction is signed during this state.
2024    AnchorSign = 2,
2025    /// The outbound packet is written to the database during this state,
2026    /// including the partial proof suffixes. Only parcels that complete this
2027    /// state can be resumed on restart.
2028    LogCommitment = 3,
2029    /// The Bitcoin anchor transaction is broadcast to the network during this
2030    /// state.
2031    Broadcast = 4,
2032    /// The on-chain anchor transaction needs to reach at least 1 confirmation.
2033    /// This state waits for the confirmation.
2034    WaitConfirmation = 5,
2035    /// The anchor transaction was confirmed in a block and the full proofs can
2036    /// now be constructed during this stage.
2037    StoreProofs = 6,
2038    /// The full proofs are sent to the recipient(s) with the proof courier
2039    /// service during this state.
2040    TransferProofs = 7,
2041    /// The send state machine has completed the send process.
2042    Completed = 8,
2043}
2044impl SendState {
2045    /// String value of the enum field names used in the ProtoBuf definition.
2046    ///
2047    /// The values are not transformed in any way and thus are considered stable
2048    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2049    pub fn as_str_name(&self) -> &'static str {
2050        match self {
2051            Self::VirtualInputSelect => "SEND_STATE_VIRTUAL_INPUT_SELECT",
2052            Self::VirtualSign => "SEND_STATE_VIRTUAL_SIGN",
2053            Self::AnchorSign => "SEND_STATE_ANCHOR_SIGN",
2054            Self::LogCommitment => "SEND_STATE_LOG_COMMITMENT",
2055            Self::Broadcast => "SEND_STATE_BROADCAST",
2056            Self::WaitConfirmation => "SEND_STATE_WAIT_CONFIRMATION",
2057            Self::StoreProofs => "SEND_STATE_STORE_PROOFS",
2058            Self::TransferProofs => "SEND_STATE_TRANSFER_PROOFS",
2059            Self::Completed => "SEND_STATE_COMPLETED",
2060        }
2061    }
2062    /// Creates an enum from field names used in the ProtoBuf definition.
2063    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2064        match value {
2065            "SEND_STATE_VIRTUAL_INPUT_SELECT" => Some(Self::VirtualInputSelect),
2066            "SEND_STATE_VIRTUAL_SIGN" => Some(Self::VirtualSign),
2067            "SEND_STATE_ANCHOR_SIGN" => Some(Self::AnchorSign),
2068            "SEND_STATE_LOG_COMMITMENT" => Some(Self::LogCommitment),
2069            "SEND_STATE_BROADCAST" => Some(Self::Broadcast),
2070            "SEND_STATE_WAIT_CONFIRMATION" => Some(Self::WaitConfirmation),
2071            "SEND_STATE_STORE_PROOFS" => Some(Self::StoreProofs),
2072            "SEND_STATE_TRANSFER_PROOFS" => Some(Self::TransferProofs),
2073            "SEND_STATE_COMPLETED" => Some(Self::Completed),
2074            _ => None,
2075        }
2076    }
2077}
2078#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2079#[repr(i32)]
2080pub enum ParcelType {
2081    /// The parcel is an address parcel.
2082    Address = 0,
2083    /// The parcel type is a pre-signed parcel where the virtual transactions are
2084    /// signed outside of the send state machine. Parcels of this type will only
2085    /// get send states starting from SEND_STATE_ANCHOR_SIGN.
2086    PreSigned = 1,
2087    /// The parcel is pending and was resumed on the latest restart of the
2088    /// daemon. The original parcel type (address or pre-signed) is not known
2089    /// anymore, as it's not relevant for the remaining steps. Parcels of this
2090    /// type will only get send states starting from SEND_STATE_BROADCAST.
2091    Pending = 2,
2092    /// The parcel type is a pre-anchored parcel where the full anchor
2093    /// transaction and all proofs are already available. Parcels of this type
2094    /// will only get send states starting from SEND_STATE_LOG_COMMITMENT.
2095    PreAnchored = 3,
2096}
2097impl ParcelType {
2098    /// String value of the enum field names used in the ProtoBuf definition.
2099    ///
2100    /// The values are not transformed in any way and thus are considered stable
2101    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2102    pub fn as_str_name(&self) -> &'static str {
2103        match self {
2104            Self::Address => "PARCEL_TYPE_ADDRESS",
2105            Self::PreSigned => "PARCEL_TYPE_PRE_SIGNED",
2106            Self::Pending => "PARCEL_TYPE_PENDING",
2107            Self::PreAnchored => "PARCEL_TYPE_PRE_ANCHORED",
2108        }
2109    }
2110    /// Creates an enum from field names used in the ProtoBuf definition.
2111    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2112        match value {
2113            "PARCEL_TYPE_ADDRESS" => Some(Self::Address),
2114            "PARCEL_TYPE_PRE_SIGNED" => Some(Self::PreSigned),
2115            "PARCEL_TYPE_PENDING" => Some(Self::Pending),
2116            "PARCEL_TYPE_PRE_ANCHORED" => Some(Self::PreAnchored),
2117            _ => None,
2118        }
2119    }
2120}
2121/// Generated client implementations.
2122pub mod taproot_assets_client {
2123    #![allow(
2124        unused_variables,
2125        dead_code,
2126        missing_docs,
2127        clippy::wildcard_imports,
2128        clippy::let_unit_value,
2129    )]
2130    use tonic::codegen::*;
2131    use tonic::codegen::http::Uri;
2132    #[derive(Debug, Clone)]
2133    pub struct TaprootAssetsClient<T> {
2134        inner: tonic::client::Grpc<T>,
2135    }
2136    impl TaprootAssetsClient<tonic::transport::Channel> {
2137        /// Attempt to create a new client by connecting to a given endpoint.
2138        pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
2139        where
2140            D: TryInto<tonic::transport::Endpoint>,
2141            D::Error: Into<StdError>,
2142        {
2143            let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
2144            Ok(Self::new(conn))
2145        }
2146    }
2147    impl<T> TaprootAssetsClient<T>
2148    where
2149        T: tonic::client::GrpcService<tonic::body::Body>,
2150        T::Error: Into<StdError>,
2151        T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
2152        <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
2153    {
2154        pub fn new(inner: T) -> Self {
2155            let inner = tonic::client::Grpc::new(inner);
2156            Self { inner }
2157        }
2158        pub fn with_origin(inner: T, origin: Uri) -> Self {
2159            let inner = tonic::client::Grpc::with_origin(inner, origin);
2160            Self { inner }
2161        }
2162        pub fn with_interceptor<F>(
2163            inner: T,
2164            interceptor: F,
2165        ) -> TaprootAssetsClient<InterceptedService<T, F>>
2166        where
2167            F: tonic::service::Interceptor,
2168            T::ResponseBody: Default,
2169            T: tonic::codegen::Service<
2170                http::Request<tonic::body::Body>,
2171                Response = http::Response<
2172                    <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
2173                >,
2174            >,
2175            <T as tonic::codegen::Service<
2176                http::Request<tonic::body::Body>,
2177            >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
2178        {
2179            TaprootAssetsClient::new(InterceptedService::new(inner, interceptor))
2180        }
2181        /// Compress requests with the given encoding.
2182        ///
2183        /// This requires the server to support it otherwise it might respond with an
2184        /// error.
2185        #[must_use]
2186        pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
2187            self.inner = self.inner.send_compressed(encoding);
2188            self
2189        }
2190        /// Enable decompressing responses.
2191        #[must_use]
2192        pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
2193            self.inner = self.inner.accept_compressed(encoding);
2194            self
2195        }
2196        /// Limits the maximum size of a decoded message.
2197        ///
2198        /// Default: `4MB`
2199        #[must_use]
2200        pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
2201            self.inner = self.inner.max_decoding_message_size(limit);
2202            self
2203        }
2204        /// Limits the maximum size of an encoded message.
2205        ///
2206        /// Default: `usize::MAX`
2207        #[must_use]
2208        pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
2209            self.inner = self.inner.max_encoding_message_size(limit);
2210            self
2211        }
2212        /// tapcli: `assets list`
2213        /// ListAssets lists the set of assets owned by the target daemon.
2214        pub async fn list_assets(
2215            &mut self,
2216            request: impl tonic::IntoRequest<super::ListAssetRequest>,
2217        ) -> std::result::Result<
2218            tonic::Response<super::ListAssetResponse>,
2219            tonic::Status,
2220        > {
2221            self.inner
2222                .ready()
2223                .await
2224                .map_err(|e| {
2225                    tonic::Status::unknown(
2226                        format!("Service was not ready: {}", e.into()),
2227                    )
2228                })?;
2229            let codec = tonic::codec::ProstCodec::default();
2230            let path = http::uri::PathAndQuery::from_static(
2231                "/taprpc.TaprootAssets/ListAssets",
2232            );
2233            let mut req = request.into_request();
2234            req.extensions_mut()
2235                .insert(GrpcMethod::new("taprpc.TaprootAssets", "ListAssets"));
2236            self.inner.unary(req, path, codec).await
2237        }
2238        /// tapcli: `assets utxos`
2239        /// ListUtxos lists the UTXOs managed by the target daemon, and the assets they
2240        /// hold.
2241        pub async fn list_utxos(
2242            &mut self,
2243            request: impl tonic::IntoRequest<super::ListUtxosRequest>,
2244        ) -> std::result::Result<
2245            tonic::Response<super::ListUtxosResponse>,
2246            tonic::Status,
2247        > {
2248            self.inner
2249                .ready()
2250                .await
2251                .map_err(|e| {
2252                    tonic::Status::unknown(
2253                        format!("Service was not ready: {}", e.into()),
2254                    )
2255                })?;
2256            let codec = tonic::codec::ProstCodec::default();
2257            let path = http::uri::PathAndQuery::from_static(
2258                "/taprpc.TaprootAssets/ListUtxos",
2259            );
2260            let mut req = request.into_request();
2261            req.extensions_mut()
2262                .insert(GrpcMethod::new("taprpc.TaprootAssets", "ListUtxos"));
2263            self.inner.unary(req, path, codec).await
2264        }
2265        /// tapcli: `assets groups`
2266        /// ListGroups lists the asset groups known to the target daemon, and the assets
2267        /// held in each group.
2268        pub async fn list_groups(
2269            &mut self,
2270            request: impl tonic::IntoRequest<super::ListGroupsRequest>,
2271        ) -> std::result::Result<
2272            tonic::Response<super::ListGroupsResponse>,
2273            tonic::Status,
2274        > {
2275            self.inner
2276                .ready()
2277                .await
2278                .map_err(|e| {
2279                    tonic::Status::unknown(
2280                        format!("Service was not ready: {}", e.into()),
2281                    )
2282                })?;
2283            let codec = tonic::codec::ProstCodec::default();
2284            let path = http::uri::PathAndQuery::from_static(
2285                "/taprpc.TaprootAssets/ListGroups",
2286            );
2287            let mut req = request.into_request();
2288            req.extensions_mut()
2289                .insert(GrpcMethod::new("taprpc.TaprootAssets", "ListGroups"));
2290            self.inner.unary(req, path, codec).await
2291        }
2292        /// tapcli: `assets balance`
2293        /// ListBalances lists asset balances
2294        pub async fn list_balances(
2295            &mut self,
2296            request: impl tonic::IntoRequest<super::ListBalancesRequest>,
2297        ) -> std::result::Result<
2298            tonic::Response<super::ListBalancesResponse>,
2299            tonic::Status,
2300        > {
2301            self.inner
2302                .ready()
2303                .await
2304                .map_err(|e| {
2305                    tonic::Status::unknown(
2306                        format!("Service was not ready: {}", e.into()),
2307                    )
2308                })?;
2309            let codec = tonic::codec::ProstCodec::default();
2310            let path = http::uri::PathAndQuery::from_static(
2311                "/taprpc.TaprootAssets/ListBalances",
2312            );
2313            let mut req = request.into_request();
2314            req.extensions_mut()
2315                .insert(GrpcMethod::new("taprpc.TaprootAssets", "ListBalances"));
2316            self.inner.unary(req, path, codec).await
2317        }
2318        /// tapcli: `assets transfers`
2319        /// ListTransfers lists outbound asset transfers tracked by the target daemon.
2320        pub async fn list_transfers(
2321            &mut self,
2322            request: impl tonic::IntoRequest<super::ListTransfersRequest>,
2323        ) -> std::result::Result<
2324            tonic::Response<super::ListTransfersResponse>,
2325            tonic::Status,
2326        > {
2327            self.inner
2328                .ready()
2329                .await
2330                .map_err(|e| {
2331                    tonic::Status::unknown(
2332                        format!("Service was not ready: {}", e.into()),
2333                    )
2334                })?;
2335            let codec = tonic::codec::ProstCodec::default();
2336            let path = http::uri::PathAndQuery::from_static(
2337                "/taprpc.TaprootAssets/ListTransfers",
2338            );
2339            let mut req = request.into_request();
2340            req.extensions_mut()
2341                .insert(GrpcMethod::new("taprpc.TaprootAssets", "ListTransfers"));
2342            self.inner.unary(req, path, codec).await
2343        }
2344        /// tapcli: `stop`
2345        /// StopDaemon will send a shutdown request to the interrupt handler, triggering
2346        /// a graceful shutdown of the daemon.
2347        pub async fn stop_daemon(
2348            &mut self,
2349            request: impl tonic::IntoRequest<super::StopRequest>,
2350        ) -> std::result::Result<tonic::Response<super::StopResponse>, tonic::Status> {
2351            self.inner
2352                .ready()
2353                .await
2354                .map_err(|e| {
2355                    tonic::Status::unknown(
2356                        format!("Service was not ready: {}", e.into()),
2357                    )
2358                })?;
2359            let codec = tonic::codec::ProstCodec::default();
2360            let path = http::uri::PathAndQuery::from_static(
2361                "/taprpc.TaprootAssets/StopDaemon",
2362            );
2363            let mut req = request.into_request();
2364            req.extensions_mut()
2365                .insert(GrpcMethod::new("taprpc.TaprootAssets", "StopDaemon"));
2366            self.inner.unary(req, path, codec).await
2367        }
2368        /// tapcli: `debuglevel`
2369        /// DebugLevel allows a caller to programmatically set the logging verbosity of
2370        /// tapd. The logging can be targeted according to a coarse daemon-wide logging
2371        /// level, or in a granular fashion to specify the logging for a target
2372        /// sub-system.
2373        pub async fn debug_level(
2374            &mut self,
2375            request: impl tonic::IntoRequest<super::DebugLevelRequest>,
2376        ) -> std::result::Result<
2377            tonic::Response<super::DebugLevelResponse>,
2378            tonic::Status,
2379        > {
2380            self.inner
2381                .ready()
2382                .await
2383                .map_err(|e| {
2384                    tonic::Status::unknown(
2385                        format!("Service was not ready: {}", e.into()),
2386                    )
2387                })?;
2388            let codec = tonic::codec::ProstCodec::default();
2389            let path = http::uri::PathAndQuery::from_static(
2390                "/taprpc.TaprootAssets/DebugLevel",
2391            );
2392            let mut req = request.into_request();
2393            req.extensions_mut()
2394                .insert(GrpcMethod::new("taprpc.TaprootAssets", "DebugLevel"));
2395            self.inner.unary(req, path, codec).await
2396        }
2397        /// tapcli: `addrs query`
2398        /// QueryAddrs queries the set of Taproot Asset addresses stored in the
2399        /// database.
2400        pub async fn query_addrs(
2401            &mut self,
2402            request: impl tonic::IntoRequest<super::QueryAddrRequest>,
2403        ) -> std::result::Result<
2404            tonic::Response<super::QueryAddrResponse>,
2405            tonic::Status,
2406        > {
2407            self.inner
2408                .ready()
2409                .await
2410                .map_err(|e| {
2411                    tonic::Status::unknown(
2412                        format!("Service was not ready: {}", e.into()),
2413                    )
2414                })?;
2415            let codec = tonic::codec::ProstCodec::default();
2416            let path = http::uri::PathAndQuery::from_static(
2417                "/taprpc.TaprootAssets/QueryAddrs",
2418            );
2419            let mut req = request.into_request();
2420            req.extensions_mut()
2421                .insert(GrpcMethod::new("taprpc.TaprootAssets", "QueryAddrs"));
2422            self.inner.unary(req, path, codec).await
2423        }
2424        /// tapcli: `addrs new`
2425        /// NewAddr makes a new address from the set of request params.
2426        pub async fn new_addr(
2427            &mut self,
2428            request: impl tonic::IntoRequest<super::NewAddrRequest>,
2429        ) -> std::result::Result<tonic::Response<super::Addr>, tonic::Status> {
2430            self.inner
2431                .ready()
2432                .await
2433                .map_err(|e| {
2434                    tonic::Status::unknown(
2435                        format!("Service was not ready: {}", e.into()),
2436                    )
2437                })?;
2438            let codec = tonic::codec::ProstCodec::default();
2439            let path = http::uri::PathAndQuery::from_static(
2440                "/taprpc.TaprootAssets/NewAddr",
2441            );
2442            let mut req = request.into_request();
2443            req.extensions_mut()
2444                .insert(GrpcMethod::new("taprpc.TaprootAssets", "NewAddr"));
2445            self.inner.unary(req, path, codec).await
2446        }
2447        /// tapcli: `addrs decode`
2448        /// DecodeAddr decode a Taproot Asset address into a partial asset message that
2449        /// represents the asset it wants to receive.
2450        pub async fn decode_addr(
2451            &mut self,
2452            request: impl tonic::IntoRequest<super::DecodeAddrRequest>,
2453        ) -> std::result::Result<tonic::Response<super::Addr>, tonic::Status> {
2454            self.inner
2455                .ready()
2456                .await
2457                .map_err(|e| {
2458                    tonic::Status::unknown(
2459                        format!("Service was not ready: {}", e.into()),
2460                    )
2461                })?;
2462            let codec = tonic::codec::ProstCodec::default();
2463            let path = http::uri::PathAndQuery::from_static(
2464                "/taprpc.TaprootAssets/DecodeAddr",
2465            );
2466            let mut req = request.into_request();
2467            req.extensions_mut()
2468                .insert(GrpcMethod::new("taprpc.TaprootAssets", "DecodeAddr"));
2469            self.inner.unary(req, path, codec).await
2470        }
2471        /// tapcli: `addrs receives`
2472        /// List all receives for incoming asset transfers for addresses that were
2473        /// created previously.
2474        pub async fn addr_receives(
2475            &mut self,
2476            request: impl tonic::IntoRequest<super::AddrReceivesRequest>,
2477        ) -> std::result::Result<
2478            tonic::Response<super::AddrReceivesResponse>,
2479            tonic::Status,
2480        > {
2481            self.inner
2482                .ready()
2483                .await
2484                .map_err(|e| {
2485                    tonic::Status::unknown(
2486                        format!("Service was not ready: {}", e.into()),
2487                    )
2488                })?;
2489            let codec = tonic::codec::ProstCodec::default();
2490            let path = http::uri::PathAndQuery::from_static(
2491                "/taprpc.TaprootAssets/AddrReceives",
2492            );
2493            let mut req = request.into_request();
2494            req.extensions_mut()
2495                .insert(GrpcMethod::new("taprpc.TaprootAssets", "AddrReceives"));
2496            self.inner.unary(req, path, codec).await
2497        }
2498        /// tapcli: `proofs verify`
2499        /// VerifyProof attempts to verify a given proof file that claims to be anchored
2500        /// at the specified genesis point.
2501        pub async fn verify_proof(
2502            &mut self,
2503            request: impl tonic::IntoRequest<super::ProofFile>,
2504        ) -> std::result::Result<
2505            tonic::Response<super::VerifyProofResponse>,
2506            tonic::Status,
2507        > {
2508            self.inner
2509                .ready()
2510                .await
2511                .map_err(|e| {
2512                    tonic::Status::unknown(
2513                        format!("Service was not ready: {}", e.into()),
2514                    )
2515                })?;
2516            let codec = tonic::codec::ProstCodec::default();
2517            let path = http::uri::PathAndQuery::from_static(
2518                "/taprpc.TaprootAssets/VerifyProof",
2519            );
2520            let mut req = request.into_request();
2521            req.extensions_mut()
2522                .insert(GrpcMethod::new("taprpc.TaprootAssets", "VerifyProof"));
2523            self.inner.unary(req, path, codec).await
2524        }
2525        /// tapcli: `proofs decode`
2526        /// DecodeProof attempts to decode a given proof file into human readable
2527        /// format.
2528        pub async fn decode_proof(
2529            &mut self,
2530            request: impl tonic::IntoRequest<super::DecodeProofRequest>,
2531        ) -> std::result::Result<
2532            tonic::Response<super::DecodeProofResponse>,
2533            tonic::Status,
2534        > {
2535            self.inner
2536                .ready()
2537                .await
2538                .map_err(|e| {
2539                    tonic::Status::unknown(
2540                        format!("Service was not ready: {}", e.into()),
2541                    )
2542                })?;
2543            let codec = tonic::codec::ProstCodec::default();
2544            let path = http::uri::PathAndQuery::from_static(
2545                "/taprpc.TaprootAssets/DecodeProof",
2546            );
2547            let mut req = request.into_request();
2548            req.extensions_mut()
2549                .insert(GrpcMethod::new("taprpc.TaprootAssets", "DecodeProof"));
2550            self.inner.unary(req, path, codec).await
2551        }
2552        /// tapcli: `proofs export`
2553        /// ExportProof exports the latest raw proof file anchored at the specified
2554        /// script_key.
2555        pub async fn export_proof(
2556            &mut self,
2557            request: impl tonic::IntoRequest<super::ExportProofRequest>,
2558        ) -> std::result::Result<tonic::Response<super::ProofFile>, tonic::Status> {
2559            self.inner
2560                .ready()
2561                .await
2562                .map_err(|e| {
2563                    tonic::Status::unknown(
2564                        format!("Service was not ready: {}", e.into()),
2565                    )
2566                })?;
2567            let codec = tonic::codec::ProstCodec::default();
2568            let path = http::uri::PathAndQuery::from_static(
2569                "/taprpc.TaprootAssets/ExportProof",
2570            );
2571            let mut req = request.into_request();
2572            req.extensions_mut()
2573                .insert(GrpcMethod::new("taprpc.TaprootAssets", "ExportProof"));
2574            self.inner.unary(req, path, codec).await
2575        }
2576        /// tapcli: `proofs unpack`
2577        /// UnpackProofFile unpacks a proof file into a list of the individual raw
2578        /// proofs in the proof chain.
2579        pub async fn unpack_proof_file(
2580            &mut self,
2581            request: impl tonic::IntoRequest<super::UnpackProofFileRequest>,
2582        ) -> std::result::Result<
2583            tonic::Response<super::UnpackProofFileResponse>,
2584            tonic::Status,
2585        > {
2586            self.inner
2587                .ready()
2588                .await
2589                .map_err(|e| {
2590                    tonic::Status::unknown(
2591                        format!("Service was not ready: {}", e.into()),
2592                    )
2593                })?;
2594            let codec = tonic::codec::ProstCodec::default();
2595            let path = http::uri::PathAndQuery::from_static(
2596                "/taprpc.TaprootAssets/UnpackProofFile",
2597            );
2598            let mut req = request.into_request();
2599            req.extensions_mut()
2600                .insert(GrpcMethod::new("taprpc.TaprootAssets", "UnpackProofFile"));
2601            self.inner.unary(req, path, codec).await
2602        }
2603        /// tapcli: `assets send`
2604        /// SendAsset uses one or multiple passed Taproot Asset address(es) to attempt
2605        /// to complete an asset send. The method returns information w.r.t the on chain
2606        /// send, as well as the proof file information the receiver needs to fully
2607        /// receive the asset.
2608        pub async fn send_asset(
2609            &mut self,
2610            request: impl tonic::IntoRequest<super::SendAssetRequest>,
2611        ) -> std::result::Result<
2612            tonic::Response<super::SendAssetResponse>,
2613            tonic::Status,
2614        > {
2615            self.inner
2616                .ready()
2617                .await
2618                .map_err(|e| {
2619                    tonic::Status::unknown(
2620                        format!("Service was not ready: {}", e.into()),
2621                    )
2622                })?;
2623            let codec = tonic::codec::ProstCodec::default();
2624            let path = http::uri::PathAndQuery::from_static(
2625                "/taprpc.TaprootAssets/SendAsset",
2626            );
2627            let mut req = request.into_request();
2628            req.extensions_mut()
2629                .insert(GrpcMethod::new("taprpc.TaprootAssets", "SendAsset"));
2630            self.inner.unary(req, path, codec).await
2631        }
2632        /// tapcli: `assets burn`
2633        /// BurnAsset burns the given number of units of a given asset by sending them
2634        /// to a provably un-spendable script key. Burning means irrevocably destroying
2635        /// a certain number of assets, reducing the total supply of the asset. Because
2636        /// burning is such a destructive and non-reversible operation, some specific
2637        /// values need to be set in the request to avoid accidental burns.
2638        pub async fn burn_asset(
2639            &mut self,
2640            request: impl tonic::IntoRequest<super::BurnAssetRequest>,
2641        ) -> std::result::Result<
2642            tonic::Response<super::BurnAssetResponse>,
2643            tonic::Status,
2644        > {
2645            self.inner
2646                .ready()
2647                .await
2648                .map_err(|e| {
2649                    tonic::Status::unknown(
2650                        format!("Service was not ready: {}", e.into()),
2651                    )
2652                })?;
2653            let codec = tonic::codec::ProstCodec::default();
2654            let path = http::uri::PathAndQuery::from_static(
2655                "/taprpc.TaprootAssets/BurnAsset",
2656            );
2657            let mut req = request.into_request();
2658            req.extensions_mut()
2659                .insert(GrpcMethod::new("taprpc.TaprootAssets", "BurnAsset"));
2660            self.inner.unary(req, path, codec).await
2661        }
2662        /// tapcli: `assets listburns`
2663        /// ListBurns lists the asset burns that this wallet has performed. These assets
2664        /// are not recoverable in any way. Filters may be applied to return more
2665        /// specific results.
2666        pub async fn list_burns(
2667            &mut self,
2668            request: impl tonic::IntoRequest<super::ListBurnsRequest>,
2669        ) -> std::result::Result<
2670            tonic::Response<super::ListBurnsResponse>,
2671            tonic::Status,
2672        > {
2673            self.inner
2674                .ready()
2675                .await
2676                .map_err(|e| {
2677                    tonic::Status::unknown(
2678                        format!("Service was not ready: {}", e.into()),
2679                    )
2680                })?;
2681            let codec = tonic::codec::ProstCodec::default();
2682            let path = http::uri::PathAndQuery::from_static(
2683                "/taprpc.TaprootAssets/ListBurns",
2684            );
2685            let mut req = request.into_request();
2686            req.extensions_mut()
2687                .insert(GrpcMethod::new("taprpc.TaprootAssets", "ListBurns"));
2688            self.inner.unary(req, path, codec).await
2689        }
2690        /// tapcli: `getinfo`
2691        /// GetInfo returns the information for the node.
2692        pub async fn get_info(
2693            &mut self,
2694            request: impl tonic::IntoRequest<super::GetInfoRequest>,
2695        ) -> std::result::Result<
2696            tonic::Response<super::GetInfoResponse>,
2697            tonic::Status,
2698        > {
2699            self.inner
2700                .ready()
2701                .await
2702                .map_err(|e| {
2703                    tonic::Status::unknown(
2704                        format!("Service was not ready: {}", e.into()),
2705                    )
2706                })?;
2707            let codec = tonic::codec::ProstCodec::default();
2708            let path = http::uri::PathAndQuery::from_static(
2709                "/taprpc.TaprootAssets/GetInfo",
2710            );
2711            let mut req = request.into_request();
2712            req.extensions_mut()
2713                .insert(GrpcMethod::new("taprpc.TaprootAssets", "GetInfo"));
2714            self.inner.unary(req, path, codec).await
2715        }
2716        /// tapcli: `assets meta`
2717        /// FetchAssetMeta allows a caller to fetch the reveal meta data for an asset
2718        /// either by the asset ID for that asset, or a meta hash.
2719        pub async fn fetch_asset_meta(
2720            &mut self,
2721            request: impl tonic::IntoRequest<super::FetchAssetMetaRequest>,
2722        ) -> std::result::Result<
2723            tonic::Response<super::FetchAssetMetaResponse>,
2724            tonic::Status,
2725        > {
2726            self.inner
2727                .ready()
2728                .await
2729                .map_err(|e| {
2730                    tonic::Status::unknown(
2731                        format!("Service was not ready: {}", e.into()),
2732                    )
2733                })?;
2734            let codec = tonic::codec::ProstCodec::default();
2735            let path = http::uri::PathAndQuery::from_static(
2736                "/taprpc.TaprootAssets/FetchAssetMeta",
2737            );
2738            let mut req = request.into_request();
2739            req.extensions_mut()
2740                .insert(GrpcMethod::new("taprpc.TaprootAssets", "FetchAssetMeta"));
2741            self.inner.unary(req, path, codec).await
2742        }
2743        /// tapcli: `events receive`
2744        /// SubscribeReceiveEvents allows a caller to subscribe to receive events for
2745        /// incoming asset transfers.
2746        pub async fn subscribe_receive_events(
2747            &mut self,
2748            request: impl tonic::IntoRequest<super::SubscribeReceiveEventsRequest>,
2749        ) -> std::result::Result<
2750            tonic::Response<tonic::codec::Streaming<super::ReceiveEvent>>,
2751            tonic::Status,
2752        > {
2753            self.inner
2754                .ready()
2755                .await
2756                .map_err(|e| {
2757                    tonic::Status::unknown(
2758                        format!("Service was not ready: {}", e.into()),
2759                    )
2760                })?;
2761            let codec = tonic::codec::ProstCodec::default();
2762            let path = http::uri::PathAndQuery::from_static(
2763                "/taprpc.TaprootAssets/SubscribeReceiveEvents",
2764            );
2765            let mut req = request.into_request();
2766            req.extensions_mut()
2767                .insert(
2768                    GrpcMethod::new("taprpc.TaprootAssets", "SubscribeReceiveEvents"),
2769                );
2770            self.inner.server_streaming(req, path, codec).await
2771        }
2772        /// tapcli: `events send`
2773        /// SubscribeSendEvents allows a caller to subscribe to send events for outgoing
2774        /// asset transfers.
2775        pub async fn subscribe_send_events(
2776            &mut self,
2777            request: impl tonic::IntoRequest<super::SubscribeSendEventsRequest>,
2778        ) -> std::result::Result<
2779            tonic::Response<tonic::codec::Streaming<super::SendEvent>>,
2780            tonic::Status,
2781        > {
2782            self.inner
2783                .ready()
2784                .await
2785                .map_err(|e| {
2786                    tonic::Status::unknown(
2787                        format!("Service was not ready: {}", e.into()),
2788                    )
2789                })?;
2790            let codec = tonic::codec::ProstCodec::default();
2791            let path = http::uri::PathAndQuery::from_static(
2792                "/taprpc.TaprootAssets/SubscribeSendEvents",
2793            );
2794            let mut req = request.into_request();
2795            req.extensions_mut()
2796                .insert(GrpcMethod::new("taprpc.TaprootAssets", "SubscribeSendEvents"));
2797            self.inner.server_streaming(req, path, codec).await
2798        }
2799        ///
2800        /// RegisterTransfer informs the daemon about a new inbound transfer that has
2801        /// happened. This is used for interactive transfers where no TAP address is
2802        /// involved and the recipient is aware of the transfer through an out-of-band
2803        /// protocol but the daemon hasn't been informed about the completion of the
2804        /// transfer. For this to work, the proof must already be in the recipient's
2805        /// local universe (e.g. through the use of the universerpc.InsertProof RPC or
2806        /// the universe proof courier and universe sync mechanisms) and this call
2807        /// simply instructs the daemon to detect the transfer as an asset it owns.
2808        pub async fn register_transfer(
2809            &mut self,
2810            request: impl tonic::IntoRequest<super::RegisterTransferRequest>,
2811        ) -> std::result::Result<
2812            tonic::Response<super::RegisterTransferResponse>,
2813            tonic::Status,
2814        > {
2815            self.inner
2816                .ready()
2817                .await
2818                .map_err(|e| {
2819                    tonic::Status::unknown(
2820                        format!("Service was not ready: {}", e.into()),
2821                    )
2822                })?;
2823            let codec = tonic::codec::ProstCodec::default();
2824            let path = http::uri::PathAndQuery::from_static(
2825                "/taprpc.TaprootAssets/RegisterTransfer",
2826            );
2827            let mut req = request.into_request();
2828            req.extensions_mut()
2829                .insert(GrpcMethod::new("taprpc.TaprootAssets", "RegisterTransfer"));
2830            self.inner.unary(req, path, codec).await
2831        }
2832    }
2833}
2834/// Generated server implementations.
2835pub mod taproot_assets_server {
2836    #![allow(
2837        unused_variables,
2838        dead_code,
2839        missing_docs,
2840        clippy::wildcard_imports,
2841        clippy::let_unit_value,
2842    )]
2843    use tonic::codegen::*;
2844    /// Generated trait containing gRPC methods that should be implemented for use with TaprootAssetsServer.
2845    #[async_trait]
2846    pub trait TaprootAssets: std::marker::Send + std::marker::Sync + 'static {
2847        /// tapcli: `assets list`
2848        /// ListAssets lists the set of assets owned by the target daemon.
2849        async fn list_assets(
2850            &self,
2851            request: tonic::Request<super::ListAssetRequest>,
2852        ) -> std::result::Result<
2853            tonic::Response<super::ListAssetResponse>,
2854            tonic::Status,
2855        >;
2856        /// tapcli: `assets utxos`
2857        /// ListUtxos lists the UTXOs managed by the target daemon, and the assets they
2858        /// hold.
2859        async fn list_utxos(
2860            &self,
2861            request: tonic::Request<super::ListUtxosRequest>,
2862        ) -> std::result::Result<
2863            tonic::Response<super::ListUtxosResponse>,
2864            tonic::Status,
2865        >;
2866        /// tapcli: `assets groups`
2867        /// ListGroups lists the asset groups known to the target daemon, and the assets
2868        /// held in each group.
2869        async fn list_groups(
2870            &self,
2871            request: tonic::Request<super::ListGroupsRequest>,
2872        ) -> std::result::Result<
2873            tonic::Response<super::ListGroupsResponse>,
2874            tonic::Status,
2875        >;
2876        /// tapcli: `assets balance`
2877        /// ListBalances lists asset balances
2878        async fn list_balances(
2879            &self,
2880            request: tonic::Request<super::ListBalancesRequest>,
2881        ) -> std::result::Result<
2882            tonic::Response<super::ListBalancesResponse>,
2883            tonic::Status,
2884        >;
2885        /// tapcli: `assets transfers`
2886        /// ListTransfers lists outbound asset transfers tracked by the target daemon.
2887        async fn list_transfers(
2888            &self,
2889            request: tonic::Request<super::ListTransfersRequest>,
2890        ) -> std::result::Result<
2891            tonic::Response<super::ListTransfersResponse>,
2892            tonic::Status,
2893        >;
2894        /// tapcli: `stop`
2895        /// StopDaemon will send a shutdown request to the interrupt handler, triggering
2896        /// a graceful shutdown of the daemon.
2897        async fn stop_daemon(
2898            &self,
2899            request: tonic::Request<super::StopRequest>,
2900        ) -> std::result::Result<tonic::Response<super::StopResponse>, tonic::Status>;
2901        /// tapcli: `debuglevel`
2902        /// DebugLevel allows a caller to programmatically set the logging verbosity of
2903        /// tapd. The logging can be targeted according to a coarse daemon-wide logging
2904        /// level, or in a granular fashion to specify the logging for a target
2905        /// sub-system.
2906        async fn debug_level(
2907            &self,
2908            request: tonic::Request<super::DebugLevelRequest>,
2909        ) -> std::result::Result<
2910            tonic::Response<super::DebugLevelResponse>,
2911            tonic::Status,
2912        >;
2913        /// tapcli: `addrs query`
2914        /// QueryAddrs queries the set of Taproot Asset addresses stored in the
2915        /// database.
2916        async fn query_addrs(
2917            &self,
2918            request: tonic::Request<super::QueryAddrRequest>,
2919        ) -> std::result::Result<
2920            tonic::Response<super::QueryAddrResponse>,
2921            tonic::Status,
2922        >;
2923        /// tapcli: `addrs new`
2924        /// NewAddr makes a new address from the set of request params.
2925        async fn new_addr(
2926            &self,
2927            request: tonic::Request<super::NewAddrRequest>,
2928        ) -> std::result::Result<tonic::Response<super::Addr>, tonic::Status>;
2929        /// tapcli: `addrs decode`
2930        /// DecodeAddr decode a Taproot Asset address into a partial asset message that
2931        /// represents the asset it wants to receive.
2932        async fn decode_addr(
2933            &self,
2934            request: tonic::Request<super::DecodeAddrRequest>,
2935        ) -> std::result::Result<tonic::Response<super::Addr>, tonic::Status>;
2936        /// tapcli: `addrs receives`
2937        /// List all receives for incoming asset transfers for addresses that were
2938        /// created previously.
2939        async fn addr_receives(
2940            &self,
2941            request: tonic::Request<super::AddrReceivesRequest>,
2942        ) -> std::result::Result<
2943            tonic::Response<super::AddrReceivesResponse>,
2944            tonic::Status,
2945        >;
2946        /// tapcli: `proofs verify`
2947        /// VerifyProof attempts to verify a given proof file that claims to be anchored
2948        /// at the specified genesis point.
2949        async fn verify_proof(
2950            &self,
2951            request: tonic::Request<super::ProofFile>,
2952        ) -> std::result::Result<
2953            tonic::Response<super::VerifyProofResponse>,
2954            tonic::Status,
2955        >;
2956        /// tapcli: `proofs decode`
2957        /// DecodeProof attempts to decode a given proof file into human readable
2958        /// format.
2959        async fn decode_proof(
2960            &self,
2961            request: tonic::Request<super::DecodeProofRequest>,
2962        ) -> std::result::Result<
2963            tonic::Response<super::DecodeProofResponse>,
2964            tonic::Status,
2965        >;
2966        /// tapcli: `proofs export`
2967        /// ExportProof exports the latest raw proof file anchored at the specified
2968        /// script_key.
2969        async fn export_proof(
2970            &self,
2971            request: tonic::Request<super::ExportProofRequest>,
2972        ) -> std::result::Result<tonic::Response<super::ProofFile>, tonic::Status>;
2973        /// tapcli: `proofs unpack`
2974        /// UnpackProofFile unpacks a proof file into a list of the individual raw
2975        /// proofs in the proof chain.
2976        async fn unpack_proof_file(
2977            &self,
2978            request: tonic::Request<super::UnpackProofFileRequest>,
2979        ) -> std::result::Result<
2980            tonic::Response<super::UnpackProofFileResponse>,
2981            tonic::Status,
2982        >;
2983        /// tapcli: `assets send`
2984        /// SendAsset uses one or multiple passed Taproot Asset address(es) to attempt
2985        /// to complete an asset send. The method returns information w.r.t the on chain
2986        /// send, as well as the proof file information the receiver needs to fully
2987        /// receive the asset.
2988        async fn send_asset(
2989            &self,
2990            request: tonic::Request<super::SendAssetRequest>,
2991        ) -> std::result::Result<
2992            tonic::Response<super::SendAssetResponse>,
2993            tonic::Status,
2994        >;
2995        /// tapcli: `assets burn`
2996        /// BurnAsset burns the given number of units of a given asset by sending them
2997        /// to a provably un-spendable script key. Burning means irrevocably destroying
2998        /// a certain number of assets, reducing the total supply of the asset. Because
2999        /// burning is such a destructive and non-reversible operation, some specific
3000        /// values need to be set in the request to avoid accidental burns.
3001        async fn burn_asset(
3002            &self,
3003            request: tonic::Request<super::BurnAssetRequest>,
3004        ) -> std::result::Result<
3005            tonic::Response<super::BurnAssetResponse>,
3006            tonic::Status,
3007        >;
3008        /// tapcli: `assets listburns`
3009        /// ListBurns lists the asset burns that this wallet has performed. These assets
3010        /// are not recoverable in any way. Filters may be applied to return more
3011        /// specific results.
3012        async fn list_burns(
3013            &self,
3014            request: tonic::Request<super::ListBurnsRequest>,
3015        ) -> std::result::Result<
3016            tonic::Response<super::ListBurnsResponse>,
3017            tonic::Status,
3018        >;
3019        /// tapcli: `getinfo`
3020        /// GetInfo returns the information for the node.
3021        async fn get_info(
3022            &self,
3023            request: tonic::Request<super::GetInfoRequest>,
3024        ) -> std::result::Result<tonic::Response<super::GetInfoResponse>, tonic::Status>;
3025        /// tapcli: `assets meta`
3026        /// FetchAssetMeta allows a caller to fetch the reveal meta data for an asset
3027        /// either by the asset ID for that asset, or a meta hash.
3028        async fn fetch_asset_meta(
3029            &self,
3030            request: tonic::Request<super::FetchAssetMetaRequest>,
3031        ) -> std::result::Result<
3032            tonic::Response<super::FetchAssetMetaResponse>,
3033            tonic::Status,
3034        >;
3035        /// Server streaming response type for the SubscribeReceiveEvents method.
3036        type SubscribeReceiveEventsStream: tonic::codegen::tokio_stream::Stream<
3037                Item = std::result::Result<super::ReceiveEvent, tonic::Status>,
3038            >
3039            + std::marker::Send
3040            + 'static;
3041        /// tapcli: `events receive`
3042        /// SubscribeReceiveEvents allows a caller to subscribe to receive events for
3043        /// incoming asset transfers.
3044        async fn subscribe_receive_events(
3045            &self,
3046            request: tonic::Request<super::SubscribeReceiveEventsRequest>,
3047        ) -> std::result::Result<
3048            tonic::Response<Self::SubscribeReceiveEventsStream>,
3049            tonic::Status,
3050        >;
3051        /// Server streaming response type for the SubscribeSendEvents method.
3052        type SubscribeSendEventsStream: tonic::codegen::tokio_stream::Stream<
3053                Item = std::result::Result<super::SendEvent, tonic::Status>,
3054            >
3055            + std::marker::Send
3056            + 'static;
3057        /// tapcli: `events send`
3058        /// SubscribeSendEvents allows a caller to subscribe to send events for outgoing
3059        /// asset transfers.
3060        async fn subscribe_send_events(
3061            &self,
3062            request: tonic::Request<super::SubscribeSendEventsRequest>,
3063        ) -> std::result::Result<
3064            tonic::Response<Self::SubscribeSendEventsStream>,
3065            tonic::Status,
3066        >;
3067        ///
3068        /// RegisterTransfer informs the daemon about a new inbound transfer that has
3069        /// happened. This is used for interactive transfers where no TAP address is
3070        /// involved and the recipient is aware of the transfer through an out-of-band
3071        /// protocol but the daemon hasn't been informed about the completion of the
3072        /// transfer. For this to work, the proof must already be in the recipient's
3073        /// local universe (e.g. through the use of the universerpc.InsertProof RPC or
3074        /// the universe proof courier and universe sync mechanisms) and this call
3075        /// simply instructs the daemon to detect the transfer as an asset it owns.
3076        async fn register_transfer(
3077            &self,
3078            request: tonic::Request<super::RegisterTransferRequest>,
3079        ) -> std::result::Result<
3080            tonic::Response<super::RegisterTransferResponse>,
3081            tonic::Status,
3082        >;
3083    }
3084    #[derive(Debug)]
3085    pub struct TaprootAssetsServer<T> {
3086        inner: Arc<T>,
3087        accept_compression_encodings: EnabledCompressionEncodings,
3088        send_compression_encodings: EnabledCompressionEncodings,
3089        max_decoding_message_size: Option<usize>,
3090        max_encoding_message_size: Option<usize>,
3091    }
3092    impl<T> TaprootAssetsServer<T> {
3093        pub fn new(inner: T) -> Self {
3094            Self::from_arc(Arc::new(inner))
3095        }
3096        pub fn from_arc(inner: Arc<T>) -> Self {
3097            Self {
3098                inner,
3099                accept_compression_encodings: Default::default(),
3100                send_compression_encodings: Default::default(),
3101                max_decoding_message_size: None,
3102                max_encoding_message_size: None,
3103            }
3104        }
3105        pub fn with_interceptor<F>(
3106            inner: T,
3107            interceptor: F,
3108        ) -> InterceptedService<Self, F>
3109        where
3110            F: tonic::service::Interceptor,
3111        {
3112            InterceptedService::new(Self::new(inner), interceptor)
3113        }
3114        /// Enable decompressing requests with the given encoding.
3115        #[must_use]
3116        pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
3117            self.accept_compression_encodings.enable(encoding);
3118            self
3119        }
3120        /// Compress responses with the given encoding, if the client supports it.
3121        #[must_use]
3122        pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
3123            self.send_compression_encodings.enable(encoding);
3124            self
3125        }
3126        /// Limits the maximum size of a decoded message.
3127        ///
3128        /// Default: `4MB`
3129        #[must_use]
3130        pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
3131            self.max_decoding_message_size = Some(limit);
3132            self
3133        }
3134        /// Limits the maximum size of an encoded message.
3135        ///
3136        /// Default: `usize::MAX`
3137        #[must_use]
3138        pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
3139            self.max_encoding_message_size = Some(limit);
3140            self
3141        }
3142    }
3143    impl<T, B> tonic::codegen::Service<http::Request<B>> for TaprootAssetsServer<T>
3144    where
3145        T: TaprootAssets,
3146        B: Body + std::marker::Send + 'static,
3147        B::Error: Into<StdError> + std::marker::Send + 'static,
3148    {
3149        type Response = http::Response<tonic::body::Body>;
3150        type Error = std::convert::Infallible;
3151        type Future = BoxFuture<Self::Response, Self::Error>;
3152        fn poll_ready(
3153            &mut self,
3154            _cx: &mut Context<'_>,
3155        ) -> Poll<std::result::Result<(), Self::Error>> {
3156            Poll::Ready(Ok(()))
3157        }
3158        fn call(&mut self, req: http::Request<B>) -> Self::Future {
3159            match req.uri().path() {
3160                "/taprpc.TaprootAssets/ListAssets" => {
3161                    #[allow(non_camel_case_types)]
3162                    struct ListAssetsSvc<T: TaprootAssets>(pub Arc<T>);
3163                    impl<
3164                        T: TaprootAssets,
3165                    > tonic::server::UnaryService<super::ListAssetRequest>
3166                    for ListAssetsSvc<T> {
3167                        type Response = super::ListAssetResponse;
3168                        type Future = BoxFuture<
3169                            tonic::Response<Self::Response>,
3170                            tonic::Status,
3171                        >;
3172                        fn call(
3173                            &mut self,
3174                            request: tonic::Request<super::ListAssetRequest>,
3175                        ) -> Self::Future {
3176                            let inner = Arc::clone(&self.0);
3177                            let fut = async move {
3178                                <T as TaprootAssets>::list_assets(&inner, request).await
3179                            };
3180                            Box::pin(fut)
3181                        }
3182                    }
3183                    let accept_compression_encodings = self.accept_compression_encodings;
3184                    let send_compression_encodings = self.send_compression_encodings;
3185                    let max_decoding_message_size = self.max_decoding_message_size;
3186                    let max_encoding_message_size = self.max_encoding_message_size;
3187                    let inner = self.inner.clone();
3188                    let fut = async move {
3189                        let method = ListAssetsSvc(inner);
3190                        let codec = tonic::codec::ProstCodec::default();
3191                        let mut grpc = tonic::server::Grpc::new(codec)
3192                            .apply_compression_config(
3193                                accept_compression_encodings,
3194                                send_compression_encodings,
3195                            )
3196                            .apply_max_message_size_config(
3197                                max_decoding_message_size,
3198                                max_encoding_message_size,
3199                            );
3200                        let res = grpc.unary(method, req).await;
3201                        Ok(res)
3202                    };
3203                    Box::pin(fut)
3204                }
3205                "/taprpc.TaprootAssets/ListUtxos" => {
3206                    #[allow(non_camel_case_types)]
3207                    struct ListUtxosSvc<T: TaprootAssets>(pub Arc<T>);
3208                    impl<
3209                        T: TaprootAssets,
3210                    > tonic::server::UnaryService<super::ListUtxosRequest>
3211                    for ListUtxosSvc<T> {
3212                        type Response = super::ListUtxosResponse;
3213                        type Future = BoxFuture<
3214                            tonic::Response<Self::Response>,
3215                            tonic::Status,
3216                        >;
3217                        fn call(
3218                            &mut self,
3219                            request: tonic::Request<super::ListUtxosRequest>,
3220                        ) -> Self::Future {
3221                            let inner = Arc::clone(&self.0);
3222                            let fut = async move {
3223                                <T as TaprootAssets>::list_utxos(&inner, request).await
3224                            };
3225                            Box::pin(fut)
3226                        }
3227                    }
3228                    let accept_compression_encodings = self.accept_compression_encodings;
3229                    let send_compression_encodings = self.send_compression_encodings;
3230                    let max_decoding_message_size = self.max_decoding_message_size;
3231                    let max_encoding_message_size = self.max_encoding_message_size;
3232                    let inner = self.inner.clone();
3233                    let fut = async move {
3234                        let method = ListUtxosSvc(inner);
3235                        let codec = tonic::codec::ProstCodec::default();
3236                        let mut grpc = tonic::server::Grpc::new(codec)
3237                            .apply_compression_config(
3238                                accept_compression_encodings,
3239                                send_compression_encodings,
3240                            )
3241                            .apply_max_message_size_config(
3242                                max_decoding_message_size,
3243                                max_encoding_message_size,
3244                            );
3245                        let res = grpc.unary(method, req).await;
3246                        Ok(res)
3247                    };
3248                    Box::pin(fut)
3249                }
3250                "/taprpc.TaprootAssets/ListGroups" => {
3251                    #[allow(non_camel_case_types)]
3252                    struct ListGroupsSvc<T: TaprootAssets>(pub Arc<T>);
3253                    impl<
3254                        T: TaprootAssets,
3255                    > tonic::server::UnaryService<super::ListGroupsRequest>
3256                    for ListGroupsSvc<T> {
3257                        type Response = super::ListGroupsResponse;
3258                        type Future = BoxFuture<
3259                            tonic::Response<Self::Response>,
3260                            tonic::Status,
3261                        >;
3262                        fn call(
3263                            &mut self,
3264                            request: tonic::Request<super::ListGroupsRequest>,
3265                        ) -> Self::Future {
3266                            let inner = Arc::clone(&self.0);
3267                            let fut = async move {
3268                                <T as TaprootAssets>::list_groups(&inner, request).await
3269                            };
3270                            Box::pin(fut)
3271                        }
3272                    }
3273                    let accept_compression_encodings = self.accept_compression_encodings;
3274                    let send_compression_encodings = self.send_compression_encodings;
3275                    let max_decoding_message_size = self.max_decoding_message_size;
3276                    let max_encoding_message_size = self.max_encoding_message_size;
3277                    let inner = self.inner.clone();
3278                    let fut = async move {
3279                        let method = ListGroupsSvc(inner);
3280                        let codec = tonic::codec::ProstCodec::default();
3281                        let mut grpc = tonic::server::Grpc::new(codec)
3282                            .apply_compression_config(
3283                                accept_compression_encodings,
3284                                send_compression_encodings,
3285                            )
3286                            .apply_max_message_size_config(
3287                                max_decoding_message_size,
3288                                max_encoding_message_size,
3289                            );
3290                        let res = grpc.unary(method, req).await;
3291                        Ok(res)
3292                    };
3293                    Box::pin(fut)
3294                }
3295                "/taprpc.TaprootAssets/ListBalances" => {
3296                    #[allow(non_camel_case_types)]
3297                    struct ListBalancesSvc<T: TaprootAssets>(pub Arc<T>);
3298                    impl<
3299                        T: TaprootAssets,
3300                    > tonic::server::UnaryService<super::ListBalancesRequest>
3301                    for ListBalancesSvc<T> {
3302                        type Response = super::ListBalancesResponse;
3303                        type Future = BoxFuture<
3304                            tonic::Response<Self::Response>,
3305                            tonic::Status,
3306                        >;
3307                        fn call(
3308                            &mut self,
3309                            request: tonic::Request<super::ListBalancesRequest>,
3310                        ) -> Self::Future {
3311                            let inner = Arc::clone(&self.0);
3312                            let fut = async move {
3313                                <T as TaprootAssets>::list_balances(&inner, request).await
3314                            };
3315                            Box::pin(fut)
3316                        }
3317                    }
3318                    let accept_compression_encodings = self.accept_compression_encodings;
3319                    let send_compression_encodings = self.send_compression_encodings;
3320                    let max_decoding_message_size = self.max_decoding_message_size;
3321                    let max_encoding_message_size = self.max_encoding_message_size;
3322                    let inner = self.inner.clone();
3323                    let fut = async move {
3324                        let method = ListBalancesSvc(inner);
3325                        let codec = tonic::codec::ProstCodec::default();
3326                        let mut grpc = tonic::server::Grpc::new(codec)
3327                            .apply_compression_config(
3328                                accept_compression_encodings,
3329                                send_compression_encodings,
3330                            )
3331                            .apply_max_message_size_config(
3332                                max_decoding_message_size,
3333                                max_encoding_message_size,
3334                            );
3335                        let res = grpc.unary(method, req).await;
3336                        Ok(res)
3337                    };
3338                    Box::pin(fut)
3339                }
3340                "/taprpc.TaprootAssets/ListTransfers" => {
3341                    #[allow(non_camel_case_types)]
3342                    struct ListTransfersSvc<T: TaprootAssets>(pub Arc<T>);
3343                    impl<
3344                        T: TaprootAssets,
3345                    > tonic::server::UnaryService<super::ListTransfersRequest>
3346                    for ListTransfersSvc<T> {
3347                        type Response = super::ListTransfersResponse;
3348                        type Future = BoxFuture<
3349                            tonic::Response<Self::Response>,
3350                            tonic::Status,
3351                        >;
3352                        fn call(
3353                            &mut self,
3354                            request: tonic::Request<super::ListTransfersRequest>,
3355                        ) -> Self::Future {
3356                            let inner = Arc::clone(&self.0);
3357                            let fut = async move {
3358                                <T as TaprootAssets>::list_transfers(&inner, request).await
3359                            };
3360                            Box::pin(fut)
3361                        }
3362                    }
3363                    let accept_compression_encodings = self.accept_compression_encodings;
3364                    let send_compression_encodings = self.send_compression_encodings;
3365                    let max_decoding_message_size = self.max_decoding_message_size;
3366                    let max_encoding_message_size = self.max_encoding_message_size;
3367                    let inner = self.inner.clone();
3368                    let fut = async move {
3369                        let method = ListTransfersSvc(inner);
3370                        let codec = tonic::codec::ProstCodec::default();
3371                        let mut grpc = tonic::server::Grpc::new(codec)
3372                            .apply_compression_config(
3373                                accept_compression_encodings,
3374                                send_compression_encodings,
3375                            )
3376                            .apply_max_message_size_config(
3377                                max_decoding_message_size,
3378                                max_encoding_message_size,
3379                            );
3380                        let res = grpc.unary(method, req).await;
3381                        Ok(res)
3382                    };
3383                    Box::pin(fut)
3384                }
3385                "/taprpc.TaprootAssets/StopDaemon" => {
3386                    #[allow(non_camel_case_types)]
3387                    struct StopDaemonSvc<T: TaprootAssets>(pub Arc<T>);
3388                    impl<
3389                        T: TaprootAssets,
3390                    > tonic::server::UnaryService<super::StopRequest>
3391                    for StopDaemonSvc<T> {
3392                        type Response = super::StopResponse;
3393                        type Future = BoxFuture<
3394                            tonic::Response<Self::Response>,
3395                            tonic::Status,
3396                        >;
3397                        fn call(
3398                            &mut self,
3399                            request: tonic::Request<super::StopRequest>,
3400                        ) -> Self::Future {
3401                            let inner = Arc::clone(&self.0);
3402                            let fut = async move {
3403                                <T as TaprootAssets>::stop_daemon(&inner, request).await
3404                            };
3405                            Box::pin(fut)
3406                        }
3407                    }
3408                    let accept_compression_encodings = self.accept_compression_encodings;
3409                    let send_compression_encodings = self.send_compression_encodings;
3410                    let max_decoding_message_size = self.max_decoding_message_size;
3411                    let max_encoding_message_size = self.max_encoding_message_size;
3412                    let inner = self.inner.clone();
3413                    let fut = async move {
3414                        let method = StopDaemonSvc(inner);
3415                        let codec = tonic::codec::ProstCodec::default();
3416                        let mut grpc = tonic::server::Grpc::new(codec)
3417                            .apply_compression_config(
3418                                accept_compression_encodings,
3419                                send_compression_encodings,
3420                            )
3421                            .apply_max_message_size_config(
3422                                max_decoding_message_size,
3423                                max_encoding_message_size,
3424                            );
3425                        let res = grpc.unary(method, req).await;
3426                        Ok(res)
3427                    };
3428                    Box::pin(fut)
3429                }
3430                "/taprpc.TaprootAssets/DebugLevel" => {
3431                    #[allow(non_camel_case_types)]
3432                    struct DebugLevelSvc<T: TaprootAssets>(pub Arc<T>);
3433                    impl<
3434                        T: TaprootAssets,
3435                    > tonic::server::UnaryService<super::DebugLevelRequest>
3436                    for DebugLevelSvc<T> {
3437                        type Response = super::DebugLevelResponse;
3438                        type Future = BoxFuture<
3439                            tonic::Response<Self::Response>,
3440                            tonic::Status,
3441                        >;
3442                        fn call(
3443                            &mut self,
3444                            request: tonic::Request<super::DebugLevelRequest>,
3445                        ) -> Self::Future {
3446                            let inner = Arc::clone(&self.0);
3447                            let fut = async move {
3448                                <T as TaprootAssets>::debug_level(&inner, request).await
3449                            };
3450                            Box::pin(fut)
3451                        }
3452                    }
3453                    let accept_compression_encodings = self.accept_compression_encodings;
3454                    let send_compression_encodings = self.send_compression_encodings;
3455                    let max_decoding_message_size = self.max_decoding_message_size;
3456                    let max_encoding_message_size = self.max_encoding_message_size;
3457                    let inner = self.inner.clone();
3458                    let fut = async move {
3459                        let method = DebugLevelSvc(inner);
3460                        let codec = tonic::codec::ProstCodec::default();
3461                        let mut grpc = tonic::server::Grpc::new(codec)
3462                            .apply_compression_config(
3463                                accept_compression_encodings,
3464                                send_compression_encodings,
3465                            )
3466                            .apply_max_message_size_config(
3467                                max_decoding_message_size,
3468                                max_encoding_message_size,
3469                            );
3470                        let res = grpc.unary(method, req).await;
3471                        Ok(res)
3472                    };
3473                    Box::pin(fut)
3474                }
3475                "/taprpc.TaprootAssets/QueryAddrs" => {
3476                    #[allow(non_camel_case_types)]
3477                    struct QueryAddrsSvc<T: TaprootAssets>(pub Arc<T>);
3478                    impl<
3479                        T: TaprootAssets,
3480                    > tonic::server::UnaryService<super::QueryAddrRequest>
3481                    for QueryAddrsSvc<T> {
3482                        type Response = super::QueryAddrResponse;
3483                        type Future = BoxFuture<
3484                            tonic::Response<Self::Response>,
3485                            tonic::Status,
3486                        >;
3487                        fn call(
3488                            &mut self,
3489                            request: tonic::Request<super::QueryAddrRequest>,
3490                        ) -> Self::Future {
3491                            let inner = Arc::clone(&self.0);
3492                            let fut = async move {
3493                                <T as TaprootAssets>::query_addrs(&inner, request).await
3494                            };
3495                            Box::pin(fut)
3496                        }
3497                    }
3498                    let accept_compression_encodings = self.accept_compression_encodings;
3499                    let send_compression_encodings = self.send_compression_encodings;
3500                    let max_decoding_message_size = self.max_decoding_message_size;
3501                    let max_encoding_message_size = self.max_encoding_message_size;
3502                    let inner = self.inner.clone();
3503                    let fut = async move {
3504                        let method = QueryAddrsSvc(inner);
3505                        let codec = tonic::codec::ProstCodec::default();
3506                        let mut grpc = tonic::server::Grpc::new(codec)
3507                            .apply_compression_config(
3508                                accept_compression_encodings,
3509                                send_compression_encodings,
3510                            )
3511                            .apply_max_message_size_config(
3512                                max_decoding_message_size,
3513                                max_encoding_message_size,
3514                            );
3515                        let res = grpc.unary(method, req).await;
3516                        Ok(res)
3517                    };
3518                    Box::pin(fut)
3519                }
3520                "/taprpc.TaprootAssets/NewAddr" => {
3521                    #[allow(non_camel_case_types)]
3522                    struct NewAddrSvc<T: TaprootAssets>(pub Arc<T>);
3523                    impl<
3524                        T: TaprootAssets,
3525                    > tonic::server::UnaryService<super::NewAddrRequest>
3526                    for NewAddrSvc<T> {
3527                        type Response = super::Addr;
3528                        type Future = BoxFuture<
3529                            tonic::Response<Self::Response>,
3530                            tonic::Status,
3531                        >;
3532                        fn call(
3533                            &mut self,
3534                            request: tonic::Request<super::NewAddrRequest>,
3535                        ) -> Self::Future {
3536                            let inner = Arc::clone(&self.0);
3537                            let fut = async move {
3538                                <T as TaprootAssets>::new_addr(&inner, request).await
3539                            };
3540                            Box::pin(fut)
3541                        }
3542                    }
3543                    let accept_compression_encodings = self.accept_compression_encodings;
3544                    let send_compression_encodings = self.send_compression_encodings;
3545                    let max_decoding_message_size = self.max_decoding_message_size;
3546                    let max_encoding_message_size = self.max_encoding_message_size;
3547                    let inner = self.inner.clone();
3548                    let fut = async move {
3549                        let method = NewAddrSvc(inner);
3550                        let codec = tonic::codec::ProstCodec::default();
3551                        let mut grpc = tonic::server::Grpc::new(codec)
3552                            .apply_compression_config(
3553                                accept_compression_encodings,
3554                                send_compression_encodings,
3555                            )
3556                            .apply_max_message_size_config(
3557                                max_decoding_message_size,
3558                                max_encoding_message_size,
3559                            );
3560                        let res = grpc.unary(method, req).await;
3561                        Ok(res)
3562                    };
3563                    Box::pin(fut)
3564                }
3565                "/taprpc.TaprootAssets/DecodeAddr" => {
3566                    #[allow(non_camel_case_types)]
3567                    struct DecodeAddrSvc<T: TaprootAssets>(pub Arc<T>);
3568                    impl<
3569                        T: TaprootAssets,
3570                    > tonic::server::UnaryService<super::DecodeAddrRequest>
3571                    for DecodeAddrSvc<T> {
3572                        type Response = super::Addr;
3573                        type Future = BoxFuture<
3574                            tonic::Response<Self::Response>,
3575                            tonic::Status,
3576                        >;
3577                        fn call(
3578                            &mut self,
3579                            request: tonic::Request<super::DecodeAddrRequest>,
3580                        ) -> Self::Future {
3581                            let inner = Arc::clone(&self.0);
3582                            let fut = async move {
3583                                <T as TaprootAssets>::decode_addr(&inner, request).await
3584                            };
3585                            Box::pin(fut)
3586                        }
3587                    }
3588                    let accept_compression_encodings = self.accept_compression_encodings;
3589                    let send_compression_encodings = self.send_compression_encodings;
3590                    let max_decoding_message_size = self.max_decoding_message_size;
3591                    let max_encoding_message_size = self.max_encoding_message_size;
3592                    let inner = self.inner.clone();
3593                    let fut = async move {
3594                        let method = DecodeAddrSvc(inner);
3595                        let codec = tonic::codec::ProstCodec::default();
3596                        let mut grpc = tonic::server::Grpc::new(codec)
3597                            .apply_compression_config(
3598                                accept_compression_encodings,
3599                                send_compression_encodings,
3600                            )
3601                            .apply_max_message_size_config(
3602                                max_decoding_message_size,
3603                                max_encoding_message_size,
3604                            );
3605                        let res = grpc.unary(method, req).await;
3606                        Ok(res)
3607                    };
3608                    Box::pin(fut)
3609                }
3610                "/taprpc.TaprootAssets/AddrReceives" => {
3611                    #[allow(non_camel_case_types)]
3612                    struct AddrReceivesSvc<T: TaprootAssets>(pub Arc<T>);
3613                    impl<
3614                        T: TaprootAssets,
3615                    > tonic::server::UnaryService<super::AddrReceivesRequest>
3616                    for AddrReceivesSvc<T> {
3617                        type Response = super::AddrReceivesResponse;
3618                        type Future = BoxFuture<
3619                            tonic::Response<Self::Response>,
3620                            tonic::Status,
3621                        >;
3622                        fn call(
3623                            &mut self,
3624                            request: tonic::Request<super::AddrReceivesRequest>,
3625                        ) -> Self::Future {
3626                            let inner = Arc::clone(&self.0);
3627                            let fut = async move {
3628                                <T as TaprootAssets>::addr_receives(&inner, request).await
3629                            };
3630                            Box::pin(fut)
3631                        }
3632                    }
3633                    let accept_compression_encodings = self.accept_compression_encodings;
3634                    let send_compression_encodings = self.send_compression_encodings;
3635                    let max_decoding_message_size = self.max_decoding_message_size;
3636                    let max_encoding_message_size = self.max_encoding_message_size;
3637                    let inner = self.inner.clone();
3638                    let fut = async move {
3639                        let method = AddrReceivesSvc(inner);
3640                        let codec = tonic::codec::ProstCodec::default();
3641                        let mut grpc = tonic::server::Grpc::new(codec)
3642                            .apply_compression_config(
3643                                accept_compression_encodings,
3644                                send_compression_encodings,
3645                            )
3646                            .apply_max_message_size_config(
3647                                max_decoding_message_size,
3648                                max_encoding_message_size,
3649                            );
3650                        let res = grpc.unary(method, req).await;
3651                        Ok(res)
3652                    };
3653                    Box::pin(fut)
3654                }
3655                "/taprpc.TaprootAssets/VerifyProof" => {
3656                    #[allow(non_camel_case_types)]
3657                    struct VerifyProofSvc<T: TaprootAssets>(pub Arc<T>);
3658                    impl<T: TaprootAssets> tonic::server::UnaryService<super::ProofFile>
3659                    for VerifyProofSvc<T> {
3660                        type Response = super::VerifyProofResponse;
3661                        type Future = BoxFuture<
3662                            tonic::Response<Self::Response>,
3663                            tonic::Status,
3664                        >;
3665                        fn call(
3666                            &mut self,
3667                            request: tonic::Request<super::ProofFile>,
3668                        ) -> Self::Future {
3669                            let inner = Arc::clone(&self.0);
3670                            let fut = async move {
3671                                <T as TaprootAssets>::verify_proof(&inner, request).await
3672                            };
3673                            Box::pin(fut)
3674                        }
3675                    }
3676                    let accept_compression_encodings = self.accept_compression_encodings;
3677                    let send_compression_encodings = self.send_compression_encodings;
3678                    let max_decoding_message_size = self.max_decoding_message_size;
3679                    let max_encoding_message_size = self.max_encoding_message_size;
3680                    let inner = self.inner.clone();
3681                    let fut = async move {
3682                        let method = VerifyProofSvc(inner);
3683                        let codec = tonic::codec::ProstCodec::default();
3684                        let mut grpc = tonic::server::Grpc::new(codec)
3685                            .apply_compression_config(
3686                                accept_compression_encodings,
3687                                send_compression_encodings,
3688                            )
3689                            .apply_max_message_size_config(
3690                                max_decoding_message_size,
3691                                max_encoding_message_size,
3692                            );
3693                        let res = grpc.unary(method, req).await;
3694                        Ok(res)
3695                    };
3696                    Box::pin(fut)
3697                }
3698                "/taprpc.TaprootAssets/DecodeProof" => {
3699                    #[allow(non_camel_case_types)]
3700                    struct DecodeProofSvc<T: TaprootAssets>(pub Arc<T>);
3701                    impl<
3702                        T: TaprootAssets,
3703                    > tonic::server::UnaryService<super::DecodeProofRequest>
3704                    for DecodeProofSvc<T> {
3705                        type Response = super::DecodeProofResponse;
3706                        type Future = BoxFuture<
3707                            tonic::Response<Self::Response>,
3708                            tonic::Status,
3709                        >;
3710                        fn call(
3711                            &mut self,
3712                            request: tonic::Request<super::DecodeProofRequest>,
3713                        ) -> Self::Future {
3714                            let inner = Arc::clone(&self.0);
3715                            let fut = async move {
3716                                <T as TaprootAssets>::decode_proof(&inner, request).await
3717                            };
3718                            Box::pin(fut)
3719                        }
3720                    }
3721                    let accept_compression_encodings = self.accept_compression_encodings;
3722                    let send_compression_encodings = self.send_compression_encodings;
3723                    let max_decoding_message_size = self.max_decoding_message_size;
3724                    let max_encoding_message_size = self.max_encoding_message_size;
3725                    let inner = self.inner.clone();
3726                    let fut = async move {
3727                        let method = DecodeProofSvc(inner);
3728                        let codec = tonic::codec::ProstCodec::default();
3729                        let mut grpc = tonic::server::Grpc::new(codec)
3730                            .apply_compression_config(
3731                                accept_compression_encodings,
3732                                send_compression_encodings,
3733                            )
3734                            .apply_max_message_size_config(
3735                                max_decoding_message_size,
3736                                max_encoding_message_size,
3737                            );
3738                        let res = grpc.unary(method, req).await;
3739                        Ok(res)
3740                    };
3741                    Box::pin(fut)
3742                }
3743                "/taprpc.TaprootAssets/ExportProof" => {
3744                    #[allow(non_camel_case_types)]
3745                    struct ExportProofSvc<T: TaprootAssets>(pub Arc<T>);
3746                    impl<
3747                        T: TaprootAssets,
3748                    > tonic::server::UnaryService<super::ExportProofRequest>
3749                    for ExportProofSvc<T> {
3750                        type Response = super::ProofFile;
3751                        type Future = BoxFuture<
3752                            tonic::Response<Self::Response>,
3753                            tonic::Status,
3754                        >;
3755                        fn call(
3756                            &mut self,
3757                            request: tonic::Request<super::ExportProofRequest>,
3758                        ) -> Self::Future {
3759                            let inner = Arc::clone(&self.0);
3760                            let fut = async move {
3761                                <T as TaprootAssets>::export_proof(&inner, request).await
3762                            };
3763                            Box::pin(fut)
3764                        }
3765                    }
3766                    let accept_compression_encodings = self.accept_compression_encodings;
3767                    let send_compression_encodings = self.send_compression_encodings;
3768                    let max_decoding_message_size = self.max_decoding_message_size;
3769                    let max_encoding_message_size = self.max_encoding_message_size;
3770                    let inner = self.inner.clone();
3771                    let fut = async move {
3772                        let method = ExportProofSvc(inner);
3773                        let codec = tonic::codec::ProstCodec::default();
3774                        let mut grpc = tonic::server::Grpc::new(codec)
3775                            .apply_compression_config(
3776                                accept_compression_encodings,
3777                                send_compression_encodings,
3778                            )
3779                            .apply_max_message_size_config(
3780                                max_decoding_message_size,
3781                                max_encoding_message_size,
3782                            );
3783                        let res = grpc.unary(method, req).await;
3784                        Ok(res)
3785                    };
3786                    Box::pin(fut)
3787                }
3788                "/taprpc.TaprootAssets/UnpackProofFile" => {
3789                    #[allow(non_camel_case_types)]
3790                    struct UnpackProofFileSvc<T: TaprootAssets>(pub Arc<T>);
3791                    impl<
3792                        T: TaprootAssets,
3793                    > tonic::server::UnaryService<super::UnpackProofFileRequest>
3794                    for UnpackProofFileSvc<T> {
3795                        type Response = super::UnpackProofFileResponse;
3796                        type Future = BoxFuture<
3797                            tonic::Response<Self::Response>,
3798                            tonic::Status,
3799                        >;
3800                        fn call(
3801                            &mut self,
3802                            request: tonic::Request<super::UnpackProofFileRequest>,
3803                        ) -> Self::Future {
3804                            let inner = Arc::clone(&self.0);
3805                            let fut = async move {
3806                                <T as TaprootAssets>::unpack_proof_file(&inner, request)
3807                                    .await
3808                            };
3809                            Box::pin(fut)
3810                        }
3811                    }
3812                    let accept_compression_encodings = self.accept_compression_encodings;
3813                    let send_compression_encodings = self.send_compression_encodings;
3814                    let max_decoding_message_size = self.max_decoding_message_size;
3815                    let max_encoding_message_size = self.max_encoding_message_size;
3816                    let inner = self.inner.clone();
3817                    let fut = async move {
3818                        let method = UnpackProofFileSvc(inner);
3819                        let codec = tonic::codec::ProstCodec::default();
3820                        let mut grpc = tonic::server::Grpc::new(codec)
3821                            .apply_compression_config(
3822                                accept_compression_encodings,
3823                                send_compression_encodings,
3824                            )
3825                            .apply_max_message_size_config(
3826                                max_decoding_message_size,
3827                                max_encoding_message_size,
3828                            );
3829                        let res = grpc.unary(method, req).await;
3830                        Ok(res)
3831                    };
3832                    Box::pin(fut)
3833                }
3834                "/taprpc.TaprootAssets/SendAsset" => {
3835                    #[allow(non_camel_case_types)]
3836                    struct SendAssetSvc<T: TaprootAssets>(pub Arc<T>);
3837                    impl<
3838                        T: TaprootAssets,
3839                    > tonic::server::UnaryService<super::SendAssetRequest>
3840                    for SendAssetSvc<T> {
3841                        type Response = super::SendAssetResponse;
3842                        type Future = BoxFuture<
3843                            tonic::Response<Self::Response>,
3844                            tonic::Status,
3845                        >;
3846                        fn call(
3847                            &mut self,
3848                            request: tonic::Request<super::SendAssetRequest>,
3849                        ) -> Self::Future {
3850                            let inner = Arc::clone(&self.0);
3851                            let fut = async move {
3852                                <T as TaprootAssets>::send_asset(&inner, request).await
3853                            };
3854                            Box::pin(fut)
3855                        }
3856                    }
3857                    let accept_compression_encodings = self.accept_compression_encodings;
3858                    let send_compression_encodings = self.send_compression_encodings;
3859                    let max_decoding_message_size = self.max_decoding_message_size;
3860                    let max_encoding_message_size = self.max_encoding_message_size;
3861                    let inner = self.inner.clone();
3862                    let fut = async move {
3863                        let method = SendAssetSvc(inner);
3864                        let codec = tonic::codec::ProstCodec::default();
3865                        let mut grpc = tonic::server::Grpc::new(codec)
3866                            .apply_compression_config(
3867                                accept_compression_encodings,
3868                                send_compression_encodings,
3869                            )
3870                            .apply_max_message_size_config(
3871                                max_decoding_message_size,
3872                                max_encoding_message_size,
3873                            );
3874                        let res = grpc.unary(method, req).await;
3875                        Ok(res)
3876                    };
3877                    Box::pin(fut)
3878                }
3879                "/taprpc.TaprootAssets/BurnAsset" => {
3880                    #[allow(non_camel_case_types)]
3881                    struct BurnAssetSvc<T: TaprootAssets>(pub Arc<T>);
3882                    impl<
3883                        T: TaprootAssets,
3884                    > tonic::server::UnaryService<super::BurnAssetRequest>
3885                    for BurnAssetSvc<T> {
3886                        type Response = super::BurnAssetResponse;
3887                        type Future = BoxFuture<
3888                            tonic::Response<Self::Response>,
3889                            tonic::Status,
3890                        >;
3891                        fn call(
3892                            &mut self,
3893                            request: tonic::Request<super::BurnAssetRequest>,
3894                        ) -> Self::Future {
3895                            let inner = Arc::clone(&self.0);
3896                            let fut = async move {
3897                                <T as TaprootAssets>::burn_asset(&inner, request).await
3898                            };
3899                            Box::pin(fut)
3900                        }
3901                    }
3902                    let accept_compression_encodings = self.accept_compression_encodings;
3903                    let send_compression_encodings = self.send_compression_encodings;
3904                    let max_decoding_message_size = self.max_decoding_message_size;
3905                    let max_encoding_message_size = self.max_encoding_message_size;
3906                    let inner = self.inner.clone();
3907                    let fut = async move {
3908                        let method = BurnAssetSvc(inner);
3909                        let codec = tonic::codec::ProstCodec::default();
3910                        let mut grpc = tonic::server::Grpc::new(codec)
3911                            .apply_compression_config(
3912                                accept_compression_encodings,
3913                                send_compression_encodings,
3914                            )
3915                            .apply_max_message_size_config(
3916                                max_decoding_message_size,
3917                                max_encoding_message_size,
3918                            );
3919                        let res = grpc.unary(method, req).await;
3920                        Ok(res)
3921                    };
3922                    Box::pin(fut)
3923                }
3924                "/taprpc.TaprootAssets/ListBurns" => {
3925                    #[allow(non_camel_case_types)]
3926                    struct ListBurnsSvc<T: TaprootAssets>(pub Arc<T>);
3927                    impl<
3928                        T: TaprootAssets,
3929                    > tonic::server::UnaryService<super::ListBurnsRequest>
3930                    for ListBurnsSvc<T> {
3931                        type Response = super::ListBurnsResponse;
3932                        type Future = BoxFuture<
3933                            tonic::Response<Self::Response>,
3934                            tonic::Status,
3935                        >;
3936                        fn call(
3937                            &mut self,
3938                            request: tonic::Request<super::ListBurnsRequest>,
3939                        ) -> Self::Future {
3940                            let inner = Arc::clone(&self.0);
3941                            let fut = async move {
3942                                <T as TaprootAssets>::list_burns(&inner, request).await
3943                            };
3944                            Box::pin(fut)
3945                        }
3946                    }
3947                    let accept_compression_encodings = self.accept_compression_encodings;
3948                    let send_compression_encodings = self.send_compression_encodings;
3949                    let max_decoding_message_size = self.max_decoding_message_size;
3950                    let max_encoding_message_size = self.max_encoding_message_size;
3951                    let inner = self.inner.clone();
3952                    let fut = async move {
3953                        let method = ListBurnsSvc(inner);
3954                        let codec = tonic::codec::ProstCodec::default();
3955                        let mut grpc = tonic::server::Grpc::new(codec)
3956                            .apply_compression_config(
3957                                accept_compression_encodings,
3958                                send_compression_encodings,
3959                            )
3960                            .apply_max_message_size_config(
3961                                max_decoding_message_size,
3962                                max_encoding_message_size,
3963                            );
3964                        let res = grpc.unary(method, req).await;
3965                        Ok(res)
3966                    };
3967                    Box::pin(fut)
3968                }
3969                "/taprpc.TaprootAssets/GetInfo" => {
3970                    #[allow(non_camel_case_types)]
3971                    struct GetInfoSvc<T: TaprootAssets>(pub Arc<T>);
3972                    impl<
3973                        T: TaprootAssets,
3974                    > tonic::server::UnaryService<super::GetInfoRequest>
3975                    for GetInfoSvc<T> {
3976                        type Response = super::GetInfoResponse;
3977                        type Future = BoxFuture<
3978                            tonic::Response<Self::Response>,
3979                            tonic::Status,
3980                        >;
3981                        fn call(
3982                            &mut self,
3983                            request: tonic::Request<super::GetInfoRequest>,
3984                        ) -> Self::Future {
3985                            let inner = Arc::clone(&self.0);
3986                            let fut = async move {
3987                                <T as TaprootAssets>::get_info(&inner, request).await
3988                            };
3989                            Box::pin(fut)
3990                        }
3991                    }
3992                    let accept_compression_encodings = self.accept_compression_encodings;
3993                    let send_compression_encodings = self.send_compression_encodings;
3994                    let max_decoding_message_size = self.max_decoding_message_size;
3995                    let max_encoding_message_size = self.max_encoding_message_size;
3996                    let inner = self.inner.clone();
3997                    let fut = async move {
3998                        let method = GetInfoSvc(inner);
3999                        let codec = tonic::codec::ProstCodec::default();
4000                        let mut grpc = tonic::server::Grpc::new(codec)
4001                            .apply_compression_config(
4002                                accept_compression_encodings,
4003                                send_compression_encodings,
4004                            )
4005                            .apply_max_message_size_config(
4006                                max_decoding_message_size,
4007                                max_encoding_message_size,
4008                            );
4009                        let res = grpc.unary(method, req).await;
4010                        Ok(res)
4011                    };
4012                    Box::pin(fut)
4013                }
4014                "/taprpc.TaprootAssets/FetchAssetMeta" => {
4015                    #[allow(non_camel_case_types)]
4016                    struct FetchAssetMetaSvc<T: TaprootAssets>(pub Arc<T>);
4017                    impl<
4018                        T: TaprootAssets,
4019                    > tonic::server::UnaryService<super::FetchAssetMetaRequest>
4020                    for FetchAssetMetaSvc<T> {
4021                        type Response = super::FetchAssetMetaResponse;
4022                        type Future = BoxFuture<
4023                            tonic::Response<Self::Response>,
4024                            tonic::Status,
4025                        >;
4026                        fn call(
4027                            &mut self,
4028                            request: tonic::Request<super::FetchAssetMetaRequest>,
4029                        ) -> Self::Future {
4030                            let inner = Arc::clone(&self.0);
4031                            let fut = async move {
4032                                <T as TaprootAssets>::fetch_asset_meta(&inner, request)
4033                                    .await
4034                            };
4035                            Box::pin(fut)
4036                        }
4037                    }
4038                    let accept_compression_encodings = self.accept_compression_encodings;
4039                    let send_compression_encodings = self.send_compression_encodings;
4040                    let max_decoding_message_size = self.max_decoding_message_size;
4041                    let max_encoding_message_size = self.max_encoding_message_size;
4042                    let inner = self.inner.clone();
4043                    let fut = async move {
4044                        let method = FetchAssetMetaSvc(inner);
4045                        let codec = tonic::codec::ProstCodec::default();
4046                        let mut grpc = tonic::server::Grpc::new(codec)
4047                            .apply_compression_config(
4048                                accept_compression_encodings,
4049                                send_compression_encodings,
4050                            )
4051                            .apply_max_message_size_config(
4052                                max_decoding_message_size,
4053                                max_encoding_message_size,
4054                            );
4055                        let res = grpc.unary(method, req).await;
4056                        Ok(res)
4057                    };
4058                    Box::pin(fut)
4059                }
4060                "/taprpc.TaprootAssets/SubscribeReceiveEvents" => {
4061                    #[allow(non_camel_case_types)]
4062                    struct SubscribeReceiveEventsSvc<T: TaprootAssets>(pub Arc<T>);
4063                    impl<
4064                        T: TaprootAssets,
4065                    > tonic::server::ServerStreamingService<
4066                        super::SubscribeReceiveEventsRequest,
4067                    > for SubscribeReceiveEventsSvc<T> {
4068                        type Response = super::ReceiveEvent;
4069                        type ResponseStream = T::SubscribeReceiveEventsStream;
4070                        type Future = BoxFuture<
4071                            tonic::Response<Self::ResponseStream>,
4072                            tonic::Status,
4073                        >;
4074                        fn call(
4075                            &mut self,
4076                            request: tonic::Request<super::SubscribeReceiveEventsRequest>,
4077                        ) -> Self::Future {
4078                            let inner = Arc::clone(&self.0);
4079                            let fut = async move {
4080                                <T as TaprootAssets>::subscribe_receive_events(
4081                                        &inner,
4082                                        request,
4083                                    )
4084                                    .await
4085                            };
4086                            Box::pin(fut)
4087                        }
4088                    }
4089                    let accept_compression_encodings = self.accept_compression_encodings;
4090                    let send_compression_encodings = self.send_compression_encodings;
4091                    let max_decoding_message_size = self.max_decoding_message_size;
4092                    let max_encoding_message_size = self.max_encoding_message_size;
4093                    let inner = self.inner.clone();
4094                    let fut = async move {
4095                        let method = SubscribeReceiveEventsSvc(inner);
4096                        let codec = tonic::codec::ProstCodec::default();
4097                        let mut grpc = tonic::server::Grpc::new(codec)
4098                            .apply_compression_config(
4099                                accept_compression_encodings,
4100                                send_compression_encodings,
4101                            )
4102                            .apply_max_message_size_config(
4103                                max_decoding_message_size,
4104                                max_encoding_message_size,
4105                            );
4106                        let res = grpc.server_streaming(method, req).await;
4107                        Ok(res)
4108                    };
4109                    Box::pin(fut)
4110                }
4111                "/taprpc.TaprootAssets/SubscribeSendEvents" => {
4112                    #[allow(non_camel_case_types)]
4113                    struct SubscribeSendEventsSvc<T: TaprootAssets>(pub Arc<T>);
4114                    impl<
4115                        T: TaprootAssets,
4116                    > tonic::server::ServerStreamingService<
4117                        super::SubscribeSendEventsRequest,
4118                    > for SubscribeSendEventsSvc<T> {
4119                        type Response = super::SendEvent;
4120                        type ResponseStream = T::SubscribeSendEventsStream;
4121                        type Future = BoxFuture<
4122                            tonic::Response<Self::ResponseStream>,
4123                            tonic::Status,
4124                        >;
4125                        fn call(
4126                            &mut self,
4127                            request: tonic::Request<super::SubscribeSendEventsRequest>,
4128                        ) -> Self::Future {
4129                            let inner = Arc::clone(&self.0);
4130                            let fut = async move {
4131                                <T as TaprootAssets>::subscribe_send_events(&inner, request)
4132                                    .await
4133                            };
4134                            Box::pin(fut)
4135                        }
4136                    }
4137                    let accept_compression_encodings = self.accept_compression_encodings;
4138                    let send_compression_encodings = self.send_compression_encodings;
4139                    let max_decoding_message_size = self.max_decoding_message_size;
4140                    let max_encoding_message_size = self.max_encoding_message_size;
4141                    let inner = self.inner.clone();
4142                    let fut = async move {
4143                        let method = SubscribeSendEventsSvc(inner);
4144                        let codec = tonic::codec::ProstCodec::default();
4145                        let mut grpc = tonic::server::Grpc::new(codec)
4146                            .apply_compression_config(
4147                                accept_compression_encodings,
4148                                send_compression_encodings,
4149                            )
4150                            .apply_max_message_size_config(
4151                                max_decoding_message_size,
4152                                max_encoding_message_size,
4153                            );
4154                        let res = grpc.server_streaming(method, req).await;
4155                        Ok(res)
4156                    };
4157                    Box::pin(fut)
4158                }
4159                "/taprpc.TaprootAssets/RegisterTransfer" => {
4160                    #[allow(non_camel_case_types)]
4161                    struct RegisterTransferSvc<T: TaprootAssets>(pub Arc<T>);
4162                    impl<
4163                        T: TaprootAssets,
4164                    > tonic::server::UnaryService<super::RegisterTransferRequest>
4165                    for RegisterTransferSvc<T> {
4166                        type Response = super::RegisterTransferResponse;
4167                        type Future = BoxFuture<
4168                            tonic::Response<Self::Response>,
4169                            tonic::Status,
4170                        >;
4171                        fn call(
4172                            &mut self,
4173                            request: tonic::Request<super::RegisterTransferRequest>,
4174                        ) -> Self::Future {
4175                            let inner = Arc::clone(&self.0);
4176                            let fut = async move {
4177                                <T as TaprootAssets>::register_transfer(&inner, request)
4178                                    .await
4179                            };
4180                            Box::pin(fut)
4181                        }
4182                    }
4183                    let accept_compression_encodings = self.accept_compression_encodings;
4184                    let send_compression_encodings = self.send_compression_encodings;
4185                    let max_decoding_message_size = self.max_decoding_message_size;
4186                    let max_encoding_message_size = self.max_encoding_message_size;
4187                    let inner = self.inner.clone();
4188                    let fut = async move {
4189                        let method = RegisterTransferSvc(inner);
4190                        let codec = tonic::codec::ProstCodec::default();
4191                        let mut grpc = tonic::server::Grpc::new(codec)
4192                            .apply_compression_config(
4193                                accept_compression_encodings,
4194                                send_compression_encodings,
4195                            )
4196                            .apply_max_message_size_config(
4197                                max_decoding_message_size,
4198                                max_encoding_message_size,
4199                            );
4200                        let res = grpc.unary(method, req).await;
4201                        Ok(res)
4202                    };
4203                    Box::pin(fut)
4204                }
4205                _ => {
4206                    Box::pin(async move {
4207                        let mut response = http::Response::new(
4208                            tonic::body::Body::default(),
4209                        );
4210                        let headers = response.headers_mut();
4211                        headers
4212                            .insert(
4213                                tonic::Status::GRPC_STATUS,
4214                                (tonic::Code::Unimplemented as i32).into(),
4215                            );
4216                        headers
4217                            .insert(
4218                                http::header::CONTENT_TYPE,
4219                                tonic::metadata::GRPC_CONTENT_TYPE,
4220                            );
4221                        Ok(response)
4222                    })
4223                }
4224            }
4225        }
4226    }
4227    impl<T> Clone for TaprootAssetsServer<T> {
4228        fn clone(&self) -> Self {
4229            let inner = self.inner.clone();
4230            Self {
4231                inner,
4232                accept_compression_encodings: self.accept_compression_encodings,
4233                send_compression_encodings: self.send_compression_encodings,
4234                max_decoding_message_size: self.max_decoding_message_size,
4235                max_encoding_message_size: self.max_encoding_message_size,
4236            }
4237        }
4238    }
4239    /// Generated gRPC service name
4240    pub const SERVICE_NAME: &str = "taprpc.TaprootAssets";
4241    impl<T> tonic::server::NamedService for TaprootAssetsServer<T> {
4242        const NAME: &'static str = SERVICE_NAME;
4243    }
4244}