Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/lmvdz/zo-mm
01.xyz Market Maker - Solana
https://github.com/lmvdz/zo-mm
bot cryptocurrency solana web3js
Last synced: 3 months ago
JSON representation
01.xyz Market Maker - Solana
- Host: GitHub
- URL: https://github.com/lmvdz/zo-mm
- Owner: lmvdz
- Created: 2022-05-07T00:30:59.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2022-07-14T19:30:48.000Z (over 2 years ago)
- Last Synced: 2024-02-12T17:33:56.446Z (9 months ago)
- Topics: bot, cryptocurrency, solana, web3js
- Language: TypeScript
- Homepage:
- Size: 39.1 KB
- Stars: 2
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# 01.xyz Perp DEX Market Making Bot
> Should be easily configurable by anyone, plug and play
> Should place both ask and bid orders around some mid price
> The spread should be configurable
> Should automatically rebalance, and be able to maintain 24/7 liquidity
> Written in either TS, Python, or Rust
> Should be Open Sourced and available to all### Install
`git clone [email protected]:lmvdz/zo-mm.git`
`cd zo-client`
`git clone [email protected]:01protocol/zo-client.git`
`yarn`
`yarn build`
`cd ..`
`yarn`### Setup
`cp .env .env.local`
```.env
# the private key of the bot can be UInt8Array or base58
BOT_KEY=# the RPC url
RPC_URL=https://ssc-dao.genesysgo.net/# the delimiter which separates the markets to make
ACTIVE_MARKETS_DELIMITER=,# the pairs which the bot should act on ( BTC,ETH,SOL,LUNA,AVAX,APE,NEAR,GMT )
ACTIVE_MARKETS=BTC,ETH# how often in seconds the bot should cancel open orders and open fresh orders using the MM_SPREAD_PERCENTAGE to determine the distance from mark price
REBALANCE_INTERVAL=60# the total distance from short to long with mark price residing in the middle
MM_SPREAD_PERCENTAGE=0.1# the maximum loss percentage to allow before closing an open position
MAX_LOSS=0.25# the maximum gain percentage to allow before closing an open position
MAX_GAIN=0.25
```### Running
`yarn start`
![image](https://user-images.githubusercontent.com/2179775/167247190-00387c13-f40c-4368-86dc-2e9107a7a16e.png)
![image](https://user-images.githubusercontent.com/2179775/167247194-69d451c4-9155-4b79-bd82-5acf02d012c0.png)