BPM step types

The step types JSON describes the step types that can be involved a process. Generally a project will use the standard Core BPM step types, augmented with some solution-specific step types, and reuse this for all processes. See BPM step type reference for a quick reference to the Core BPM step types.

The JSON is an array, each item of which specifies one step type.

[
{
"reference": "stepTypeReference",
"name": "stepTypeName",
"script": "stepTypeScript",
"userTask": true|false,
"properties": [
{
"reference": "propertyReference",
"dataType": "string|number|boolean|object|array|any",
"value": defaultValue
}, ...
],
"subStepTypes": ["subStep1", "subStep2", ...]
}, ...
]
reference Reference used to refer to the step type in the process JSON.
name Name for the step type
script Node reference of the step type script.
properties A list of properties required by steps of these types (these form the config properties in the process definition).
properties[].reference Reference for the property, i.e. config property name.
properties[].dataType Data type, used to validate/convert incoming properties. A data type of "any", which is the default, means that data type can be anything (though it may be validated later).
properties[].value Default value for the property. This can be overridden in the BPM definition or the independent properties.
subStepTypes

This allows a number of step types to be represented by a single step type. For example, the Form step type may require a Set to create the form in the first place. This could be represented by a step type for "openForm", something like this:

[
{
"reference": "openForm",
"name": "Create and open a form",
"attributes": [
{
"reference": "dataReference",
"type": "string",
"defaultValue": "data"
},
{
"reference": "form",
"type": "object"
}
],
"subStepTypes": [
"createForm",
"openForm"
]
},
{
"reference": "createForm",
"name": "Create a form",
"script": "library.worker.SetStepType",
"properties": [
{
"reference": "dataReference",
"type": "string"
},
{
"reference": "data",
"type": "object",
"value":"${form}"
}
]
},
{
"reference": "openForm",
"name": "Open the form",
"script": "library.worker.FormStepType",
"properties": [
{
"reference": "dataReference",
"type": "string"
}
]
}
]

The properties are defined at the group level and the sub level. This allows all the properties for all the sub-steps to be set in one place.

properties can use placeholders which refer to properties defined at a higher level. For example ${form} is used to set the data to the form property defined at a higher level.

Use the Object List Merge type to hold BPM step types. This allows different lists of step types to be merged, and allows solution-specific step types to be merged with the Core BPM step types.

Sub step type items

Instead of a simple list of references in a subStepTypes, you can provide an array of items that specify the sub steps in more detail. Each item should be an object with the following properties.

reference Sub step type reference.
when A condition that should evaluate for true at compile time to indicate that the step should be included. Optional, defaults to true.
suffix

A suffix to be added to the bpm step reference to provide an executable process step name for the step. Optional, defaults to no process step name generated.

The first sub step to be generated always takes the BPM step reference as the name of the executable process step, i.e. suffix doesn't work on the first item in the list.

flows

A list of flows to be applied for the sub step as the source. The flows can refer to subling sub steps using the ${step} runtime parameter and their suffix, e.g. "target":"${step}_confirm".

If omitted or null, a "next": true flow is generated to the next step if there is one, otherwise a "next": false.

If an empty array, no next clauses are generated.

name

A name to use for the sub step. This can refer to the name of the BPM step using the runtime parameter ${step.name}, e.g. "${step.name} confirm".

Optional, defaults to the name of the BPM step.