Skip to main content

Unsubscribe bot-like users from the Instagram account

Project description

Copyright (c) 2019 Viktor Krasheninnikov
https://github.com/VikGit/byebyebots-instagram.git

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
Description: # ByeByeBots for Instagram
Unsubscribe Instagram accounts who follows to more than _N_ (e.g. 1500) accounts, because they are not only don't see your posts, but also reduce your stats.

### Long story short
Say goodbye to all Internet-shops, follow4follow, and automatically subscribed to you Instagram accounts.

### Long story long
In 2018, Instagram has changed the algorithm and there’s no question about it, Instagram posts are no longer getting the amount of exposure they used to. Now, it’s estimated that only **10%** of your audience is actually seeing your posts.
This can be extremely frustrating for users who aren’t seeing their friends and family’s posts, businesses hoping to reach new customers, and even worse for influencers whose business model depends on their followers seeing their content.

Since the original shift from a chronological feed, we’ve known the Instagram algorithm is mainly based on engagement. This includes number of likes, comments, video views, saves, shared posts, DM’s and any other type of interactions a post gets. More info in the [original post](https://later.com/blog/how-instagram-algorithm-works/).

Imagine you have 150 followers, and average amount of likes on your photos is 50. Having that, Instagram thinks that your posts are interested to only 33% of your followers. Then imagine that 50 of your 150 followers are not real people - bussines accounts, Internet-shops etc. Those accounts are only interested in you seeing them, they are not insterested in your life or posts - we can easily unsubscribe them from us. Thus, you'll have 100 followers and your 50 likes becomes 50% instead of 33%! This will give the instagram a sign that your posts engage more people in activity, and it will more recommend your account for viewing to other people.

### Logic
The tool combines both BeautifulSoup response parsing and unofficial Instagram API developed by [LevPasha](https://github.com/LevPasha/Instagram-API-python). This hepls to reduce number of [429 HTTP responces](https://stackoverflow.com/questions/49606300/instagram-api-request-limit-max-200-only-2018-april) during processing.

To detect who is bot and who's not is pretty complicated nowaday, often bots put a few random likes or comments, to simulate users activity. We can suppose that if account is subscribed to 1500+ accounts - it's a bot-like. With new Instagram alghoritm, this account will see only the top-rated post, and if your are not super star, your posts most probably won't even shown to them.

The logic is straighforward:
1. Get accounts subscribed to you
2. Take away accounts to which you are subscribed
3. Unsubscribe from you accounts with more than _N_ subscriptions

### Installation
The tool requires Python 3.7.x. To install the package from PyPi run:
```
pip3 install byebyebots
```

Alternatively, you can install it from source:
```
git clone git@github.com:VikGit/byebyebots-instagram.git
cd byebyebots-instagram
python3 setup.py install
```

### Usage
```
usage: byebyebots [-h] [-u USER] [-p PASSWORD] [-l LIMIT]
[--email_sender_user EMAIL_SENDER_USER]
[--email_sender_password EMAIL_SENDER_PASSWORD]
[--email_recipient EMAIL_RECIPIENT] [--yes] [--dryrun]

Unsubscribe user with unrealistic number of followings

optional arguments:
-h, --help show this help message and exit
-u USER, --user USER Username fot the Instagram account
-p PASSWORD, --password PASSWORD
Password fot the Instagram account
-l LIMIT, --limit LIMIT
Number of followings which can be considered
unrealistic
--email_sender_user EMAIL_SENDER_USER
Email of service user to deliver notifications
--email_sender_password EMAIL_SENDER_PASSWORD
Password of service user to deliver notifications
--email_recipient EMAIL_RECIPIENT
Password of service user to deliver notifications
--yes Proceed without manul approving of unsubscribe action
--dryrun Replace unsubscribe action with a safe one, for
testing purposes
```

### Examples
Run in interactove dryrun mode to see how many potential bots are going to be unsubscribed. You will be asked to authenticate to Instagram account:
```
byebyebots --dryrun
```

Run in non-interactive mode. Remove `--dryrun` option to proceed with unsubscribing.
```
goodbyebots -u instagram_login -p instagram_password --yes --dryrun
```
In case you decide to run this tool by schedule, it supports email notifications. First, you'll need to create a mailbox for service user - from who you'll receive notifications. If you select Gmail, you'll probably need to [allow this script](https://support.google.com/accounts/answer/6010255) to use that mailbox.
When done, pass service-user credentials to the script and specify your own email - to which you'll send notifications. Remove `--dryrun` option to proceed with unsubscribing.
```
goodbyebots --email_sender_user sender_login@gmail.com --email_sender_pass sender_pass --email_recipient myemail@gmail.com -u instagram_login -p instagram_password --yes --dryrun
```

Keywords: instagram bots unsubscribe
Platform: UNKNOWN

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

byebyebots-0.0.6.tar.gz (8.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

byebyebots-0.0.6-py3-none-any.whl (9.9 kB view details)

Uploaded Python 3

File details

Details for the file byebyebots-0.0.6.tar.gz.

File metadata

  • Download URL: byebyebots-0.0.6.tar.gz
  • Upload date:
  • Size: 8.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.5.0.1 requests/2.11.1 setuptools/40.7.2 requests-toolbelt/0.9.1 tqdm/4.30.0 CPython/3.7.1

File hashes

Hashes for byebyebots-0.0.6.tar.gz
Algorithm Hash digest
SHA256 4cac42666a222446bd8758323331dc796c8759813eefa6fb0aa6e61fd1923b0c
MD5 a8d0a14b0bc84b096f3c52fa8ccb3718
BLAKE2b-256 9b0d5933c2a6ee8ed90633d673719034ea28659c91938e5e37f13ffcf658b9d1

See more details on using hashes here.

File details

Details for the file byebyebots-0.0.6-py3-none-any.whl.

File metadata

  • Download URL: byebyebots-0.0.6-py3-none-any.whl
  • Upload date:
  • Size: 9.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.5.0.1 requests/2.11.1 setuptools/40.7.2 requests-toolbelt/0.9.1 tqdm/4.30.0 CPython/3.7.1

File hashes

Hashes for byebyebots-0.0.6-py3-none-any.whl
Algorithm Hash digest
SHA256 68fb2bbd9233fb108cad5f4b8a40b2399a5a501fdce4d4ca5fd3724068c91cd3
MD5 626b33711b99e1420480e819a4b355a9
BLAKE2b-256 37ce6b55eca8cf6987240696d9ac3e7c1bae96b1d2ade5384cb8904d2869a983

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page