Papercraft Book ex. Telegram Bot Handbook
Welcome to the Papercraft Book! This is your guide to developing user-friendly, feature-rich, and stable bots for Telegram messenger. The book is independent of any specific programming language or library — I will gladly accept contributions from readers who add examples for different libraries.
We will cover all major features of the Telegram bot platform, starting from common features like /commands
and progressing to more specialized ones, such as managing join requests and subtopics in groups. Additionally, we will explore corner cases and development tips.
Another focus of this book is user experience. The book describes how to make bots easy to use and which Telegram features are more suitable in different cases.
I believe the Papercraft Book to be the most comprehensive and practical guide on developing bots for Telegram.
Table of contents
The book has four chapters, each divided into multiple pages:
- Development. Things to note before you start coding: API and libraries, bot configuration, some basic notions and tips.
- Messages. Features of messages: sending/editing/deleting, commands, markup, buttons.
- Chats. Managing user data & developing bots for different kinds of chats. Rules of PM, groups, and channels. Forums and supergroups.
- Interaction. Non-dialog Telegram features: join requests, deep links, payments, mini apps, etc.
Feel free to use navigation on the left or just hit the "Next page" button below.
Book updated
This site was previously called Telegram Bot Handbook and was more like a reference of Telegram features. Now, I've rewritten it so it became — well, a book.
The new platform is called Papercraft and also contains the docs for TGPy userbot and my new Folds framework.
About
Some pictures and videos are taken from the Telegram site. Most screenshots are made in Telegram web apps.
The sources are open on GitHub — corrections and improvements are welcome!