# Telebot ## Docs - [Custom Middleware](https://mintlify.wiki/tucnak/telebot/advanced/custom-middleware.md): Write, compose, and attach your own middleware functions to control the handler pipeline. - [Custom Poller](https://mintlify.wiki/tucnak/telebot/advanced/custom-poller.md): Implement the Poller interface to control how your bot receives updates. - [Error Handling](https://mintlify.wiki/tucnak/telebot/advanced/error-handling.md): Understand how Telebot handles errors, configure global error callbacks, and write resilient production bots. - [Layout](https://mintlify.wiki/tucnak/telebot/advanced/layout.md): YAML-driven bot configuration, keyboards, and i18n with the layout subpackage. - [Bot](https://mintlify.wiki/tucnak/telebot/api/bot.md): Complete API reference for the Bot type in Telebot v4. - [Context](https://mintlify.wiki/tucnak/telebot/api/context.md): Reference for the Context interface, HandlerFunc type, and NewContext constructor. - [Editable](https://mintlify.wiki/tucnak/telebot/api/editable.md): The Editable interface and StoredMessage type for editing and deleting messages. - [Events](https://mintlify.wiki/tucnak/telebot/api/endpoints.md): All event endpoint constants and chat action constants for gopkg.in/telebot.v4. - [File](https://mintlify.wiki/tucnak/telebot/api/file.md): The File type and constructors for local, URL-based, and reader-based files. - [Markup & Keyboards](https://mintlify.wiki/tucnak/telebot/api/markup.md): Reference for ReplyMarkup, Btn, inline and reply keyboard types, and button constructors. - [Message](https://mintlify.wiki/tucnak/telebot/api/message.md): Reference for the Message struct, MessageEntity, and related types. - [Middleware](https://mintlify.wiki/tucnak/telebot/api/middleware.md): Built-in middleware functions from the gopkg.in/telebot.v4/middleware subpackage. - [Sendable](https://mintlify.wiki/tucnak/telebot/api/sendable.md): The Sendable interface, Recipient interface, SendOptions, and all built-in sendable media types. - [Settings](https://mintlify.wiki/tucnak/telebot/api/settings.md): Configuration struct passed to NewBot to create a Bot instance. - [Update](https://mintlify.wiki/tucnak/telebot/api/update.md): Reference for the Update struct, all update fields, and the event endpoint constants. - [Bot](https://mintlify.wiki/tucnak/telebot/concepts/bot.md): The Bot struct, NewBot constructor, Settings configuration, and core lifecycle methods. - [Context](https://mintlify.wiki/tucnak/telebot/concepts/context.md): The Context interface — wrapping an incoming Update with helpers for reading data and sending responses. - [Handlers](https://mintlify.wiki/tucnak/telebot/concepts/handlers.md): Registering handlers with b.Handle(), supported endpoint types, and the full list of built-in event constants. - [Middleware](https://mintlify.wiki/tucnak/telebot/concepts/middleware.md): Global, group, and per-handler middleware with the MiddlewareFunc type, b.Use(), Group.Use(), and built-in middleware. - [Poller](https://mintlify.wiki/tucnak/telebot/concepts/poller.md): The Poller interface, LongPoller, MiddlewarePoller, and ProcessUpdate for webhook or manual update injection. - [Commands](https://mintlify.wiki/tucnak/telebot/guides/commands.md): Handle bot commands, deep links, arguments, and register commands with BotFather. - [Editable Messages](https://mintlify.wiki/tucnak/telebot/guides/editable.md): Edit, delete, and pin messages using the Editable interface and StoredMessage. - [Files](https://mintlify.wiki/tucnak/telebot/guides/files.md): Upload files from disk, URL, or io.Reader, cache file IDs, and download files from Telegram. - [Inline Mode](https://mintlify.wiki/tucnak/telebot/guides/inline-mode.md): Handle inline queries, build result types, and respond with QueryResponse. - [Keyboards](https://mintlify.wiki/tucnak/telebot/guides/keyboards.md): Build reply keyboards, inline keyboards, and handle button callbacks in Telebot. - [Payments](https://mintlify.wiki/tucnak/telebot/guides/payments.md): Accept payments, handle shipping and pre-checkout queries, and process Telegram Stars. - [Sendable](https://mintlify.wiki/tucnak/telebot/guides/sendable.md): Understand the Sendable interface, built-in media types, SendOptions, parse modes, and the Album type. - [Webhooks](https://mintlify.wiki/tucnak/telebot/guides/webhooks.md): Replace long polling with a webhook server, configure TLS, and use ProcessUpdate for custom routing. - [Introduction](https://mintlify.wiki/tucnak/telebot/introduction.md): Telebot is an ergonomic Go framework for building Telegram bots — not a 1:1 API wrapper, but a thoughtfully designed toolkit focused on clean, concise code. - [Quickstart](https://mintlify.wiki/tucnak/telebot/quickstart.md): Build and run your first Telegram bot with Telebot in under five minutes.