Skip to content

Requirements

Vijai Chander edited this page Jul 1, 2017 · 4 revisions

The bot requires and is dependent on few server configuration and libraries.

Requirements

  1. A 64bit linux server with shell access. Jailed shell wont work Note: Arm based servers cannot build app because android SDK's aapt fails on ARM processors eg. raspberry pi
  2. Python (2.7 preferred)
  3. Java JDK 1.8
  4. Android SDK. You may find a lot of guide on setting up standalone SDK from internet. Note: Gradle will handle installing missing platforms and tools for you. It is enough if you install SDK tools and setup the environment library
  5. Pip to install python libraries. Installation guide for pip

Dependencies/Libraries

Install the following dependencies and libraries before you can start using the bot

  1. Mysql
  2. Git
  3. Python telegram bot api
  4. Python Requests
  5. GitPython Library
  6. MySqldb

Mysql

The bot requires Mysql database for storing bot configuration for each chat. Install Mysql depending on your linux flavour and optionally webserver and phpmyadmin if you need a easy visual management for the database from your browser

Git

Install Git from your distro's package manager (apt, yum, etc.)

Python telegram bot api

This bot is built using an opensource telegram bot API python wrapper called python-telegram-bot which is the heart of this bot. Install it with:

# pip install python-telegram-bot

Python Requests

Python's reuests package is required for communicating with GitHub API

# pip install requests

GitPython library

GitPython libary for easy handling of repo clone, pull and init

# pip install GitPython

MySqldb

MySql db libary is required for all communication between the python and the database

# pip install MySQL-python

Read Next: Setting up the bot using botfather in telegram