You know how we all do it - scrolling through Instagram, finding cool workout videos, design tips, or coding hacks, hitting that save button... and never looking at them again? They just sit there in a hidden folder, forgotten forever.
I built this bot to fix exactly that.
Instagram is great for inspiration but terrible for organization. WhatsApp is where we actually chat and share things, but it's not built for storage. So I thought - why not combine them?
It's simple. You forward an Instagram link to a WhatsApp number, and my bot:
- Reads the link
- Figures out what it's about (fitness, coding, food, etc.)
- Saves it to a website where you can actually find it later
✅ WhatsApp Integration - Just forward any Instagram post or reel
✅ Smart Categorization - Tries to figure out if it's Fitness, Coding, Food, Travel, or Design
✅ One-Line Summaries - So you remember what you saved
✅ Web Dashboard - All your saved stuff in one place
✅ Search - Finally find that recipe you saved 2 weeks ago
✅ Random Button - When you need inspiration
- Python/Flask for the backend (what I'm comfortable with)
- Twilio for WhatsApp (their sandbox is free for testing)
- Google Gemini AI (the free tier - no costs involved)
- HTML/CSS/JavaScript for the dashboard
- JSON file for storage (kept it simple, no database headaches)
- ngrok to connect my local computer to the internet
- You send an Instagram link to the WhatsApp number
- My code grabs the link and tries to extract info (Instagram's API is tricky, so I built fallbacks)
- It sends the caption to Gemini AI (or uses keywords if AI fails)
- The AI decides what category it belongs to and writes a quick summary
- Everything gets saved to a JSON file
- The web dashboard reads that file and shows all your saved posts
- You can search, filter, or click the random button
- Instagram's API doesn't always cooperate - built 3 different ways to extract data
- Keeping API keys secret (almost pushed them to GitHub once!)
- Making sure the bot doesn't crash when something unexpected happens
- Getting the webhook to work with ngrok (spent way too long on this)
- Add Twitter/X support
- Let users create their own categories
- Make it work for multiple users (right now it's one dashboard)
- Better error messages when things fail
- Export your saved stuff as CSV or PDF
Want to test it? Here's how:
# Clone the repo
git clone https://github.com/SumitPanigrahi171/social-bot
cd social-saver-bot
# Install what you need
pip install -r requirements.txt
# Add your Gemini API key to .env file
# Get a free key from https://makersuite.google.com/app/apikey
# Run it
python app.py
# In another terminal, expose it with ngrok
ngrok http 5000
# Update Twilio webhook with your ngrok URL + /webhook
# Send a message to your WhatsApp sandbox number