Nick Oak blog
← Back

tg-useragent-cli

Telegram user-account operations for agents, with the safety rails up front.

`tg-useragent-cli` is a Go CLI for working with Telegram through MTProto, not the Bot API. That means it sits near a much more sensitive surface: real dialogs, real messages, real media, and write-capable user-account actions.

The design is agent-first but local-first. Agents can inspect command schemas, sync scoped dialogs into a local SQLite mirror, search or export bounded windows, chunk messages for analysis, and plan media downloads or replies without dumping private text into command output by default.

The safety model is the product. Writes require explicit command surfaces, dry-run plans, scoped permissions, and confirmation tokens. Global DM search and media access are treated as sensitive disclosure events, not casual convenience features.

This is a huge thing for me because Telegram is where a lot of real life enters the agent interface. The goal is not "let the model read everything". The goal is a disciplined bridge: enough access for useful coordination, enough friction that account automation remains legible and intentional.

Receipts: public repo.