How geffrerson7/iv100-bot works
This repository implements a Telegram bot that periodically finds Pokémon coordinates for IV 90 or IV 100 and posts formatted results to a configured Telegram group. Users start or stop a search with commands; scheduled callbacks obtain data, build messages, and send them. The app can receive Telegram updates through a FastAPI webhook or run Telegram polling in debug mode. The graph includes the documented command capabilities and data-enrichment files. Some service internals and endpoint behavior are unsampled, so only relationships shown in excerpts, the source index, or README are connected.
Main entry points: ptb.py Telegram application · main.py Startup and routing · api.py FastAPI application · service.py Coordinate processing
Components 16
Runtime entry
- Startup and routing
main.py - FastAPI application
api.py - Webhook endpoint
bot/endpoints.py - Telegram application
bot/ptb.py - Runtime settings
settings/config.py
Bot workflow
- IV and stop commands
bot/commands.py - Scheduled IV callbacks
bot/commands.py - Update error handling
bot/handlers.py - Logging setup
common/log.py
Pokemon data
- Coordinate processing
bot/service.py - Pokemon name data
data/pokemon_data.json - Move metadata
data/moves.json
Other components
- Telegram user
- Telegram platform
- Pokemon map services
- Configured Telegram group
Connections 23
- Telegram user → Telegram platform: sends commands
README.md - Startup and routing → Runtime settings: reads settings
main.py - Startup and routing → FastAPI application: runs app
main.py - Startup and routing → Telegram application: registers commands
main.py - Startup and routing → IV and stop commands: registers handlers
main.py - FastAPI application → Runtime settings: selects mode
api.py - FastAPI application → Webhook endpoint: mounts router
api.py - FastAPI application → Telegram application: uses lifespan
api.py - Webhook endpoint → Telegram application: dispatches updates
bot/endpoints.py - Telegram platform → Webhook endpoint: posts updates
bot/endpoints.py - Telegram application → Runtime settings: reads token
bot/ptb.py - Telegram application → Telegram platform: configures webhook
bot/ptb.py - Telegram platform → Telegram application: delivers updates
- IV and stop commands → Scheduled IV callbacks: schedules callbacks
bot/commands.py - Scheduled IV callbacks → Coordinate processing: generates messages
bot/commands.py - Coordinate processing → Pokemon map services: fetches coordinates
bot/service.py - Coordinate processing → Pokemon name data: reads names
bot/service.py - Coordinate processing → Move metadata: reads moves
bot/service.py - IV and stop commands → Configured Telegram group: sends results
bot/commands.py - Telegram user → IV and stop commands: invokes commands
README.md - Telegram application → Update error handling: routes errors
main.py - Update error handling → Logging setup: uses logger
bot/handlers.py - Update error handling → Configured Telegram group: sends notices
bot/handlers.py