Coder Social home page Coder Social logo

artis's Introduction

Artis

Simple trading bot for cryptocurrencies.

We decided to open-source the bot since we are no longer using it. The main strategy used is arbitrage. The supported markets are Liqui and Binance. We always traded between ETH and another coin. Mainly TRX and ADX.

Some of the code is legacy from other strategies or attempts. Start from strategies/balance if you want to analyse the code. I started a refactor in one of the branches, but I have not finished it. The main algorithm is pretty much all unit tested.

We also wanted to add automatic balancing between networks, but never got to it. There is still some code for that all around.

Setup

It is meant to run in docker. The docker-compose.yml file will spawn the service and the database. It will record all the transactions made by the bot and the balance of each coin in each market.

You will need to add a settings.yaml file with the following information:

DYNACONF:
    MARKETS: ['LIQUI', 'BINANCE']
    SLACK:
        TOKEN: '<YOUR TOKEN HERE>'
        CHANNEL: '#trading_bot' # Change this for the channel you want
    LIQUI:
        TIMEOUT: 30000
        SERVICE_FEE_HIGH: 0.0025 # Sometimes markets have a different fee when you place an order vs fulfill one
        SERVICE_FEE_LOW: 0.0010
        COINS: ['ADX', 'TRX'] # Supported coins
        API_KEY: <API KEY HERE>
        API_SECRET: <API SECRET HERE>
    BINANCE:
        TIMEOUT: 10000
        SERVICE_FEE_HIGH: 0.0010
        SERVICE_FEE_LOW: 0.0010
        COINS: ['ADX', 'TRX']
        API_KEY: <API KEY HERE>
        API_SECRET: <API SECRET HERE>
    DATABASE_URL: postgresql://{}:{}@localhost/{}
    COIN: "TRX" # Selected coin
    PRECISION: 0 # How many digits to use after the dot
    AMOUNT_TO_TRADE: 0.1 # Trade volume in ETH to trade each time
    MINIMUM_AMOUNT_TO_TRADE: 0.015 # Minimum volume in ETH for a trade to occur
    PROFIT_FACTOR: 1.0135 # Minimum difference (in %) in prices for a trade to occur
    PROFIT_REDUCTION: 0.005 # Reduction of profit if we missed the trade
    SERVICE_NUMBER: 1
    SLEEP_TIME: 0.05 # Sleep between iterations (avoid too many API requests)

artis's People

Contributors

sytten avatar

Watchers

 avatar  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.