Skip to content

paulhumanity/wallet-airdropper

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

1 Commit
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Wallet Airdropper

Script that uses a master wallet with gas and automatically checks balances and funds to an array of wallets and making sure it maintains a defined minimum balance.

Requirements

  • Python 3.x
  • web3.py
  • eth-account
  • python-dotenv

Installation

  1. Clone this repository:
git clone <repository-url>
cd <repository-directory>
  1. Create a virtual environment and install dependencies:
python -m venv venv
source venv/bin/activate  # On Windows: venv\Scripts\activate
pip install web3 eth-account python-dotenv
  1. Configure your environment variables in .env file:
# API Keys
ALCHEMY_API_KEY=your_alchemy_api_key_here

# Master Wallet (funds distributor)
MASTER_PRIVATE_KEY=your_master_wallet_private_key

# Wallet Private Keys (comma-separated)
WALLET_PRIVATE_KEYS=key1,key2,key3,...

# Configuration
TOKEN_MAX=0.5
CHAIN_ID=7080969
RPC_URL=https://humanity-testnet.g.alchemy.com/v2/${ALCHEMY_API_KEY}

Usage

  1. Make sure your environment variables are set in the .env file
  2. Ensure your master wallet has enough funds to distribute
  3. Run the script:
python airdrop.py

The script will:

  1. Load your wallet configurations
  2. Create accounts.json file if it doesn't exist
  3. Check each wallet's balance
  4. Send funds from the master wallet to any wallet with a balance below TOKEN_MAX

Example Output

🌐 Connected to network: 7080969
πŸ“„ Loaded accounts.json with 20 wallets
πŸ’Ό Master wallet: 0xC206074d9153054E88C86197f940F5F1F79E8D11
πŸ’° Master balance: 30.004875684100000025 ETH
πŸ‘› Wallet 0 (0x25583917f7Ca519DcF9aF389ae7A97e5cA174a50): 0.5 ETH
πŸ“€ Sending 0.1 ETH to 0x53AE1Cd91EFfa8476c2ecc7dfF0A2Bb084613F5B...
βœ… Transaction successful: 0xabcdef1234567890abcdef1234567890abcdef1234567890abcdef1234567890

Configuration Options

  • TOKEN_MAX: The target ETH balance for each wallet (default: 0.5)
  • CHAIN_ID: The Ethereum network chain ID (7080969 for Humanity Arbitrum Testnet)
  • RPC_URL: The RPC endpoint URL for the Ethereum network
  • MASTER_PRIVATE_KEY: The private key of the master wallet that will fund other wallets
  • WALLET_PRIVATE_KEYS: Comma-separated list of wallet private keys to manage

License

MIT License

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Languages