feat: Add /status command to Telegram bot for position monitoring

- Implemented /status command handler in telegram_command_bot.py
- Shows real-time P&L, entry/current prices, TP/SL levels, position info
- Added TRADING_BOT_URL and API_SECRET_KEY environment variables
- Updated docker-compose.telegram-bot.yml with new env vars
- Bot connects to trading-bot-v4:3000 API via internal Docker network
- Added comprehensive documentation and testing guides
- Command displays formatted position info with emojis (profit/loss indicators)
- Shows 'No open positions' message when no trades active
This commit is contained in:
mindesbunister
2025-10-27 12:40:10 +01:00
parent 4ae9c38ad8
commit 97ba6a9856
8 changed files with 571 additions and 3 deletions

View File

@@ -14,6 +14,8 @@ services:
- TELEGRAM_BOT_TOKEN=${TELEGRAM_BOT_TOKEN}
- N8N_WEBHOOK_URL=${N8N_WEBHOOK_URL}
- TELEGRAM_CHAT_ID=579304651
- TRADING_BOT_URL=${TRADING_BOT_URL:-http://trading-bot-v4:3000}
- API_SECRET_KEY=${API_SECRET_KEY}
networks:
- traderv4_trading-net