We have made you a wrapper you can't refuse https://python-telegram-bot.org/
Find a file
2015-07-08 09:55:06 -03:00
examples Adding RoboEd as example 2015-07-08 00:59:43 -03:00
telegram Adding sendChatAction, its tests and minor fixes 2015-07-08 09:55:06 -03:00
tests Adding sendChatAction, its tests and minor fixes 2015-07-08 09:55:06 -03:00
.gitignore Adding sendPhoto method 2015-07-07 18:46:32 -03:00
.travis.yml Adding tests 2015-07-07 17:28:53 -03:00
LICENSE Initial commit 2015-07-07 12:30:39 -03:00
Makefile Adding tests 2015-07-07 17:19:26 -03:00
README.rst Update README.rst 2015-07-07 21:13:58 -03:00
requirements.txt Adding Travis CI 2015-07-07 16:50:36 -03:00
telegram_test.py Adding tests 2015-07-07 17:19:26 -03:00

Python Telegram Bot

A Python wrapper around the Telegram Bot API.

By `Leandro Toledo <leandrotoledodesouza@gmail.com>`_

.. image:: https://travis-ci.org/leandrotoledo/python-telegram-bot.svg?branch=master
    :target: https://travis-ci.org/leandrotoledo/python-telegram-bot
    :alt: Travis CI Status

============
Introduction
============

This library provides a pure Python interface for the `Telegram Bot API <https://core.telegram.org/bots/api>`_. It works with Python versions from 2.6+. Python 3 support is under development.

================
Getting the code
================

The code is hosted at https://github.com/leandrotoledo/python-telegram-bot

Check out the latest development version anonymously with::

    $ git clone https://github.com/leandrotoledo/python-telegram-bot
    $ cd python-telegram-bot

Setup a virtual environment and install dependencies:

	$ make env

Activate the virtual environment created:

	$ source env/bin/activate

Run tests:

	$ make test

To see other options available, run:

	$ make help

=============
Documentation
=============

View the last release API documentation at: https://core.telegram.org/bots/api

---
API
---

The API is exposed via the ``telegram.Bot`` class::

    >>> import telegram
    >>> bot = telegram.Bot(token='token')

To see if your credentials are successful::

    >>> print bot.getMe()
    {"first_name": "Toledo's Palace Bot", "username": "ToledosPalaceBot"}

**NOTE**: much more than the small sample given here will print