forked from MN-BOTS/Tamil-Blasters-Rss-Bot
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathconfig.py
More file actions
42 lines (30 loc) · 946 Bytes
/
config.py
File metadata and controls
42 lines (30 loc) · 946 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
from dotenv import load_dotenv
load_dotenv() # This will load the variables from .env into os.environ
import os
class BOT:
"""
TOKEN: Bot token generated from @BotFather
"""
TOKEN = os.environ.get("TOKEN", "")
class API:
"""
HASH: Telegram API hash from https://my.telegram.org
ID = Telegram API ID from https://my.telegram.org
"""
HASH = os.environ.get("API_HASH", "")
ID = int(os.environ.get("API_ID", 0))
class OWNER:
"""
ID: Owner's user id, get it from @userinfobot
"""
ID = int(os.environ.get("OWNER", 0))
class CHANNEL:
"""
ID: Telegram Channel ID where the bot will post automatically
"""
ID = int(os.environ.get("CHANNEL_ID", 0))
class WEB:
"""
PORT: Specific port no. on which you want to run your bot, DON'T TOUCH IT IF YOU DON'T KNOW WHAT IS IT.
"""
PORT = int(os.environ.get("PORT", 8000))