Thai Certificate Studio Built on Foxit PDF APIs

Non-Latin documents · Foxit PDF Services

Thai certificates that print right, built on Foxit

I run one-day AI hackathons in rural Thai public schools. Every event needs a personalised Thai certificate for each student, a letter signed by the principal and a public Hall of Fame. I'm building that pipeline on Foxit APIs, and writing the guide to non-Latin documents that Foxit developers don't have yet.

A Thai certificate of achievement for a student, with the APEX Mini AI Hackathon crest, the student's name, team, school, date, award and a QR code to the Hall of Fame.
Rendered by Foxit PDF Services from HTML. Sample data.

Live demo

Type a name, get a print-ready PDF

This page calls the same four Foxit PDF Services steps as the batch script: upload, HTML-to-PDF, poll, download. One certificate takes about 15 seconds.

Use a made-up name. Nothing is stored; the text goes to Foxit only to render this PDF.

Your certificate will appear here.
Thai name in, A4 landscape PDF out.

What I found

Same Thai text, same font, three Foxit routes

Before proposing anything, I ran certificate text through Foxit three ways on my own account. The font is Kanit (Google Fonts, SIL Open Font License) every time.

An empty white area: no Thai text was drawn.
(nothing drawn)
Thai text disappears

Document Generation, Word template

The API reports success and returns a PDF, but every Thai character is missing. The server has no Thai font and falls back without a warning. 0.9 s.

Thai text with vowel and tone marks drawn in the wrong positions.
Glyphs appear, marks misplaced

Document Generation, font embedded in the .docx

Embedding the font (Word's “Embed fonts in the file”) brings the glyphs back and the merge tags work, but vowel and tone marks land in the wrong place and copied text comes out scrambled. 1.0 s.

Correctly shaped Thai text.
Correct and searchable

PDF Services, HTML-to-PDF with the font as @font-face

Marks sit where they belong, and the text copies and searches as real Thai. This is the route the pipeline uses today. About 13 s, because conversion is asynchronous.

Why it matters beyond Thailand. Thai, Lao, Khmer, Burmese and Indic scripts all place vowels and tone marks with OpenType rules. Developers in those markets need to know which Foxit route to use and how to make Word templates work. The project turns these results into a tested guide, plus a reproducible test file for the Document Generation team.

End to end

One school, one print-ready file

CSV of students HTML-to-PDF ×6, four at a time pdf-combine pdf-compress 254 KB · 6 pages

Six certificates in about 50 seconds end to end, each at full A4 landscape size. Foxit's HTML renderer fits pages to A4 portrait, so the template lays the certificate on a portrait sheet turned 90° and the PDF marks the page /Rotate 270: one of the practical tips the article will cover.

Open the sample batch (PDF, 254 KB)

The project

What I'll build and publish with Foxit

PDF Services

Render each certificate from HTML, merge a school's batch with pdf-combine and shrink it with pdf-compress.

Working now, on this page

Document Generation

Thai Word templates for the principal's letter: font embedding, Thai numerals and the official TH Sarabun font, with a shaping test kit.

Tested, results above

eSign

The principal signs the school's letter and certificate batch online.

Used in my API World project, GotPaid

PDF Embed

A public Hall of Fame page where families open their child's certificate.

Planned

MCP Server

An AI agent runs the whole batch from one prompt: “make the certificates for today's school”.

Planned

Real users

Real certificates for real students at upcoming APEX events, with consent. The public repo uses fictional names.

After the build
Open-source repo, MIT Article, 1,500–2,000 words 3-minute demo video About 3 weeks

About me

Thanawin Padsamran

Computer engineer and founder of Harvest Hub Innovations Co., Ltd. in Thailand.

  • APEX Mini AI Hackathon: 3 events in 4 rural public schools in September 2026, with more than 100 students and 40+ teams building working apps in Thai.
  • Two awards at the 2026 ASEAN-Oriented “AI+Cross-Border E-commerce” Innovation Application Competition in Nanning, China, for LaungPro.
  • Built GotPaid at DevNetwork API World 2026 with Foxit PDF Services and eSign.

thanawin@harvesthubs.app · github.com/thanawinhvh · thanawin.dev