We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Originally posted by @asalomeri in blockcypher/explorer#572
The text was updated successfully, but these errors were encountered:
import requests
block_url = "https://api.blockcypher.com/v1/btc/main/blocks/00000000000000000000cfbeaeb0b5f18dffc118597310d3f87096a2a204b512" response = requests.get(block_url) block_data = response.json()
print(f"Block Height: {block_data['height']}") print(f"Block Hash: {block_data['hash']}") print(f"Previous Block Hash: {block_data['prev_block']}") print(f"Time: {block_data['time']}") print(f"Number of Transactions: {block_data['n_tx']}") print(f"Total Value: {block_data['total']} satoshis") print(f"Fees: {block_data['fees']} satoshis")
Sorry, something went wrong.
from bitcoinlib.wallets import Wallet
wallet = Wallet('MyWallet') # تأكد من أن المحفظة "MyWallet" تم إنشاؤها مسبقًا وتحتوي على المفتاح الخاص للعنوان المصدر
destination_address = 'bc1qv4ccyjl85pnm89fl3kqlkeegc5resqwzjg4tzz'
amount_btc = 1.0 # قم بتحديد المبلغ الذي تود تحويله
tx = wallet.send_to(destination_address, amount_btc)
print("Transaction ID:", tx.txid) print("Transaction details:", tx.info())
No branches or pull requests
Originally posted by @asalomeri in blockcypher/explorer#572
The text was updated successfully, but these errors were encountered: