@wmfs/tymly
Version:
A framework for building and sharing workflows in Node.js
64 lines (63 loc) • 1.28 kB
JSON
{
"Comment": "Find a cat.",
"StartAt": "FindingRupert",
"version": "1.0",
"States": {
"FindingRupert": {
"Type": "Task",
"Resource": "module:finding",
"ResourceConfig": {
"modelId": "cat",
"filter": {
"where": {
"name": {
"equals": "Rupert"
}
}
}
},
"ResultPath": "$.catDocFromStorage",
"Next": "CountingRupert"
},
"CountingRupert": {
"Type": "Task",
"Resource": "module:findingCount",
"ResourceConfig": {
"modelId": "cat",
"filter": {
"where": {
"name": {
"equals": "Rupert"
}
}
}
},
"ResultPath": "$.countCatDocFromStorage",
"Next": "FindingWilfred"
},
"FindingWilfred": {
"Type": "Task",
"Resource": "module:finding",
"ResourceConfig": {
"modelId": "cat",
"filter": {
"where": {
"name": {
"equals": "$.catName"
}
}
}
},
"ResultPath": "$.anotherCatDocFromStorage",
"End": true
}
},
"restrictions": [
{
"roleId": "$authenticated",
"allows": [
"*"
]
}
]
}