Add the following environment variables to your .env file:
.env
# EnvironmentENVIRONMENT=development# MongoDB ConnectionMONGODB_URI_DEVELOPMENT="mongodb+srv://user:pass@cluster.mongodb.net/"MONGODB_URI_PRODUCTION="mongodb://localhost:27017/"MONGODB_DATABASE="proppr"# Telegram Bot TokensTELEGRAM_TOKEN_TEAM_BOT="123456789:ABCdefGHIjklMNOpqrsTUVwxyz"TELEGRAM_TOKEN_PLAYER_BOT="123456789:ABCdefGHIjklMNOpqrsTUVwxyz"TELEGRAM_TOKEN_EV_BOT="123456789:ABCdefGHIjklMNOpqrsTUVwxyz"TELEGRAM_TOKEN_ARB_BOT="123456789:ABCdefGHIjklMNOpqrsTUVwxyz"TELEGRAM_TOKEN_HORSE_BOT="123456789:ABCdefGHIjklMNOpqrsTUVwxyz"TELEGRAM_TOKEN_OVERTIME_BOT="123456789:ABCdefGHIjklMNOpqrsTUVwxyz"# API KeysODDS_API_KEY="your_odds_api_key"FOOTYSTATS_API_KEY="your_footystats_key"SPORTMONKS_API_TOKEN="your_sportmonks_token"# Google Sheets (optional for local)GOOGLE_SHEET_ID_TEAM="spreadsheet_id"GOOGLE_SHEET_ID_PLAYER="spreadsheet_id"# AdminADMIN_USER_ID="your_telegram_user_id"
Never commit the .env file to version control. It’s already in .gitignore to prevent accidental commits.
PROPPR uses a centralized configuration system at PROPPR/config/:
from PROPPR.config import ( get_mongo_connection_string, get_mongo_database, get_telegram_token, is_production, is_development,)# Automatically loads from .env in developmentmongo_uri = get_mongo_connection_string()db_name = get_mongo_database()token = get_telegram_token('team') # For Team Bot
The config system automatically detects whether you’re running on Linux (production) or macOS (development) and loads the appropriate MongoDB URI.