Skip to content

Instantly share code, notes, and snippets.

@johnataylor
Last active March 2, 2016 18:22
Show Gist options
  • Save johnataylor/ad7d21689b79a6134402 to your computer and use it in GitHub Desktop.
Save johnataylor/ad7d21689b79a6134402 to your computer and use it in GitHub Desktop.
Example Workflow Definitions
{
"@id": "http://app.org/workflow/expenses#workflow",
"@type": "BusinessProcess",
"rule": {
"@id": "http://app.org/workflow/expenses#approved",
"@type": "Rule",
"action": {
"@id": "http://app.org/workflow/expenses#send_approval_email",
"message": "Expense claim has been approved."
},
"whenAll": [
{
"@id": "http://app.org/workflow/expenses#belle",
"@type": "Rule",
"action": {
"@id": "http://app.org/workflow/expenses#send_belle_email",
"message": "Thanks Belle"
},
"when": {
"@id": "http://app.org/workflow/expenses#receive_belle_approval",
"data": "belle"
}
},
{
"@id": "http://app.org/workflow/expenses#sebastian",
"@type": "Rule",
"action": {
"@id": "http://app.org/workflow/expenses#send_sebastian_email",
"message": "Thanks Sebastian"
},
"when": {
"@id": "http://app.org/workflow/expenses#receive_sebastian_approval",
"data": "sebastian"
}
}
]
},
"@context": {
"@vocab": "http://schema.azure.org/workflow#"
}
}
{
"@id": "http://app.org/workflow/expenses#receive_belle_approval",
"evaluated": true,
"@context": {
"@vocab": "http://schema.azure.org/workflow#"
}
}
{
"@id": "http://app.org/workflow/expenses#receive_sebastian_approval",
"evaluated": true,
"@context": {
"@vocab": "http://schema.azure.org/workflow#"
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment