A Telegram mirror bot which can be deployed using Heroku.

Overview

Slam

Slam Mirror Bot

This is a telegram bot writen in python for mirroring files on the internet to our beloved Google Drive.

Getting Google OAuth API credential file

  • Visit the Google Cloud Console
  • Go to the OAuth Consent tab, fill it, and save.
  • Go to the Credentials tab and click Create Credentials -> OAuth Client ID
  • Choose Desktop and Create.
  • Use the download button to download your credentials.
  • Clone this repo:
git clone https://github.com/breakdowns/slam-mirrorbot mirrorbot/
cd mirrorbot
  • Move that file to the root of mirrorbot, and rename it to credentials.json
  • Visit Google API page
  • Search for Drive and enable it if it is disabled
  • Finally, run the script to generate token file (token.pickle) for Google Drive:
pip install google-api-python-client google-auth-httplib2 google-auth-oauthlib
python3 generate_drive_token.py

Deployment

Fork this repo, than upload credentials.json and token.pickle to your forks

Deploy to Heroku

Features supported:

  • Mirroring direct download links to Google Drive
  • Mirroring Mega.nz links to Google Drive (In development stage)
  • Mirroring Uptobox.com links to Google Drive (Uptobox account must be premium)
  • Copy files from someone's drive to your drive (Using Autorclone)
  • Download/upload progress
  • Download/upload speeds and ETAs
  • Docker support
  • Uploading To Team Drives.
  • Index Link support
  • Service account support
  • Mirror all youtube-dl supported links
  • Mirror telegram files
  • Delete files from drive
  • Add stickers to your pack
  • Nyaa.si and Sukebei Torrent search
  • Shell and Executor
  • Index Link support
  • Shortener support
  • Custom Buttons
  • Speedtest with picture results
  • Extract these filetypes and uploads to google drive

ZIP, RAR, TAR, 7z, ISO, WIM, CAB, GZIP, BZIP2, APM, ARJ, CHM, CPIO, CramFS, DEB, DMG, FAT, HFS, LZH, LZMA, LZMA2, MBR, MSI, MSLZ, NSIS, NTFS, RPM, SquashFS, UDF, VHD, XAR, Z.

Using service accounts for uploading to avoid user rate limit

For Service Account to work, you must set USE_SERVICE_ACCOUNTS="True" in config file or environment variables Many thanks to AutoRClone for the scripts NOTE: Using service accounts is only recommended while uploading to a team drive.

Generate service accounts What is service account

Let us create only the service accounts that we need. Warning: abuse of this feature is not the aim of this project and we do NOT recommend that you make a lot of projects, just one project and 100 sa allow you plenty of use, its also possible that over abuse might get your projects banned by google.

Note: 1 service account can copy around 750gb a day, 1 project can make 100 service accounts so that's 75tb a day, for most users this should easily suffice. 

python3 gen_sa_accounts.py --quick-setup 1 --new-only

A folder named accounts will be created which will contain keys for the service accounts

NOTE: If you have created SAs in past from this script, you can also just re download the keys by running:

python3 gen_sa_accounts.py --download-keys project_id

Add all the service accounts to the Team Drive

  • Run:
python3 add_to_team_drive.py -d SharedTeamDriveSrcID

Youtube-dl authentication using .netrc file

For using your premium accounts in youtube-dl, edit the .netrc file according to following format:

machine host login username password my_youtube_password

where host is the name of extractor (eg. youtube, twitch). Multiple accounts of different hosts can be added each separated by a new line

Credits

Thanks to:

and many more people who aren't mentioned here, but may be found in Contributors.

Comments
  • bot: Change deploy method

    bot: Change deploy method

    • change deploy method to heroku container registry
    • for now, we no need HEROKU_EMAIL in github secrets
    • update credits

    Signed-off-by: GudMeong [email protected]

    opened by gudmeong 5
  • Undefined name: pe --> pw

    Undefined name: pe --> pw

    $ flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics

    ./slam-mirrorbot/bot/helper/mirror_utils/download_utils/direct_link_generator.py:351:39: F821 undefined name 'pe'
            req = requests.post(url, data=pe)
                                          ^
    1     F821 undefined name 'pe'
    1
    
    opened by cclauss 2
  • added proxy support

    added proxy support

    added proxy support for watch command (for personal use,might have to modify to make it usable)(im a noob) , you have to use /watch [youtube-dl supported link] [quality] |[CustomName] | [http://username:[email protected]:port/]

    other usable methods ex - http(s)://PROXY_URL:PROXY_PORT socks5://127.0.0.1:1080

    opened by eXtizi 2
  • Sourcery refactored master branch

    Sourcery refactored master branch

    Branch master refactored by Sourcery.

    If you're happy with these changes, merge this Pull Request using the Squash and merge strategy.

    See our documentation here.

    Run Sourcery locally

    Reduce the feedback loop during development by using the Sourcery editor plugin:

    Review changes via command line

    To manually merge these changes, make sure you're on the master branch, then run:

    git fetch origin sourcery/master
    git merge --ff-only FETCH_HEAD
    git reset HEAD^
    

    Help us improve this pull request!

    opened by sourcery-ai[bot] 1
  • Sourcery refactored master branch

    Sourcery refactored master branch

    Branch master refactored by Sourcery.

    If you're happy with these changes, merge this Pull Request using the Squash and merge strategy.

    See our documentation here.

    Run Sourcery locally

    Reduce the feedback loop during development by using the Sourcery editor plugin:

    Review changes via command line

    To manually merge these changes, make sure you're on the master branch, then run:

    git fetch origin sourcery/master
    git merge --ff-only FETCH_HEAD
    git reset HEAD^
    

    Help us improve this pull request!

    opened by sourcery-ai[bot] 1
Releases(v5.2)
  • v5.2(Sep 22, 2021)

  • v5.1(Sep 4, 2021)

  • v5.0(Aug 7, 2021)

  • v4.8.7(Jun 19, 2021)

    • Tar/Unzip G-Drive Links Support
    • Fix overall download speed for Mega and others
    • Add shell custom command
    • Add Set Variable, Delete Variable, and Bot Info Menu (Only for Heroku)
    • Add Updater for update Bot from upstream
    • Torrent Search: Add 1337x, piratebay, tgx, yts, eztv, torlock, rarbg support

    NOTE: Please Redeploy

    Source code(tar.gz)
    Source code(zip)
  • v4.8.6(Jun 14, 2021)

    • direct_link_generator: add letsupload.io, feurl.com, pixeldrain.com support
    • Block Drive & YouTube link using /mirror command
    • Remove anime & stickers module, because not related in mirror bot
    • Some update in aria.sh
    • Tidying Up

    NOTE: Refroks & Redeploy Recommended.

    Source code(tar.gz)
    Source code(zip)
  • v4.8.4(Jun 8, 2021)

    • Added support for tar.xz
    • Fix Mega auto canceling if deleted file
    • Direct link generator: Addad Naniplay.com, Naniplay.nanime.in, Naniplay.nanime.biz, Sbembed.com, Streamsb.net support
    Source code(tar.gz)
    Source code(zip)
  • v4.8.3(Jun 5, 2021)

  • v4.8.2(Jun 4, 2021)

    • direct link generator: Added Hxfile, Anonfiles, Fembed (femax20 & layarkacaxxi), Onedrive (Only works for file not folder for now, thanks to UsergeTeam) support
    • aria: Added more tracker
    Source code(tar.gz)
    Source code(zip)
  • v4.8.1(May 31, 2021)

  • v4.8.0(May 30, 2021)

  • v4.7.6(May 18, 2021)

  • v4.7.5(May 17, 2021)

    • Added sudo using database NOTE: redeploy recommended to generating database, or you can go to your herokuapp > resources > add-ons > then serach Heroku Postgres > hit Submit Order Form. Done Database will automatic come in config vars
    • mirror: Fix for uploading telegram file_name of None type
    • gdriveTools: Fix infinite loop when hitting rate limits
    Source code(tar.gz)
    Source code(zip)
  • v4.6.9(Apr 26, 2021)

  • v4.6.6(Apr 18, 2021)

    • direct_links: Added racaty.net support
    • Update support group link
    • Fix Index URL encode problem
    • Added support for password protected index links by magneto
    Source code(tar.gz)
    Source code(zip)
  • v4.6.3(Apr 12, 2021)

  • v4.6.2(Apr 8, 2021)

  • v4.6(Mar 29, 2021)

  • v4.4(Mar 22, 2021)

  • v4.2(Mar 17, 2021)

  • v3.8(Mar 9, 2021)

  • v3.7(Mar 6, 2021)

  • v3.0(Mar 3, 2021)

    • Added auto generate Telegraph Token
    • Added Inline Buttons
    • Update /stats command
    • /list module will post search result on telegra.ph
    • Speedtest
    Source code(tar.gz)
    Source code(zip)
Find rare users in discord servers

BadgeScraper Find rare users in discord servers How to use Replace the guild_id, server_id and token by the values you wanna use If you never used dis

20 Dec 09, 2022
An async-ready Python wrapper around FerrisChat's API.

FerrisWheel An async-ready Python wrapper around FerrisChat's API. Installation Instructions Linux: $ python3.9 -m pip install -U ferriswheel Python 3

FerrisChat 8 Feb 08, 2022
Yes, it's true :two_hearts: This repository has 316 stars.

Yes, it's true! Inspired by a similar repository from @RealPeha, but implemented using a webhook on AWS Lambda and API Gateway, so it's serverless! If

510 Dec 28, 2022
E0 AI Bot is based on the message, it prints the answer with the highest probability using probability from the database.

E0 AI Chat Bot Based on the message, it prints the answer with the highest probability using probability from the database. Install on linux (Arch,Deb

Error 27 Dec 03, 2022
Script for polybar to display and control media(not only Spotify) using DBus.

polybar-now-playing Script for polybar to display and control media(not only Spotify) using DBus Python script to display and control current playing

Dope Wizard 48 Dec 31, 2022
Python script to extract all Humble Bundle keys and redeem them on Steam automagically.

humble-steam-key-redeemer Python script to extract all Humble keys and redeem them on Steam automagically. This is primarily designed to be a set-it-a

74 Jan 08, 2023
This is a simple Python bot to identify sentiments in tweets

Twitter-Sentiment 👋 Hi There! 📱 This is a simple Python bot to identify sentiments in tweets 👨‍💻 This project was made for study, and pratice. You

Guilherme Silva 1 Oct 28, 2021
Telegram bot to host python bots

Host-Bot Setup the api Upload the flask api on your host #its not important to do #i used it just for simple captcha system + save ids on your host!

Plugin 15 Feb 11, 2022
A jokes api python module

A jokes api python module

Fayas Noushad 3 Nov 28, 2021
A fully decentralized protocol for private transactions FAST snipe BUY token on LUANCH after add LIQUIDITY

TORNADO CASH Pancakeswap Sniper BOT 2022-V1 (MAC WINDOWS ANDROID LINUX) ⭐️ A fully decentralized protocol for private and safe transactions ⭐️ AUTO DO

Crypto Trader 2 Jan 06, 2022
A Python wrapper for the DeepL API

deepl.py A Python wrapper for the DeepL API installing Install and update using pip: pip install deepl.py A simple example. # Sync Sample import deep

grarich 18 Dec 12, 2022
A very tiny python api for the stock exchange tradegate.de

pytradegate A very tiny python api for the stock exchange tradegate.de The api provides the recent ask/bid data and all other data as found on the det

dunderstr aka seimen 7 Aug 24, 2022
this is a telegram torrent bot

owner of this repo :- AYUSH contact me :- AYUSH Slam Mirror Bot This is a telegram bot writen in python for mirroring files on the internet to our bel

AYUSH 237 Dec 16, 2021
The python SDK for Eto, the AI focused data platform for teams bringing AI models to production

Eto Labs Python SDK This is the python SDK for Eto, the AI focused data platform for teams bringing AI models to production. The python SDK makes it e

5 Apr 21, 2022
Elemeno.ai standard development kit in Python

Overview A set of glue code and utilities to make using elemeno AI platform a smooth experience Free software: Apache Software License 2.0 Installatio

Elemeno AI 3 Dec 14, 2022
C Y B Ξ R UserBot is a project that simplifies the use of Telegram. All rights reserved.

C Y B Ξ R USΞRBOT 🇦🇿 C Y B Ξ R UserBot is a project that simplifies the use of Telegram. All rights reserved. Automatic Setup Android: open Termux p

C Y B Ξ R 0 Sep 20, 2022
Discord Voice Channel Automatic Online

Discord-Selfbot-voice Features: Discord Voice Channel Automatic Online FAQ Q: How can I obtain my token? A: 1. How to obtain your token in android 2.

Pranav Ajay 3 Oct 31, 2022
Boilerplate template for the discord-py-interactions library

discord-py-interactions_boilerplate Boilerplate template for the discord-py-interactions library Currently, this boilerplate supports discord-py-inter

Ventus 7 Dec 03, 2022
Nflmetrics - Johns Hopkins Spring 2022 Sports Analytics research project about NFL Draft Metrics

nflmetrics GitHub repo for Johns Hopkins Spring 2022 Sports Analytics research p

Anish Kulkarni 4 Feb 24, 2022
Automatically deploy freqtrade to a remote Docker host and auto update strategies.

Freqtrade Automatically deploy freqtrade to a remote Docker host and auto update strategies. I've been using it to automatically deploy to vultr, but

p-zombie 109 Jan 07, 2023