Code Monkey home page Code Monkey logo

drifting-mango's Introduction

Drifting Mango

please use caution and burner wallets when using this experimental software

What is it

The program looks at Mango SOL-PERP price and Drift SOL-PERP price.

Once the gap becomes wide enough, it opens a postion on both side to close the gap.

For example if Mango is selling at 260 and Drift is selling at 230, it will open Mango market short and Drift market long (in one transaction!).

Pre-requisite

  1. You will need Drift Alpha access
  2. Import your Drift Alpha access's wallet private key into Phantom. You can paste the whole array in as private key.
  3. Deposit USDC into Drift via UI
  4. Create new Mango Account in the same wallet via UI
  5. Deposit same amount of money into Mango
  6. Adjust POSITION_SIZE_USD, MAX_POSITION_SIZE.
  7. Enjoy

Quick Start

yarn
ts-node src/drifting-mango.ts

Disclaimer

NFA, everything is written as an experiment, please don't put more than couple bucks into it.

It also has no liquidation preventive measure, you will get liquidated.

drifting-mango's People

Contributors

0xbigz avatar chenwainuo avatar crispheaney avatar

Stargazers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.