Start Sub Task
Summary
- Internal name:
StartSubTask - Category: Workflow Control
- Purpose: Mark the entry point of a nested sub-workflow, embedded under a Connector task's
"do"key. - Task type: Workflow Control
Compatibility
-
Minimum AndroMate version:
1.1.0 -
Maximum AndroMate version:
1.1.0 -
Minimum Android:
Android 13 (API 33) -
Maximum Android tested:
Android 16 (API 36) -
Supported manufacturers:
- Samsung (One UI 6.x / 7.x / 8.x)
- Other manufacturers - not supported yet (Xiaomi HyperOS and Google Pixel are being adapted)
-
Required permissions:
- None
Detailed description
The Start Sub Task is the mandatory entry point of a nested sub-workflow - the "do" object embedded inside a Connector task like Iterate or ForEachElement. It is the StartSubTask-equivalent of the outer workflow's own Start node, scoped to that one "do" block only.
It is not interchangeable with Start:
Start |
StartSubTask |
|
|---|---|---|
| Used in | The top-level workflow, exactly once | Each "do" sub-workflow, exactly once |
Declares variables |
Yes | No - the sub-workflow reads/writes the same shared context as the outer workflow |
Configures Time_out / exec_policy |
Yes | No - those apply only to the whole workflow run, set once at the top |
| Parameters | Time_out, exec_policy, variables |
None - only an "id" |
Like Start, this task performs no action during execution (it returns immediately) - it is purely a marker that tells the engine where to begin traversing that particular sub-workflow's graph.
Input parameters
This task has no input parameters beyond the "id" every node needs.
Output parameters
This task produces no output variables. It returns VoidResult.
Exceptions
The Start Sub Task does not raise any exceptions.
Execution flowchart
flowchart TD
Connector([Connector task, e.g. Iterate]) --> Sub([StartSubTask\nsub-workflow entry point])
Sub --> Body[Sub-workflow body]
Body --> End([do's own End])
End --> Continue([Connector task continues\nto its outer 'to' link])
style Connector fill:#e3f2fd
style Sub fill:#f3e5f5
style Continue fill:#c8e6c9
How it works:
- A Connector task (
Iterate,ForEachElement) begins running its"do"sub-workflow. - The engine looks up the node with the
StartSubTasktype inside that"do"object and begins traversal there. StartSubTaskperforms no logic - the engine immediately moves to whichever node its own"do"-scopedLinkspoint to.- Traversal continues within the sub-workflow's own
Links/End, independent of the outer graph, until it reaches the sub-workflow's ownEnd. - Once that pass finishes, control returns to the Connector task, which repeats the sub-workflow (per its own looping rule) or continues to the outer graph's
"to"link.
Complete JSON example
{
"Start": [
{ "id": "1000", "variables": [{ "variableName": "$i", "variableValue": "0", "is_kpi": false }] }
],
"Iterate": [
{
"id": "1001",
"iteration_variable_input": "$i",
"start_index": 1,
"end_index": 3,
"do": {
"StartSubTask": [{ "id": "10001" }],
"TextReport": [{ "id": "10002", "texte": "i = $i", "texte_type": 0 }],
"End": [{ "id": "10003" }],
"Links": [
{ "from": "10001", "to": "10002" },
{ "from": "10002", "to": "10003" }
]
}
}
],
"End": [{ "id": "1002" }],
"Links": [
{ "from": "1000", "to": "1001" },
{ "from": "1001", "to": "1002" }
]
}