-
Notifications
You must be signed in to change notification settings - Fork 1
/
config.py
112 lines (76 loc) · 3.88 KB
/
config.py
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
import os
from instaloader import Instaloader
class Config:
API_ID = int(os.environ.get("API_ID", ""))
API_HASH = os.environ.get("API_HASH", "")
BOT_TOKEN = os.environ.get("BOT_TOKEN", "")
USER = os.environ.get("INSTAGRAM_USERNAME", "")
OWNER = os.environ.get("OWNER_ID", "")
INSTA_SESSIONFILE_ID = os.environ.get("INSTA_SESSIONFILE_ID", None)
S = "0"
STATUS = set(int(x) for x in (S).split())
L=Instaloader()
HELP="""
You can Download almost anything From your Instagram Account.
<b>What Can Be Downloaded?:</b>
1. All posts of any Profile. (Both Public and Private,for private profiles you need to be a follower.)
2. All Posts from your feed.
3. Stories of any profile (Both Public and Private,for private profiles you need to be a follower.)
4. DP of any profile (No need to follow)
5. Followers and Followees List of any Profile.
6. List of followees who follows back the given username.
7. List of followees who are not following back the given username.
8. Stories of your Followees.
9. Tagged posts of any profile.
10. Your saved Posts.
11. IGTV videos.
12. Highlights from any profiles.
13. Any Public Post from Link(Post/Reels/IGTV)
<b>How to Download:</b>
Its Easy!!
You Need to login into your account by /login.
You have two Options:
1. From Username:
Just send any instagram username.
For Example:
<code>ZeusNetworks</code>
2. From URL:
You can also sent a post link to download the post or video.
For Example:
<code>https://www.instagram.com/p/CL4QbUiLRNW/?utm_medium=copy_link</code>
<b>Available Commands and Usage</b>
/start - Check wheather bot alive.
/restart - Restart the bot (If you messed up anything use /restart.)
/help - Shows this menu.
/login - Login into your account.
/logout - Logout of your account.
/account - Shows the details of logged in account.
/posts <username> - Download posts of any username. Use /posts to download own posts or <code> /posts <username> </code>for others.
Example : <code>/posts samantharuthprabhuoffl</code>
/igtv <username> - Download IGTV videos from given username. If no username given, downloads your IGTV.
/feed <number of posts to download> - Downloads posts from your feed.If no number specified all posts from feed will be downloaded.
Example: <code>/feed 10</code> to download latest 10 posts from feed.
/saved <number of posts to download> - Downloads your saved posts. If no number specified all saved posts will be downloaded.
Example: <code>/saved 10</code> to download latest 10 saved posts.
/followers <username> - Get a list of all followers of given username. If no username given, then your list will be retrieved.
Example: <code>/followers samantharuthprabhuoffl</code>
/followees <username> - Get a list of all followees of given username. If no username given, then your list will be retrieved.
/fans <username> - Get a list of of followees who follow back the given username. If no username given, your list will be retrieved.
/notfollowing <username> - Get a list of followees who is not following back the given username.
/tagged <username> - Downloads all posts in which given username is tagged. If nothing given your tagged posts will be downloaded.
/story <username> - Downloads all stories from given username. If nothing given your stories will be downloaded.
/stories - Downloads all the stories of all your followees.
/highlights <username> - Downloads highlights from given username, If nothing given your highlights will be downloaded.
"""
HOME_TEXT = """
<b>Helo, [{}](tg://user?id={})
This is a bot of [{}](www.instagram.com/{}) to manage his Instagram account.
I can only work for my master [{}](tg://user?id={}).
But you can Deploy the same bot for your use from the below source code.
Use /help to know What I can Do?</b>
"""
HOME_TEXT_OWNER = """
<b>Helo, [{}](tg://user?id={})
I am your assistant to manage your Instagram account.
Use /help to know what I can do for you.</b>
"""