Skip to content

Latest commit

 

History

3 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Gmail Referral Automation (SMTP)

Send professional referral-request emails in controlled batches using Gmail SMTP + App Password, with:

  • CSV-driven outreach (Name, Email, Title, Company)
  • Resume attachment (PDF/DOCX)
  • Daily cap (defaults to 50% of personal Gmail daily sending limit)
  • sent_log.csv to avoid re-sending the same recipient
  • Template selection (3 variants) + centralized variables (TITLE, LinkedIn, Portfolio, etc.)

This project uses SMTP App Passwords (no OAuth / no Gmail API credentials.json).


Folder Structure

gmail-referral-automation/
  ├─ src/
  │   └─ send_referrals.py
  ├─ samples/
  │   └─ prospects_sample.csv
  ├─ .gitignore
  ├─ requirements.txt
  └─ README.md

Requirements

  • Python 3.9+
  • A Gmail account with 2-Step Verification enabled
  • A Gmail App Password (16 characters)

Install dependencies:

pip install -r requirements.txt

Steps to make this Automation work

Step 1 — Enable 2FA

Navigate to Google Account Security and enable 2-Step Verification:

Step 2 — Create an App Password (SMTP password)

Create a new app password here:

  1. In the App name field enter: Colab SMTP
  2. Copy the 16-character code and store it safely.
    • It is a one-time view password.
    • If you lose it, you must create a new App Password.

Step 3 — Update your personal details in the code

Modify all your personal details in the template section (Template Choice / Title / Name / LinkedIn / Portfolio), otherwise you will be helping me get referrals ✊.

Step 4 — Respect daily limits + use the log file

  • Personal Gmail commonly has a daily send limit (example: 500 emails/day).
  • This project sends 50% by default (example: 250/day) for safety.

Important: Every new day you run the script, attach/keep the same sent_log.csv (or keep it in the repo folder locally) so the same person does not receive multiple emails.


Input CSV Format

Your CSV must include these columns:

  • Name
  • Email
  • Title
  • Company

Example file: samples/prospects_sample.csv


Resume Attachment

Provide a file path to your resume:

  • resume.pdf or resume.docx

The script attaches this resume to every email.


Configure Email Templates

Inside src/send_referrals.py, you can edit:

  • TITLE (the role you want referral for)
  • YOUR_NAME
  • LINKEDIN
  • PORTFOLIO
  • TEMPLATE_CHOICE (1/2/3)
  • SKILLS_LINE, STACK_LINE, IMPACT_LINE

These variables control subject/body formatting.


Sending Limits & Safety Controls

Key controls:

  • ACCOUNT_TYPE"gmail" / "workspace_paid" / "workspace_trial"
  • TARGET_FRACTION → default 0.5
  • DRY_RUNTrue to test without sending
  • SLEEP_EACH + JITTER → reduces burst behavior

Run the Script

Example

python src/send_referrals.py   --csv samples/prospects_sample.csv   --resume ./resume.pdf   --from_email yourgmail@gmail.com

Dry run (no emails sent)

python src/send_referrals.py   --csv samples/prospects_sample.csv   --resume ./resume.pdf   --from_email yourgmail@gmail.com   --dry_run

Logging & Re-runs

  • The script writes/updates sent_log.csv to track:
    • sent
    • failed
    • dry_run

It only skips recipients that have status = sent in the log, so dry_run entries won’t block future sending.


Security Notes

✅ DO:

  • Keep sent_log.csv local or private
  • Use App Password (never your regular password)
  • Use .gitignore to avoid committing sensitive files

❌ DON’T:

  • Commit real prospect lists
  • Commit your resume
  • Commit App Passwords / tokens

Disclaimer ❗

These email lists and code are explicitly for improving the chances of getting into a job or getting a referral. Do not misuse anything and do not spam anyone - respect their privacy and opt-out requests.

About

SMTP-based Gmail outreach automation for referral requests: CSV-driven emails, resume attachment, daily caps, and sent_log to prevent duplicate sends.

Resources

Stars

6 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages