A professional desktop application for sending personalized certificate emails in bulk using the Mailjet API. Built with Python and Tkinter, featuring an intuitive GUI, real-time progress tracking, and comprehensive error handling.
For Windows Users (No Python Required):
- Download
mailjet.exefrom Releases - Double-click to launch the application
- Follow the setup wizard in the GUI
For Python Users:
git clone https://github.com/lovnishverma/certificate-email-sender.git
cd certificate-email-sender
pip install -r requirements.txt
python mailjet.py- Features
- Prerequisites
- Installation
- Configuration
- Usage
- Data Format Requirements
- Troubleshooting
- Building from Source
- Contributing
- License
- Bulk Email Sending: Send personalized certificates to multiple recipients
- Multi-format Support: Compatible with Excel (
.xlsx) and CSV (.csv) files - PDF Attachment: Automatically attach certificates based on certificate numbers
- Email Validation: Built-in validation to prevent sending to invalid addresses
- Intuitive GUI: Clean, user-friendly interface built with Tkinter
- Real-time Progress: Live progress bar and detailed logging
- Summary Reports: Comprehensive email delivery summary sent to sender
- Secure Configuration: Encrypted API key storage with masked input fields
- Error Handling: Robust error detection and recovery
- Configuration Persistence: Auto-saves settings in
config.json - Cross-platform: Runs on Windows, macOS, and Linux
- Standalone Executable: Windows
.exeversion requires no Python installation
- Python 3.7 or higher
- Active internet connection
- Mailjet account with API credentials
- Windows 10 or later
- Active internet connection
- Mailjet account with API credentials
- Create a free account at Mailjet.com
- Navigate to Account Settings β REST API β API Key Management
- Generate your API Key and Secret Key
- Keep these credentials secure - you'll need them for the application
git clone https://github.com/yourusername/certificate-email-sender.git
cd certificate-email-sender# Create virtual environment
python -m venv certificate_sender_env
# Activate virtual environment
# Windows:
certificate_sender_env\Scripts\activate
# macOS/Linux:
source certificate_sender_env/bin/activatepip install -r requirements.txtpython mailjet.py- Download the latest
mailjet.exefrom the Releases page - Save to your preferred location (no installation required)
- Double-click
mailjet.exeto launch - Windows may show a security warning - click "More info" β "Run anyway"
- Launch the application
- Enter your Mailjet API credentials:
- API Key: Your Mailjet public key
- API Secret: Your Mailjet private key (masked for security)
- Sender Name: Display name for outgoing emails
- Sender Email: Must be verified in your Mailjet account
Settings are automatically saved to config.json in the application directory:
{
"api_key": "your_api_key",
"api_secret": "your_api_secret",
"sender_name": "Your Organization",
"sender_email": "[email protected]"
}Security Note: Keep config.json secure and never share it publicly.
Create an Excel or CSV file with the following columns:
full_name: Recipient's complete nameemail: Recipient's email addresscert_no: Unique certificate identifier
- Place all PDF certificates in a single folder
- Name each certificate file exactly as:
{cert_no}.pdf - Example: If
cert_nois "CERT101", the file should be named "CERT101.pdf"
- Subject Line: Customize the email subject
- Email Body: Write your personalized message
- Use placeholders:
{full_name}- Replaced with recipient's name{cert_no}- Replaced with certificate number
- Click "Browse" to select your data file
- Click "Browse" to select your certificates folder
- Verify all settings are correct
- Click "Start Sending Emails"
- Monitor progress in the log window
Subject: Your Certificate - Congratulations {full_name}!
Dear {full_name},
Congratulations on your achievement! Please find your certificate ({cert_no}) attached to this email.
Best regards,
The Certification Team
Your data file must contain these exact column names:
| Column | Description | Example |
|---|---|---|
full_name |
Recipient's complete name | "John Smith" |
email |
Valid email address | "[email protected]" |
cert_no |
Unique certificate identifier | "CERT001" |
CSV Format:
full_name,email,cert_no
John Smith,[email protected],CERT001
Jane Doe,[email protected],CERT002
Bob Johnson,[email protected],CERT003
Excel Format:
| full_name | cert_no | |
|---|---|---|
| John Smith | [email protected] | CERT001 |
| Jane Doe | [email protected] | CERT002 |
| Bob Johnson | [email protected] | CERT003 |
Certificate PDF files must be named exactly as the cert_no value:
- CERT001.pdf
- CERT002.pdf
- CERT003.pdf
- Progress Bar: Visual indication of completion percentage
- Live Log: Detailed status updates for each email
- Error Reporting: Immediate notification of any issues
Upon completion, a summary report is automatically sent to the sender's email containing:
- Total records processed
- Number of emails sent successfully
- Number of failed deliveries
- List of failed recipients (if any)
- Processing time and timestamp
| Issue | Possible Cause | Solution |
|---|---|---|
| "Invalid email format" | Email doesn't match standard format | Verify email addresses in your data file |
| "Certificate not found" | PDF file missing or incorrectly named | Ensure {cert_no}.pdf exists in certificates folder |
| "API authentication failed" | Incorrect Mailjet credentials | Verify API Key and Secret in Mailjet dashboard |
| "Daily limit exceeded" | Mailjet sending limit reached | Wait 24 hours or upgrade your Mailjet plan |
| "Application won't start" | Missing dependencies or corrupted installation | Reinstall Python dependencies or re-download executable |
| "Permission denied" | Insufficient file access rights | Run as administrator or check file permissions |
To enable detailed logging:
- Open command prompt/terminal
- Navigate to application directory
- Run:
python mailjet.py --debug(Python version only)
If you encounter persistent issues:
- Check the Issues page
- Create a new issue with:
- Your operating system
- Application version
- Error message (if any)
- Steps to reproduce the problem
pip install pyinstallerpyinstaller --noconfirm --onefile --windowed --name="Certificate_Email_Sender" mailjet.pypyinstaller --noconfirm --onefile --windowed \
--add-data="config.json;." \
--icon="icon.ico" \
--name="Certificate_Email_Sender" \
mailjet.pyThe executable will be created in the dist/ directory.
certificate_email_sender/
βββ mailjet.py # Main application code
βββ config.json # Configuration file (auto-generated)
βββ requirements.txt # Python dependencies
βββ README.md # This documentation
βββ LICENSE # License file
βββ .gitignore # Git ignore rules
βββ dist/ # Built executables
β βββ Certificate_Email_Sender.exe
βββ build/ # Build artifacts
βββ mailjet.spec # PyInstaller configuration
mailjet-rest==1.3.4
pandas>=1.3.0
tqdm>=4.62.0
openpyxl>=3.0.9We welcome contributions! Please follow these steps:
- Fork the repository
- Create a feature branch:
git checkout -b feature/your-feature-name - Make your changes and test thoroughly
- Commit your changes:
git commit -am 'Add some feature' - Push to the branch:
git push origin feature/your-feature-name - Submit a Pull Request
- Follow PEP 8 style guidelines
- Add comments for complex logic
- Test on multiple platforms when possible
- Update documentation for new features
This project is licensed under the MIT License. See the LICENSE file for details.
- Mailjet API - Email delivery service
- Python Tkinter - GUI framework
- Pandas - Data manipulation
- PyInstaller - Executable creation
- Mailjet team for providing reliable email API
- Python community for excellent libraries
- Beta testers for valuable feedback
- Documentation: This README and inline code comments
- Issues: GitHub Issues
- Discussions: GitHub Discussions
Built with β€οΈ by Lovnish Verma
β Star this project | π Report Bug | π‘ Request Feature