Welcome to Pyrogram =================== .. raw:: html
Pyrogram Logo

Telegram MTProto API Framework for Python
Source Code Releases Community

.. code-block:: python from pyrogram import Client, Filters app = Client("my_account") @app.on_message(Filters.private) def hello(client, message): message.reply("Hello {}".format(message.from_user.first_name)) app.run() **Pyrogram** is an elegant, easy-to-use Telegram_ client library and framework written from the ground up in Python and C. It enables you to easily create custom apps for both user and bot identities (bot API alternative) via the `MTProto API`_. .. _Telegram: https://telegram.org .. _MTProto API: topics/mtproto-vs-botapi#what-is-the-mtproto-api How the Documentation is Organized ---------------------------------- Contents are organized into self-contained topics and can be all accessed from the sidebar, or by following them in order using the Next button at the end of each page. Here below you can, instead, find a list of the most relevant pages for a quick access. First Steps ----------- .. hlist:: :columns: 2 - `Quick Start`_: Overview to get you started quickly. - `Calling Methods`_: How to call Pyrogram's methods. - `Handling Updates`_: How to handle Telegram updates. - `Error Handling`_: How to handle API errors correctly. .. _Quick Start: intro/quickstart .. _Calling Methods: start/invoking .. _Handling Updates: start/updates .. _Error Handling: start/errors API Reference ------------- .. hlist:: :columns: 2 - `Pyrogram Client`_: Reference details about the Client class. - `Available Methods`_: List of available high-level methods. - `Available Types`_: List of available high-level types. - `Bound Methods`_: List of convenient bound methods. .. _Pyrogram Client: ./api/client .. _Available Methods: api/methods .. _Available Types: api/types .. _Bound Methods: api/bound-methods Meta ---- .. hlist:: :columns: 2 - `Pyrogram FAQ`_: Answers to common Pyrogram questions. - `Pyrogram Glossary`_: List of words with brief explanations. - `Release Notes`_: Release notes for Pyrogram releases. - `Powered by Pyrogram`_: Collection of Pyrogram Projects. - `Support Pyrogram`_: Ways to show your appreciation. .. _Pyrogram FAQ: faq .. _Pyrogram Glossary: glossary .. _Release Notes: releases .. _Powered by Pyrogram: powered-by .. _Support Pyrogram: support-pyrogram .. toctree:: :hidden: :caption: Introduction intro/quickstart intro/install intro/setup .. toctree:: :hidden: :caption: Getting Started start/auth start/invoking start/updates start/errors .. toctree:: :hidden: :caption: API Reference api/client api/methods api/types api/bound-methods api/handlers api/decorators api/filters api/errors .. toctree:: :hidden: :caption: Topic Guides topics/filters topics/more-on-updates topics/config-file topics/smart-plugins topics/auto-auth topics/session-settings topics/tgcrypto topics/text-formatting topics/serialize topics/proxy topics/bots-interaction topics/mtproto-vs-botapi topics/test-servers topics/advanced-usage topics/voice-calls .. toctree:: :hidden: :caption: Meta faq glossary releases powered-by support-pyrogram .. toctree:: :hidden: :caption: Telegram API telegram/functions/index telegram/types/index