PDF Export Workflow
A PDF export is a synchronous workflow that starts from a webhook event, writes a file with action/export, and returns
that file with action/viewFile.
Minimal flow
Section titled “Minimal flow”{ "identifier": "ExamplePdfExport", "title": "Export example as PDF", "async": false, "entry": "onExportPdf", "elements": [ { "name": "onExportPdf", "type": "event/webhook", "options": { "module": "example_module", "title": "Als PDF exportieren", "show_in_button_bar": false }, "to": { "default": { "exportPdf": ["default"] } } }, { "name": "exportPdf", "type": "action/export", "options": { "type": "pdf", "filename": "example.pdf", "content": "example_pdf_content", "store_module": "files", "view_module": "views" }, "to": { "default": { "viewPdf": ["default"] } } }, { "name": "viewPdf", "type": "action/viewFile" } ], "events": [ { "identifier": "onExportPdf", "type": "webhook", "module": "example_module", "title": "Als PDF exportieren", "show_in_button_bar": false } ]}Views and data
Section titled “Views and data”The content, header, and footer options reference Brezel views. Create or reuse those views before the workflow is
expected to render successfully.
Use view_data or export options when the template needs derived values. Keep filenames deterministic enough for users
to understand them, but avoid unsafe clear-name overwrites unless the system explicitly needs them.
Implementation checklist
Section titled “Implementation checklist”- Add a UI trigger with the
buttonscomponent orshow_in_button_bar. - Create the workflow with
async: false, becauseaction/viewFilereturns an HTTP response. - Check the current
event/webhook,action/export, andaction/viewFileelement specs before writing the workflow. - Add or reuse required views/templates in the same draft if they do not exist yet.
- Refresh the preview only after the button, workflow, and required view references are in place.