Thanks to visit codestin.com
Credit goes to github.com

Skip to content

tushar-manna/WhatsDownloader

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

WhatsApp Instagram Video Downloader Bot

Node Version

A WhatsApp bot that automatically detects Instagram links, downloads videos, and sends them back to users.

Features

  • Automatic Instagram link detection (Posts, Reels, Stories)
  • Video downloading using yt-dlp
  • Session persistence with encrypted credentials
  • Automatic temporary file cleanup
  • Cross-platform support (Windows/Linux)

Prerequisites

  • Node.js v20+
  • yt-dlp 2025+
  • FFmpeg (latest stable version)
  • WhatsApp mobile app (for initial QR scan)

Installation

1. Clone Repository

git clone https://github.com/yourusername/whatsapp-video-bot.git
cd whatsapp-video-bot

2. Install Dependencies

npm install

3. Environment Setup

Create .env file in root directory:

LOCATION=./temp/  # Always include trailing slash

4. Tool Installation

Windows Users

winget install yt-dlp

Restart your computer after installation

Debian/Ubuntu Users

# Install yt-dlp
sudo curl -L https://github.com/yt-dlp/yt-dlp/releases/latest/download/yt-dlp -o /usr/local/bin/yt-dlp
sudo chmod a+rx /usr/local/bin/yt-dlp

# Install FFmpeg
sudo apt update
sudo apt install ffmpeg

Usage

  1. Start the bot:
node main.js
  1. Scan QR code using WhatsApp mobile app:

    • Open WhatsApp → Settings → Linked Devices → Link a Device
  2. Send Instagram link to bot:

    https://www.instagram.com/reel/CxYzABC123/
    
  3. Receive downloaded video within 1-2 minutes

Configuration

Edit .env file:

# Required
LOCATION=./temp/

# Optional Proxy Configuration
# PROXY=http://yourproxy:8080
# USER_AGENT="Mozilla/5.0 ..."

Supported Systems

OS Status Notes
Windows 10/11 Verified Requires winget
Ubuntu 22.04 Verified Needs manual updates
macOS Untested Community help needed

Troubleshooting

Common Issues

  1. "Command not found" errors

    • Verify installation paths
    • Reinstall yt-dlp/FFmpeg
  2. Login session expires

    • Delete auth folder and restart bot
  3. Large file failures

NODE_OPTIONS=--max-old-space-size=4096

Contributing

We welcome contributions! Current priorities:

  • Add Facebook support
  • Implement YouTube Shorts download
  • Improve error handling
  • Add progress tracking
  1. Fork the repository
  2. Create feature branch (git checkout -b feature/amazing-feature)
  3. Commit changes (git commit -m 'Add amazing feature')
  4. Push to branch (git push origin feature/amazing-feature)
  5. Open Pull Request

Important Notes

  • First run requires QR login
  • Terminate and restart after initial setup
  • Temporary files auto-delete after sending

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published