types.ts # Types for TelegramUpdate, MergedDb, UserLink, BillingCheckResult
webhook.ts # Handles secret verification and update parsing
router.ts # Routes messages to bound agents and provides Telegram API helpers
bindings.ts # CRUD operations for telegram_chat_bindings in the platform-core DB
user-link.ts # Functions for resolving, ensuring, and linking users in LucidMerged DB
billing.ts # Functions for checking launch permissions, tracking deployments, and handling billing
layer-client.ts # HTTP client for interacting with the Lucid Layer API
wizard.ts # Multi-step launch wizard with a 30-minute TTL
keyboards.ts # Builders for inline keyboards
callbacks.ts # Handler for callback queries (button taps)
commands/
index.ts # Command dispatcher
start.ts # Handles /start command for agent binding and account linking
launch.ts # Handles /launch command for the deployment wizard
status.ts # Handles /status command
list.ts # Handles /list command
plan.ts # Handles /plan command
upgrade.ts # Handles /upgrade command for Stripe checkout
help.ts # Handles /help command