Add multi-channel support for stock updates

Bot now supports sending updates to multiple Discord channels simultaneously.

Changes:
- CHANNEL_ID accepts comma-separated list of channel IDs
- Config parses and validates multiple channel IDs
- Hourly and market close updates sent to all configured channels
- Update .env.example to show multi-channel format
- Document multi-channel configuration in README

Example: CHANNEL_ID=1442203998932304035,9876543210123456789

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Michael Simard
2025-12-03 19:01:01 -06:00
parent 584ad2a4f4
commit 327e7e0914
4 changed files with 28 additions and 14 deletions

View File

@@ -159,11 +159,16 @@ Environment variables in `.env`:
| Variable | Description | Default |
|----------|-------------|---------|
| `DISCORD_TOKEN` | Your Discord bot token | Required |
| `CHANNEL_ID` | Discord channel ID for updates | Required |
| `CHANNEL_ID` | Discord channel ID(s) for updates (comma-separated for multiple) | Required |
| `COMMAND_PREFIX` | Command prefix for bot | `!` |
| `PRIMARY_TICKER` | Stock ticker for hourly updates | `PYPL` |
| `UPDATE_INTERVAL_HOURS` | Hours between updates | `1` |
**Multi-Channel Support:** To send updates to multiple channels, provide comma-separated channel IDs:
```
CHANNEL_ID=1442203998932304035,9876543210123456789
```
## Switching Stock API Providers
The bot is designed with an abstract API layer. To switch providers: