A powerful Node.js application that automatically scrapes LinkedIn profiles of new connections, analyzes them using AI (OpenAI), and integrates the data into GoHighLevel CRM with intelligent duplicate prevention.
- Automated LinkedIn profile data extraction
- Handles authentication with existing Chrome browser
- Extracts comprehensive profile information
- Local storage to avoid re-scraping
- OpenAI integration for persona analysis
- Pain point identification
- Outreach angle generation
- Email subject line suggestions
- Intelligent tagging system
- Automatic contact creation
- Intelligent duplicate prevention
- Search before create functionality
- Custom fields and notes
- Tag management
- SQLite database for persistence
- Profile and analysis caching
- Avoid re-scraping and re-analyzing
- Offline capability
- Node.js 18+
- Chrome browser (for LinkedIn authentication)
- OpenAI API key
- GoHighLevel API credentials
- Clone the repository:
git clone https://github.com/yourusername/zdor.git
cd zdor- Install dependencies:
npm install- Set up environment variables:
cp .env.example .env
# Edit .env with your API keys- Initialize the database:
npm run setupCreate a .env file with the following variables:
# OpenAI Configuration
OPENAI_API_KEY=your_openai_api_key
# GoHighLevel Configuration
GHL_API_KEY=your_ghl_api_key
GHL_LOCATION_ID=your_location_id
GHL_PRIVATE_INTEGRATION_TOKEN=your_private_integration_token
# LinkedIn Configuration
LINKEDIN_PROFILE_COOKIE_STATE_PATH=./storage/linkedin-state.json
# App Configuration
RUN_INTERVAL_MINUTES=10
MAX_PROFILES_PER_HOUR=5
DATABASE_PATH=./storage/app.db
# Logging
LOG_LEVEL=info
LOG_FILE=./logs/app.log# Start the application
npm start
# Development mode with auto-reload
npm run dev# Test LinkedIn login
npm run login
# Test profile scraping
npm run test-profile
# Test AI analysis
npm run save-profile
# Test GoHighLevel integration
npm run test-ghl
# Test contact search
npm run search-ghl
# Test search before create
npm run test-search-create# Login to LinkedIn (uses your Chrome browser)
npm run login
# The system will save authentication state for future use- Search Before Create: Always searches for existing contacts
- Email-based Matching: Most reliable duplicate prevention
- Name-based Fallback: Secondary matching strategy
- Company-based Fallback: Additional matching options
- Tag Management: Automatic tagging and organization
- Persona Analysis: Detailed personality and role analysis
- Pain Point Identification: Business challenges and opportunities
- Outreach Angles: Personalized communication strategies
- Email Subjects: Compelling subject line suggestions
- Smart Tagging: Automatic categorization
- No Re-scraping: Saves profiles locally
- No Re-analysis: Caches AI analysis results
- Faster Processing: Instant retrieval of saved data
- Offline Capability: Works without internet for saved profiles
src/
├── ai/ # AI analysis modules
├── crm/ # GoHighLevel integration
├── db/ # Database management
├── scrapers/ # LinkedIn scraping
├── utils/ # Utility functions
└── index.js # Main application
scripts/
├── linkedin-login.js # Authentication
├── test-profile.js # Profile testing
├── save-profile.js # Local storage testing
└── search-ghl.js # Contact search testing
- Uses GPT-4 for profile analysis
- Generates comprehensive personas
- Identifies pain points and opportunities
- Creates personalized outreach content
- REST API for contact management
- Custom fields for LinkedIn data
- Notes with AI analysis
- Tag-based organization
- Duplicate prevention
- Local Storage: Avoids re-processing
- Batch Processing: Handles multiple profiles
- Rate Limiting: Respects API limits
- Error Handling: Robust error management
- Logging: Comprehensive logging system
- Environment Variables: Secure API key storage
- Local Storage: Data stays on your machine
- Authentication: Secure LinkedIn login
- API Security: Proper authentication headers
- Fork the repository
- Create a feature branch
- Make your changes
- Add tests if applicable
- Submit a pull request
MIT License - see LICENSE file for details
For issues and questions:
- Create an issue on GitHub
- Check the documentation
- Review the logs for debugging
- LinkedIn API integration (when available)
- Additional CRM integrations
- Advanced AI analysis features
- Web dashboard interface
- Mobile app support
Built with ❤️ for efficient LinkedIn connection management