In Flow-driven generation, template selection is handled through the Automator. When the Flow determines which template should be used, retrieve the Automator whose Template Name matches that selection and use the Automator in the Gutenburg generation step.
1. Determine the template in Flow
The Flow can determine a template through user selection or automation logic.
The result should identify the Template Name that should be generated.
2. Retrieve the matching Automator
Use Flow logic to get the Gutenburg Automator where the configured Template Name matches the Template Name selected by the Flow.
3. Pass the Automator into the Gutenburg action
Use the matching Automator Name in the appropriate Gutenburg Flow action together with the record ID or record IDs being processed.
Why Gutenburg uses the Automator layer
The Automator acts as the document-generation configuration between the Flow and the template or templates that should be produced. This lets the Flow determine the business choice while the Automator defines the Gutenburg generation setup.
