Welcome to Pyrogram

Telegram MTProto API Framework for Python
Source Code Releases Community

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.

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

API Reference

Meta

Last updated on Jun 10, 2019