In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-18 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >
Share
Shulou(Shulou.com)06/01 Report--
This article is to share with you about the features of BtcTool in php. The editor thinks it is very practical, so share it with you as a reference and follow the editor to have a look.
BtcTool is a PHP bitcoin application development kit based on third-party services and offline naked transactions. It is suitable for PHP developers who do not want to deploy local nodes. The development package mainly includes the following features:
Using third-party services to obtain utxo collections of specified addresses
Offline generation of naked consumer transactions
Broadcast naked transactions using third-party services
The third-party services currently supported by BtcTool include and can be easily extended:
Blockchain.info
Btc.com
BtcTool download address: http://sc.hubwiz.com/codebag/btc-php-lib/
1. Code list
BtcTool runs under the environment of * * Php 7.1 drivers *. The current version 1.0.0. The main code files are as follows:
The code file describes the btctool/src/Wallet.php offline wallet class Development package entry btctool/src/Utxo.php unconsumed transaction output class btctool/src/UtxoBag.phpUtxo collection class btctool/src/UtxoCollector.phpUtxo collector interface btctool/src/CloudUtxoCollector.php Utxo collector implementation based on third-party services btctool/src/UtxoSelector.phpUtxo filter interface btchtool/src/DefaultUtxoSelector.php default Utxo filter implementation btctool/src/Broadcaster.php transaction broadcaster interface btctool/src/CloudBroadcaster.php based on third-party services Transaction broadcaster implements btctool/src/Utils.php common auxiliary functions demo/wallet-init.php local wallet initialization demo/wallet-demo.php wallet load, Naked transaction construction and broadcast vendor third-party dependency package directory composer.jsoncomposer configuration file 2. instructions
The entry of BtcTool is the Wallet class, and the basic steps are as follows:
Create an instance of Wallet
Add the private key to the Wallet instance
Use the * * sendTx () * * method of the Wallet instance to obtain the encoded naked transaction
Use the * * broadcast () * * method of the Wallet instance to broadcast naked transactions
The sample code is as follows, which is explained in the notes:
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.