{"id":22035169,"url":"https://github.com/cryptojoma/adaptivetradebot","last_synced_at":"2025-03-23T12:25:15.864Z","repository":{"id":265022421,"uuid":"894891035","full_name":"CryptoJoma/AdaptiveTradeBot","owner":"CryptoJoma","description":"Dynamic cryptocurrency trading bot for Binance that supports both spot and futures trading. It automatically adjusts trade amounts between $10 and $100, optimizes investment quantities between operations, and utilizes a Moving Average Crossover strategy to execute trades on pairs like BTCUSDT, ETHUSDT, POLUSDT, and more.","archived":false,"fork":false,"pushed_at":"2024-11-27T07:58:38.000Z","size":0,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-11-27T08:27:48.231Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/CryptoJoma.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-11-27T07:28:15.000Z","updated_at":"2024-11-27T07:58:41.000Z","dependencies_parsed_at":"2024-11-27T08:38:18.275Z","dependency_job_id":null,"html_url":"https://github.com/CryptoJoma/AdaptiveTradeBot","commit_stats":null,"previous_names":["cryptojoma/adaptivetradebot"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CryptoJoma%2FAdaptiveTradeBot","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CryptoJoma%2FAdaptiveTradeBot/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CryptoJoma%2FAdaptiveTradeBot/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CryptoJoma%2FAdaptiveTradeBot/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/CryptoJoma","download_url":"https://codeload.github.com/CryptoJoma/AdaptiveTradeBot/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":236072177,"owners_count":19090401,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-30T10:16:37.152Z","updated_at":"2025-01-28T18:41:43.054Z","avatar_url":"https://github.com/CryptoJoma.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# AdaptiveTradeBot\n\nDynamic cryptocurrency trading bot for Binance that supports both spot and futures trading. It automatically adjusts trade amounts between a specific range, adapts investment quantities to optimize trading operations, and implements a Moving Average Crossover strategy. Compatible with popular trading pairs like BTCUSDT, ETHUSDT, and more.\n\n## Table of Contents\n\n- [Features](#features)\n- [Prerequisites](#prerequisites)\n- [Installation](#installation)\n- [Configuration](#configuration)\n- [Usage](#usage)\n- [Customization](#customization)\n- [Security Considerations](#security-considerations)\n- [Disclaimer](#disclaimer)\n- [License](#license)\n- [Contact](#contact)\n- [Contribution](#contribution)\n\n## Features\n\n- **Dynamic Trade Amounts**: Automatically adjusts trade amounts between \\$10 and \\$100.\n- **Spot and Futures Trading**: Supports both spot and futures markets on Binance.\n- **Moving Average Crossover Strategy**: Implements a simple yet effective trading strategy.\n- **Supports Multiple Trading Pairs**: Works with BTCUSDT, ETHUSDT, and other popular pairs.\n- **Logging**: Records detailed logs of trading activities and errors.\n- **Error Handling**: Includes robust error handling for network issues and API errors.\n\n## Prerequisites\n\n- **Python 3.x** installed on your system.\n- **Binance Account** with API access:\n  - Ensure API keys have the necessary permissions (Spot and/or Futures Trading).\n  - **Do not** enable withdrawal permissions.\n- Basic knowledge of Python and cryptocurrency trading concepts.\n\n## Installation\n\n1. **Clone the Repository**\n\n   ```bash\n   git clone https://github.com/yourusername/AdaptiveTradeBot.git\n   cd AdaptiveTradeBot\n2. **Install Required Libraries**\n   ```bash\n   pip install -r requirements.txt\n  Note: If requirements.txt is not present, install the libraries manually:\n   ```bash\n   pip install python-binance pandas\n   ```\n\n## Configuration\n\n1. **API Keys**\n- Obtain your Binance API Key and Secret Key from your Binance account.\n- Store them securely.\n\n2. **Set Up Environment Variables**\n   For enhanced security, use environment variables to store your API keys.\n   - On Linux/Mac\n    ```bash\n    export BINANCE_API_KEY='your_api_key'\n    export BINANCE_API_SECRET='your_api_secret'\n    ```\n   - On Windows:\n    ```bash\n    set BINANCE_API_KEY='your_api_key'\n    set BINANCE_API_SECRET='your_api_secret'\n\n3. **Adjust Trading Parameters**\n   Open trading_bot.py and modify the following variables as needed:\n   ```bash\n   symbol = 'BTCUSDT'         # Trading pair (e.g., 'BTCUSDT', 'ETHUSDT', 'POLUSDT')\n   min_trade_amount = 10      # Minimum trade amount in USD\n   max_trade_amount = 100     # Maximum trade amount in USD\n   short_window = 10          # Short-term moving average window\n   long_window = 30           # Long-term moving average window\n   trading_type = 'spot'      # Choose 'spot' or 'futures'\n   demo_mode = True           # Set to False to enable live trading\n\n## Usage\n1. **Run the Bot**\n   ```bash\n   python trading_bot.py\n2. **Monitor Logs**\n   - The bot writes logs to trading_bot.log. Monitor this file to track activities.\n   - Adjust the logging level in trading_bot.py if needed.\n3. **Demo Mode**\n   - By default, the bot runs in demo mode and simulates trades without executing them.\n   - To enable live trading, set demo_mode to False in trading_bot.py.\n     ```bash\n     demo_mode = False\n\n## Customization\n- **Trading Strategy**: Modify the apply_strategy function to implement different trading strategies or indicators.\n- **Trade Amount Logic**: Enhance the get_trade_amount function to adjust trade amounts based on your risk management strategy.\n- **Risk Management**: Implement stop-loss and take-profit mechanisms.\n\n## Security Considerations\n- **API Keys**: Keep your API keys confidential. Do not share them or commit them to version control.\n- **API Permissions**: Only enable the permissions necessary for the bot to function.\n- **Environment Variables**: Use environment variables or secure key storage solutions.\n\n## Disclaimer\n- **Financial Risk**: Trading cryptocurrencies involves significant risk and may result in financial loss. Only trade with funds you can afford to lose.\n- **Educational Purpose**: This bot is provided for educational purposes and does not constitute financial advice.\n- **No Warranty**: The software is provided \"as is\", without warranty of any kind.\n\n## License\nThis code is provided under the Apache 2.0 License\n\n## Contact\nFor any questions or support, please contact coffee@joma.dev\n\n## Contribution\nFeel free to fork this repository and submit pull requests. For major changes, please open an issue first to discuss what you would like to change.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcryptojoma%2Fadaptivetradebot","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcryptojoma%2Fadaptivetradebot","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcryptojoma%2Fadaptivetradebot/lists"}