Skip to content

Latest commit

 

History

History
81 lines (57 loc) · 2.79 KB

File metadata and controls

81 lines (57 loc) · 2.79 KB
title Bidder CLI application
sidebarTitle Bidder CLI

Bidder CLI

The bidder-cli is a tool designed to provide a better User Experience (UX) for users sending raw transactions or bids on existing transactions to the mev-commit network.

You can download the latest version of the tool from the [official releases page](https://github.com/primev/mev-commit/releases/latest).

General Usage

The basic structure for interacting with the gRPC bidder server is:

bidder-cli [global options] command [command options]

Commands

  • send-tx: Send a transaction to the gRPC bidder server.

  • send-tx-hash: Send a bid to the gRPC bidder server for existing transactions.

  • help: Shows the full list of commands and options.


Sending Transactions (send-tx)

This command allows you to create a simple transfer transaction on the L1 chain and submit it directly to mev-commit.

Security: You must provide the private key of the account to sign the transaction. Never share this key or include it in public enviroments.

Example Usage

./bidder-cli send-tx \
  --from <PRIVATE_KEY> \
  --to <DESTINATION_ADDRESS> \
  --value <AMOUNT_IN_WEI> \
  --bid-amount <BID_IN_WEI> \
  --rpc-url localhost:13524

Key Options

  • --rpc-url: The URL for the gRPC server (default is localhost:13524).

  • --block-number: Target block for the bid. If omitted, the next block is used.

  • --decay-duration: The time window for the bid amount to decay (default: 10m).

  • --l1-rpc-url: Used to fetch the account nonce. Default: https://ethereum-hoodi-rpc.publicnode.com.


Bidding by Transaction Hash (send-tx-hash)

Use this command to bid on transactions that are already in the public mempool or block-builder mempools.

Example Usage

./bidder-cli send-tx-hash \
  --tx-hashes <HASH_1> \
  --tx-hashes <HASH_2> \
  --bid-amount <AMOUNT> \
  --rpc-url localhost:13524

Users can provide multiple --tx-hashes flags to bid on several transactions simultaneously.

Important Considerations

  • Gossip Latency: There is a possibility that a transaction is not gossiped to the provider's infrastructure in time. For better results, consider using the Provider's RPC for submitting transactions.

  • Reverting Hashes: You can specify transactions that should be considered "reverting" using the --reverting-tx-hashes flag.


Troubleshooting

If you're having trouble receiving commitments:

  1. Check Connectivity: Ensure you are connected to providers via the topology endpoint.

  2. Port Configuration: By default, the gRPC server runs on port 13524.

  3. Verbose Logging: Use the --verbose flag to enable detailed logging for debugging.