Generate & Deliver Certificates with VerifiEmail & HTMLcsstoImg to Gmail

Go to Workflow
0 views
Built by Jitesh Dugar Jitesh Dugar
Created on June 05, 2026

Description

Automated Certificate Generator with Email Validation & Delivery

Automatically generate, validate, and deliver professional course completion certificates with zero manual work — from webhook request to PDF delivery in seconds.

Overview

This workflow transforms certificate generation from a manual design task into a fully automated system. It receives certificate requests via webhook, validates recipient emails using advanced verification, generates beautifully designed HTML certificates, converts them to high-quality PNG images, delivers via professional email templates, and maintains complete audit trails in Google Sheets.

Powered by email validation APIs and HTML-to-image conversion, it ensures every certificate meets professional standards while preventing delivery to invalid or fraudulent email addresses.

What This Workflow Does

Receives certificate requests** via webhook from your LMS, CRM, or custom application
Validates recipient emails** using VerifiEmail API with comprehensive checks:
RFC compliance verification
MX record validation
Disposable email detection
Spoof and fraud prevention
Generates professional certificates** with custom HTML/CSS templates featuring:
Purple gradient backgrounds with modern typography
Google Fonts integration (Playfair Display + Montserrat)
Gold achievement badges
Auto-generated unique certificate IDs
Formatted completion dates
Instructor signatures
Converts HTML to PNG** using HTMLcsstoImg API for permanent, shareable images
Delivers via email** with branded HTML templates including download links and LinkedIn sharing CTAs
Logs everything** to Google Sheets for reporting, analytics, and certificate verification
Handles errors** with automatic validation checks and optional Slack notifications

Key Features

Zero Manual Work**: Fully automated from request to delivery
Advanced Email Validation**: Blocks invalid, temporary, and fraudulent email addresses
Professional Design**: Print-ready certificates with customizable branding
Unique Certificate IDs**: Auto-generated format: CERT-{timestamp}-{random}
Instant Delivery**: Certificates sent within seconds of completion
Complete Audit Trail**: All certificates logged with 10+ data points
Error Prevention**: Validation stops invalid requests before processing
Highly Customizable**: Easy to modify colors, fonts, layouts, and email templates
Scalable**: Handles hundreds of certificates per day
API-Ready**: RESTful webhook endpoint for easy integration

Use Cases

Educational Institutions
Automatically issue certificates for online courses and programs
Generate graduation certificates for completed degrees
Create participation certificates for workshops and seminars

Corporate Training
Award compliance training certificates to employees
Recognize professional development completions
Issue skill certification for internal programs

Online Course Platforms
Integrate with LMS systems (Teachable, Thinkific, Kajabi)
Automate certificate delivery upon course completion
Build certificate libraries for student portfolios

Event Management
Issue attendance certificates for conferences and webinars
Generate speaker appreciation certificates
Create volunteer recognition certificates

Certification Programs
Award professional certifications and credentials
Generate CPE/CE certificates for continuing education
Issue examination completion certificates

Prerequisites

Required Services & Accounts

n8n** (self-hosted or cloud) - Workflow automation platform
VerifiEmail Account** - Email validation API
HTMLcsstoImg Account** - HTML to PNG conversion
Gmail Account** - Email delivery via OAuth2
Google Workspace** - For Sheets logging and tracking

Required Credentials

VerifiEmail API Key
HTMLcsstoImg User ID + API Key
Gmail OAuth2 credentials
Google Sheets OAuth2 credentials

Setup Instructions

1. Import the Workflow

Download the certificate-generator.json file
In n8n, navigate to Workflows → Import from File
Select the JSON file and click Import

2. Configure Credentials

VerifiEmail API

Sign up at https://verifi.email
Navigate to Dashboard → API Keys
Copy your API key
In n8n: Settings → Credentials → Add Credential
Search for "VerifiEmail"
Name: VerifiEmail API
Paste API key and save
Assign to "Verifi Email" node in workflow

HTMLcsstoImg API

Sign up at https://htmlcsstoimg.com
Go to Dashboard → API
Copy User ID and API Key
In n8n: Credentials → Add Credential → "HTMLcsstoImg"
Name: HTMLcsstoImg API
Enter User ID and API Key
Assign to "HTML/CSS to Image" node

Gmail OAuth2

In n8n: Credentials → Add Credential → "Gmail OAuth2"
Click Connect my account
Follow Google OAuth flow
Grant permissions: Send email
Name: Gmail OAuth2
Assign to "Send Certificate Email" node

Google Sheets OAuth2

Create new Google Sheet: "Certificates Log"
Add column headers in Row 1:
Certificate ID
Recipient Name
Course
Email
Completion Date
Generated At
Certificate URL
Status
Instructor
Duration
In n8n: Credentials → Gmail OAuth2 (same as above works for Sheets)
Assign to "Log to Google Sheets" node
Select your "Certificates Log" spreadsheet
Select "Sheet1"

3. Activate Workflow

Click the toggle switch in top-right to activate
Copy the Webhook URL from "Certificate Request Webhook" node
Format: https://your-n8n-instance.com/webhook/certificate-generator

4. Configure Your Application

For LMS Integration:
// When course is completed
fetch('https://your-n8n-instance.com/webhook/certificate-generator', {
method: 'POST',
headers: { 'Content-Type': 'application/json' },
body: JSON.stringify({
name: student.fullName,
course: course.title,
date: new Date().toISOString().split('T')[0],
email: student.email,
instructor: course.instructor,
duration: course.duration
})
});

For Zapier/Make.com:
Trigger: Course completed
Action: Webhooks → POST
URL: Your webhook URL
Body: Map fields to JSON format

5. Test the Workflow

Send test request:
curl -X POST https://your-n8n-instance.com/webhook/certificate-generator \
-H "Content-Type: application/json" \
-d '{
"name": "Test User",
"course": "Test Course",
"date": "2025-10-04",
"email": "[email protected]"
}'

Verify:
Email validation passes
Certificate generated successfully
Image created at HTMLcsstoImage
Email delivered to inbox
Entry logged in Google Sheets

How It Works

Webhook Trigger → Receives POST request with certificate data
Email Validation → VerifiEmail checks RFC, MX records, disposable status
Field Validation → Ensures name, course, date present and email valid
Data Combination → Merges webhook data with validation results
HTML Generation → Creates styled certificate with dynamic content
Image Conversion → HTMLcsstoImg renders 1200x850px PNG
Email Delivery → Gmail sends professional template with download link
Database Logging → Google Sheets records all certificate details
Error Handling → Catches failures and stops invalid requests

Processing Time: 5-10 seconds per certificate

API Reference

Endpoint
POST /webhook/certificate-generator
Content-Type: application/json

Required Fields
{
"name": "string", // Full name of recipient
"course": "string", // Course or program name
"date": "YYYY-MM-DD", // Completion date
"email": "string" // Recipient email address
}

Optional Fields
{
"instructor": "string", // Instructor name (default: "Program Director")
"duration": "string", // Course duration (e.g., "40 hours")
"certificateId": "string" // Custom ID (auto-generated if not provided)
}

Success Response
{
"success": true,
"message": "Certificate generated and sent successfully",
"certificateId": "CERT-1728000000-ABC123",
"certificateUrl": "https://hcti.io/v1/image/xyz123"
}

Error Response
{
"success": false,
"error": "Missing required fields: name, course, date, or valid email"
}

Customization

Certificate Design

Edit the "Generate HTML Certificate" Code node:

Change Brand Colors:
// Background gradient
background: linear-gradient(135deg, #YOUR_COLOR_1 0%, #YOUR_COLOR_2 100%);

// Border color
border: 3px solid #YOUR_BRAND_COLOR;

Add Company Logo:




Modify Fonts:
@import url('https://fonts.googleapis.com/css2?family=Your+Font&display=swap');
font-family: 'Your Font', sans-serif;

Email Template

Edit the "Send Certificate Email" node message:

Update Company Info:
© 2025 Your Company Name
Contact: [email protected]

Change Header Color:
.header {
background: linear-gradient(135deg, #YOUR_COLOR_1, #YOUR_COLOR_2);
}

Certificate ID Format

In "Generate HTML Certificate" node:
// Custom format: COURSE-YEAR-NUMBER
const certId = ${data.course.substring(0,3).toUpperCase()}-${new Date().getFullYear()}-${Math.floor(Math.random() * 10000)};

Data Flow

Webhook → Email Validation → Field Validation → Combine Data

Generate HTML → Convert to PNG → Send Email

Log to Sheets → Success Response

Error Handling (if failed)

Expected Output

PNG Certificate Includes:
Branded header with logo/company name
Recipient name in large display font
Course name and duration
Formatted completion date
Instructor signature section
Unique certificate ID
Gold achievement badge
Professional borders and styling

Google Sheets Entry:
Certificate ID
Recipient details
Course information
Completion date and time
Direct link to certificate image
Status: "Sent"

Email Notification:
Professional HTML template
Personalized congratulations message
Direct download button
Certificate details table
LinkedIn sharing encouragement

Performance

Processing Time:** 5-10 seconds per certificate
Daily Capacity:** 250+ certificates (limited by free tier quotas)
Image Resolution:** 1200x850px (print-ready)
File Size:** ~200-400 KB per PNG
Email Delivery:** ~98% success rate

Troubleshooting

Webhook not receiving data
Verify webhook URL is correct
Check n8n workflow is activated
Ensure POST method is used
Validate JSON format

Email validation fails
Use real email domains (not example.com)
Check VerifiEmail API quota
Verify API credentials are correct
Test with gmail.com addresses first

Certificate not generating
Check required fields are present
Verify date format is YYYY-MM-DD
Review "Generate HTML Certificate" node logs
Ensure HTMLcsstoImg API key valid

Image conversion fails
Verify HTMLcsstoImg credits available
Check HTML syntax is valid
Review API response in execution logs
Test HTML locally first

Email not delivered
Confirm Gmail OAuth2 connected
Check recipient email is valid
Review spam/junk folders
Verify Gmail daily limit not exceeded

Google Sheets not updating
Re-authenticate Google Sheets OAuth2
Verify spreadsheet permissions
Check column names match exactly
Ensure sheet exists and is accessible

Best Practices

Test with small batches before production rollout
Monitor API quotas to avoid unexpected failures
Use real email addresses during testing (avoid disposable)
Archive old certificates periodically from Google Sheets
Set up Slack notifications for error monitoring
Validate webhook payload before sending
Document customizations for team reference
Back up Google Sheets regularly
Review email deliverability weekly
Keep credentials secure and rotate periodically

Security Notes

All API credentials encrypted in n8n
Certificate URLs are publicly accessible via direct link
Email validation prevents delivery to fraudulent addresses
Webhook uses HTTPS for secure data transmission
Google Sheets access controlled via OAuth2 permissions
No sensitive data stored in workflow logs

Future Enhancements

PDF output option for formal certifications
Multiple certificate templates (modern, classic, minimalist)
QR code verification system
Batch certificate generation
Multi-language support
Certificate revocation capability
Analytics dashboard
WhatsApp/SMS delivery option
Integration with Notion/Confluence knowledge bases

Support Resources

n8n Documentation
n8n Community Forum
VerifiEmail Docs
HTMLcsstoImage API
Gmail API Reference
Google Sheets API

License

This workflow template is provided as-is for free use and modification under the MIT License. Attribution appreciated but not required.

Version: 1.0.0
Last Updated: October 2025
Compatibility: n8n v1.0.0+

Nodes Used (4)

Code
n8n-nodes-base.code
Gmail
n8n-nodes-base.gmail
Google Sheets
n8n-nodes-base.googleSheets
Slack
n8n-nodes-base.slack