instagram-cli


Nameinstagram-cli JSON
Version 1.3.6 PyPI version JSON
download
home_pageNone
SummaryUse Instagram in the terminal, the end of brainrot is here
upload_time2025-07-24 06:23:22
maintainerNone
docs_urlNone
authorNone
requires_python>=3.10
licenseMIT
keywords instagram cli terminal social-media tui command-line instagram-api
VCS
bugtrack_url
requirements annotated-types art certifi charset-normalizer click emoji idna instagrapi markdown-it-py mdurl pillow pycryptodomex pydantic pydantic_core Pygments PySocks PyYAML requests rich shellingham typer typing_extensions urllib3
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # Instagram CLI

The ultimate weapon against brainrot. Shown experimentally to effectively reduce screentime.

![PyPI](https://img.shields.io/pypi/v/instagram-cli)
[![PyPI Downloads](https://static.pepy.tech/badge/instagram-cli)](https://pepy.tech/projects/instagram-cli)
![Python](https://img.shields.io/pypi/pyversions/instagram-cli)
[![MIT license](https://img.shields.io/github/license/supreme-gg-gg/instagram-cli.svg)](https://github.com/supreme-gg-gg/instagram-cli/blob/main/LICENSE)
[![GitHub issues](https://img.shields.io/github/issues/supreme-gg-gg/instagram-cli.svg)](https://github.com/supreme-gg-gg/instagram-cli/issues)

<!-- ![PyPI - Downloads](https://img.shields.io/pypi/dm/instagram-cli) -->
<!-- ![LOC](https://tokei.rs/b1/github/supreme-gg-gg/instagram-cli?category=code) -->

https://github.com/user-attachments/assets/e9206e14-8141-49b2-8e2c-17c76402e3cb

The world's first open-source CLI (command line interface) + Terminal UI client for Instagram.

> [!WARNING]
> This project is not affiliated with, authorized, or endorsed by Instagram. This is an independent and unofficial project. Using it might violate Meta's Terms of Service. Use at your own risk.

## What does it do?

- We transform Instagram from a brainrot hell into productivity tool
- We give back control of social media to the user
- We allow you to focus on meaningful conversation with friends
- We celebrate the art and simplicity of terminal UI
- We preserve the core of social media and protect your attention

> [!TIP]
> Use Instagram with 100% keyboard control - no mouse clicks or touchscreen taps needed! Perfect for developers and Linux users who love staying on the keyboard 🤣

## Installation

The simplest way to get started is to install the package from PyPI if you have Python installed:

```bash
pip install instagram-cli
```

If you do not have Python installed, you can download and install it from the [official website](https://www.python.org/downloads/).

### Installation from Source

```bash
git clone https://github.com/supreme-gg-gg/instagram-cli.git
cd instagram-cli
pip install .
```

### Pre-built Executables

> [!CAUTION]
> This option is **not recommended** unless the other methods do not work for you.

We no longer provide pre-built executables. If you want to run the application in an environment without Python, you can build the executable yourself with `pyinstaller`. We recommend using the `instagram-cli.spec` file we provided.

```bash
pyinstaller --onedir instagram-cli.spec
```

This will generate the executable in the `dist/` directory.

```bash
./instagram-cli [OPTIONS] command [ARGS] # for macOS and Linux
instagram-cli.exe [OPTIONS] command [ARGS] # for Windows
```

> [!CAUTION]
> Starting from Version 1.3, Windows support will be discontinued due to incompatibilities between the `curses` and `windows-curses` libraries. While the application may still work on Windows, we will no longer be testing or maintaining Windows-specific functionality. We recommend using WSL (Windows Subsystem for Linux) or Docker for Windows users.

## Commands

The following commands will be available after installing the package:

```bash
instagram                                  # display title art
instagram --help                           # view available commands

# Authentication
instagram auth login -u                    # login with username and password
instagram auth logout                      # logout and removes session

# Chat Features
instagram chat start                       # start chat interface
instagram chat search -u <username>        # search and open chat by username
instagram chat search -t <text>           # search and open chat by chat title

# Utility Commands
instagram notify                           # view notifications (inbox, followers, mentions)
instagram schedule ls                      # view scheduled messages
instagram schedule cancel <index>          # cancel scheduled message
instagram stats --days <last_n_days>       # view usage analytics (default: 14 days)
instagram config --get --set --edit        # manage custom configuration
instagram cleanup -t                       # cleanup media and session cache files
```

> [!NOTE]
> All searches in the package uses a custom fuzzy matching based on ratcliff/obershelp similarity algorithm. This means chat search and emoji search will be more flexible and forgiving.

## Chat

The chat interface is the main feature of this package. It allows you to interact with your Instagram chats in a terminal-based interface.

In the chat list page, use arrow keys (or 'j', 'k') + Enter to select a chat. You can also search for user by username using @user_name + Enter.

> [!NOTE]
> Chat commands (prefixed with `:`) are NOT available in the chat menu page. You must enter a chat to use chat commands.

After entering the chat page, you can type messages as usual and send them with Enter. You can also use chat commands to supercharge your chat experience.

> [!TIP]
> Press Enter in the middle of a message to insert a line break, and at the very end to send it.

### Chat Commands

All chat commands have the following syntax:

```bash
:command <args> <long-args>
```

> [!IMPORTANT]
> Long arguments should have special enclosures such as `"..."` for strings with spaces and `$...$` for LaTeX code.

- `:help`: view available commands
- `:quit`: quit the application
- `:back`: back to chat menu for selecting chat
- `:reply`: reply mode to select and reply to messages
- `:scrollup`or `:k`: scroll up in chat messages
- `:scrolldown` or `:j`: scroll down in chat messages
- `:schedule <time> "<message>"`: schedule a message, see [scheduling messages](#scheduling-messages)
- `:delay <seconds> "<message>"`: delay sending the message, similar as schedule
- `:cancel`: cancel the latest scheduled/delayed message
- `:upload`: upload media using the file navigator
- `:upload <path>`: upload media (photo or video) directly from path
- `:view <index>`: view and download media at index or open URL directly in browser
- `:latex $<expr>$`: render and send LaTeX code as image, see [latex](#latex)

### Emoji

Text with emoji syntax will be rendered as emoji. For example,

`This is an emoji :thumbsup:`

will be rendered as

`This is an emoji 👍`

> ![TIP]
> This does not have to be an exact match with the emoji name. For example, `:thumbsup:` can also be written as `:thumbs_up:`.

### LaTeX

We support LaTeX rendering and sending as images in the chat. For example,

`:latex $\frac{a}{b} + c = d$`

![sample1](https://github.com/supreme-gg-gg/instagram-cli/blob/main/resource/latex_sample_1.png?raw=true)

```bash
:latex $\left( \begin{bmatrix} a & b \\ c & d \end{bmatrix} \cdot \begin{bmatrix} e & f \\ g & h \end{bmatrix} \right) + \begin{bmatrix} i & j \\ k & l \end{bmatrix}^{-1} \times \left( \int_0^1 x^2 \, dx \right) + \begin{bmatrix} \sin(\theta) & \cos(\theta) \\ \tan(\phi) & \ln(\psi) \end{bmatrix}$
```

![sample2](https://github.com/supreme-gg-gg/instagram-cli/blob/main/resource/latex_sample.png?raw=true)

Please note that the LaTeX code **_MUST_** be enclosed in `$` symbols.

You can choose to render with [online API](https://latex.codecogs.com) (default) or local LaTeX installation such as TeX Live, MiKTeX, etc. You can set the rendering method with `instagram config --set latex_rendering_method <online|local>`.

### Scheduling Messages

You can schedule messages to be sent at a later time. The syntax is as follows:

```bash
:schedule <Optional[Y-m-d] HH:MM> "<message>"
```

If the date is not provided, the message will be scheduled for the current day. Input format must be either YYYY-MM-DD HH:MM or HH:MM. **The time must be in 24-hour format, otherwise you might run into warnings for scheduling messages in the past.**

> [!IMPORTANT]
> If you exit the app, the scheduled messages will not be sent but will be restored when you open the app again. You will be prompted by a notification to decide whether to send the scheduled messages or not. We might include system background service in the future to send scheduled messages even when the app is closed.

## Contributing

We welcome contributors! Please see the comprehensive [CONTRIBUTING.md](CONTRIBUTING.md) file for details on how to get started, create issues, and submit pull requests.

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "instagram-cli",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.10",
    "maintainer_email": null,
    "keywords": "instagram, cli, terminal, social-media, tui, command-line, instagram-api",
    "author": null,
    "author_email": "Jet Chiang <jetjiang.ez@gmail.com>, James Zheng <endernoke@gmail.com>",
    "download_url": "https://files.pythonhosted.org/packages/2c/e8/faf28cec20bbc3559cebd544e0a2ff45840cbbe38e182e386bdf5a46f4fa/instagram_cli-1.3.6.tar.gz",
    "platform": null,
    "description": "# Instagram CLI\n\nThe ultimate weapon against brainrot. Shown experimentally to effectively reduce screentime.\n\n![PyPI](https://img.shields.io/pypi/v/instagram-cli)\n[![PyPI Downloads](https://static.pepy.tech/badge/instagram-cli)](https://pepy.tech/projects/instagram-cli)\n![Python](https://img.shields.io/pypi/pyversions/instagram-cli)\n[![MIT license](https://img.shields.io/github/license/supreme-gg-gg/instagram-cli.svg)](https://github.com/supreme-gg-gg/instagram-cli/blob/main/LICENSE)\n[![GitHub issues](https://img.shields.io/github/issues/supreme-gg-gg/instagram-cli.svg)](https://github.com/supreme-gg-gg/instagram-cli/issues)\n\n<!-- ![PyPI - Downloads](https://img.shields.io/pypi/dm/instagram-cli) -->\n<!-- ![LOC](https://tokei.rs/b1/github/supreme-gg-gg/instagram-cli?category=code) -->\n\nhttps://github.com/user-attachments/assets/e9206e14-8141-49b2-8e2c-17c76402e3cb\n\nThe world's first open-source CLI (command line interface) + Terminal UI client for Instagram.\n\n> [!WARNING]\n> This project is not affiliated with, authorized, or endorsed by Instagram. This is an independent and unofficial project. Using it might violate Meta's Terms of Service. Use at your own risk.\n\n## What does it do?\n\n- We transform Instagram from a brainrot hell into productivity tool\n- We give back control of social media to the user\n- We allow you to focus on meaningful conversation with friends\n- We celebrate the art and simplicity of terminal UI\n- We preserve the core of social media and protect your attention\n\n> [!TIP]\n> Use Instagram with 100% keyboard control - no mouse clicks or touchscreen taps needed! Perfect for developers and Linux users who love staying on the keyboard \ud83e\udd23\n\n## Installation\n\nThe simplest way to get started is to install the package from PyPI if you have Python installed:\n\n```bash\npip install instagram-cli\n```\n\nIf you do not have Python installed, you can download and install it from the [official website](https://www.python.org/downloads/).\n\n### Installation from Source\n\n```bash\ngit clone https://github.com/supreme-gg-gg/instagram-cli.git\ncd instagram-cli\npip install .\n```\n\n### Pre-built Executables\n\n> [!CAUTION]\n> This option is **not recommended** unless the other methods do not work for you.\n\nWe no longer provide pre-built executables. If you want to run the application in an environment without Python, you can build the executable yourself with `pyinstaller`. We recommend using the `instagram-cli.spec` file we provided.\n\n```bash\npyinstaller --onedir instagram-cli.spec\n```\n\nThis will generate the executable in the `dist/` directory.\n\n```bash\n./instagram-cli [OPTIONS] command [ARGS] # for macOS and Linux\ninstagram-cli.exe [OPTIONS] command [ARGS] # for Windows\n```\n\n> [!CAUTION]\n> Starting from Version 1.3, Windows support will be discontinued due to incompatibilities between the `curses` and `windows-curses` libraries. While the application may still work on Windows, we will no longer be testing or maintaining Windows-specific functionality. We recommend using WSL (Windows Subsystem for Linux) or Docker for Windows users.\n\n## Commands\n\nThe following commands will be available after installing the package:\n\n```bash\ninstagram                                  # display title art\ninstagram --help                           # view available commands\n\n# Authentication\ninstagram auth login -u                    # login with username and password\ninstagram auth logout                      # logout and removes session\n\n# Chat Features\ninstagram chat start                       # start chat interface\ninstagram chat search -u <username>        # search and open chat by username\ninstagram chat search -t <text>           # search and open chat by chat title\n\n# Utility Commands\ninstagram notify                           # view notifications (inbox, followers, mentions)\ninstagram schedule ls                      # view scheduled messages\ninstagram schedule cancel <index>          # cancel scheduled message\ninstagram stats --days <last_n_days>       # view usage analytics (default: 14 days)\ninstagram config --get --set --edit        # manage custom configuration\ninstagram cleanup -t                       # cleanup media and session cache files\n```\n\n> [!NOTE]\n> All searches in the package uses a custom fuzzy matching based on ratcliff/obershelp similarity algorithm. This means chat search and emoji search will be more flexible and forgiving.\n\n## Chat\n\nThe chat interface is the main feature of this package. It allows you to interact with your Instagram chats in a terminal-based interface.\n\nIn the chat list page, use arrow keys (or 'j', 'k') + Enter to select a chat. You can also search for user by username using @user_name + Enter.\n\n> [!NOTE]\n> Chat commands (prefixed with `:`) are NOT available in the chat menu page. You must enter a chat to use chat commands.\n\nAfter entering the chat page, you can type messages as usual and send them with Enter. You can also use chat commands to supercharge your chat experience.\n\n> [!TIP]\n> Press Enter in the middle of a message to insert a line break, and at the very end to send it.\n\n### Chat Commands\n\nAll chat commands have the following syntax:\n\n```bash\n:command <args> <long-args>\n```\n\n> [!IMPORTANT]\n> Long arguments should have special enclosures such as `\"...\"` for strings with spaces and `$...$` for LaTeX code.\n\n- `:help`: view available commands\n- `:quit`: quit the application\n- `:back`: back to chat menu for selecting chat\n- `:reply`: reply mode to select and reply to messages\n- `:scrollup`or `:k`: scroll up in chat messages\n- `:scrolldown` or `:j`: scroll down in chat messages\n- `:schedule <time> \"<message>\"`: schedule a message, see [scheduling messages](#scheduling-messages)\n- `:delay <seconds> \"<message>\"`: delay sending the message, similar as schedule\n- `:cancel`: cancel the latest scheduled/delayed message\n- `:upload`: upload media using the file navigator\n- `:upload <path>`: upload media (photo or video) directly from path\n- `:view <index>`: view and download media at index or open URL directly in browser\n- `:latex $<expr>$`: render and send LaTeX code as image, see [latex](#latex)\n\n### Emoji\n\nText with emoji syntax will be rendered as emoji. For example,\n\n`This is an emoji :thumbsup:`\n\nwill be rendered as\n\n`This is an emoji \ud83d\udc4d`\n\n> ![TIP]\n> This does not have to be an exact match with the emoji name. For example, `:thumbsup:` can also be written as `:thumbs_up:`.\n\n### LaTeX\n\nWe support LaTeX rendering and sending as images in the chat. For example,\n\n`:latex $\\frac{a}{b} + c = d$`\n\n![sample1](https://github.com/supreme-gg-gg/instagram-cli/blob/main/resource/latex_sample_1.png?raw=true)\n\n```bash\n:latex $\\left( \\begin{bmatrix} a & b \\\\ c & d \\end{bmatrix} \\cdot \\begin{bmatrix} e & f \\\\ g & h \\end{bmatrix} \\right) + \\begin{bmatrix} i & j \\\\ k & l \\end{bmatrix}^{-1} \\times \\left( \\int_0^1 x^2 \\, dx \\right) + \\begin{bmatrix} \\sin(\\theta) & \\cos(\\theta) \\\\ \\tan(\\phi) & \\ln(\\psi) \\end{bmatrix}$\n```\n\n![sample2](https://github.com/supreme-gg-gg/instagram-cli/blob/main/resource/latex_sample.png?raw=true)\n\nPlease note that the LaTeX code **_MUST_** be enclosed in `$` symbols.\n\nYou can choose to render with [online API](https://latex.codecogs.com) (default) or local LaTeX installation such as TeX Live, MiKTeX, etc. You can set the rendering method with `instagram config --set latex_rendering_method <online|local>`.\n\n### Scheduling Messages\n\nYou can schedule messages to be sent at a later time. The syntax is as follows:\n\n```bash\n:schedule <Optional[Y-m-d] HH:MM> \"<message>\"\n```\n\nIf the date is not provided, the message will be scheduled for the current day. Input format must be either YYYY-MM-DD HH:MM or HH:MM. **The time must be in 24-hour format, otherwise you might run into warnings for scheduling messages in the past.**\n\n> [!IMPORTANT]\n> If you exit the app, the scheduled messages will not be sent but will be restored when you open the app again. You will be prompted by a notification to decide whether to send the scheduled messages or not. We might include system background service in the future to send scheduled messages even when the app is closed.\n\n## Contributing\n\nWe welcome contributors! Please see the comprehensive [CONTRIBUTING.md](CONTRIBUTING.md) file for details on how to get started, create issues, and submit pull requests.\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Use Instagram in the terminal, the end of brainrot is here",
    "version": "1.3.6",
    "project_urls": {
        "Homepage": "https://github.com/supreme-gg-gg/instagram-cli"
    },
    "split_keywords": [
        "instagram",
        " cli",
        " terminal",
        " social-media",
        " tui",
        " command-line",
        " instagram-api"
    ],
    "urls": [
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "406192eee51e8b1115e646e1f8a668cbdf90825819015978fa801f9426649aa7",
                "md5": "a3d028459d14b15ea5a0a20de2c0ca09",
                "sha256": "adfed3f4a52760fada000fe63a27d1659709160766053c380e046433c9480314"
            },
            "downloads": -1,
            "filename": "instagram_cli-1.3.6-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "a3d028459d14b15ea5a0a20de2c0ca09",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.10",
            "size": 57634,
            "upload_time": "2025-07-24T06:23:21",
            "upload_time_iso_8601": "2025-07-24T06:23:21.699398Z",
            "url": "https://files.pythonhosted.org/packages/40/61/92eee51e8b1115e646e1f8a668cbdf90825819015978fa801f9426649aa7/instagram_cli-1.3.6-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "2ce8faf28cec20bbc3559cebd544e0a2ff45840cbbe38e182e386bdf5a46f4fa",
                "md5": "8e37f14cdb9a431abd78048fd983fdd0",
                "sha256": "610f110b7cc2d2a919331876e78334455050ac301712a2212b96cc8c8d16a89a"
            },
            "downloads": -1,
            "filename": "instagram_cli-1.3.6.tar.gz",
            "has_sig": false,
            "md5_digest": "8e37f14cdb9a431abd78048fd983fdd0",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.10",
            "size": 53263,
            "upload_time": "2025-07-24T06:23:22",
            "upload_time_iso_8601": "2025-07-24T06:23:22.884443Z",
            "url": "https://files.pythonhosted.org/packages/2c/e8/faf28cec20bbc3559cebd544e0a2ff45840cbbe38e182e386bdf5a46f4fa/instagram_cli-1.3.6.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2025-07-24 06:23:22",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "supreme-gg-gg",
    "github_project": "instagram-cli",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "requirements": [
        {
            "name": "annotated-types",
            "specs": [
                [
                    "==",
                    "0.7.0"
                ]
            ]
        },
        {
            "name": "art",
            "specs": [
                [
                    "==",
                    "6.5"
                ]
            ]
        },
        {
            "name": "certifi",
            "specs": [
                [
                    "==",
                    "2025.1.31"
                ]
            ]
        },
        {
            "name": "charset-normalizer",
            "specs": [
                [
                    "==",
                    "3.4.1"
                ]
            ]
        },
        {
            "name": "click",
            "specs": [
                [
                    "==",
                    "8.1.8"
                ]
            ]
        },
        {
            "name": "emoji",
            "specs": [
                [
                    "==",
                    "2.14.1"
                ]
            ]
        },
        {
            "name": "idna",
            "specs": [
                [
                    "==",
                    "3.10"
                ]
            ]
        },
        {
            "name": "instagrapi",
            "specs": [
                [
                    "==",
                    "2.1.3"
                ]
            ]
        },
        {
            "name": "markdown-it-py",
            "specs": [
                [
                    "==",
                    "3.0.0"
                ]
            ]
        },
        {
            "name": "mdurl",
            "specs": [
                [
                    "==",
                    "0.1.2"
                ]
            ]
        },
        {
            "name": "pillow",
            "specs": [
                [
                    "==",
                    "11.2.1"
                ]
            ]
        },
        {
            "name": "pycryptodomex",
            "specs": [
                [
                    "==",
                    "3.21.0"
                ]
            ]
        },
        {
            "name": "pydantic",
            "specs": [
                [
                    "==",
                    "2.10.1"
                ]
            ]
        },
        {
            "name": "pydantic_core",
            "specs": [
                [
                    "==",
                    "2.27.1"
                ]
            ]
        },
        {
            "name": "Pygments",
            "specs": [
                [
                    "==",
                    "2.19.1"
                ]
            ]
        },
        {
            "name": "PySocks",
            "specs": [
                [
                    "==",
                    "1.7.1"
                ]
            ]
        },
        {
            "name": "PyYAML",
            "specs": [
                [
                    "==",
                    "6.0.2"
                ]
            ]
        },
        {
            "name": "requests",
            "specs": [
                [
                    "==",
                    "2.32.3"
                ]
            ]
        },
        {
            "name": "rich",
            "specs": [
                [
                    "==",
                    "14.0.0"
                ]
            ]
        },
        {
            "name": "shellingham",
            "specs": [
                [
                    "==",
                    "1.5.4"
                ]
            ]
        },
        {
            "name": "typer",
            "specs": [
                [
                    "==",
                    "0.12.5"
                ]
            ]
        },
        {
            "name": "typing_extensions",
            "specs": [
                [
                    "==",
                    "4.13.2"
                ]
            ]
        },
        {
            "name": "urllib3",
            "specs": [
                [
                    "==",
                    "2.4.0"
                ]
            ]
        }
    ],
    "lcname": "instagram-cli"
}
        
Elapsed time: 0.74961s