Open-source lead generation tool with AI-powered content creation and web dashboard
Generate business leads from Google Maps, create personalized marketing content using OpenAI, and manage everything through a modern web interface.
This tool helps you:
- Scrape business information from Google Maps (name, address, phone, rating)
- Generate AI marketing content personalized for each business
- Manage campaigns through a modern web dashboard
- Track lead quality with AI-powered scoring
- Export results in CSV and JSON formats
- Create email and WhatsApp templates automatically
- Monitor performance with real-time analytics
Perfect for: Digital agencies, freelance marketers, SME consultants, and business developers looking for an affordable lead generation solution with professional management tools.
- Node.js 16+
- OpenAI API key (get one here)
git clone https://github.com/asiifdev/business-leads-ai-automation.git
cd business-leads-ai-automation
npm install
# Copy environment template
cp .env.example .env
# Add your OpenAI API key to .env
OPENAI_API_KEY=your-openai-key-here
# Start the web dashboard
npm run web
# Open your browser to http://localhost:3000
# Create campaigns, manage leads, and view analytics through the web interface
# Basic CLI usage
node index.js -q "Restaurant Jakarta" -l 20 -m "Increase your restaurant sales with digital marketing"
# Results will be saved in the output/ folder
node index.js -q "Coffee Shop Jakarta" -l 5 -m "Boost your coffee shop with online ordering system"
📄 leads_[timestamp].csv
ID,Name,Address,Phone,Website,Rating
1,"Kopi Tuku","Jl. Kemang Raya No.1","+6281234567890","kopituku.com","4.5"
2,"Filosofi Kopi","Jl. Senopati No.5","+6281234567891","filosofikopi.com","4.3"
📧 email_template.txt
Subject: Tingkatkan Penjualan Coffee Shop dengan Sistem Online
Halo Tim Kopi Tuku,
Saya melihat coffee shop Anda di Kemang dengan rating 4.5 stars - impressive!
Apakah Anda tertarik meningkatkan penjualan dengan sistem online ordering yang terbukti efektif untuk coffee shop?
[Your personalized message continues...]
📱 whatsapp_template.txt
Halo Kopi Tuku! ☕
Lihat coffee shop Anda di Kemang rating 4.5⭐ - keren!
Mau boost penjualan pakai sistem online ordering? 📱
[Continues with personalized content...]
- Google Maps scraping with auto-scroll
- Business data extraction (name, address, phone, rating, website)
- AI content generation using OpenAI GPT
- Lead quality scoring with AI intelligence
- Dual template creation (email + WhatsApp)
- CSV and JSON export
- Indonesian market optimization
- Rate limiting to avoid blocking
- Modern web interface for non-technical users
- Campaign management with real-time progress tracking
- Lead management with filtering and sorting
- Analytics dashboard with performance insights
- Responsive design for mobile and desktop
- Real-time notifications via Server-Sent Events
- Data export functionality (CSV/JSON)
- Campaign templates for different industries
- Email finding returns empty array (work in progress)
- Phone number validation could be improved
- Error handling needs enhancement for edge cases
- Fix email discovery functionality
- Better phone number validation for Indonesian numbers
- Multiple search engine support
- Advanced AI prompt customization
- Batch processing for multiple queries
- API integrations (CRM, email marketing)
For the best experience, use the web dashboard:
npm run web
Then open http://localhost:3000 in your browser. The web interface provides:
- Campaign Creation: Easy form-based campaign setup
- Real-time Monitoring: Live progress tracking
- Lead Management: Filter, sort, and export leads
- Analytics: Performance insights and reporting
📚 Full Web Dashboard Guide: docs/WEB_DASHBOARD_GUIDE.md
node index.js [options]
Required:
-q, --query <query> Google Maps search query
-l, --limit <number> Number of results to scrape
-m, --message <text> Your marketing message for AI templates
Optional:
-o, --output <format> Output format: csv or json (default: csv)
-h, --help Show help information
Examples:
node index.js -q "Restaurant Bandung" -l 50 -m "Digital marketing for restaurants"
node index.js -q "Salon Jakarta" -l 30 -m "Online booking system" -o json
npm run web # Start web dashboard (recommended)
npm run web:dev # Start web dashboard in development mode
npm run cli # Run CLI version
npm test # Run tests
Edit .env
file for customization:
# Required
OPENAI_API_KEY=your-openai-key-here
# Web Dashboard (optional)
PORT=3000 # Web dashboard port
HOST=localhost # Web dashboard host
# Scraping Configuration (optional)
DELAY_BETWEEN_SCRAPES=2000 # Milliseconds between requests
MAX_RETRIES=3 # Retry failed requests
OUTPUT_FORMAT=csv # Default output format
# Database (optional)
DB_PATH=./data/leads.db # SQLite database path
- Free to use vs $99-299/month for SaaS alternatives
- Open source - modify as needed
- No monthly subscriptions
- Local business understanding in AI prompts
- WhatsApp marketing integration (popular in Indonesia)
- Indonesian language optimization
- Full source code access
- Easy to customize and extend
- Well-documented codebase
- Active community support
We welcome contributions! Here's how you can help:
- Report bugs via GitHub Issues
- Suggest features you'd like to see
- Submit pull requests for improvements
- Share your use cases and success stories
# Fork the repo, then clone your fork
git clone https://github.com/YOUR_USERNAME/business-leads-ai-automation.git
cd business-leads-ai-automation
npm install
# Create a feature branch
git checkout -b feature/your-feature-name
# Make your changes and test
npm test
# Submit a pull request
- Public data only - scrapes publicly available information
- Respectful scraping - includes rate limiting
- No spam - use for legitimate business outreach only
- MIT License - free for commercial use
Please read our DISCLAIMER.md for full legal information.
- Web Dashboard Guide: Complete user guide for the web interface
- Deployment Guide: Production deployment instructions
- API Documentation: REST API reference (coming soon)
- GitHub Issues: For bug reports and feature requests
- Discussions: For questions and community chat
- Email: [your-email] for urgent matters
Ready for production? Check our comprehensive deployment guide:
- VPS/Server deployment
- Docker containerization
- Cloud platform deployment (Heroku, AWS, etc.)
- SSL/HTTPS setup
- Monitoring and maintenance
📚 Full Deployment Guide: docs/DEPLOYMENT_GUIDE.md
- Built with Puppeteer for web scraping
- Powered by OpenAI for AI content generation
- Inspired by the need for affordable lead generation tools in Indonesia
MIT License - see LICENSE file for details.
⭐ Star this repo if you find it useful!
Made with ❤️ for Indonesian businesses