Giter VIP home page Giter VIP logo

ethtxgenerator's Introduction

ethTxGenerator

Generate an ethereum transaction via Geth.

Make an executable file

go build

Execute ethTxGenerator

You need to pass some arguments needed to make a transaction.

./ethTxGenerator endPoint txType chainID gasPrice gas baseFee value fromPrivateKey nonce to [data]

For example, you can execute like below without data.

./ethTxGenerator http://your_en_url:port 1 8217 0x5d21dba00 0xdbba0 0 1 0xFromPrivateKey 0 0xToAddress

You can send either int or hex string for chainId, gasPrice, gas, baseFee and value.

If you want to deploy a smart contract, then you can pass nil string to to argument like below. Note that you need to pass data argument together.

./ethTxGenerator http://your_en_url:port 1 8217 0x5d21dba00 0xdbba0 0 1 0xFromPrivateKey 0 nil 0xByteCode

If you want to execute a smart contract, then you can pass a smart contract address to to argument and an encoded function call to data argument like below.

./ethTxGenerator http://your_en_url:port 1 8217 0x5d21dba00 0xdbba0 0 1 0xFromPrivateKey 0 0xSmartContractAddress 0xEncodedFunctionCall

For easy testing

If you want to make a tx with a random account, you can pass "random" instead of from and to like below. Maybe this can be used only to check a transaction format which is generated from this ethTxGenerator.

./ethTxGenerator endPoint txType chainID gasPrice gas baseFee value random nonce random

ethtxgenerator's People

Contributors

jimni1222 avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.