izcrypto

How to Check Flashbots Protect Transaction Status via API

Flashbots Protect’s status API turns a private transaction hash into a clear next action: send GET flashbots.net and read the JSON status, which is PENDING, INCLUDED, FAILED, CANCELLED, or UNKNOWN. Use Flashbots to track your Protect submission because a pending private transaction is absent from the public mempool and may be invisible to public explorers. When the status is INCLUDED, request a transaction receipt to confirm inclusion.

How to Poll a Protect Transaction

Polling a Protect transaction starts with the transaction hash returned when you sent the signed transaction through Protect RPC. Keep that hash with your submission record. The Transaction Status API documentation defines the GET endpoint, response fields, status meanings, and how long records remain available.

  1. Send GET flashbots.net replacing the placeholder with your hash. In JavaScript, use const data = await (await fetch("https://protect.flashbots.net/tx/" + txHash)).json(); The response gives you a status and a hash you can compare with the one you submitted.
  2. Read data.status, data.maxBlockNumber, and data.seenInMempool. Record maxBlockNumber with the status so you can inspect the submission’s block window later. If seenInMempool is true, mark the transaction as publicly exposed. A copy reached the public mempool, usually because it was also sent elsewhere; a later INCLUDED status does not restore its privacy. Say you sent the same signed transaction through a second RPC: keep the exposure flag even after its receipt arrives.
  3. Map each status to a handler: const action = ({PENDING:"poll", INCLUDED:"receipt", FAILED:"stop-or-resubmit", CANCELLED:"stop-or-resubmit", UNKNOWN:"verify-submission"})[data.status]; This gives your integration one explicit branch for every documented response.
  4. While PENDING, query again on each new block. FAILED means the transaction was not included during its submission window; decide whether to resubmit. CANCELLED means it was cancelled without inclusion; stop or submit a new transaction deliberately. For UNKNOWN, verify the hash and submission path. Protect may never have received it, or its status record may have expired after 45 minutes.
  5. On INCLUDED, call eth_getTransactionReceipt with the transaction hash. If the receipt is still null, retry the receipt request; when a receipt is found, the status check is done. Read the receipt’s execution status separately to determine whether the included transaction succeeded.

Questions After a Status Check

How do I cancel a pending Protect transaction?

For a submission made with eth_sendPrivateTransaction, call eth_cancelPrivateTransaction with its hash and sign the request with the same authentication key used to submit it. The status endpoint reports the resulting state.

Is the status endpoint rate-limited?

The published Protect RPC rate-limit table does not specify a limit for the GET status endpoint. Polling once per new block follows the transaction’s progress without repeated requests within the same block; back off if the endpoint returns a rate-limit response.

How do I check a bundle sent with eth_sendBundle?

The Protect transaction status endpoint covers Protect RPC transactions, not a bundle submission. Keep the bundle hash and target block from the relay response, then check receipts for the bundle’s transaction hashes after that block to see which transactions landed.