Early access. Oomplo is looking for its first pilot companies. Tell us about your documents →

Preparing a template

A template is a Word document (DOCX) with places for data. You prepare it in Word, import it into Oomplo and add the data places in Oomplo's editor; or you start a new template in the editor. Everything Oomplo adds is stored as Word's own elements (content controls), so the file still opens in Word.

Fonts and layout #

Write the template in Word as usual. Oomplo reproduces Word's layout closely (the same lines and pages for ordinary documents). Use the fonts Oomplo ships (Liberation, Noto, Carlito, Caladea and others) or upload your company's fonts in the template report (Upload font, with the licence confirmation). A font that is missing is replaced by one with the same widths and the report says so.

Data #

Each template has data: JSON, an Excel sheet or a CSV file (Data in the toolbar). The data you give the API replaces it. A plain JSON object sent to the API is the main source json.dane1, so a field json.dane1.client.name reads {"client": {"name": "…"}}. Fields and data explains paths, related tables and series with pictures of each case.

ElementHowIn the PDF
Data fieldInsert data, or select text and Turn into a fieldThe value from the data, with the field's formatting
{{client.name}} in the textType itThe value, like a field
Repeated table rowA field of an array item (items[].name) in a table row, or Repeat row…One row per item; header and total rows stay
Repeated paragraphA field of an array item in an ordinary paragraphOne paragraph per item
Repeated groupSelect paragraphs and tables, Repeat for each item…The whole part once per item (e.g. a heading and a table for each client)
FormulaInsert formula (Word's = field): SUM(ABOVE), COUNT(ABOVE), B2*C2, net * 23%Computed after the data is filled in: totals of the rows the data gave
Nested rowsA repeated row of an item's array (clients[].items) inside a group or a repeated rowEach client's own items
Conditional blockSelect paragraphs (or put the caret in a table) and Show when…The paragraphs, row or table only when the condition holds
Signature lineWord's Insert → Signature line, or the toolbar buttonAn empty PDF signature field with the signer's role

Formats. Click a field to choose how its value is written: dates (31.01.2026, 31 January 2026, Saturday, 31 January 2026, ISO, with the time), numbers (1 234,50, an amount in złoty, 1,234.50, a whole number), upper or lower case, or Word's own field switches for anything else: \@ "d MMMM yyyy", \# "# ##0,00 zł", \* Upper, \b "Street " (text before a value that is not empty). The dialog previews the value from the template's data. Month and day names follow the field's language (Polish, English, German). A marker takes a format after its path: {{total \# "# ##0.00"}}. Send dates as 2026-11-22 (or with a time, 2026-11-22T14:05:00Z) and numbers as JSON numbers; the template writes them the way the reader expects.

Pictures. In Insert logo / picture, give a path of the data (Choose from the data…) such as json.dane1.logo: the picture you choose (or a grey box) becomes a frame, and the PDF shows the data's PNG or JPEG in it, as large as fits with its proportions kept. Send the image as "logo": "data:image/png;base64,iVBORw0…" (or plain base64). A path of an array item (people[].photo) in a repeated row gives each item its photo. In Word the frame is a picture content control. Pictures you use often (logos, signatures, product photos) can be kept with the template: in Template data → Images of the template add PNG or JPEG files, and the data name one as "logo": "magazyn:logo.png" (in JSON, an Excel or CSV column, or the API's data). Double-click a picture of the data to change its path.

Codes. Insert a QR code or barcode adds Word's DISPLAYBARCODE field: a QR code (e.g. a payment address), Code 128 (an invoice or parcel number) or EAN-13, with a fixed value or a value of the data. Word for Windows draws such a code itself; Word for Mac shows the saved picture.

Without data. In the same dialog, Without data sets the text a field shows when the data has no value or an empty one (e.g. "to be agreed").

A value missing in the data stops the PDF with a message naming every missing field at once (send "missing": "empty" to leave them empty instead), so a mistake does not reach a customer. The template's schema (GET /api/templates/{id}/schema, or oomplo schema template.docx) lists its fields and gives an example data file that fills all of them.

Conditions #

Show when… keeps a block when a value of the data is filled in, is empty, equals, differs from, is greater or less than a value. Numbers compare as numbers (also 1 234,50), other values as text; a value missing in the data is empty. Word shows the block always; only the PDF leaves it out. Example: serial-letter.docx picks "Dear Ms …", "Dear Mr …" or "Dear Customer," from title.

Word mail merge templates #

A Word mail merge document (fields MERGEFIELD Name) opens in Oomplo as a template: every merge field becomes a data field json.seria.Name, with Word's switches (\b, \f, \@ dates, \# numbers, \* letter case). A paragraph made only of empty merge fields is left out, as Word does. Generate from a file then makes the same copies as Word's merge. The saved DOCX keeps Word's fields.

Sample data sets and publishing #

Save named sample data sets (Sets… in the preview: typical, long names, many items). Publish makes a new version of the template that the API uses; before publishing Oomplo makes a PDF with every sample set and tells you when one fails. Editing afterwards changes only the draft. Restore brings an older version back.

Checklist #

  • Every field reads a path that exists in your data (see the schema).
  • Long values: try a sample set with the longest names you have.
  • Tables with many rows: try a sample set with many items; the header row repeats on every page when it is marked as a header row in Word.
  • Signature lines have a role (e.g. "Client"); the signer's name and e-mail can come from the data.