Skip to main content

SecureRpc Network Reference

v01.601 Specification Document

Overview

  • CDN: CDN-like block propagation network that utilizes optimizations for filtering and connecting nodes

  • Front-running protection: transactions will not be seen by generalized bots in the public mempool.

  • No failed transactions: transactions will only be mined if it doesn't include any reverts, so users don't pay for failed transactions. Note: transactions could be included in uncle blocks, emitted to the mempool, and then included on-chain.

  • Priority in blocks: transactions sent via SecureRPC are mined either at the top OR bottom of blocks, giving end-users flexibility in their use cases.

  • Transaction Status integration: users can see the status of their transactions on either Etherscan or via our API.

  • Backfilling

Mempool behavior

When OpenMEV is disabled, every sent transaction is added to the mempool, which contains all the transactions that could be mined in the future. By default, SecureRpc Network's mempool follows the same rules as Geth. This means, among other things, that:

  • Transactions with a higher gas price are included first

  • If two transactions can be included and both are offering the miner the same total fees, the one that was received first is included first

  • If a transaction is invalid (for example, its nonce is lower than the nonce of the address that sent it), the transaction is dropped.

You can get the list of pending transactions that will be included in the next block by using the "pending" block tag:

const pendingBlock = await network.provider.send("eth_getBlockByNumber", ["pending", false]);
const pendingBlock = await ethers.provider.send("eth_getBlockByNumber", ["latest", false]);
blockGasLimit = BigNumber.from(pendingBlock.gasLimit);

Transaction ordering

SecureRpc Network can sort mempool transactions in two different ways. How they are sorted will alter which transactions from the mempool get included in the next block, and in which order.

The first ordering mode, called "priority", mimics Geth's behavior. This means that it prioritizes transactions based on the fees paid to the miner. This is the default.

The second ordering mode, called "fifo", keeps the mempool transactions sorted in the order they arrive.

see https://brandur.org/nanoglyphs/027-15-minutes#randomness

Transaction ID's

see https://www.cockroachlabs.com/blog/how-to-choose-db-index-keys/

  • Uses Crockford's base32 for better efficiency and readability (5 bits per character).
  • Case insensitive.
  • No special characters (URL safe).
  • Monotonic sort order (correctly detects and handles the same millisecond).

Notes: see postgres ext. that uses ID's that wrap around every 45 days, maybe for consideration as thats when we remove data?

Removing and replacing transactions

Transactions in the mempool can be removed using the manifold_dropTransaction method:

const txHash = "0xabc...";
await network.provider.send("hardhat_dropTransaction", [txHash]);

You can also replace a transaction by sending a new one with the same nonce as the one that it's already in the mempool but with a higher gas price. Keep in mind that, like in Go-Ethereum, for this to work the new gas/fees prices have to be at least 10% higher than the gas price of the current transaction.

Automatic error messages

SecureRpc Network always knows why your transaction or call failed, and it uses this information to make debugging your contracts easier.

When a transaction fails without a reason, SecureRpc Network will create a clear error message in the following cases:

  • Calling a non-payable function with ETH
  • Sending ETH to a contract without a payable fallback or receive function
  • Calling a non-existent function when there's no fallback function
  • Calling a function with incorrect parameters
  • Calling an external function that doesn't return the right amount of data
  • Calling an external function on a non-contract account
  • Failing to execute an external call because of its parameters (e.g. trying to send too much ETH)
  • Calling a library without DELEGATECALL
  • Incorrectly calling a precompiled contract
  • Trying to deploy a contract that exceeds the bytecode size limit imposed by EIP-170

Logging

SecureRpc Network uses its tracing infrastructure to offer rich logging that will help you develop and debug smart contracts.

For example, a successful transaction and a failed call would look like this:

eth_sendTransaction
Contract deployment: Greeter
Contract address: 0x8858eeb3dfffa017d4bce9801d340d36cf895ccf
Transaction: 0x7ea2754e53f09508d42bd3074046f90595bedd61fcdf75a4764453454733add0
From: 0xc783df8a850f42e7f7e57013759c285caa701eb6
Value: 0 ETH
Gas used: 568851 of 2844255
Block: #2 - Hash: 0x4847b316b12170c576999183da927c2f2056aa7d8f49f6e87430e6654a56dab0

console.log:
Deploying a Greeter with greeting: Hello, world!

eth_call
Contract call: Greeter#greet
From: 0xc783df8a850f42e7f7e57013759c285caa701eb6

Error: VM Exception while processing transaction: revert Not feeling like it
at Greeter.greet (contracts/Greeter.sol:14)
at process._tickCallback (internal/process/next_tick.js:68:7)

Supported hardforks

HardforkblockNumber
FHomestead1150000
FTangerineWhistle2463000
FSpuriousDragon2675000
FByzantium4370000
FConstantinople7280000
FPetersburg7280000
FIstanbul9069000
FMuirGlacier9200000
FBerlin12244000
FLondon12965000
FArrowGlacier13773000

^1

Custom RPC Methods

Flashbots/MEV Geth RPC Methods

eth_sendBundle

flashbots standard latest

ethSendBundle can be used to send your bundles to the relay.

eth_callBundle

eth_callBundle can be used to simulate a bundle against a specific block number, including simulating a bundle at the top of the next block.

eth_callMultiBundle

eth_callMultiBundle Multi CallBundle will simulate a bundle of transactions on top of the most recent block. Partially follows flashbots spec v0.5.

// CallBundleArgs represents the arguments for a bundle of calls.
type CallBundleArgs struct {
Txs []TransactionArgs `json:"txs"`
Coinbase *string `json:"coinbase"`
Timestamp *uint64 `json:"timestamp"`
Timeout *int64 `json:"timeout"`
GasLimit *uint64 `json:"gasLimit"`
Difficulty *big.Int `json:"difficulty"`
BaseFee *big.Int `json:"baseFee"`
}

Manifold SecureRpc Methods

manifold_dropTransaction

Remove a transaction from the mempool (must be signed by originating account)

manifold_evictTransaction

Remove a transaction from the mempool (admin only)

manifold_setLoggingEnabled

Enable or disable logging in SecureRpc Network (auth required)

manifold_CreateAccessList

takes eth_callBundle and adds the arguments:

  • SimulationLogs bool
  • CreateAccessList bool

eth_multiCall

implements eth_call. Executes a new message call immediately without creating a transaction on the block chain.

Parity Methods

trace_rawTransaction

trace Transaction trace. An equivalent trace to that in the previous section. vmTrace Virtual Machine execution trace. Provides a full trace of the VM’s state throughout the execution of the transaction, including for any subcalls.

stateDiff State difference. Provides information detailing all altered portions of the Ethereum state made due to the execution of the transaction.

trace_call

Executes the given call and returns a number of possible traces for it.

Parameters

ParametersDescription
Objectwhere from field is optional and nonce field is ommited.
Quantity, or 'tag'Integer of a block number, or the string 'earliest', 'latest' or 'pending'.
ArrayType of trace, one or more of: "vmTrace", "trace", "stateDiff".

Returns

  • Array - Block traces

Request

curl --data '{"method":"trace_call","params":[{ ... },["trace"]],"id":1,"jsonrpc":"2.0"}' -H "Content-Type: application/json" -X POST localhost:8545
Response
{
"id": 1,
"jsonrpc": "2.0",
"result": {
"output": "0x",
"stateDiff": null,
"trace": [{
"action": { ... },
"result": {
"gasUsed": "0x0",
"output": "0x"
},
"subtraces": 0,
"traceAddress": [],
"type": "call"
}],
"vmTrace": null
}
}

trace_callMany

Performs multiple call traces on top of the same block. i.e. transaction n will be executed on top of a pending block with all n-1 transactions applied (traced) first. Allows to trace dependent transactions.

Parameters

  1. Array - List of trace calls with the type of trace, one or more of: "vmTrace", "trace", "stateDiff".
  2. Quantity or Tag - (optional) integer block number, or the string 'latest', 'earliest' or 'pending', see the default block parameter.
params: [
[
[
{
"from": "0x407d73d8a49eeb85d32cf465507dd71d507100c1",
"to": "0xa94f5374fce5edbc8e2a8697c15331677e6ebf0b",
"value": "0x186a0"
},
["trace"]
],
[
{
"from": "0x407d73d8a49eeb85d32cf465507dd71d507100c1",
"to": "0xa94f5374fce5edbc8e2a8697c15331677e6ebf0b",
"value": "0x186a0"
},
["trace"]
]
],
"latest"
]

Returns

  • Array - Array of the given transactions’ traces

Request

curl --data '{"method":"trace_callMany","params":[[[{"from":"0x407d73d8a49eeb85d32cf465507dd71d507100c1","to":"0xa94f5374fce5edbc8e2a8697c15331677e6ebf0b","value":"0x186a0"},["trace"]],[{"from":"0x407d73d8a49eeb85d32cf465507dd71d507100c1","to":"0xa94f5374fce5edbc8e2a8697c15331677e6ebf0b","value":"0x186a0"},["trace"]]],"latest"],"id":1,"jsonrpc":"2.0"}' -H "Content-Type: application/json" -X POST localhost:8545

Response

{
"id": 1,
"jsonrpc": "2.0",
"result": [
{
"output": "0x",
"stateDiff": null,
"trace": [
{
"action": {
"callType": "call",
"from": "0x407d73d8a49eeb85d32cf465507dd71d507100c1",
"gas": "0x1dcd12f8",
"input": "0x",
"to": "0xa94f5374fce5edbc8e2a8697c15331677e6ebf0b",
"value": "0x186a0"
},
"result": {
"gasUsed": "0x0",
"output": "0x"
},
"subtraces": 0,
"traceAddress": [],
"type": "call"
}
],
"vmTrace": null
},
{
"output": "0x",
"stateDiff": null,
"trace": [
{
"action": {
"callType": "call",
"from": "0x407d73d8a49eeb85d32cf465507dd71d507100c1",
"gas": "0x1dcd12f8",
"input": "0x",
"to": "0xa94f5374fce5edbc8e2a8697c15331677e6ebf0b",
"value": "0x186a0"
},
"result": {
"gasUsed": "0x0",
"output": "0x"
},
"subtraces": 0,
"traceAddress": [],
"type": "call"
}
],
"vmTrace": null
}
]
}

trace_rawTransaction

Traces a call to eth_sendRawTransaction without making the call, returning the traces

Parameters

  1. Data - Raw transaction data.
  2. Array - Type of trace, one or more of: "vmTrace", "trace", "stateDiff".
{
"params": ["0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675", ["trace"]]
}

Returns

  • Object - Block traces.

Request

'{"method":"trace_rawTransaction","params":["0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675",["trace"]],"id":1,"jsonrpc":"2.0"}'

Response

{
"id": 1,
"jsonrpc": "2.0",
"result": {
"output": "0x",
"stateDiff": null,
"trace": [{
"action": { ... },
"result": {
"gasUsed": "0x0",
"output": "0x"
},
"subtraces": 0,
"traceAddress": [],
"type": "call"
}],
"vmTrace": null
}
}

trace_replayBlockTransactions

Replays all transactions in a block returning the requested traces for each transaction.

Parameters

ParametersDescription
Quantity, or 'tag'Integer of a block number, or the string 'earliest', 'latest' or 'pending'.
ArrayType of trace, one or more of: "vmTrace", "trace", "stateDiff".
params: [
"0x2ed119",
["trace"]
]

Returns

  • Array - Block transactions traces.

Request

curl --data '{"method":"trace_replayBlockTransactions","params":["0x2ed119",["trace"]],"id":1,"jsonrpc":"2.0"}' -H "Content-Type: application/json" -X POST localhost:8545

Response

{
"id": 1,
"jsonrpc": "2.0",
"result": [
{
"output": "0x",
"stateDiff": null,
"trace": [{
"action": { ... },
"result": {
"gasUsed": "0x0",
"output": "0x"
},
"subtraces": 0,
"traceAddress": [],
"type": "call"
}],
"transactionHash": "0x...",
"vmTrace": null
},
{ ... }
]
}

trace_replayTransaction

Replays a transaction, returning the traces.

Parameters

  1. Hash - Transaction hash.
  2. Array - Type of trace, one or more of: "vmTrace", "trace", "stateDiff".
{ "params": ["0x02d4a872e096445e80d05276ee756cefef7f3b376bcec14246469c0cd97dad8f", ["trace"]] }

Returns

  • Object - Block traces.

Request

curl --data '{"method":"trace_replayTransaction","params":["0x02d4a872e096445e80d05276ee756cefef7f3b376bcec14246469c0cd97dad8f",["trace"]],"id":1,"jsonrpc":"2.0"}' -H "Content-Type: application/json" -X POST localhost:8545

Response

{
"id": 1,
"jsonrpc": "2.0",
"result": {
"output": "0x",
"stateDiff": null,
"trace": [{
"action": { ... },
"result": {
"gasUsed": "0x0",
"output": "0x"
},
"subtraces": 0,
"traceAddress": [],
"type": "call"
}],
"vmTrace": null
}
}

trace_block

Returns traces created at given block.

Parameters

  1. Quantity or Tag - Integer of a block number, or the string 'earliest', 'latest' or 'pending'.
"params": [
"0x2ed119" // 3068185
]

Returns

  • Array - Block traces.

Request

"{\"method\":\"trace_block\",\"params\":[\"0x2ed119\"],\"id\":1,\"jsonrpc\":\"2.0\"}"

Response

{
"id": 1,
"jsonrpc": "2.0",
"result": [
{
"action": {
"callType": "call",
"from": "0xaa7b131dc60b80d3cf5e59b5a21a666aa039c951",
"gas": "0x0",
"input": "0x",
"to": "0xd40aba8166a212d6892125f079c33e6f5ca19814",
"value": "0x4768d7effc3fbe"
},
"blockHash": "0x7eb25504e4c202cf3d62fd585d3e238f592c780cca82dacb2ed3cb5b38883add",
"blockNumber": 3068185,
"result": {
"gasUsed": "0x0",
"output": "0x"
},
"subtraces": 0,
"traceAddress": [],
"transactionHash": "0x07da28d752aba3b9dd7060005e554719c6205c8a3aea358599fc9b245c52f1f6",
"transactionPosition": 0,
"type": "call"
},
...
]
}

trace_filter

Returns traces matching given filter

Parameters

ParameterDescription
- ObjectThe filter object
- fromBlockQuantity or Tag - (optional) From this block.
- toBlockQuantity or Tag - (optional) To this block.
- fromAddressArray - (optional) Sent from these addresses.
- toAddressAddress - (optional) Sent to these addresses.
- afterQuantity - (optional) The offset trace number
- countQuantity - (optional) Integer number of traces to display in a batch.
params: [{
"fromBlock": "0x2ed0c4", // 3068100
"toBlock": "0x2ed128", // 3068200
"toAddress": ["0x8bbB73BCB5d553B5A556358d27625323Fd781D37"],
"after": 1000,
"count": 100
}]

Returns

  • Array - Traces matching given filter

Request

'{"method":"trace_filter","params":[{"fromBlock":"0x2ed0c4","toBlock":"0x2ed128","toAddress":["0x8bbB73BCB5d553B5A556358d27625323Fd781D37"],"after":1000,"count":100}],"id":1,"jsonrpc":"2.0"}' -H "Content-Type: application/json"

Response

{
"id": 1,
"jsonrpc": "2.0",
"result": [
{
"action": {
"callType": "call",
"from": "0x32be343b94f860124dc4fee278fdcbd38c102d88",
"gas": "0x4c40d",
"input": "0x",
"to": "0x8bbb73bcb5d553b5a556358d27625323fd781d37",
"value": "0x3f0650ec47fd240000"
},
"blockHash": "0x86df301bcdd8248d982dbf039f09faf792684e1aeee99d5b58b77d620008b80f",
"blockNumber": 3068183,
"result": {
"gasUsed": "0x0",
"output": "0x"
},
"subtraces": 0,
"traceAddress": [],
"transactionHash": "0x3321a7708b1083130bd78da0d62ead9f6683033231617c9d268e2c7e3fa6c104",
"transactionPosition": 3,
"type": "call"
},
...
]
}

trace_get

Returns trace at given position.

Parameters

NameRequiredDescription
HashYes (req.)Transaction hash.
ArrayYes (req.)Index positions of the traces.
params: [
"0x17104ac9d3312d8c136b7f44d4b8b47852618065ebfa534bd2d3b5ef218ca1f3",
["0x0"]
]

Returns

  • Object - Trace object

Request

curl --data '{"method":"trace_get","params":["0x17104ac9d3312d8c136b7f44d4b8b47852618065ebfa534bd2d3b5ef218ca1f3",["0x0"]],"id":1,"jsonrpc":"2.0"}' -H "Content-Type: application/json" -X POST localhost:8545

Response

{
"id": 1,
"jsonrpc": "2.0",
"result": {
"action": {
"callType": "call",
"from": "0x1c39ba39e4735cb65978d4db400ddd70a72dc750",
"gas": "0x13e99",
"input": "0x16c72721",
"to": "0x2bd2326c993dfaef84f696526064ff22eba5b362",
"value": "0x0"
},
"blockHash": "0x7eb25504e4c202cf3d62fd585d3e238f592c780cca82dacb2ed3cb5b38883add",
"blockNumber": 3068185,
"result": {
"gasUsed": "0x183",
"output": "0x0000000000000000000000000000000000000000000000000000000000000001"
},
"subtraces": 0,
"traceAddress": [0],
"transactionHash": "0x17104ac9d3312d8c136b7f44d4b8b47852618065ebfa534bd2d3b5ef218ca1f3",
"transactionPosition": 2,
"type": "call"
}
}

trace_transaction

Returns all traces of the given transaction

Parameters

  1. Hash - Transaction hash
"params": ["0x17104ac9d3312d8c136b7f44d4b8b47852618065ebfa534bd2d3b5ef218ca1f3"]

Returns

  • Array - Traces of given transaction

Request

'{"method":"trace_transaction","params":["0x17104ac9d3312d8c136b7f44d4b8b47852618065ebfa534bd2d3b5ef218ca1f3"],"id":1,"jsonrpc":"2.0"}'

Response

{
"id": 1,
"jsonrpc": "2.0",
"result": [
{
"action": {
"callType": "call",
"from": "0x1c39ba39e4735cb65978d4db400ddd70a72dc750",
"gas": "0x13e99",
"input": "0x16c72721",
"to": "0x2bd2326c993dfaef84f696526064ff22eba5b362",
"value": "0x0"
},
"blockHash": "0x7eb25504e4c202cf3d62fd585d3e238f592c780cca82dacb2ed3cb5b38883add",
"blockNumber": 3068185,
"result": {
"gasUsed": "0x183",
"output": "0x0000000000000000000000000000000000000000000000000000000000000001"
},
"subtraces": 0,
"traceAddress": [
0
],
"transactionHash": "0x17104ac9d3312d8c136b7f44d4b8b47852618065ebfa534bd2d3b5ef218ca1f3",
"transactionPosition": 2,
"type": "call"
},
...
]
}

Relay Switchboard

TODO

  • eth_setRelayPeer
  • eth_getRelayPeer
  • eth_getRelayStats

Global Virtual Mempool

  • manifold_txpool_health
  • manifold_txpool_map
  • manifold_txpool_search

methods manifold_txpool_* are available only for users with access to SecureRPC

curl -X POST -H 'Content-type: application/json' -d

manifold_txpool_health

Returns the number of transactions currently pending for inclusion in the next block(s), as well as the ones that are being scheduled for future execution only.

Request

'{"jsonrpc": "2.0", "method": "txpool_health", "id": 1}'

Response

{ "jsonrpc": "2.0", "id": 1, "result": { "pending": "0x1400", "queued": "0x400" } }
curl -X POST -H 'Content-type: application/json' -d '{"jsonrpc": "2.0", "method": "manifold_txpool_health", "id": 1}' https://q.securerpc.com/v1/eth/YOUR-APP-ID
{ "jsonrpc": "2.0", "id": 1, "result": { "pending": "0xdc2e", "queued": "0xbbbe", "total": "0x197ec" } }

manifold_txpool_map

Returns a list with the exact details of all the transactions currently pending for inclusion in the next block(s), as well as the ones that are being scheduled for future execution only.

Parameters

NameRequiredDescription
offsetNo (optional)start index (default is == 0)
limitNo (optional)number of items to return (maxResults = 10_000)

Example

curl -X POST -H 'Content-type: application/json' -d '{"jsonrpc": "2.0", "method": "manifold_txpool_map", "params":[0, 10], "id": 1}' https://q.securerpc.com/v1/eth/YOUR-APP-ID
{
"jsonrpc": "2.0",
"id": 1,
"result": {
"pending": {
"0x5f7a3238efb2d450be97afcf5b1dd34451024d860fe65a9eea1fe116508ec124": {
"302213": {
"blockHash": null,
"blockNumber": null,
"from": "0x077d360f11d220e4d5d831430c81c26c9be7c4a4",
"gas": "0x15f90",
"gasPrice": "0x9d21fb900",
"hash": "0x5f7a3238efb2d450be97afcf5b1dd34451024d860fe65a9eea1fe116508ec124",
"input": "0x",
"nonce": "0x49c85",
"to": "0xe0f70bc1c864b7ace8a80d454565ee5b6f68dfd4",
"transactionIndex": null,
"value": "0x388b7b360f3000",
"type": "0x0",
"v": "0x26",
"r": "0x25e22877938610b58ed2f941399b551d9749030c2112f4845fe382ea504fa4bd",
"s": "0x129832f580977771e1184b39d55a699700855562badb656a6c12d59d01efbd48"
}
},
"0xe2e22009fc6ca711311b354f75c15de2a96cd8f8aea7f8baf91911881b5d78e1": {
"315739": {
"blockHash": null,
"blockNumber": null,
"from": "0x48c04ed5691981c42154c6167398f95e8f38a7ff",
"gas": "0x2bf20",
"gasPrice": "0x9d21fb900",
"hash": "0xe2e22009fc6ca711311b354f75c15de2a96cd8f8aea7f8baf91911881b5d78e1",
"input": "0xa9059cbb000000000000000000000000f8f0036fd0c89113ad06fec122ce8fc50c4bd8b500000000000000000000000000000000000000000000000000000000c20c945d",
"nonce": "0x4d15b",
"to": "0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48",
"transactionIndex": null,
"value": "0x0",
"type": "0x0",
"v": "0x25",
"r": "0x4c803af95903e07f34bc52db272015c5e3a3340f8ff8c436c970617e1179661f",
"s": "0x2693cd957456b3481aefc968f1730ffdfb3bd81e6dc4115fc2771ccfa82d1b9a"
}
},
"0xe5f74e7e3d8bbc47341e2c30d38166d7f7fa76807597acc9d2f5d0ede6f775b5": {
"9": {
"blockHash": null,
"blockNumber": null,
"from": "0x5060734d755a235b8fb6a2769824ee07ce1e0e1d",
"gas": "0x5208",
"gasPrice": "0x2cefb24a00",
"maxFeePerGas": "0x2cefb24a00",
"maxPriorityFeePerGas": "0x77359400",
"hash": "0xe5f74e7e3d8bbc47341e2c30d38166d7f7fa76807597acc9d2f5d0ede6f775b5",
"input": "0x",
"nonce": "0x9",
"to": "0x9ccf394fdbeec9926cb1ae877cc28c606fbd2cab",
"transactionIndex": null,
"value": "0x68ce6f220edaa",
"type": "0x2",
"accessList": [],
"chainId": "0x1",
"v": "0x0",
"r": "0xc3f2cb393319e6506f0fb2ebc46c19d6ad2838577dcf8f049f00b8e117423c35",
"s": "0x777c0ec1daf7ba7f030356a60ea3be11217fb319c77a5367e00a0423ae535636"
}
},
"0x313cec5a71bfdbb3e50550f6289c1a0ab9b8150ada201f8eebebf6f1936fdac5": {
"10": {
"blockHash": null,
"blockNumber": null,
"from": "0x5060734d755a235b8fb6a2769824ee07ce1e0e1d",
"gas": "0x5208",
"gasPrice": "0x400746fe00",
"maxFeePerGas": "0x400746fe00",
"maxPriorityFeePerGas": "0x77359400",
"hash": "0x313cec5a71bfdbb3e50550f6289c1a0ab9b8150ada201f8eebebf6f1936fdac5",
"input": "0x",
"nonce": "0xa",
"to": "0x5060734d755a235b8fb6a2769824ee07ce1e0e1d",
"transactionIndex": null,
"value": "0x346fe398e12",
"type": "0x2",
"accessList": [],
"chainId": "0x1",
"v": "0x1",
"r": "0x79f0f6dcd1cd931c8cd5ceaf86e412a0a60226cda3f82a064af71b86493601ee",
"s": "0x291185c574299706653983845210e33629d428e5e4b92a5f0fcc6868a3427d7b"
}
},
"0xfe972fd2b99babab1d0b038456c7d97a62714cbbf6983ad180cc2113b7d11ae8": {
"11": {
"blockHash": null,
"blockNumber": null,
"from": "0x5060734d755a235b8fb6a2769824ee07ce1e0e1d",
"gas": "0x5208",
"gasPrice": "0x13532f7e00",
"maxFeePerGas": "0x13532f7e00",
"maxPriorityFeePerGas": "0x77359400",
"hash": "0xfe972fd2b99babab1d0b038456c7d97a62714cbbf6983ad180cc2113b7d11ae8",
"input": "0x",
"nonce": "0xb",
"to": "0x5060734d755a235b8fb6a2769824ee07ce1e0e1d",
"transactionIndex": null,
"value": "0x34796070b78",
"type": "0x2",
"accessList": [],
"chainId": "0x1",
"v": "0x1",
"r": "0x6f40aaf13320a8a05d9e2c123524f9204a09614c166e5979522cbfddc38528fe",
"s": "0x393a10aeab49e2751f2db15e4f94a973730f1728a2b2b1db92b614f7e7cb4dae"
}
}
}
}
}

Returns a list with the exact details of all the pending/queued transactions in the global public mempool. Takes parameters for input on search criteria.

Parameters

1: from - (optional) exact match in the transaction 'from' property 2: to - (optional) exact match in the transaction 'to' property 3: value - (optional) exact match in the transaction 'value' property 4: input - (optional) wildcard match of the transaction 'input' data

Example:

Sample usage how to get all pending/queued transactions to Uniswap V2 Router (0x7a250d5630B4cF539739dF2C5dAcb4c659F2488D) with method call:

swapExactTokensForTokens(uint256,uint256,address[],address,uint256)

This sample usage is often used during the gasPrice analyze of the arbitrages on Uniswap.

curl -X POST -H 'Content-type: application/json' -d '{"jsonrpc": "2.0", "method": "manifold_txpool_search", "params":[{"to": "0x7a250d5630B4cF539739dF2C5dAcb4c659F2488D", "input": "0x38ed1739*"}], "id": 1}' https://q.securerpc.com/v1/eth/YOUR-APP-ID
{
"jsonrpc": "2.0",
"id": 1,
"result": {
"pending": {
"0x87b23e2124e50bc1e6539b61043f39e0071afd6f11311b19b29b865d6c138882": {
"70223": {
"blockHash": null,
"blockNumber": null,
"from": "0x98041ab523024dacaefa3bb70dd982dbac68e855",
"gas": "0x61a80",
"gasPrice": "0x14e7458a40",
"maxFeePerGas": "0x14e7458a40",
"maxPriorityFeePerGas": "0x14e7458a40",
"hash": "0x87b23e2124e50bc1e6539b61043f39e0071afd6f11311b19b29b865d6c138882",
"input": "0x38ed17390000000000000000000000000000000000000000000006999e1c5668566c39b6000000000000000000000000000000000000000000000035a83bffd099a3ffff00000000000000000000000000000000000000000000000000000000000000a000000000000000000000000098041ab523024dacaefa3bb70dd982dbac68e85500000000000000000000000000000000000000000000000000000000624f1c5f0000000000000000000000000000000000000000000000000000000000000002000000000000000000000000853d955acef822db058eb8505911ed77f175b99e0000000000000000000000003432b6a60d23ca0dfca7761b7ab56459d9c964d0",
"nonce": "0x1124f",
"to": "0x7a250d5630b4cf539739df2c5dacb4c659f2488d",
"transactionIndex": null,
"value": "0x0",
"type": "0x2",
"accessList": [],
"chainId": "0x1",
"v": "0x1",
"r": "0xf0eb5d621aeab0a952fcb233e271f9ca0f71e1acd39c91dcb4295fa966ea870e",
"s": "0x6f238592d31ec1b36f9314a0eb6f190c6e833cfcebcbf66ebd95c8451630a3d3"
}
}
},
"queued": {}
}
}

Max results for manifold_txpool_search are limited to 10_000 results

interface ErrorCodes {
readonly rpc: {
readonly invalidInput: -32000;
readonly resourceNotFound: -32001;
readonly resourceUnavailable: -32002;
readonly transactionRejected: -32003;
readonly methodNotSupported: -32004;
readonly limitExceeded: -32005;
readonly parse: -32700;
readonly invalidRequest: -32600;
readonly methodNotFound: -32601;
readonly invalidParams: -32602;
readonly internal: -32603;
};
readonly provider: {
readonly userRejectedRequest: 4001;
readonly unauthorized: 4100;
readonly unsupportedMethod: 4200;
readonly disconnected: 4900;
readonly chainDisconnected: 4901;
};
}

export const errorCodes: ErrorCodes = {
rpc: {
invalidInput: -32000,
resourceNotFound: -32001,
resourceUnavailable: -32002,
transactionRejected: -32003,
methodNotSupported: -32004,
limitExceeded: -32005,
parse: -32700,
invalidRequest: -32600,
methodNotFound: -32601,
invalidParams: -32602,
internal: -32603,
},
provider: {
userRejectedRequest: 4001,
unauthorized: 4100,
unsupportedMethod: 4200,
disconnected: 4900,
chainDisconnected: 4901,
},
};
{
"4001": {
"standard": "EIP-1193",
"message": "User rejected the request."
},
"4100": {
"standard": "EIP-1193",
"message": "The requested account and/or method has not been authorized by the user."
},
"4200": {
"standard": "EIP-1193",
"message": "The requested method is not supported by this Ethereum provider."
},
"4900": {
"standard": "EIP-1193",
"message": "The provider is disconnected from all chains."
},
"4901": {
"standard": "EIP-1193",
"message": "The provider is disconnected from the specified chain."
},
"-32700": {
"standard": "JSON RPC 2.0",
"message": "Invalid JSON was received by the server. An error occurred on the server while parsing the JSON text."
},
"-32600": {
"standard": "JSON RPC 2.0",
"message": "The JSON sent is not a valid Request object."
},
"-32601": {
"standard": "JSON RPC 2.0",
"message": "The method does not exist / is not available."
},
"-32602": {
"standard": "JSON RPC 2.0",
"message": "Invalid method parameter(s)."
},
"-32603": {
"standard": "JSON RPC 2.0",
"message": "Internal JSON-RPC error."
},
"-32000": {
"standard": "EIP-1474",
"message": "Invalid input."
},
"-32001": {
"standard": "EIP-1474",
"message": "Resource not found."
},
"-32002": {
"standard": "EIP-1474",
"message": "Resource unavailable."
},
"-32003": {
"standard": "EIP-1474",
"message": "Transaction rejected."
},
"-32004": {
"standard": "EIP-1474",
"message": "Method not supported."
},
"-32005": {
"standard": "EIP-1474",
"message": "Request limit exceeded."
}
}

^2.2. Which History?, Ethereum Yellowpaper