This application is designed to fetch and analyze Bitcoin transactions associated with a specific address, leveraging the capabilities of Quicknode's Blockbook add-on. It provides users with detailed reports within a specified date range, offering insights into transaction history, balances after each transaction, and the USD value of Bitcoin movements.
For an in-depth guide on how to fetch data and develop further functionalities, refer to our comprehensive guide on Quicknode or our script files.
- Frontend Framework/Library: React
- Language: TypeScript
- Build Tool/Development Server: Vite
- Balance Calculation: Calculates the BTC balance before and after each transaction.
- Transaction Direction: Identifies whether transactions are incoming or outgoing.
- Confirmation Status: Determines whether transactions are confirmed.
- USD Conversion: Computes the USD value of each transaction at the time it occurred.
- Transaction Filtering: Excludes internal wallet transactions that are not relevant to the address in question.
- Date Range Filtering: Generates reports for transactions within a specified date range.
- Time Zone Selection: Performs date filtering according to the selected timezone.
- CSV Support: Ability to export or copy result as CSV file.
Before you begin, ensure you have the following:
- Node.js installed on your system.
- A Quicknode account with the Blockbook RPC add-on enabled.
Blockbook RPC is a paid add-on. Please check the details here and compare plans based on your needs.
- A code editor or an IDE (e.g., VS Code)
- Typescript and ts-node
You can run the commands below to install TypeScript and ts-node globally to have TypeScript available across all projects.
npm install -g typescript
npm install -g ts-node- Clone the repository to your local machine:
git clone https://github.com/quiknode-labs/qn-guide-examples.git- Navigate to the project directory:
cd sample-dapps/bitcoin-transaction-report-generator- Install the necessary dependencies:
npm installRename .env.example to .env and replace the YOUR_QUICKNODE_BITCOIN_ENDPOINT_URL placeholder with your Quicknode Bitcoin Node Endpoint. Make sure that the Blockbook RPC add-on is enabled.
VITE_QUICKNODE_ENDPOINT = "YOUR_QUICKNODE_BITCOIN_ENDPOINT_URL"Please note that while we utilize
dotenvfor environment variable management, sensitive information like endpoints can still be visible on the frontend. This configuration is not recommended for production environments as-is.
Run the development server:
npm run devOpen http://localhost:5173/ with your browser to see the application.
- Input a Bitcoin wallet address.
- (Optional) Select date range and time zone.
- Press
Generate. - (Optional) Export or copy results as CSV.
The Bitcoin Transaction Report Generator application will query the Bitcoin blockchain for the wallet's transactions, filter these transactions data and calculate additional variables. Lastly, the app display results.
Quicknode's Blockbook add-on facilitates the creation of detailed Bitcoin transaction reports for developers and businesses alike. While this application covers the fundamentals, there's a vast scope for customization and extended functionalities. Whether for audit purposes, regulatory compliance, or market analysis, the Blockbook add-on streamlines the process of extracting blockchain data.
To discover more about how Quicknode assists auditing firms and individuals in extracting this type of data from blockchains, please contact us; we're eager to engage with you!
