Zero Runtime Dependencies: Deployed code runs with zero runtime node_modules. Modules inside tgcloud/ may import only the built-in sdk (db, api, fetch, InputFile, BotApiError) / sdk/db and relative .js files inside tgcloud/.
Flat Handlers Directory:tgcloud/handlers/ is strictly flat (one level deep).
Bot-Only Surface:tgcloud.jsonc defines no "static" front-end and there are no Mini App endpoints/.
Handles owner private-chat commands (/start, /trigger, /autodelete) and CLI owner bootstrap ({owner_id} with {ci_bootstrap: true}); rejects non-owners and groups.
business_connection.js
business_connection
Validates single-owner access, updates connections.is_enabled, and delivers 🔗 Telegram Business Connected.
business_message.js
business_message
Archives incoming and outgoing Business messages, runs View-Once capture and smart-trigger auto-delete on owner replies, and triggers ~2% opportunistic retention cleanup.
edited_business_message.js
edited_business_message
Filters false positives via isMeaningfulEdit, updates messages.edit_history with optimistic edit_date checks, and sends silent 1-message or 3-message diffs.
deleted_business_messages.js
deleted_business_messages
Atomically claims incoming deleted messages (up to MAX_DELETE_BATCH = 25), reconstructs albums (sendMediaGroup) or 4,000-character digests, and summarizes unarchived deletions.
Contributing Boundaries: Keep all runtime additions inside tgcloud/ using only built-in sdk / sdk/db imports and relative .js paths, maintain a flat tgcloud/handlers/ directory, and keep zero runtime node_modules.
Privacy Notice: This assistant is intended strictly for personal, single-owner Telegram Business use. The bot owner is solely responsible for complying with applicable local privacy and consent laws as well as Telegram’s Terms of Service and Bot Developer Terms.
License: Distributed under the Mozilla Public License 2.0 (MPL-2.0).