
Exploring Blockchain Data
FreeEfficiently query and analyze blockchain data across networks.
Free · Opens the source repo
What Exploring Blockchain Data does
Exploring Blockchain Data is a command-line interface (CLI) tool designed for developers and blockchain enthusiasts who need to query and analyze blockchain data across multiple EVM-compatible networks, including Ethereum, Polygon, Arbitrum, Optimism, and Binance Smart Chain (BSC). This skill allows users to perform a variety of operations, such as looking up transactions, checking address balances, inspecting blocks, and tracking token holdings, all from a unified interface. By leveraging the power of Python and specific blockchain APIs, it simplifies the process of accessing complex blockchain data.
The skill requires users to set up their environment with Python 3.8 or higher and install necessary libraries like requests and web3. Users must also obtain an Etherscan API key to enhance their query limits. Once set up, the CLI provides straightforward commands to execute various queries. For example, users can retrieve transaction details by hash, check wallet balances, or even analyze the most recent blocks. The inclusion of detailed output options allows for in-depth insights into transactions, including gas details and decoded function calls, which can be crucial for developers working with smart contracts.
This skill is particularly useful for developers who need to interact with blockchain data regularly, whether for building decentralized applications, conducting audits, or performing analytics. It streamlines the workflow by providing a set of commands that can be easily integrated into scripts or used interactively. Additionally, the ability to export results in JSON or CSV formats makes it suitable for further data processing or reporting.
Overall, Exploring Blockchain Data is a practical tool for anyone involved in blockchain development or analysis, providing essential capabilities to access and interpret on-chain data efficiently.
When to use it
Use this tool when you need to perform transactions lookups, address balance checks, or analyze blockchain data quickly.
When not to use it
This skill is not suitable for users who require a graphical interface or those who do not have experience with command-line tools.
What you can build with it
Transaction Lookup
Use the CLI to quickly look up transaction details across different EVM chains by providing the transaction hash.
Wallet Analysis
Analyze a wallet's transaction history and token holdings by querying the address with specific flags for detailed insights.
Block Inspection
Inspect the latest blocks or specific block details to monitor on-chain activity and gas usage.
How to install Exploring Blockchain Data
View source1. Install with the skills CLI
npx skills add jeremylongshore/claude-code-plugins-plus-skills/exploring-blockchain-data --agent claude-code2. Or install it manually
Download the skill folder and drop it into ~/.claude/skills/ for all projects, or .claude/skills/ to scope it to one repo. Restart Claude Code so it picks up the new skill.
Anthropic's agentic coding CLI, and the reference implementation of Agent Skills. Drop a skill folder into ~/.claude/skills and Claude Code loads it automatically whenever a task matches the skill's description. Claude Code docs
Inside SKILL.md
Written by jeremylongshoreExploring Blockchain Data
Overview
Query and analyze blockchain data across multiple EVM-compatible networks including Ethereum, Polygon, Arbitrum, Optimism, and BSC. Supports transaction lookups, address balance checks, block inspection, token balance queries, transaction history retrieval, and whale wallet tracking via a unified CLI.
Prerequisites
- Python 3.8+ with
requestsandweb3libraries installed (pip install requests web3) - Etherscan API key (free tier provides 5 requests/second; set via
ETHERSCAN_API_KEYenvironment variable) - Optional: API keys for Polygonscan, Arbiscan, and other chain-specific explorers for higher rate limits
blockchain_explorer.pyCLI script,chain_client.py, andtoken_resolver.pymodules available in the plugin directory- RPC endpoint access (public endpoints work; dedicated providers like Alchemy, Infura, Chainstack, or QuickNode recommended for reliability)
Instructions
- Set the Etherscan API key as an environment variable:
export ETHERSCAN_API_KEY=<key>to unlock higher rate limits beyond the default 5 requests/second. - Run
python blockchain_explorer.py tx <hash>to look up a transaction by hash, returning status, block number, from/to addresses, value transferred, and gas details. - Append
--detailedto the transaction query to decode the function call, identify the interacting protocol, and display input parameters. - Specify
--chain polygon,--chain arbitrum, or--chain bscto query transactions on alternative EVM chains when the hash is not found on Ethereum. - Run
python blockchain_explorer.py address <address>to check the native token balance and total transaction count for a wallet. - Add
--history --limit 50to the address query to retrieve the most recent 50 transactions with timestamps, values, and counterparties. - Add
--tokensto the address query to list all ERC-20 token holdings with balances, symbols, and USD values via CoinGecko price resolution. - Run
python blockchain_explorer.py block latestto inspect the most recent block, orpython blockchain_explorer.py block <number>for a specific block. - Run
python blockchain_explorer.py token <wallet> <contract>to check the balance of a specific ERC-20 token at a wallet address, with automatic decimal and symbol resolution. - Export any query result in JSON or CSV format using
--format jsonor--format csvand redirect to a file for downstream processing. - Enable verbose mode with
--verboseto display API request URLs, response times, cache hit/miss status, and rate limit counters for debugging.
See ${CLAUDE_SKILL_DIR}/references/implementation.md for the full four-step implementation workflow.
Output
- Transaction detail tables showing hash, chain, status, block number, from/to addresses, value, gas price (Gwei), gas limit, gas used, and gas cost
- Decoded transaction data with function name, protocol identification, and parsed input parameters (when
--detailedis used) - Address summary with native balance, transaction count, and explorer link
- Transaction history tables with timestamp, hash, from/to, value, and direction (in/out)
- Token balance listings with contract address, token name, symbol, raw balance, human-readable balance, and USD value
- Block details with block number, timestamp, transaction count, gas used, and miner/validator
- JSON (
output.json) or CSV (transactions.csv) export files for programmatic consumption
Error Handling
| Error | Cause | Solution |
|---|---|---|
Transaction not found | Transaction pending in mempool, wrong chain selected, or invalid hash | Wait and retry for pending transactions; try --chain polygon, --chain arbitrum, --chain bsc; verify hash is 66 characters starting with 0x |
Explorer API error: Max rate limit reached | Too many requests; no API key or quota exhausted | Wait 1-5 seconds and retry; set ETHERSCAN_API_KEY for higher limits; upgrade to paid tier for production use |
RPC error: execution timeout | RPC endpoint overloaded or complex query timed out | Retry with a different RPC endpoint; use a dedicated provider (Alchemy, Infura, QuickNode); simplify the query |
Invalid address: 0xinvalid | Address has wrong length, invalid checksum, or non-hex characters | Verify 42 characters with 0x prefix; use the checksummed version from a block explorer; convert to lowercase if checksum fails |
Contract source code not verified | Contract source not published on the explorer | Use known function signature databases for decoding; check if the contract is a proxy and look up the implementation address |
Token: ??? (Unknown Token) | Token too new, too obscure, or not tracked by CoinGecko | Check the token contract directly on the explorer; look up on a DEX (Uniswap, SushiSwap); manually specify decimals if known |
Price: N/A | Token not listed on CoinGecko, API rate limited, or very low liquidity | Check the DEX for on-chain price; use an alternative price feed; calculate from LP reserves |
ImportError: No module named 'requests' | Missing Python dependencies | Run pip install requests web3 to install required packages |
Examples
Look Up a Transaction Across Chains
# Try Ethereum first, then Polygon if not found
python blockchain_explorer.py tx 0x1234...abcdef --chain ethereum
python blockchain_explorer.py tx 0x1234...abcdef --chain polygon
Returns a formatted table with transaction status, block number, value transferred, gas details, and a link to the block explorer. Adding --detailed decodes the function call (e.g., swapExactTokensForTokens on Uniswap).
Full Wallet Analysis
python blockchain_explorer.py address 0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045 --history --tokens --limit 50
Produces a wallet summary (ETH balance, total transaction count), the 50 most recent transactions with timestamps and counterparties, and a complete ERC-20 token holdings list with USD values. Useful for whale watching or due diligence on a wallet.
Check USDC Balance and Export to JSON
python blockchain_explorer.py token 0xYourWallet 0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48 --format json > usdc_balance.json
Resolves the USDC contract, fetches the wallet balance with proper decimal handling (6 decimals for USDC), includes the current USD price, and writes the result to usdc_balance.json for integration with dashboards or alerting pipelines.
Resources
- Etherscan API Documentation -- primary explorer API for Ethereum; free tier available with registration
- CoinGecko API -- token price resolution and metadata lookup
- web3.py Documentation -- Python library for direct RPC interaction with EVM chains
- Alchemy / Infura / QuickNode -- dedicated RPC providers for reliable node access
- 4byte.directory -- function signature database for decoding unverified contract interactions
Frequently asked questions about Exploring Blockchain Data
Similar skills
WinMD API Search
Easily find and explore Windows desktop APIs.
WebMCPify
Transform any web app into an agent-ready platform.
Phoenix Tracing
Instrument LLM applications with OpenInference tracing.
Foundry Hosted Agent CopilotKit
Guidance for developing agentic web apps on Azure.
Power Automate Foundation
Connect AI agents to Power Automate seamlessly.
Power Automate Flow Builder
Efficiently build and deploy Power Automate flows programmatically.
