How jishnuharis/anonchatzonebot works
AnonChatZoneBot is a Telegram anonymous-chat product. Users complete profile setup and interest preferences, request a partner, are filtered and paired, then exchange relayed messages until either ends the session; supporting branches include games, friends, subscriptions, and privacy features. The graph preserves the README’s major capabilities. Relationship evidence is limited to README statements and SOURCE INDEX references; unsampled modules are represented by their documented responsibilities, without claiming their internals were inspected.
Main entry points: session_manager.py Session lifecycle · saveNload.py PostgreSQL storage · matchmaking.py Matchmaking and filters · setup.py Profile onboarding
Components 31
User experience
- Profile onboarding
handlers/setup.py - Country selection
handlers/country.py - Interest preferences
handlers/preferences.py - Channel membership gate
channel_gate.py - Post-chat rating
handlers/rating.py
Chat runtime
- Partner search command
commands/find.py - Matchmaking and filters
matchmaking.py - Session lifecycle
session_manager.py - Message and action relay
relay.py - View-once media privacy
media_privacy.py - Skip and reconnect
commands/next.py
Engagement features
- Anonymous friends
handlers/friends.py - Game challenges
games/game_requests.py - Active game registry
games/registry.py - Mini-game engines
games - Game content loader
games/content/content_manager.py - Transcript export
handlers/transcript.py - Sponsor campaigns
promotions/service.py - Referral rewards
referral.py - Anonymous voice calls
commands/call.py
Platform services
- Bot startup and routing
main.py - Reports and restrictions
moderation.py - Payment handlers
handlers/payments.py - Subscription entitlements
subscription.py - API safety and rate limits
security.py - Shared runtime state
init.py - PostgreSQL storage
saveNload.py - Schema and migration
migrations.py
Operations
- Health endpoint
app.py
Other components
- Telegram users
- Telegram API
Connections 42
- Telegram users → Telegram API: send commands
- Telegram API → Bot startup and routing: delivers updates
- Bot startup and routing → Partner search command: routes commands
main.py - Bot startup and routing → Profile onboarding: routes handlers
main.py - Profile onboarding → Country selection: requests selection
handlers/setup.py - Profile onboarding → Referral rewards: captures referral
handlers/setup.py - Profile onboarding → Channel membership gate: checks membership
handlers/setup.py - Interest preferences → Channel membership gate: checks membership
handlers/preferences.py - Telegram users → Partner search command: requests partner
- Partner search command → Matchmaking and filters: queues for match
- Matchmaking and filters → Session lifecycle: creates paired session
matchmaking.py - Matchmaking and filters → Reports and restrictions: filters restrictions
matchmaking.py - Session lifecycle → Shared runtime state: tracks active pairs
session_manager.py - Session lifecycle → Active game registry: tears down games
session_manager.py - Session lifecycle → Sponsor campaigns: triggers post-chat delivery
session_manager.py - Session lifecycle → Post-chat rating: starts post-chat rating
session_manager.py - Session lifecycle → Transcript export: supports export
- Telegram users → Message and action relay: sends chat messages
- Message and action relay → Telegram API: forwards messages
- Message and action relay → View-once media privacy: applies media privacy
relay.py - Message and action relay → API safety and rate limits: uses safe calls
relay.py - Telegram users → Skip and reconnect: skips partner
- Skip and reconnect → Session lifecycle: ends current session
commands/next.py - Skip and reconnect → Matchmaking and filters: requests another match
commands/next.py - Telegram users → Anonymous friends: manages friend list
- Anonymous friends → Matchmaking and filters: checks busy state
handlers/friends.py - Anonymous friends → PostgreSQL storage: reads friend records
handlers/friends.py - Game challenges → Mini-game engines: dispatches challenges
games/game_requests.py - Mini-game engines → Active game registry: registers active game
games/coin_steal.py - Mini-game engines → Game content loader: loads questions
games/trivia.py - Game content loader → PostgreSQL storage: loads database content
- Sponsor campaigns → PostgreSQL storage: reads campaign data
promotions/service.py - Referral rewards → Subscription entitlements: grants rewards
referral.py - Payment handlers → Subscription entitlements: applies purchases
handlers/payments.py - Subscription entitlements → Shared runtime state: checks cached entitlements
subscription.py - Reports and restrictions → PostgreSQL storage: persists restrictions
moderation.py - Shared runtime state → PostgreSQL storage: loads and flushes users
init.py - Schema and migration → PostgreSQL storage: defines schema
saveNload.py - Telegram users → Anonymous voice calls: starts voice call
- Anonymous voice calls → Telegram API: launches WebApp room
- Telegram users → Health endpoint: requests health status
- Health endpoint → Telegram API: uses bot metrics