Actions21
- Conversion Actions
- Document Builder Actions
Document Builder → Mail Merge
AI-generatedSummary
Generates one document for each record by filling matching {{key}} placeholders in a template file. Each output is named with a numbered suffix and returned as a separate n8n item.
Inputs
- File URL (required) — URL of the template document, reachable from the ONLYOFFICE Document Server.
- Records (JSON Array) (required) — Array of objects; each object supplies values for matching {{key}} placeholders in the template and produces one document.
- Output Mode — Choose File Data (default) to download each document into the configured binary field, or URL Only to return its Document Server URL without downloading.
- Output Format — Document format to generate: DOCX (default), PDF, or PPTX.
- Output File Name — Base filename without extension. Outputs receive a 1-based suffix, such as output_1.docx.
- Put Output File in Field — Binary field name for generated files when Output Mode is File Data; defaults to data.
Output shape
A list of items, one per record.
Each item’s JSON includes success, fileName, zero-based recordIndex, the source record, and outputUrl. In File Data mode it also includes the generated file in the configured binary field; in URL Only mode no binary data is returned. An empty records array produces no output items. A merge error or missing output file raises an operation error.