Go to file
Dan 61e9762977 Merge branch 'develop' into asyncio
# Conflicts:
#	pyrogram/client/client.py
2019-01-25 10:22:56 +01:00
compiler Update media caption maximum length 2019-01-13 06:52:25 +01:00
docs Update documentation index page 2019-01-25 09:43:56 +01:00
examples Update examples 2019-01-07 10:34:38 +01:00
pyrogram Merge branch 'develop' into asyncio 2019-01-25 10:22:56 +01:00
.gitignore Ignore user's personal files 2017-12-05 12:48:55 +01:00
COPYING Initial commit 2017-12-05 12:09:33 +01:00
COPYING.lesser Initial commit 2017-12-05 12:09:33 +01:00
MANIFEST.in Remove requirements_extras.txt from MANIFEST.in 2018-06-24 14:26:52 +02:00
NOTICE Update copyright year 2019-01-01 12:36:16 +01:00
README.rst Update README.rst 2019-01-24 20:00:59 +01:00
readthedocs.yml Tell readthedocs to use Python 3.6 because 3.5.2 is bugged 2019-01-02 18:20:51 +01:00
requirements.txt Add async_generator requirement 2019-01-07 09:34:08 +01:00
setup.py Update copyright year 2019-01-01 12:36:16 +01:00

|header|

Pyrogram
========

    `A fully asynchronous variant is also available! <https://github.com/pyrogram/pyrogram/issues/181>`_

.. 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 build custom Telegram applications that interact with the MTProto API as both user and bot.

Features
--------

-   **Easy**: You can install Pyrogram with pip and start building your app right away.
-   **Elegant**: Low-level details are abstracted and re-presented in a much nicer and easier way.
-   **Fast**: Crypto parts are boosted up by TgCrypto_, a high-performance library written in pure C.
-   **Documented**: Pyrogram API methods, types and public interfaces are well documented.
-   **Type-hinted**: Exposed Pyrogram types and method parameters are all type-hinted.
-   **Updated**, to the latest Telegram API version, currently Layer 91 on top of MTProto 2.0.
-   **Pluggable**: The Smart Plugin system allows to write components with minimal boilerplate code.
-   **Comprehensive**: Execute any advanced action an official client is able to do, and even more.

Requirements
------------

-   Python 3.4 or higher.
-   A `Telegram API key`_.

Installing
----------

.. code:: shell

    pip3 install pyrogram

Getting Started
---------------

-   The Docs contain lots of resources to help you getting started with Pyrogram: https://docs.pyrogram.ml.
-   Reading `Examples in this repository`_ is also a good way for learning how Pyrogram works.
-   Seeking extra help? Don't be shy, come join and ask our Community_!
-   For other requests you can send an Email_ or a Message_.

Contributing
------------

Pyrogram is brand new, and **you are welcome to try it and help make it even better** by either submitting pull
requests or reporting issues/bugs as well as suggesting best practices, ideas, enhancements on both code
and documentation. Any help is appreciated!

Copyright & License
-------------------

-   Copyright (C) 2017-2019 Dan Tès <https://github.com/delivrance>
-   Licensed under the terms of the `GNU Lesser General Public License v3 or later (LGPLv3+)`_

.. _`Telegram`: https://telegram.org/
.. _`Telegram API key`: https://docs.pyrogram.ml/start/ProjectSetup#api-keys
.. _`Community`: https://t.me/PyrogramChat
.. _`Examples in this repository`: https://github.com/pyrogram/pyrogram/tree/master/examples
.. _`GitHub`: https://github.com/pyrogram/pyrogram/issues
.. _`Email`: admin@pyrogram.ml
.. _`Message`: https://t.me/haskell
.. _TgCrypto: https://github.com/pyrogram/tgcrypto
.. _`GNU Lesser General Public License v3 or later (LGPLv3+)`: COPYING.lesser

.. |header| raw:: html

    <h1 align="center">
        <a href="https://github.com/pyrogram/pyrogram">
            <div><img src="https://raw.githubusercontent.com/pyrogram/logos/master/logos/pyrogram_logo2.png" alt="Pyrogram Logo"></div>
        </a>
    </h1>

    <p align="center">
        <b>Telegram MTProto API Framework for Python</b>

        <br>
        <a href="https://docs.pyrogram.ml">
            Documentation
        </a>
        •
        <a href="https://github.com/pyrogram/pyrogram/releases">
            Changelog
        </a>
        •
        <a href="https://t.me/PyrogramChat">
            Community
        </a>
        <br>
        <a href="compiler/api/source/main_api.tl">
            <img src="https://img.shields.io/badge/schema-layer%2091-eda738.svg?longCache=true&colorA=262b30"
                alt="Schema Layer">
        </a>
        <a href="https://github.com/pyrogram/tgcrypto">
            <img src="https://img.shields.io/badge/tgcrypto-v1.1.1-eda738.svg?longCache=true&colorA=262b30"
                alt="TgCrypto Version">
        </a>
    </p>

.. |logo| image:: https://raw.githubusercontent.com/pyrogram/logos/master/logos/pyrogram_logo2.png
    :target: https://pyrogram.ml
    :alt: Pyrogram

.. |description| replace:: **Telegram MTProto API Framework for Python**

.. |schema| image:: "https://img.shields.io/badge/schema-layer%2091-eda738.svg?longCache=true&colorA=262b30"
    :target: compiler/api/source/main_api.tl
    :alt: Schema Layer

.. |tgcrypto| image:: "https://img.shields.io/badge/tgcrypto-v1.1.1-eda738.svg?longCache=true&colorA=262b30"
    :target: https://github.com/pyrogram/tgcrypto
    :alt: TgCrypto Version