Flashbots Documentation

website·Indexed 36 days ago

https://docs.flashbots.net/

Documentation for Flashbots services and tools, including MEV-Boost for block proposers and builders, MEV-Share for searchers, and Flashbots Protect RPC for retail users. Covers bundle definitions, relay and RPC endpoints, nonce management, and MEV refund mechanisms.

Tokens
40K
Snippets
161
Records
296
Agent score
71%

What's inside Flashbots

  1. Overview of the ethers-flashbots Rust library

    ethers-flashbots is a Rust library designed to interact with Flashbots endpoints, allowing developers to send bundles of transactions. It is built as a middleware layer on top of ethers-rs (a Rust port of ethers.js), enabling the automation of trading activities on Decentralized Exchanges (DEXs).
  2. Overview of Flashbots Protect benefits

    Flashbots Protect provides several key advantages for Ethereum transactions:

    • Frontrunning protection: Transactions are hidden from the public mempool to avoid sandwich bots and front-running.
    • MEV and Gas Refunds: Users can earn refunds if their transaction creates MEV or pays high priority fees.
    • No failed transactions: Transactions are only included in a block if they do not revert, meaning users do not pay fees for failed transactions.
    • Configurability: Privacy, speed, and refund settings can be customized.
  3. Overview of Flashbots Auction

    Flashbots Auction is a permissionless, transparent, and fair ecosystem designed for efficient MEV (Maximal Extractable Value) extraction and frontrunning protection. It provides a private communication channel between Ethereum users and validators to communicate preferred transaction ordering within a block. In Proof-of-Stake (PoS) Ethereum, this is implemented via mev-boost, which enables proposer-builder separation.
  4. Overview of mev-boost middleware

    mev-boost is open-source middleware used by Ethereum proof-of-stake (PoS) validators to access a competitive block-building market. It implements Proposer-Builder Separation (PBS), allowing validators (proposers) to outsource block production to specialized builders. This separation is designed to increase competition, decentralization, and censorship-resistance while maximizing staking rewards by selling blockspace to an open market.
  5. Overview of the MEV-Share protocol

    MEV-Share is an open-source protocol that enables users, wallets, and applications to internalize the MEV generated by their transactions via an 'orderflow auction'. It allows users to selectively share transaction data with searchers who bid to include those transactions in bundles. The resulting MEV bids can be redistributed among the user, validators, or other parties. The protocol is designed to be credibly neutral, permissionless for searchers, and avoids enshrining a single block builder to reduce the centralizing impact of exclusive orderflow on Ethereum.
  6. Capture transaction MEV using MEV-share

    MEV-share is a protocol designed for users, wallets, and dapps to capture the Maximum Extractable Value (MEV) created by their transactions. To use MEV-share, transactions are typically sent to MEV-share Nodes via eth_sendRawTransaction or eth_sendPrivateTransaction JSON-RPC requests. Users can utilize the Flashbots-run MEV-share Node by sending transactions through Flashbots Protect.
  7. Retrieve delayed refunds using buildernet_getDelayedRefunds

    The buildernet_getDelayedRefunds JSON-RPC method returns detailed information about delayed refunds. Responses are paginated; if a nextCursor is returned, include it in the next request to continue fetching data. The indexedUpTo field indicates the maximum block number for which delayed refunds have been indexed.
    {
      "jsonrpc": "2.0",
      "id": 1,
      "method": "buildernet_getDelayedRefunds",
      "params": [
        {
          "recipient": "0x...",       // String, address receiving delayed refunds
          "blockRangeFrom": "0x...",  // [optional] Hex-encoded start block (inclusive)
          "blockRangeTo": "0x...",    // [optional] Hex-encoded end block (inclusive)
          "cursor": "0x...",          // [optional] Cursor for pagination
          "hash": "0x..."            // [optional] Bundle hash (requires blockRangeFrom and blockRangeTo)
        }
      ]
    }
  8. Use FlashbotsBundleProvider to send bundles via ethers.js

    The FlashbotsBundleProvider is a specialized provider for ethers.js v5 that provides high-level access to the eth_sendBundle and eth_callBundle RPC endpoints. Because these endpoints are non-standard, this provider is designed to work alongside a standard, full-featured (non-Flashbots) RPC endpoint, which is required for essential operations such as nonce calculation, gas estimation, and checking transaction status.
  9. Understand the Flashbots Terms of Service and Software Licensing

    Flashbots provides two distinct types of offerings with different governing terms:

    1. Software Programs: Software provided via the Flashbots GitHub repository. These are governed by separate open-source licenses. In the event of a conflict between the Terms of Service (ToS) and an open-source license, the open-source license prevails.
    2. Flashbots Services: Includes the official website, research, product information, functionality, features, and technical support (security, configuration, etc.). These are governed by the Flashbots Terms of Service.

    Flashbots reserves the right to update the ToS at any time without notice. The sole remedy for users who disagree with updated terms is to terminate their use of the services.

  10. Understand the role of Relays in MEV-Boost

    Relays act as a doubly-trusted data-availability layer and communication interface between block builders and validators. They ensure fair payload routing for builders and verify block validity, accuracy, and data availability for proposers. Relays may connect to a single builder or aggregate bids from multiple builders, submitting only the highest valid bid to the validator for signing. To receive bids, validators must set up mev-boost and configure the relays they wish to connect to.
  11. Understand how Flashbots Ltd. processes personal data

    Flashbots Ltd. (incorporated in the Cayman Islands) processes personal data for users of the Flashbots Relay, specifically Transaction Submitters and Transaction Acceptors. Data processing is conducted in accordance with the Cayman Islands Data Protection Act, 2017 and the EU General Data Protection Regulation (GDPR). Personal data may be collected via the authentication process, the Relay process, or through communications such as Discord. Data may also be sourced from public directories, blockchains, tax authorities, and sanctions screening databases.
  12. Use Alchemy SDK for Flashbots private transactions

    The Alchemy SDK provides a streamlined way to interact with Flashbots by offering high-level access to the eth_sendPrivateTransaction and eth_cancelPrivateTransaction RPC endpoints. It acts as a superset of the ethers.js Provider library, allowing developers to use Flashbots JSON-RPC endpoints alongside core EVM APIs and Alchemy-specific APIs. Key benefits include automatic management of Flashbots reputation and the ability to receive webhook-based notifications for included or dropped private transactions via Alchemy Notify.