Go to file
Maximilian Schneider ffa4b39091 crank.sh logs now to a logfile 2021-04-28 17:09:03 +00:00
src updated waiting 2021-04-22 17:04:33 -04:00
.gitignore add notification webhook 2021-03-14 00:24:23 +01:00
LICENSE Initial commit 2021-03-09 08:20:27 -05:00
README.md cleaned up partial liquidator and readme 2021-04-18 10:08:44 -04:00
crank.sh crank.sh logs now to a logfile 2021-04-28 17:09:03 +00:00
package-lock.json add 1% bias to liquidator, to allow third parties to step in first, also improve discord logs 2021-03-16 12:35:07 +01:00
package.json updated package.json 2021-04-22 17:01:44 -04:00
tsconfig.json separated liquidator from mango repo 2021-03-09 08:32:07 -05:00
yarn.lock package json pointing to mango client npm package 2021-04-09 16:42:02 -04:00

README.md

Mango Liquidator

Setup Partial Liquidator

Make sure to edit the .env file to look something like this:

export CLUSTER="mainnet-beta"
export CLUSTER_URL="https://solana-api.projectserum.com"
export KEYPAIR=~/.config/solana/id.json
export NODE_ENV=production
export TARGETS="0.1 2"
export GROUP_NAME="BTC_ETH_USDT"
export CHECK_INTERVAL="1000.0"

TARGETS represents the BTC and ETH amounts the partial liquidator should try to maintain in the liquidator's wallet. Any excess of that amount in the wallet will be market sold on Serum DEX.

CHECK_INTERVAL is the amount of milliseconds to wait between querying all margin accounts

Run

yarn install
source .env
yarn partialLiquidate

Setup Full Liquidator [DEPRECATED]

Make sure to edit the .env file to look something like this:

export CLUSTER="mainnet-beta"
export CLUSTER_URL="https://solana-api.projectserum.com"
export KEYPAIR=~/.config/solana/id.json
export NODE_ENV=production
export GROUP_NAME="BTC_ETH_USDT"

Run

yarn install
source .env
yarn liquidate