Skip to main content

Telethon Session

Project description

!alt text alt text

Django Telethon Session

A Telethon session storage implementation backed for Django ORM to use telethon in django projects.

Tested with:

  • Python 3.7+
  • Django 2.2+

Use the following command to install using pip:

pip install django-telethon-session

Usage example

Usage is very simple, just follow three simple steps below

Add Django-Telethon-Session to your installed apps

First add django telethon session to your installed apps in your django project settings:

INSTALLED_APPS = [
    ...,
    'django_telethon_session',
    ...
]

Migrate the database

Then run migrate command to create migrations in database.

python manage.py migrate

Use custom session

Use the session in django_telethon_session.sessions to initialize telegram client:

from django_telethon_session.sessions import DjangoSession
client = TelegramClient(DjangoSession())

Feel free to send pull requests or report issues!

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

django_telethon_session-0.9.tar.gz (8.0 kB view details)

Uploaded Source

Built Distribution

django_telethon_session-0.9-py3-none-any.whl (9.7 kB view details)

Uploaded Python 3

File details

Details for the file django_telethon_session-0.9.tar.gz.

File metadata

  • Download URL: django_telethon_session-0.9.tar.gz
  • Upload date:
  • Size: 8.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.32.1 CPython/3.6.8

File hashes

Hashes for django_telethon_session-0.9.tar.gz
Algorithm Hash digest
SHA256 fa074b7d1e478797dfc5640b3979c2bd36ef2ab3a506b3db47a618a6b766c569
MD5 007ed1f7da3237675eca53c0e7c5b2b4
BLAKE2b-256 1103b03dc29763fbfd26c2261845a62a6c24850cefea19401d8bffc31f807f02

See more details on using hashes here.

File details

Details for the file django_telethon_session-0.9-py3-none-any.whl.

File metadata

  • Download URL: django_telethon_session-0.9-py3-none-any.whl
  • Upload date:
  • Size: 9.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.32.1 CPython/3.6.8

File hashes

Hashes for django_telethon_session-0.9-py3-none-any.whl
Algorithm Hash digest
SHA256 1a6c2b4e8d1170ad384be1725f8110599aca1601701e3e08063dafdb374de176
MD5 fb91e55fff112d5478589c008ef1ec03
BLAKE2b-256 b73c89d3ad50528801d128ff7a72f51e0bcfb0506175aba1e8ffe5688ee5560d

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page