Virtual Steps
What is a virtual step?
Virtual steps are a feature in ACE that enables users to create their own custom step with a unique form and associated flow. Virtual steps empower users to create and share steps that are not supported by ACE out of the box.
When creating a flow, virtual steps are not much different from core steps. They receive properties as provided in the form and then execute some underlying logic (the attached flow). The resulting data is either placed into the document target path or discarded if no target path is specified.
Defining a virtual step
The basic properties of a virtual step are
- Flow - The flow that will handle the step logic.
- Form schema - A JSON schema of the step form (ACE will visualize the form based on the JSON schema for you). The data defined by this schema is then passed to the attached flow.
It is also possible to define:
- Display name - How to display the step name within ACE. Supports additional characters (emojis ❤️, symbols ⇄, spaces, etc.) which are not allowed in filename.
- Form schema widgets (advanced use) - Custom widgets for the JSON schema nodes (see: uiSchema object).
Sample usage
For reference, we will be using a workspace with a pre-defined virtual step. Feel free to try it out by importing the following workspace to a branch in your repository. Workspace with virtual step.
Defining a virtual step
We are using a pre-defined flow 'CreatePersonModel' and schema 'PersonModelForm', both available in the attached workspace. We are also describing the 'comment' field in the schema to be treated as a textarea.
Virtual step in a flow
Virtual steps can be used freely alongside any other core step
- Create a new step and find the virtual step in the step dropdown
- Select it and edit step properties info
Make sure to define a target path as we have done in our example. Step 'create person model' will create a person object which we want to place into the first property of 'result.persons' array. Otherwise, the step would only be useful as a side effect
- After filling in the properties of the virtual step the flow can be executed as usual