This commit is contained in:
2025-07-28 17:44:23 +03:00
commit ddb8de2c2f
4 changed files with 24 additions and 0 deletions

4
.gitignore vendored Normal file
View File

@@ -0,0 +1,4 @@
.env
*.session
__pycache__/
venv/

8
config.py Normal file
View File

@@ -0,0 +1,8 @@
import os
from dotenv import load_dotenv
load_dotenv()
APP_ID = os.environ.get("APP_ID")
APP_HASH = os.environ.get("APP_HASH")

0
controllers.py Normal file
View File

12
main.py Normal file
View File

@@ -0,0 +1,12 @@
import asyncio
from pyrogram import Client
from config import APP_HASH, APP_ID
async def main():
async with Client("my_account", APP_ID, APP_HASH) as app:
await app.send_message("me", "Hello, world2!")
asyncio.run(main())