https://github.com/jtayped/pygramcore
π· A Python interface for Instagram featuring authentication, data retrieval, and posting.
https://github.com/jtayped/pygramcore
automation bot instagram instagram-bot instagram-sdk instagram-tool selenium-webdriver
Last synced: 8 months ago
JSON representation
π· A Python interface for Instagram featuring authentication, data retrieval, and posting.
- Host: GitHub
- URL: https://github.com/jtayped/pygramcore
- Owner: jtayped
- License: mit
- Created: 2024-05-02T09:23:12.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-05-13T20:04:46.000Z (over 1 year ago)
- Last Synced: 2025-02-01T15:11:29.857Z (9 months ago)
- Topics: automation, bot, instagram, instagram-bot, instagram-sdk, instagram-tool, selenium-webdriver
- Language: Python
- Homepage: https://pypi.org/project/pygramcore/
- Size: 223 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
![]()
π· pygramcore
An easy-to-use Instagram SDK using Selenium.
## π Key Features
- **Modular Elements**: Easily use and customize modular elements such as Posts, Comments, and Users.
- **Users**: Follow, direct message, get posts, and more.
- **Posts**: Like, comment, download, and more.
- **Stories** (Coming soon...)
- **Comments** (Coming soon...)
## π§ How To Use
First of all, install the package using:
```bash
pip install pygramcore
```To take authenticated actions, initialize your Instagram account with your email/password and login:
```python
from pygramcore import AccountAccount.login("youremail@email.com", "yourpassword123")
Account.save_cookies("path/to/file.pkl")
```To initialize an account from cookies:
```python
Account.load_cookies("path/to/file.pkl")
```This will allow you to post images, comment on other peoples posts, send DMs, etc...
```python
Account.post("path/to/image.png", "Your very interesting caption")
```To search for a user simply:
```python
from pygramcore import Useruser = User("username123_")
```Here is an example of the usage of a user:
```python
# Get a list of Post() objects
posts = user.get_posts(limit=50)# Like the first 10 posts in the user's feed
for post in posts[:10]:
# Get URLs of the images in the post
urls = post.get_images()# Like & comment the post
post.comment("Nice post!")
post.like()
```Please refer to the [docs](https://github.com/jtayped/pygramcore/tree/main/docs) for more.
## β About the Project
This Python package was created as a fun project to enhance my proficiency in writing "professional" Python code, building packages, implementing semantic versioning, and ensuring code maintainability.
I am still a relatively new developer, and I welcome any contributions and feedback to help me improve.
It is important to note that this project is not intended to replace essential packages such as [InstaPy](https://github.com/InstaPy/InstaPy), nor do I anticipate that it will.## πββοΈ You may also like...
- [βοΈπ±TikTok Manager](https://github.com/jtayped/tiktok-manager) - A script that manages MULTIPLE TikTok accounts by schedueling automatically generated videos from pre-selected YouTube channels to TikTok in advance.
- [π§βπΌMy Portfolio](https://joeltaylor.business) - Check out my front-end and SEO skills on my Portfolio!