Ok(GetDescriptorInfoResult { descriptor: desc, checksum: "".into(), is_range: false, is_solvable: false, has_private_keys: true, }) } fn import_descriptors( &self, req: Vec<ImportDescriptors>, ) -> Result<Vec<ImportMultiResult>, jsonrpc_core::Error> { self .state() .descriptors .extend(req.into_iter().map(|params| params.descriptor)); Ok(vec![ImportMultiResult { success: true, warnings: Vec::new(), error: None, }]) } fn get_new_address( &self, _label: Option<String>, _address_type: Option<bitcoincore_rpc::json::AddressType>, ) -> Result<bitcoin::Address, jsonrpc_core::Error> { let secp256k1 = Secp256k1::new(); let key_pair = KeyPair::new(&secp256k1, &mut rand::thread_rng()); let (public_key, _parity) = XOnlyPublicKey::from_keypair(&key_pair); let address = Address::p2tr(&secp256k1, public_key, None, self.network); Ok(address) } fn list_transactions( &self, _label: Option<String>,
Inscription number 45,021,831
Genesis block 819,131
File type text
File size 1.02 KB
Creation date Nov 30,2023 2:45 pm