Update README.md

This commit is contained in:
Ryuk 2023-03-26 22:04:42 +05:30 committed by GitHub
parent 889f031561
commit 4735b08cda
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

122
README.md
View File

@ -1,30 +1,66 @@
### Light weight Social Media downloader bot. # Light weight Social Media downloader bot.
* Supported Platforms: * Supported Platforms:
* Videos: Instagram, Tiktok, Twitter, YouTube Shorts * Videos: Instagram, Tiktok, Twitter, YouTube Shorts
* Images: Instagram, Reddit * Images: Instagram, Reddit
* Gif : Reddit * Gif : Reddit
### Usage and Commands: ## Usage and Commands:
* Send supported links in any authorised chat/channel, bot will try to download and send the media. * Send supported links in any authorised chat/channel.
* Owner only commands: Bot will try to download and send the media.
* `.dl link` to download and send media in any chat.
* `.bot update` to refresh chat list without restarting bot.
* `.bot restart` to restart bot.
* `.bot ids` to get chat / channel / user IDs.
* `.bot join or leave` to join / leave chat using ID.
* `.del` reply to a message to delete.
* `.term` to run shell commands in bot. Example: `.term ls`
* These commands can be used anywhere and are not limited to authorised chats.
### Deploy: * Owner only commands:
* For android local deploy: * `.dl link` to download and send media in any chat.
* Download Latest [Termux](https://github.com/termux/termux-app/releases). * `.bot update` to refresh chat list without restarting bot.
```bash * `.bot restart` to restart bot.
# Update local packages after installing Termux. * `.bot ids` to get chat / channel / user IDs.
yes|apt update && yes|apt upgrade * `.bot join or leave` to join / leave chat using ID.
``` * `.del` reply to a message to delete.
* `.purge` to delete all messages between command and replied message.
* Config: These commands can be used anywhere.
* Developer Mode Commands:
* `.sh` to run shell commands.
Example: `.sh ls`
* `.exec` to run python code.
Example: `.exec print(1)`
These commands are dangerous and are disabled by default.
Add `DEV_MODE="yes"` in config to enable these.
## For android local deploy:
* Download Latest [Termux](https://github.com/termux/termux-app/releases).
```bash
# Change Default repository of termux.
termux-change-repo
# ( Select Single mirror then default )
# Update local packages.
yes|apt update && yes|apt upgrade
```
## Installation:
```bash
# Install required packages.
apt install -y python git python-pip ffmpeg
# Clone Repo.
git clone -q https://github.com/anonymousx97/social-dl
cd social-dl
# Install Pypi packages
pip install -U setuptools wheel
pip install -r req.txt
#Setup config.env
cp sample-config.env config.env
# Add your variables after running next command.
nano config.env
```
## Config:
* Get API_ID and API_HASH from https://my.telegram.org/auth . * Get API_ID and API_HASH from https://my.telegram.org/auth .
* Generate String Session by running this in Termux: * Generate String Session by running this in Termux:
```bash ```bash
@ -42,44 +78,34 @@
* Bot will automatically download links in those chats/channels. * Bot will automatically download links in those chats/channels.
* Now copy that message's link and you will get something like * Now copy that message's link and you will get something like
https://t.me/c/123456789/1 https://t.me/c/123456789/1
* So your values would be LOG=-100123456789, MESSAGE=1 * So your values would be LOG=-100123456789 MESSAGE=1
</details> </details>
* User : Your user id to control bot. * User : Your user id to control bot.
* Trigger : Trigger to access bot. * Trigger : Trigger to access bot.
* Run the following commands:
```bash
# Install required packages.
apt install -y python git python-pip ffmpeg
# Clone Repo. ## Start bot
git clone -q https://github.com/anonymousx97/social-dl ```bash
cd social-dl python socialbot.py
```
# Install Pypi packages * If everything is correct you will get <b><i>Started</i></b> stdout in terminal and in your channel.
pip install -U setuptools wheel
pip install -r req.txt
#Setup config.env ## Setup a quick run command for bot.
cp sample-config.env config.env ```bash
# Add your variables after running next command. echo "alias runbot='cd social-dl && python socialbot.py'" >> ~/.bashrc && bash
nano config.env ```
# Start bot Now you can run bot with `runbot`
python instabot.py
```
* If everything is correct you will get <b><i>Started</i></b> stdout in terminal and in your channel. ## Known limitations:
* If deployed on a VPS or any server Instragram might block access to some content.
After hitting Instagram's rate limit image download might not work because servers and vps usually have static IP and Instagram would block access.
* Deploying it locally would solve all of those issues because most of us are likely to have dynamic IP.
Bot is made lightweight with local deploys in mind. But battery life will take some hit anyway.
* Logging in with your Instagram which would solve the rate-limit issues is not added and won't be added because 2 of my accounts were suspended till manual verification for using scrapping bots like these.
## Contact
### Known limitations:
* If deployed on a VPS or any server Instragram might block access to some content.
After hitting Instagram's rate limit image download might not work because servers and vps usually have static IP and Instagram would block access.
* Deploying it locally would solve all of those issues because most of us are likely to have dynamic IP so Instagram will not be able to block access.
Bot is made lightweight with local deploys in mind. But battery life will take some hit anyway.
* Logging in with your Instagram which would solve the rate-limit issues is not added and won't be added because 2 of my accounts were suspended till manual verification for using scrapping bots like these with login.
### Contact
* For any questions related to deploy or issues contact me on * For any questions related to deploy or issues contact me on
[Telegram](https://t.me/anonymousx97) [Telegram](https://t.me/anonymousx97)