aiopg storage for pyrogram
Project description
Pyrogram aiopg storage
Motivation
I need to work with multiple telegram session and keep all of them in a single PostgreSQL database. I use aiopg with SQLAlchemy hence I've written a wrapper for this stack. Maybe someone also requires such
Usage
import aiopg.sa
from pyrogram import Client
from pyrogram_aiopg_storage import PostgreSQLStorage
db_pool = await aiopg.sa.create_engine(...)
session = PostgreSQLStorage(db_pool=db_pool, user_id=..., phone=...)
pyrogram = Client(session_name=session)
await pyrogram.connect()
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Close
Hashes for pyrogram-aiopg-storage-0.2.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 00fb9ffaca3be822b64660b1dd722adaeeb3d2df09c7f71202f2ec48a4de1046 |
|
MD5 | 0bd476f1cb668a92aff33974e1c04dcc |
|
BLAKE2b-256 | dac24f0d2d3468c6e4e0432f09864ae16494896bf18b26e43a40d140af6012fd |