Go MTProto client for Telegram bots and userbots — generated TL types, domain-based packages, SQLite session storage, middleware, and plugin system
mtgo is a Go library that lets developers build Telegram bots and user account clients. It handles all the complex encryption and protocol details automatically, so developers can focus on writing simple handler functions to send messages, process callbacks, and manage chats. The library supports direct connections to Telegram or routing through MTProxy for restrictive networks, and can import existing sessions from other Telegram libraries.
How It Works
A developer friend tells you about mtgo, a fast Go library for building Telegram bots and user accounts without dealing with complex encryption.
You import mtgo into your Go project with a simple command, ready to create your first Telegram client.
You enter your Telegram API ID and hash (from my.telegram.org) to identify your application to Telegram's servers.
Behind the scenes, mtgo automatically handles all the secure handshakes, generates encryption keys, and establishes a safe connection to Telegram — no action needed from you.
You register simple handler functions that react to messages, callback buttons, or other events using easy-to-read filters.
Your bot connects straight to Telegram servers using the standard encrypted protocol.
Your bot tunnels through a proxy server, useful when Telegram is restricted in your region.
You start your application and watch your bot come online, ready to respond to users around the world.
Your bot responds to messages, handles callbacks, and sends media — all through mtgo's clean interface, while the complex protocol runs safely under the hood.
Star Growth
Repurpose is a Pro feature
Generate ready-to-use prompts for X threads, LinkedIn posts, blog posts, YouTube scripts, and more -- with full repo context baked in.
Unlock RepurposeSimilar repos coming soon.