• Stars
    star
    188
  • Rank 205,522 (Top 5 %)
  • Language
    Rust
  • License
    MIT License
  • Created over 1 year ago
  • Updated 2 months ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Sample Artemis bot to fill UniswapX orders using on-chain liquidity

UniswapX Atomic Filler

This is a sample Artemis bot that fills UniswapX orders atomically using Uniswap v2 and v3 liquidity.

Feel free to fork and modify to run any strategies you wish to fill UniswapX orders!

Usage

First you must deploy an executor contract that implements the IReactorCallback interface. This sample currently uses the provided SwapRouter02Executor.

Then update the address constant in uniswapx_strategy to point to your executor contract.

Finally, run the bot with the following command:

cargo run -- --wss <websocket RPC url> --private-key <private key> --bid-percentage <percent of profit to share as gas>

Collectors

block-collector

Collects new blocks as they are confirmed. Similar to the base one in Artemis-core but includes timestamp data to resolve dutch decays

uniswapx-order-collector

Collects new executable UniswapX orders as they are posted.

uniswapx-route-collector

Finds on-chain AMM routes to fill UniswapX orders. Ran in a separate collector thread as these can be slow and don't want to block other processing.

Strategies

uniswapx-strategy

Simple strategy that batches UniswapX orders together by tokenin/tokenout pair and attempts to fill using Uniswap protocol liquidity

Crates

uniswapx-rs

Library for encoding, decoding, and resolving UniswapX dutch orders

bindings-uniswapx

Autogenerated forge bindings for UniswapX contracts