DCAv2/README.md

2.5 KiB

DCAv2

Cryptocurrency trading bot.

Features

  • DCA/martingale hybrid trading strategy.
  • Support for Binance, Gate.io, KuCoin and OKX.
  • Spot market only.
  • Customizable trading parameters.
  • Real-time market data updates.
  • Automatic order placement and management.
  • Statistics server for building real-time dashboards.
  • Additional scripts for stats and analysis.

Getting Started

ATTENTION: THIS PROGRAM IS A PERSONAL PROJECT AND IS NOT INTENDED TO BE USED BY ANYONE ELSE. USE AT YOUR OWN RISK.

Installation

Step-by-step installation guide:

  1. Clone the repository
git clone https://gitlab.nicosanchez.com.ar/nicolas/dcav2.git
  1. Navigate to the project directory
cd DCAv2
  1. Install dependencies
pip install requirements.txt
# or
pip install -r requirements.txt
  1. Configure the project
# There are configuration file examples in the config folder.
  1. Generate keys
# Generate keys for the statistics server API
cd utils
python3 generate_keys.py
  1. Copy keys to the credentials.py file
# Copy the generated keys to the credentials.py file in the utils folder.
python3 read_key.db.py

Usage

To start the program for the first time, run the following command:

python3 main.py configs/exchange_config.json --first_start

If you stop the program and restart it, it will continue from where it left off by removing the --first_start option:

python3 main.py configs/exchange_config.json

Configuration

You should have at least one exchange configuration file. If there are no trading pairs included in that configuration, you can add them at runtime using the commander.py script located in the utils folder.

Troubleshooting

API keys

When configuring the API keys, please make sure that you have the correct permissions for the API key. If you are using a test API key, you may need to enable the test mode in the exchange's API settings.

DO NOT ASSIGN WITHDRAWAL OR TRANSFER PERMISSIONS TO YOUR API KEYS. The only permissions required are spot trading, balance read and market data (which is public anyway)

API rate limits

The program tries to be frugal with the API usage (it was tested running over 50 trading pairs with absolutely no issues), but still beware of running several instances with the same API keys/IP address.

Strategy

(WIP)

Contact

If you have any questions or issues, please contact me at nicolassanchez@tutanota.com.

Project Link: https://gitlab.nicosanchez.com.ar/nicolas/dcav2