Skip to main content

Instagram Story downloader

Project description

Instagram Story Downloader

Python Package CI Python Versions The Uncompromising Code Formatter Monthly Downloads License: MIT

Buy Me A Coffee

Installation

Install using pip

$ pip install -U instagram-story

Usage

usage: instagram-story [-h] [-f CONFIG_LOCATION] [-d DOWNLOAD_ONLY]

Instagram Story downloader

optional arguments:
  -h, --help            show this help message and exit
  -f CONFIG_LOCATION, --config-location CONFIG_LOCATION
                        Path for loading and storing config key file.
  -d DOWNLOAD_ONLY, --download-only DOWNLOAD_ONLY
                        Download stories for user id listed in the file.

Options

On first run, a config file will be generated. The script will ask for required information such as your username, user id, cookies etc., cookies can be obtained from the developer tools of Google Chrome or Firefox.

For exporting cookies you can install the EditThisCooki extension and follow this guide for exporting cookies in comma-separated format. (For this you need to set Extension->Settings->Options->Choose the preferred export format for cookies->Semicolon separated name=value pairs).

csrftoken=value;ds_user_id=value;ig_did=value;ig_nrcb=value;mid=value;rur=value;sessionid=value;shbid=value;shbts=value;

Value of ds_user_id is your instagram user id.

To periodically obtain stories from followed users, run this script at least every 24 hours. A Windows Scheduled Task or a Unix cron job is recommended to perform this automatically.

Download only selected users

There is a options to download only user ids listed in include.txt text file. If the option -d or --download-only and points to a valid text file with list of user ids then the story will be downloaded for only those id listed in this file.

Example

E:\>instagram-story
Enter your instagram username: instagrm-test
Enter your instagram user id: 501517166
Enter your instagram cookie: ig_did=52FED55D-4C3E-408F-997C-803D6385D39A; mid=c1e513b4990f_94603666c341ef61; csrftoken=AR6+5nk3N0S3xkTrRc9Pfg; ds_user_id=501517166; sessionid=501517166%3A94603666c341ef61%2a1; shbid=2051; shbts=1619505936.8752491; rur=ARN
Enter directory for saving media files (defaults to directory): B:\story
Config created at: C:\msys64\home\me\.instagram-story\config.json
Run again to download stories

Legal Disclaimer

This project is in no way affiliated with, authorized, maintained, sponsored or endorsed by Instagram or any of its affiliates or subsidiaries. This is an independent project that utilizes Instagram's unofficial API. Use at your own risk.

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

instagram-story-1.3.2.tar.gz (11.8 kB view hashes)

Uploaded Source

Built Distribution

instagram_story-1.3.2-py3-none-any.whl (11.5 kB view hashes)

Uploaded Python 3

Supported by

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