certificate-generator

from dkyazzentwatwa/chatgpt-skills

My comprehensive, tested + audited, library of skills to use for ChatGPT.

7 stars0 forksUpdated Dec 17, 2025
npx skills add https://github.com/dkyazzentwatwa/chatgpt-skills --skill certificate-generator

SKILL.md

Certificate Generator

Create professional certificates for courses, achievements, events, and awards. Supports batch generation from CSV files with customizable templates and branding.

Quick Start

from scripts.certificate_gen import CertificateGenerator

# Single certificate
cert = CertificateGenerator()
cert.set_title("Certificate of Completion")
cert.set_recipient("John Smith")
cert.set_achievement("Python Programming Course")
cert.set_date("December 14, 2024")
cert.generate().save("certificate.pdf")

# Batch from CSV
CertificateGenerator.batch_generate(
    "students.csv",
    template="achievement",
    title="Certificate of Completion",
    achievement="Data Science Bootcamp",
    output_dir="./certificates/"
)

Features

  • Professional Templates: Modern, classic, elegant, minimal styles
  • Custom Branding: Logo, colors, signatures
  • Batch Generation: Create hundreds of certificates from CSV
  • Dynamic Fields: Name, date, achievement, instructor, etc.
  • Signatures: Text or image signatures with titles
  • Certificate IDs: Auto-generated unique identifiers
  • Export: PDF output, landscape or portrait

API Reference

Initialization

cert = CertificateGenerator()

# With template
cert = CertificateGenerator(template="elegant")

Certificate Content

# Title
cert.set_title("Certificate of Completion")
cert.set_title("Certificate of Achievement")

# Recipient name
cert.set_recipient("Jane Doe")

# Achievement/course/event
cert.set_achievement("Advanced Python Programming")
cert.set_achievement("for outstanding performance in the 2024 Hackathon")

# Description (optional)
cert.set_description(
    "Has successfully completed the 40-hour intensive course "
    "covering advanced topics in Python programming."
)

# Date
cert.set_date("December 14, 2024")
cert.set_date_auto()  # Use today's date

# Certificate ID (auto-generated if not set)
cert.set_certificate_id("CERT-2024-001")

Branding

# Organization name
cert.set_organization("Acme Academy")

# Logo
cert.set_logo("logo.png")
cert.set_logo("logo.png", width=200)

# Colors
cert.set_colors(
    primary="#1e3a5f",    # Main color (title, borders)
    accent="#c9a227",     # Accent color (decorations)
    text="#333333"        # Text color
)

Signatures

# Text signature
cert.add_signature(
    name="Dr. Jane Smith",
    title="Program Director"
)

# Multiple signatures
cert.add_signature("John Doe", "CEO")
cert.add_signature("Jane Smith", "Head of Training")

# Image signature
cert.add_signature(
    name="Dr. Jane Smith",
    title="Program Director",
    signature_image="signature.png"
)

Templates

# Available templates
cert.set_template("modern")    # Clean, contemporary design
cert.set_template("classic")   # Traditional, formal design
cert.set_template("elegant")   # Decorative borders, serif fonts
cert.set_template("minimal")   # Simple, clean design
cert.set_template("academic")  # University/school style

# Orientation
cert.set_orientation("landscape")  # Default
cert.set_orientation("portrait")

Generation and Export

# Generate certificate
cert.generate()

# Save to PDF
cert.save("certificate.pdf")

# Get PDF bytes
pdf_bytes = cert.to_bytes()

Batch Generation

From CSV

# CSV with recipient data
CertificateGenerator.batch_generate(
    csv_file="students.csv",
    template="achievement",
    title="Certificate of Completion",
    achievement="Python Fundamentals",
    organization="Code Academy",
    output_dir="./certificates/"
)

CSV Format

name,date,course,certificate_id
John Smith,2024-12-14,Python 101,CERT-001
Jane Doe,2024-12-14,Python 101,CERT-002
Bob Johnson,2024-12-14,Python 101,CERT-003

Programmatic Batch

recipients = [
    {"name": "John Smith", "course": "Python 101"},
    {"name": "Jane Doe", "course": "Data Science"},
    {"name": "Bob Johnson", "course": "Machine Learning"}
]

for r in recipients:
    cert = CertificateGenerator(template="modern")
    cert.set_title("Certificate of Completion")
    cert.set_recipient(r["name"])
    cert.set_achievement(r["course"])
    cert.set_date_auto()
    cert.generate()
    cert.save(f"certificates/{r['name'].replace(' ', '_')}.pdf")

CLI Usage

# Single certificate
python certificate_gen.py \
    --recipient "John Smith" \
    --title "Certificate of Completion" \
    --achievement "Python Course" \
    --output certificate.pdf

# With options
python certificate_gen.py \
    --recipient "Jane Doe" \
    --title "Certificate of Achievement" \
    --achievement "Excellence in Data Science" \
    --organization "Data Academy" \
    --template elegant \
    --logo logo.png \
    --output achievement.pdf

# Batch from CSV
python certificate_gen.py \
    --batch students.csv \
    --title "Certificate of Completion" \
    --achievement "Bootcamp Graduate" \
    --template mod

...
Read full content

Repository Stats

Stars7
Forks0