{"slug": "create-sandboxed-rich-text-telegram-agents-with-a-single-config-file", "title": "Create sandboxed rich-text telegram agents with a single config file", "summary": "A new open-source tool allows developers to create sandboxed Telegram agents with rich-text formatting using a single YAML config file. Built on Deno, the tool supports customizable system prompts and granular sandbox permissions for network, filesystem, and environment access. The agent uses Claude models and can execute JavaScript in a restricted subprocess, enabling diverse use cases like research paper readers or coding assistants.", "body_md": "create sandboxed rich-text telegram agents with a single config file\n\nneeds [deno](https://deno.com/).\n\n```\ndeno task start my-agent.yaml\n```\n\nthis example is a research paper reader:\n\n```\nname: my-agent\ntelegram_token: \"123456:ABC-DEF...\"\nanthropic_api_key: \"sk-ant-...\"\nallowed_usernames:\n  - your-username\nmodel: claude-opus-4-8        # optional\nsystem: |                    # optional — defines what the agent is\n  you are a research paper reader assistant.\n  download all (html) papers you read and store them.\n  when embedding a figure, only use real image urls from arxiv.org.\nsandbox:                     # optional — omit to deny all\n  net:   [\"arxiv.org\"]       # hosts, not urls\n  write: [\"./papers\"]\n  env:   false\n```\n\nrequired: `telegram_token`\n\n, `anthropic_api_key`\n\n, `allowed_usernames`\n\n. the\n`system`\n\nprompt is what turns the same engine into a paper reader, a maps\nhelper, a coding assistant, etc. — telegram formatting and the agent's sandbox\npermissions are explained to it automatically, so `system`\n\nonly needs the\npersona.\n\nthe yaml holds secrets. don't commit it.\n\nthe agent's one tool is `run_javascript`\n\n, which runs in a deno subprocess. each\n`sandbox`\n\nentry maps to a deno `--allow-*`\n\nflag on that subprocess:\n\n`true`\n\n→ allow (unrestricted)`[list]`\n\n→ allow only those hosts/paths (e.g.`--allow-net=a.com,b.com`\n\n)`false`\n\n/ omitted → denied\n\nomit the whole `sandbox`\n\nblock and generated js gets zero permissions. denied\noperations fail with a deno permission error returned to the agent. the agent is\ntold its exact permissions in its system prompt, so it knows what it can and\ncan't do.\n\nreplies are sent with telegram's `sendRichMessage`\n\n, so the agent's\ngithub-flavored markdown renders natively: headings, **bold**/*italic*,\n~~strikethrough~~, lists, task lists, blockquotes, `code`\n\n, fenced code blocks,\nlinks, footnotes, latex formulas (`$x^2$`\n\n), tables, and media blocks\n(`![](url)`\n\n, including maps via `<tg-map .../>`\n\n). a bad media url is stripped\nand the message is retried so formatting never gets dropped wholesale.\n\n- typing indicator while it works\n- native rich-text replies (graceful fallback)\n- per-user conversation history (in memory, resets on restart)\n- streamed under the hood so long replies don't time out\n\n```\ndeno task test\n```\n\n", "url": "https://wpnews.pro/news/create-sandboxed-rich-text-telegram-agents-with-a-single-config-file", "canonical_source": "https://github.com/montyanderson/007", "published_at": "2026-06-29 08:44:31+00:00", "updated_at": "2026-06-29 08:58:21.218353+00:00", "lang": "en", "topics": ["ai-agents", "developer-tools", "ai-tools"], "entities": ["Deno", "Telegram", "Anthropic", "Claude"], "alternates": {"html": "https://wpnews.pro/news/create-sandboxed-rich-text-telegram-agents-with-a-single-config-file", "markdown": "https://wpnews.pro/news/create-sandboxed-rich-text-telegram-agents-with-a-single-config-file.md", "text": "https://wpnews.pro/news/create-sandboxed-rich-text-telegram-agents-with-a-single-config-file.txt", "jsonld": "https://wpnews.pro/news/create-sandboxed-rich-text-telegram-agents-with-a-single-config-file.jsonld"}}