Form fields and components
Description of form field types
In Create, forms are made up from form fields. Form fields can serve a single recipe, or they can be made available to all the recipes inside a unit, in which case they're called form components.
Editing a form component causes changes to all the recipes that use the same form component. A form component can be detached, making it into a form field, and enabling the user to make edits that are not propagated to other recipes using the same component.
Overview
These are the types of form fields that are available in Create:
TextField
Date
Select
TextInputMultiple
RecipeReference
AiAssistant
Number
DocumentAttachment
Checkbox
They allow the user to provide different types of input for filling out the template. Wherever relevant, they include the following parameters:
Title
- The name of the field as displayed to the end user.
Key
- The name of the field as displayed to the API, to be used when referencing the input in the Recipe editor. Recommended to use only alphanumerical characters, -, and _. Using other characters might have unforeseen consequences and is being deprecated.
Required
- Checkbox determining whether the field is required or not for the user filling out the form. Not required by default.
Can Capture Answer
- Checkbox determining whether the answer can be captured for later use in Captures.
Validation
- Set whether to validate the format of the input. It has three options:
None
- No validation.
Email
- Check if the input is a valid email address.
Custom
- Provide a regular expression to validate the input against.
- Set whether to validate the format of the input. It has three options:
Form field types
Here are descriptions of each of the form field types, together with any additional parameters required to set them up.
TextField
Form field for short textual responses. For multiline responses, instead use TextInputMultiple.
Date
Form field for inserting a date.
Select
Form field for selecting between defined options.
Additional parameters
Data Source
- A data source containing the options. Optional. Otherwise, list of values to be shown can be provided in Values.
Enable Multiple Selection
- If enabled, the user will be able to respond with multiple options.
Enable Search
- If enabled, the user will be able to search the options by typing in the field.
Search Field Name
- Can only be set if search is enabled.
- A data source column whose value will be passed to the template once the user has selected the row from the data source by picking one of the labels from the label column.
Label Field Name
- Only available if Data Source has been provided.
- A data source column that will be displayed to the user as dropdown options.
Values
- The list of options for the dropdown. The following fields are filled out for each option:
Label
- Value shown to the user.
Key
- Value passed to the recipe when the corresponding label is selected by the user.
- The list of options for the dropdown. The following fields are filled out for each option:
Identifier Field Name
- In silent flow, the column that should be matched on instead of the ID (default).
TextInputMultiple
A larger text field for inserting multiline text.
RecipeReference
Form field for selecting a recipe whose output will be inserted into the current document as a text element.
Additional parameters
Enable Multiple Selection
- Allow the user to select multiple elements to insert.
- If enabled, the elements are returned as an array.
Enable Free Selection
- If enabled, the user is also able to use the recipe picker to select any document from the unit to insert.
- If enabled, the following option becomes available:
- Restrict Free Selection to Folder
- If a folder is selected, the user will only be able to choose an element from this folder.
- Restrict Free Selection to Folder
Recipe references
- Add or remove references to other recipes to the dropdown. The following fields need to be added for each referenced recipe:
Identifier
- Unique identifier of the referenced recipe in the dropdown.
Label
- A string identifier for the recipe that's shown to the user in the dropdown options.
Selected recipe
- Selecting the Select a recipe button opens up the navigator through the recipes in the current unit.
- Add or remove references to other recipes to the dropdown. The following fields need to be added for each referenced recipe:
AiAssistant
Input a prompt for the AI assistant, and receive the response as the text passed as the input data to the recipe. You're able to edit the response manually before insertion.
Additional parameters
AI Prompt
- The prompt that will be used to transform the user input into data that's ultimately passed forward.
Connection
- One of the connections that's been set up, enabling communication with an AI assistant.
Number
Enter a number that's formatted according to a specified culture.
Additional parameters
Use raw number in transformation
- If enabled, the number that the user entered will be passed to the recipe, without styling applied.
- If disabled, styling will be applied to the number before passing it to the recipe.
Number format culture
- The culture that should determine the formatting of the number. US English and Danish are supported. The culture is reflected in the Example under
Number format
.
- The culture that should determine the formatting of the number. US English and Danish are supported. The culture is reflected in the Example under
Number format
DocumentAttachment
Allow your users to attach any number of PDFs from their end to the generated document. Only works when the document is set to be created as a PDF.
Checkbox
A standard checkbox that allows users to provide a true
or a false
value.
Additional parameters
Description
- Optional description text added below the checkbox.
Updated about 22 hours ago