Connect forms to document templates

Create and manage templates

A template acts as a blueprint containing placeholders for your form's answers. You can attach one or more templates to a single form to generate multiple documents in Contractbook simultaneously.

  • Log in to the form editor, and create a new form or use an existing one. For more information on how to create forms please follow this guide.

  • Log in to your Contractbook account and click on the automations tab.

  • Click on the blue button in the top right corner: "Create new automation"

  • Once inside the automation select the trigger "Form is completed" all the way in the bottom.

  • Configure the trigger to work whenever a form of the specified type is completed by selecting the desired form in the dropdown.

  • After configuring the trigger select the action: "Create a draft", this will connect your form to a whichever template you choose to configure in the "Create a draft" step.

  • After the form and template has been linked the questions in the form needs to be mapped to the data fields in the template to ensure that whatever is answered in the form is correctly displayed when the final draft is created.

Map form answers to document placeholders

To link form answers to a template, you must insert the exact form field values into your workflow "Create a draft" step.

  1. Parties section:

    1. You can add one or more parties from the automation to the template by filling out the party details and optionally adding more parties by clicking "Add new party"

    2. When you click on the party details you can map form answers by selecting an input field -> Variables -> Form is completed -> the question answer that should be mapped.

  1. Contract body:

    1. Select the data tab in the in the top of the "Create a draft" configuration.

    2. Click on a data field input box and select "Form is completed".

    3. You can now select the appropriate question answer that should be mapped to that specific datafield.

Set up conditional templates

When using conditional templates, you can implement different logic rules to generate the final documents depending on how the respondent answers the form.

  • Double-click on the field, text, or other section of the template body which you want to display based on conditions.

  • Click on Show with conditions button which appears automatically on top of the selected body section.

  • This will open the Conditions settings for the selected data in the Conditions sidebar in the right-hand side of the template.

  • Set a rule, such as "Generate this template if [field] equals [value]".

  • Combine multiple rules using AND or OR logic. If you pick AND logic, all rules you have listed will have to be true, while the OR logic indicates that one of the listed rules must be met to apply the condition.

  • To define the type of applied logic, use the dropdown menu to Show text if All (AND logic) or any (OR logic) are met.

  • Click on + Add condition to list several conditions under the selected logic type.

  • Click on Add group button to create separate logic groups which will apply to the same selected from the template body section which will appear conditionally in the generated document.

  • Leave the conditions completely blank if the template should always generate a document regardless of the answers provided.

Helpful guides:

Did you find this guide helpful?