Actions42
- Bulk Render Actions
- Document Actions
- Document Tool Actions
- File Actions
- Render Actions
Document Tool → Replace Placeholders
AI-generatedSummary
Replace placeholder tags in a DOCX or ODT document with provided values and convert to the desired output format.
Inputs
- replaceFileId (required) — ID of the DOCX or ODT file containing placeholders. Use File > Upload to get a file ID.
- variables (required) — Map of placeholder names to values. Use string for text, or an object with type for images/lists/tables.
- outputFormat — Output format for the converted document. Available: PDF, DOCX, ODT. Default: pdf.
- waitForCompletion — Whether to wait for the tool job to complete before returning. Default: true.
- downloadOutput — Whether to automatically download the output file as binary data after completion. Only effective when waitForCompletion is true. Default: false.
Output shape
If waitForCompletion is true and downloadOutput is true and the job completes successfully, the output file is returned as binary data with metadata. Otherwise, the tool job result (job status and metadata) is returned as JSON data.
The operation POSTs to /tools/docx/replace-placeholders, then optionally polls for job completion and downloads the result file if requested.
Examples
Example 1: Replace placeholders in a DOCX file and return the completed PDF as binary data.
Set replaceFileId to the DOCX file ID, variables to an object mapping placeholder names to values, outputFormat to 'pdf', waitForCompletion to true, and downloadOutput to true.