Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/0xAlcibiades/mev-bundle-generator
/ functions
Functions
95 in github.com/0xAlcibiades/mev-bundle-generator
⨍
Functions
95
◇
Types & classes
28
↓ 9 callers
Method
address
(self)
src/wallet.rs:31
↓ 9 callers
Method
order_profit
(&self, order_size: &U256)
src/arbitrage.rs:142
↓ 7 callers
Method
get_tokens_out
(&self, token_in: &Address, token_out: &Address, amount_in: &U256)
src/uniswap.rs:270
↓ 6 callers
Method
effective_gas
Return the effective gas price for the bundle
src/flashbots.rs:107
↓ 4 callers
Method
tokens
(&self)
src/uniswap.rs:250
↓ 3 callers
Method
submit
Call a simulation or send to the flashbots relay
src/flashbots.rs:116
↓ 3 callers
Method
update
(&mut self)
src/markets.rs:162
↓ 2 callers
Function
bigint_bigdecimal
Convert a BigInt into a BigDecimal
src/utilities.rs:27
↓ 2 callers
Method
get_tokens_in
(&self, token_in: &Address, token_out: &Address, amount_out: &U256)
src/uniswap.rs:276
↓ 2 callers
Function
keccak256
Return keccak 256 hash of to_hash.
src/flashbots.rs:21
↓ 2 callers
Method
miner_reward_percentage
(&self)
src/uniswap.rs:266
↓ 2 callers
Method
sell_tokens
( &self, token_in: &Address, amount_in: &U256, recipient: &Address, )
src/uniswap.rs:282
↓ 2 callers
Method
sign
Signs and returns transaction.
src/utilities.rs:156
↓ 2 callers
Function
to_gwei
Convert a U256 of wei to a
src/utilities.rs:39
↓ 2 callers
Function
u256_bigint
Convert a U256 to a BigInt
src/utilities.rs:20
↓ 1 callers
Method
best_ask_market
Return the best market to buy from, given an origin in the token pair
src/markets.rs:143
↓ 1 callers
Method
best_bid_market
TODO(Handle what clippy says here around a boxed reference) Return the best market to sell to, given an origin in the token pair
src/markets.rs:123
↓ 1 callers
Method
delta_contracts
(&self)
src/uniswap.rs:258
↓ 1 callers
Method
encode_parameters
This should take the multicall header and a vector of calls
src/evm.rs:110
↓ 1 callers
Method
evaluate_markets
( &self, markets: &'a MarketGraph, )
src/arbitrage.rs:205
↓ 1 callers
Method
generate
( &self, markets: &MarketGraph, transport: &Web3<WebSocket>, account: &Address
src/arbitrage.rs:380
↓ 1 callers
Function
generate_contract_transaction
Estimates gas, generates metadata and returns metadata and transaction parameters
src/utilities.rs:73
↓ 1 callers
Function
loop_blocks
(run_data: &mut RunData)
src/lib.rs:268
↓ 1 callers
Method
market_address
(&self)
src/uniswap.rs:254
↓ 1 callers
Method
market_count
(&self)
src/markets.rs:171
↓ 1 callers
Method
miner_payment
(&self)
src/flashbots.rs:92
↓ 1 callers
Function
nonce
Get the present nonce for an address
src/utilities.rs:47
↓ 1 callers
Method
optimize_volume
Optimize order volume for profit
src/arbitrage.rs:53
↓ 1 callers
Function
print_startup
Display startup message
src/lib.rs:321
↓ 1 callers
Function
run
(config: &Config)
src/lib.rs:331
↓ 1 callers
Method
score
Return the bundle score
src/flashbots.rs:87
↓ 1 callers
Function
search
TODO(Break down this function further)
src/lib.rs:144
↓ 1 callers
Method
sign_transactions
( self, transport: &Web3<WebSocket>, transactions: &mut Vec<utilities::Transaction>,
src/wallet.rs:36
↓ 1 callers
Method
take_crossed_market
( &self, crossed_market: &CrossedMarketDetails<'_, T>, account: &Address, ape_
src/arbitrage.rs:265
↓ 1 callers
Method
to_first_market
(&self, token_address: &Address, amount: &U256)
src/uniswap.rs:339
↓ 1 callers
Method
update_all
Update all markets
src/markets.rs:313
↓ 1 callers
Method
update_delta
Update markets based on the state block logs
src/markets.rs:276
↓ 1 callers
Method
update_exchange_rate
(&mut self)
src/compound.rs:43
Function
construct_wallet
()
src/wallet.rs:60
Function
construct_wallet_invalid
()
src/wallet.rs:75
Method
delta_contracts
(&self)
src/compound.rs:71
Method
delta_contracts
(&self)
src/weth_token.rs:47
Method
encode
(&self)
src/evm.rs:83
Method
fmt
(&self, f: &mut fmt::Formatter)
src/arbitrage.rs:163
Method
fmt
(&self, f: &mut fmt::Formatter)
src/markets.rs:39
Method
get_all_markets
(transport: &Web3<WebSocket>)
src/uniswap.rs:230
Method
get_amount_in
(reserve_in: &U256, reserve_out: &U256, amount_out: &U256)
src/uniswap.rs:96
Method
get_amount_out
(reserve_in: &U256, reserve_out: &U256, amount_in: &U256)
src/uniswap.rs:109
Method
get_price_wei
Uses Uniswap v2 getAmountsOut to get the price in weth of a token.
src/uniswap.rs:40
Method
get_prices
(transport: &Web3<WebSocket>)
src/gas.rs:16
Method
get_tokens_in
(&self, token_in: &Address, token_out: &Address, amount_out: &U256)
src/compound.rs:97
Method
get_tokens_in
(&self, _token_in: &Address, _token_out: &Address, amount_out: &U256)
src/weth_token.rs:65
Method
get_tokens_out
These functions are essentially inverse operations
src/compound.rs:85
Method
get_tokens_out
(&self, _token_in: &Address, _token_out: &Address, amount_in: &U256)
src/weth_token.rs:60
Method
get_uniswappy_markets
Return a list of all weth market pairs for a given uniswap v2 factory address
src/uniswap.rs:176
Method
get_uniswappy_markets_batch
( transport: &Web3<WebSocket>, query_interface: &Contract<WebSocket>, factory_address:
src/uniswap.rs:120
Function
main
()
src/main.rs:7
Method
market_address
(&self)
src/compound.rs:67
Method
market_address
(&self)
src/weth_token.rs:43
Method
miner_reward_percentage
(&self)
src/compound.rs:80
Method
miner_reward_percentage
(&self)
src/weth_token.rs:56
Method
new
( origin_token: Address, intermediary_token: Address, bid_market: &'a T, ask_m
src/arbitrage.rs:34
Method
new
(transport: &web3::Web3<WebSocket>)
src/sushiswap.rs:15
Method
new
()
src/markets.rs:117
Method
new
(transport: &Web3<WebSocket>)
src/gas.rs:55
Method
new
()
src/lib.rs:41
Method
new
(transport: &Web3<WebSocket>)
src/compound.rs:25
Method
new
(private_key: &str)
src/wallet.rs:20
Method
new
( target: Address, method: Vec<u8>, call_type: Type, value: Option<U256>,
src/evm.rs:34
Method
new
(address: Address, transport: &web3::Web3<WebSocket>)
src/uniswap.rs:29
Method
new
(transport: &Web3<WebSocket>)
src/weth_token.rs:23
Method
pending_reward_balance
(&self, pid: U256, address: Address)
src/sushiswap.rs:27
Method
prepare_receive
(&self, _token_address: &Address)
src/compound.rs:179
Method
prepare_receive
This is a noop for Uniswap V2
src/uniswap.rs:364
Method
prepare_receive
(&self, _token_address: &Address)
src/weth_token.rs:140
Method
protocol
(&self)
src/compound.rs:76
Method
protocol
(&self)
src/uniswap.rs:262
Method
protocol
(&self)
src/weth_token.rs:52
Method
receive_directly
(&self, _token_address: &Address)
src/compound.rs:165
Method
receive_directly
(&self, token_address: &Address)
src/uniswap.rs:335
Method
receive_directly
(&self, _token_address: &Address)
src/weth_token.rs:127
Method
sell_tokens
( &self, token_in: &Address, amount_in: &U256, _recipient: &Address, )
src/compound.rs:109
Method
sell_tokens
( &self, token_in: &Address, amount_in: &U256, _recipient: &Address, )
src/weth_token.rs:70
Function
sign_body
(body: &str, private_key: &SecretKey)
src/flashbots.rs:29
Function
sushi_balance
( sushi: &Contract<WebSocket>, public_key: Address, block_number: U64, )
src/utilities.rs:55
Method
taken_profit
(&self)
src/flashbots.rs:78
Function
to_ether
Convert a U256 of wei to an ether BigDecimal
src/utilities.rs:32
Method
to_first_market
TODO(These could be implemented to allow management of funds in another contract or EOA)
src/compound.rs:171
Method
to_first_market
TODO(These could be implemented to allow management of funds in another contract or EOA)
src/weth_token.rs:132
Method
tokens
(&self)
src/compound.rs:63
Method
tokens
(&self)
src/weth_token.rs:39
Method
total_market_count
(&self)
src/markets.rs:271
Method
update
(&mut self)
src/compound.rs:161
Method
update
(&mut self)
src/uniswap.rs:319
Method
update
(&mut self)
src/weth_token.rs:123