The open source version comes with 1 sample arbitrage strategy. Copied from /src/Arbitrage/Strategies/Spread.ts
interface SpreadAction extends ArbitrageStrategyAction {
spreadEntry: number; // 0.8% // How many % the market spread between the 2 exchanges has to be to open positions on both of them.
spreadTarget: number; // 0.5% // Targeted profit in %. This takes trading fees into account. See the 'tradingFees' setting.
// Positions will be closed according to this equation: spreadExit = spreadEntry - 4*fees - spreadTarget -> will usually negative, meaning prices flipped
trailingSpreadStop: number; // 0.08% // After reaching spreadTarget, place a trailing stop to exit the market. Set this to 0 to exit immediately,
}
/**
* Arbitrage strategy that computes the average price across exchanges.
* If the price is x% higher/lower than avg on exchanges:
* 1. buy at the cheaper exchange and (short) sell at the expensive exchange
* 2. close positions after price difference moves x% closer
*/
export default class Spread extends AbstractArbitrageStrategy {
There is also an example config under /config/arbitrage/Leverage.json doing arbitrage between Bitfinex and OKEX leveraged futures using the Spread strategy mentioned above.
You can adjust this file to your needs or (better) write your own arbitrage strategy for exchanges:
The open source version comes with 1 sample arbitrage strategy. Copied from
/src/Arbitrage/Strategies/Spread.ts
There is also an example config under
/config/arbitrage/Leverage.json
doing arbitrage between Bitfinex and OKEX leveraged futures using the Spread strategy mentioned above. You can adjust this file to your needs or (better) write your own arbitrage strategy for exchanges: