A TypeScript CLI tool that parses a list of names and looks up LinkedIn profiles using the EnrichLayer API.
- Parses name lists (one name per line)
- Identifies entries with both first and last names
- Skips entries with only a single name
- Looks up current job titles and locations via EnrichLayer
- Filters by city (San Francisco)
- Automatically detects event name from filename
- Target contact filtering - Identifies VCs, CEOs, Partners, and Investors for follow-up
- Auto-open LinkedIn profiles - Opens target contact profiles in Chrome with randomized delays
- Local caching - Saves lookups to avoid burning credits on repeated queries
- Credit tracking - Shows before/after credit balance and cost
npm install-
Copy the
.env.examplefile to.env:cp .env.example .env
-
Get your EnrichLayer API token from https://enrichlayer.com
-
Add your token to the
.envfile:ENRICHLAYER_API_TOKEN=your_token_here
# Run with tsx (development)
npm start "examples/Tech Networking Mixer on 3-15-25.txt"
# Or use tsx directly
npx tsx src/index.ts "examples/Tech Networking Mixer on 3-15-25.txt"
# After building
npm run build
node dist/index.js "examples/Tech Networking Mixer on 3-15-25.txt"Create a text file with one name per line. The filename can include an event name and date:
Alice Johnson
Bob Smith
charlie
Diana Martinez
The tool will:
- Process "Alice Johnson", "Bob Smith", and "Diana Martinez" (have first + last name)
- Skip "charlie" (only has one name)
- Look up their current job titles and locations using EnrichLayer
- Cache Check: First checks the
logs/directory for cached results - Search: If not cached, searches EnrichLayer for people by first name, last name, and city (San Francisco)
- Profile Fetch: Retrieves detailed LinkedIn profile information
- Current Role: Identifies the most recent job (where
ends_atis null) - Target Match: Tests job title against pattern to identify follow-up priority contacts
- Cache Save: Saves successful lookups to
logs/for future use - Display: Shows name, current job title, location, and follow-up status
The tool automatically identifies high-priority contacts based on their job titles. Contacts matching the following patterns are marked as TARGET CONTACTS for follow-up:
- Partner - VCs, law firms, consulting partners
- Capital - Anyone with "Capital" in their title (VCs, investment firms)
- VC - Venture Capitalists
- C-Suite Executives - CEO, CTO, CFO, COO, CMO, CIO, CPO, and any "Chief X Officer" title
- Investor - Angel investors, institutional investors
- ⭐ [TARGET CONTACT] - Appears next to the name
- ✅ FOLLOW UP - Clear action indicator with matching pattern
- ⏭️ SKIP - Non-target contacts
- Summary - Shows count: "Target contacts to follow up: 5/25"
1. John Doe [⭐ TARGET CONTACT]
Current Title: Managing Partner
Current Company: XYZ Capital
Location: San Francisco, CA
LinkedIn: https://www.linkedin.com/in/johndoe
Status: ✅ FOLLOW UP - Matches target pattern (C-Suite/VC/Partner/Investor)
2. Jane Smith
Current Title: Software Engineer
Current Company: Tech Corp
Location: San Jose, CA
LinkedIn: https://www.linkedin.com/in/janesmith
Status: ⏭️ SKIP - Does not match target pattern
After displaying results, the tool automatically opens LinkedIn profiles for all target contacts in Google Chrome. This saves time by eliminating manual clicking through each profile.
Key Features:
- Opens only target contact profiles (those marked with ⭐)
- Uses randomized delays (750ms - 3000ms) between each profile to avoid rate limiting
- Shows progress as each profile is opened
This feature runs automatically at the end of each session, opening tabs for all identified high-priority contacts.
The tool automatically caches all successful lookups in the logs/ directory to avoid burning API credits on repeated queries.
- Cache Location:
logs/firstname-lastname.json - Automatic: Caching happens automatically - no configuration needed
- Cache Hit: When a cached entry is found, you'll see
[CACHED]in the output - Credit Savings: Cached lookups don't consume API credits
# View cached entries
ls logs/
# Clear all cached entries
rm -rf logs/
# Remove a specific cached entry
rm logs/alice-johnson.jsonThe cache persists across runs, so running the same name list multiple times will only consume credits on the first run.
Environment variables in .env:
# Required: EnrichLayer API Bearer Token
ENRICHLAYER_API_TOKEN=your_token_here
# Optional: City to filter searches (default: San Francisco)
SEARCH_CITY=San Francisco
# Optional: Target contact pattern (regex) to identify high-priority follow-ups
# Default matches: C-Suite (CEO, CTO, etc.), VCs, Partners, Investors, Engineering Leadership
TARGET_CONTACT_PATTERN=Partner|Capital|VC|Investor|C[TEOFMPI]O|Chief\s+\w+\s+Officer|VP|VPE|Director|DIR\s+ENG
You can customize which job titles are flagged as target contacts by modifying the TARGET_CONTACT_PATTERN in your .env file. The pattern is a regular expression (case-insensitive) that tests both the job title and company name.
Examples:
- To only match VCs:
VC|Venture Capital - To match executives and directors:
C[TEOFMPI]O|Director|VP - To match specific roles:
Engineer|Product Manager|Designer
The default pattern includes:
- Partner - VCs, law firms, consulting partners
- Capital - Investment firms
- VC - Venture Capitalists
- Investor - Angel investors, institutional investors
- C[TEOFMPI]O - CEO, CTO, CFO, COO, CMO, CIO, CPO
- Chief\s+\w+\s+Officer - Any "Chief X Officer" title
- VP|VPE - Vice Presidents, VP of Engineering
- Director|DIR\s+ENG - Directors, Director of Engineering
src/
├── index.ts # CLI entry point
├── nameParser.ts # Name parsing logic
├── eventParser.ts # Event name extraction from filename
├── profileLookup.ts # EnrichLayer API integration
└── cache.ts # Local caching for lookup results
logs/ # Cached lookup results (auto-created)
examples/
└── Tech Networking Mixer on 3-15-25.txt # Example input file
# Watch mode
npm run dev "examples/Tech Networking Mixer on 3-15-25.txt"
# Build
npm run build
# Run tests
npm test
# Test watch mode
npm run test:watch
# Type check
npx tsc --noEmitThe project includes unit tests for core functionality:
npm testTests cover:
- Name parsing logic
- Event name extraction
- Edge cases and error handling
MIT