Design and ship PDF certificates¤
Issue thousands of signed, secure PDFs and deliver them via branded HTML email — built around a conference certificate-of-attendance workflow; reusable for any event-driven cert generation.
| What it means | |
|---|---|
| signed | Every PDF is digitally signed with a PKCS#12 keystore and cannot be altered. |
| secure | PDF permissions disallow copying text and altering the document. |
| validated on the website | A short URL per cert resolves to a public validation page on the event site. |
| branded HTML delivery | Mailgun-sent emails with inline-CID logo, brand colours, and PDF attached. |
| idempotent retry | Re-running the sender skips already-delivered records and retries failures. |
The pipeline supports three cert types:
- Attendee — driven by a CSV; gets a validation page on the website and a delivery email.
- Masterclass — driven by an XLSX; delivered only by email.
- Speaker — driven by a JSON; one cert per
(speaker, proposal)pair, delivered only by email.
Four-step process¤
- Prepare the source data (see Walkthrough §3).
- Generate signed PDFs per cert type (
run.py --type X). - Preview + smoke-test the emails locally and then to a single test inbox.
- Send for real — Mailgun, branded HTML, PDF attached, persistent retry state.
Each step is independent and can be reviewed before moving on. The complete runbook is the Walkthrough.
Configuration, secrets, source data, and outputs all live under projects/<slug>/. Activate one before running any CLI:
export CERTIFICATE_PROJECT_SLUG=<slug> # name of a projects/<slug>/ dir
Start a new event by copying projects/sample_project and filling in the placeholders.
For correcting a single recipient's name after the fact, reissue.py re-cuts that one cert while keeping the UUID + hash stable, so the recipient's existing email link keeps working.
Main libraries: pypdf + reportlab for cert rendering, endesive for digital signing, httpx for the Mailgun REST client.
Sample artefacts¤
Sample PDF certificate:
Sample validation page on the event website:
Realization¤
Pioneers Hub helps to build and maintain thriving communities of experts in tech and research to share knowledge, collaborate and innovate together.

