A simple Telegram bot that tracks Ethereum wallet transactions using the Etherscan API. Send an Ethereum address to the bot, and it will reply with the latest transaction details.
- ✅ Track the latest transaction of any Ethereum wallet.
- ✅ Converts wei to ETH for easy reading.
- ✅ Displays human-readable timestamps.
- ✅ Validates Ethereum wallet addresses.
- ✅ Handles API and network errors gracefully.
- Python 3.7+
- Telegram Bot Token (Open Telegram and search for @BotFather)
- Etherscan API Key
pip install python-telegram-bot requests
- Clone the repository:
git clone https://github.com/fd2013/wallet-tracker-telegram-bot.git
cd wallet-tracker-telegram-bot
- Configure Environment Variables:
Create a
.env
file (or set environment variables directly):
TELEGRAM_TOKEN=your_telegram_bot_token
ETHERSCAN_API_KEY=your_etherscan_api_key
- Run the bot:
python wallet-tracker-telegram-bot.py
- Start the bot on Telegram with
/start
. - Send an Ethereum wallet address (e.g.,
0x742d35Cc6634C0532925a3b844Bc454e4438f44e
). - Receive the latest transaction details:
- Hash
- Value (in ETH)
- Date (formatted timestamp)
- Never hardcode API keys. Use environment variables.
- Handle rate limits responsibly when making API calls.
- Fork the repository
- Create a new branch (
git checkout -b feature-xyz
) - Commit your changes (
git commit -m 'Add new feature'
) - Push to the branch (
git push origin feature-xyz
) - Open a pull request 🚀
Happy Tracking! 🚀