Repository navigation
v1.0.0
Email Queue Service - v1.0.0
Introducing the first stable release of Email Queue Service – a centralized email delivery microservice designed to decouple email sending from automation systems. This production-ready service provides reliable, scalable email processing through a clean API with priority-based queuing.
Key Features
- FastAPI REST API – Simple
POST /api/v1/emails/queueendpoint acceptingmultipart/form-datarequests - Priority-Based Queuing – Three-tier priority system (
high/normal/low) with RabbitMQ for reliable message delivery - Email Templates – Jinja2-powered template rendering with dynamic content injection
- File Attachments – Support for multiple attachments with SHA256 checksum verification and MIME type validation
- Status Tracking – Full lifecycle tracking (
pending/sent/failed) with PostgreSQL persistence - Worker Process – Background consumer that processes queues in priority order
- SMTP Delivery – Secure email delivery via SMTP with SSL/TLS support
- Configuration Management – Environment-based configuration for easy deployment
- Email Types System – Pre-configured recipient addresses per email type
- Resilient Architecture – Database connection pooling and error handling
Architecture
- Client
- Sends requests to → FastAPI
- Stores queued emails in → PostgreSQL (Email Queue)
- Publishes to → RabbitMQ (Priority Queues)
- Consumed by → Worker (Templates + Attachments)
- Sends via → SMTP
- Delivered to → Recipient
- Sends via → SMTP
- Consumed by → Worker (Templates + Attachments)
- Sends requests to → FastAPI
Tech Stack
- Framework: FastAPI with Uvicorn
- Queue: RabbitMQ 3.8+
- Database: PostgreSQL with
psycopg2-binary - Template Engine: Jinja2
- Email Protocol: SMTP with SSL/TLS
- Python Version: 3.8+