English | 简体中文
A lightweight, real-time automation tool to extract verification codes (OTP) from Gmail. It uses IMAP IDLE technology for zero-latency efficiency.
- Language: Python 3.x
- Protocol: IMAP (with IDLE support)
- Libraries:
imaplib,email,re(Standard Libraries)
- Real-time Monitoring: Uses IMAP IDLE (push notifications) instead of constant interval polling.
- High Efficiency: Only two simple files; no database or heavy dependencies required.
- Auto-Extraction: Automatically parses 6-digit verification codes using regex.
- Easy Configuration: Separate config file for privacy and logic separation.
- Clone the repo and copy
config.example.pytoconfig.py. - Configure
config.pywith your Gmail address and 16-character App Password. - Run the program:
python gmail_openai_otp.py
MIT License - Copyright (c) 2026 AlexVera