Go to file
Nicolás Sánchez fa51e1d97a todo update 2025-03-10 18:30:53 -03:00
configs force_restart_if_retries_exhausted 2024-11-30 13:42:08 -03:00
logs Initial commit 2024-10-24 23:33:47 -03:00
profits yearly details line 2024-12-31 21:25:44 -03:00
utils removed old strings 2025-03-03 11:23:26 -03:00
.gitignore switch_to_long error 2024-12-04 16:39:52 -03:00
LICENSE Add LICENSE 2024-12-03 23:12:23 +00:00
README.md Typo 2024-11-03 18:31:35 -03:00
changelog.txt error fix in take_profit_routine 2025-03-07 14:41:32 -03:00
config_handler.py bugfixes 2025-03-04 20:18:24 -03:00
credentials.py.example Initial documentation 2024-11-01 20:09:44 -03:00
duster.py Initial commit 2024-10-24 23:33:47 -03:00
exchange_wrapper.py renamed variable 2025-03-02 15:57:14 -03:00
main.py error fix in take_profit_routine 2025-03-07 14:41:32 -03:00
requirements.txt Initial documentation 2024-11-01 20:09:44 -03:00
status_handler.py bugfixes 2025-03-04 20:18:24 -03:00
todo.txt todo update 2025-03-10 18:30:53 -03:00
trader.py error fix in take_profit_routine 2025-03-07 14:41:32 -03:00

README.md

DCAv2

Cryptocurrency trading bot.

Features

  • DCA/martingale hybrid trading strategy.
  • Support for Binance, Gate.io, KuCoin and OKX.
  • Spot market only.
  • Customizable trading parameters.
  • Control and monitoring over REST API endpoints.
  • 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