Skip to content

pandafy/djelegram

Repository files navigation

Djelegram

Yet Another Client for Telegram (YACT)

Djelegram is a web client for Telegram developed using Django on top of robust Telegram APIs.

Installation

First thing first, download the archive containing Djelegram's code.To get started with Djelegram you will need to get API_ID and API_HASH from Telegram. They have beautifully mentioned all steps one needs to follow to get required two in their documentation.

After acquiring your API_ID and API_HASH you can follow these steps to quickly setup Djelegram on your machine.

Create a file named local_settings.py in djelegram directory. Add following to that file

API_ID = <you-api-id>
API_HASH = <yur-api-hash>

We recommend using docker-compose to quickly spin up Djelegram for development. You can install Docker from following instructions in Docker Documentation, and similarly you can install docker-compose from it's documentation.

Running Using Docker
  1. Open up a terminal or power-shell, and change the working directory to the project directory, i.e. djelegram_webclient.
  2. Run following command on terminal
    docker-compose up 

For the first run, Docker will download the base image for python from Dockerhub and build an image for our project. The first run could take some time depending upon internet connectivity. Subsequent builds will be a lot faster since Docker caches intermediate steps.

After building our image, the following message will appear on the terminal depeicting that our website is available to surf on localhost.

app_1 | Django version 3.0.5, using settings 'djelegram.settings'
app_1 | Starting development server at http://0.0.0.0:8000/
app_1 | Quit the server **with** CONTROL-C.

Visit http://127.0.0.1:8000 to checkout Djelegram, voila you can now chat on Djelegram.

Pythonic Installation

If you don't want to install Docker just for running this project, you can still install Djelegram like any other Django project. These commands will help you set up Djelegram on you machine.

  1. Install Python, you find instructions at Python's documentation.
  2. Open up a terminal or power-shell and change it's working directory to the project directory, i.e. djelegram_webclient.
  3. Create a Python virtual environment
    python3 -m venv venv/
  1. Activate this virtual environment
   source venv/bin/action #Linux
   <venv>\Scripts\Activate.ps1 #PowerShell 
  1. Install project dependencies with pip
    pip install -r requirements.txt 

Note: This step might fail due to dependencies error, you will require to install corresponding C library according to your operating system, This is why we suggest using Docker instead. If you are on Linux, you might need the gcc package. (not exhaustive)

  1. Start Django development server using
    python manage.py runserver

You should expect an output like this

Django version 3.0.5, using settings 'djelegram.settings'
Starting development server at http://127.0.0.1:8000/
Quit the server **with** CONTROL-C. 

Visit http://127.0.0.1:8000 to checkout Djelegram, voila you can now chat on Djelegram.

Using Djelegram

Using Djelegram is fairly straightforward, you can read about Djelegream at the home page. You can login into your Telegram account using you registered mobile number and authentication code, which you will receive on your Telegram account or SMS. After a successful login, you will be redirected to a chat webpage. Logging out is as simple as pressing the logout button on navigation bar,

Important Links

About

YACT - Yet Another Client for Telegram

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published