Coin Hunters Services
  • Introduction
  • Mainnet
    • Avail
      • Installation
      • Upgrade
    • Babylon
      • Installation
      • Service
      • Useful commands
      • Snapshot
    • CrossFi
      • Service
      • Installation
      • Useful commands
    • Dymension
      • Service
      • Installation
      • Snapshots
      • Useful commands
      • Upgrade
    • Lava Network
      • Service
      • Installion
      • Snapshots
      • Useful commands
    • Nibiru
      • Service
      • Installation
      • Useful commands
      • Snapshot
    • Zeta Chain
      • Service
      • Installation
      • Useful commands
      • Upgrade
    • Mantra Chain
      • Installation
      • Service
      • Useful commands
      • Snapshot
    • Rivalz
      • zNode
    • Kopi Money
      • Installation
      • Service
      • Useful commands
      • Snapshot
      • Upgrade
    • Story Protocol
      • Story Mainnet
        • Installation
        • Snapshots
        • Service
        • Upgrade
    • Side Protocol
      • Installation
      • Snapshots
      • Useful commands
    • Fuel Network
      • Installation
      • Snapshots
      • Useful commands
  • Testnet
    • 0G Labs
      • Service
      • Installation
      • Useful commands
      • 0G-Newton
        • Service
        • Installation
        • Useful commands
        • Snapshots
    • Airchains
      • Varanasi
        • Service
        • Installation
        • Snapshots
        • Useful commands
      • Junction
        • Service
        • Installation
        • Snapshots
        • Useful commands
      • Rollup Evm Airchains
      • Auto TX Script
    • AligendLayer
      • Installation
    • Allora Network
      • Service
      • Installation
      • Snapshots
      • Useful commands
      • Worker Node
    • Artela Network
      • Service
      • Installation
      • Snapshots
      • Useful commands
    • Avail
      • Installation
      • Update v2.2.1
    • Babylon
      • Installation
      • Useful commands
    • CrossFi
      • Service
      • Installation
      • Useful commands
      • Snapshots
    • Dill
      • Andes
      • Alps
    • Dymension
      • Service
      • Installation
      • Useful commands
    • Elys Network
      • Service
      • Installation
      • Snapshots
      • Useful commands
    • Empeiria
      • Service
      • Installation
      • Snapshots
      • Useful commands
    • Ethernity Chain
      • Deploy a Smart Contract and Verify
      • Create an ERC-20 token and Verify
      • Create an NFT Collection and Verify
    • Farcaster Node Hubble
      • Upgrade
    • Fiamma Chain
      • Service
      • Installation
      • Snapshots
      • Useful commands
    • Initia
      • Service
      • Installation
      • Snapshots
      • Useful commands
    • Lava Network
      • Service
      • Installation
      • Useful commands
    • Mantra Chain
      • Hongbai Testnet
        • Service
        • Installation
        • Snapshots
        • Useful commands
      • Dukong Testnet
        • Service
        • Installation
        • Snapshot
        • Useful commands
    • Nillion Network
      • Service
      • Installation
      • Snapshots
      • Useful commands
      • Verifier Program
    • Nubit
      • Light Node
      • Installation Validator
    • PINGPONG
      • Installation
      • 0G Storage Kurulumu
      • Grass Kurulumu
    • Rivalz
      • Linux Client
    • Side Protocol
      • S3 Tesnet
        • Service
        • Installation
        • Useful commands
      • S2 Incentivized Testnet
        • Installation
        • Useful commands
      • S4 Incentivized Tesnet
        • Service
        • Installation
        • Useful commands
        • Snapshots
    • Sunrise Layer
      • Service
      • Installation
      • Snapshots
      • Useful commands
      • Manual upgrade
    • Union
      • Service
      • Testnet-9
        • Installation
        • Snapshots
        • Useful commands
      • Testnet-8
        • Installation
        • Snapshots
        • Useful commands
    • Warden Protocol
      • Service
      • Installation
      • Snapshots
      • Useful commands
      • Chiado Testnet
        • Installation
        • Useful commands
    • Zero Network
      • Deploy a Smart Contract
    • Story Protocol
      • illiad Testnet
        • Installation
        • Snapshots
        • Upgrade
      • Odyssey testnet
        • Service
        • Installation
        • Snapshots
        • Useful Tool
      • Story Aeneid
        • Installation
        • Snapshots
        • Service
    • Hemi Network
    • Axone Chain
      • Service
      • Installation
      • Snapshots
      • Useful commands
    • Glacier Network
      • Installation
    • Pipe Network
      • Installation
    • Pell
      • Service
      • Installation
      • Snapshots
      • Useful commands
    • Native Network
      • Service
      • Installation
      • Snapshots
      • Useful commands
    • XRPL EVM
      • Installation
      • Useful commands
      • Snapshot
      • Service
    • Lumera Protocol
      • Installation
      • Useful commands
      • Snapshot
      • Service
Powered by GitBook
On this page
  1. Testnet
  2. Airchains

Auto TX Script

Airchains için kendi kurduğumuz, Rollup içinde TX atabilmek için, airchains rollup kurduğunuz sunucu da bu scripti çalıştırabilirsiniz.

Gerekli Kurumlar

sudo apt install curl git wget htop tmux build-essential jq make lz4 gcc unzip screen -y
sudo apt install -y curl git jq lz4 build-essential cmake perl automake autoconf libtool wget libssl-dev -y
curl -sL https://deb.nodesource.com/setup_20.x | sudo -E bash -

Nodejs ve Npm Kurulumu

sudo apt-get install -y nodejs
sudo apt install nodejs npm 
npm install -g npm@10.8.1
npm install web3@1.5.3
nano airchainstx.js

Açtığımız dosyaya aşağıdaki komutları, hiçbir yerine dokunmadan ekleyip. CTRL X Y enter ile çıkıyoruz.

const readline = require('readline');
const Web3 = require('web3');

const rl = readline.createInterface({
  input: process.stdin,
  output: process.stdout
});

rl.question('Enter your MetaMask wallet private key: ', (privateKey) => {
  rl.question('Enter the wallet address you want to send to: ', (toAddress) => {
    rl.question('Enter the amount you want to send (in tevmos): ', (amount) => {
      rl.question('How often do you want to repeat the transaction? (in seconds): ', (interval) => {

        const rpcURL = "http://localhost:8545"; // or your server's IP: "http://your-server-ip:8545"
        const web3 = new Web3(new Web3.providers.HttpProvider(rpcURL));

        function sendTransaction() {
          const account = web3.eth.accounts.privateKeyToAccount(privateKey);
          web3.eth.accounts.wallet.add(account);
          web3.eth.defaultAccount = account.address;

          const tx = {
            from: web3.eth.defaultAccount,
            to: toAddress,
            value: web3.utils.toWei(amount, 'ether'),
            gas: 21000,
            gasPrice: web3.utils.toWei('1', 'gwei')
          };

          web3.eth.sendTransaction(tx)
            .then(receipt => {
              console.log('Transaction successful with hash:', receipt.transactionHash);
            })
            .catch(err => {
              console.error('Error sending transaction:', err);
            });
        }

        setInterval(sendTransaction, interval * 1000);

        rl.close();
      });
    });
  });
});

Yeni bir screen açalım

screen -S autotx

Scriptimizi başlatıyoruz.

node airchainstx.js

Bizden bazı bilgileri isteyecek, sırasıyla yazıyorum.

MetaMask wallet private key bunu bulmak için /bin/bash ./scripts/local-keys.sh ile aldığımız private key giriyoruz.

Enter the wallet address you want to send to göndermek istediğimiz bir cüzdan adresi yazıyoruz. İstediğinizi yazabilirsiniz.

Enter the amount you want to send göndermek istediğiniz miktarı yazıyorsunuz . 1,2,3 veya istediğiniz bir miktar.

How often do you want to repeat the transaction burada ne kadar sürede bir gönderim yapacak onu seçiyoruz. 30,40,50 saniye tam sayı olarak girebilirsiniz.

Bu şekilde TX'ler görmeye başladıysanız, işlem tamamdır.

PreviousRollup Evm AirchainsNextAligendLayer

Last updated 1 year ago