Hi folks,
I’m currently working on a requirement where I need to trigger a workflow automatically if any other workflow fails in the tenant.
So far, I’ve attempted to build this using a scheduled trigger that scans workflow executions, but I haven’t been able to achieve the desired result of detecting failures across all workflows reliably.
If anyone has come across a similar use case or has suggestions/workarounds on how to monitor and react to any workflow failure within the tenant, I’d really appreciate your insights.
"name": "workflow failure notification 2",
"description": "",
"modified": "2025-06-13T03:52:22.184936954Z",
"modifiedBy": {
"type": "IDENTITY",
"id": "",
"name": ""
},
"definition": {
"start": "HTTP Request 1",
"steps": {
"End Step - Success": {
"actionId": "sp:operator-success",
"displayName": "",
"type": "success"
},
"HTTP Request 1": {
"actionId": "sp:http",
"attributes": {
"authenticationType": "OAuth",
"headerAuthName": "Authorization",
"method": "get",
"oAuthClientId": "9aa9faa9d9eb4eb08d9f783497462896",
"oAuthClientSecret": "$.secrets.b811f4a2-3960-47e2-ab2f-b1d1e90fadea",
"oAuthCredentialLocation": "oAuthInHeader",
"oAuthScope": "",
"oAuthTokenUrl": "https://partner399.api.identitynow-demo.com/oauth/token",
"requestContentType": "json",
"url": "https://partner399.api.identitynow-demo.com/v2025/workflows",
"urlParams": null
},
"displayName": "",
"nextStep": "Loop",
"type": "action",
"versionNumber": 2
},
"Loop": {
"actionId": "sp:loop:iterator",
"attributes": {
"input.$": "$.hTTPRequest1.body[*].id",
"start": "HTTP Request",
"steps": {
"Compare Timestamps": {
"actionId": "sp:compare-timestamps",
"choiceList": [
{
"comparator": "TimestampGreaterThanEqualsXDay",
"nextStep": "Define Variable",
"variableA.$": "$.hTTPRequest.body[*].startTime",
"variableB": "1"
}
],
"defaultStep": "End Step - Success 1",
"displayName": "",
"type": "choice"
},
"Define Variable": {
"actionId": "sp:define-variable",
"attributes": {
"id": "sp:define-variable",
"variables": [
{
"description": "",
"name": "workflows",
"transforms": [],
"variableA.$": "$.loop.loopInput"
}
]
},
"displayName": "",
"nextStep": "Define Variable 1",
"type": "Mutation"
},
"Define Variable 1": {
"actionId": "sp:define-variable",
"attributes": {
"id": "sp:define-variable",
"variables": [
{
"description": "",
"name": "workflows1",
"transforms": [],
"variableA": "{{$.hTTPRequest2.body.name}}"
}
]
},
"displayName": "",
"nextStep": "End Step - Success 1",
"type": "Mutation"
},
"End Step - Success 1": {
"actionId": "sp:operator-success",
"displayName": "",
"type": "success"
},
"HTTP Request": {
"actionId": "sp:http",
"attributes": {
"authenticationType": "OAuth",
"headerAuthName": "Authorization",
"method": "get",
"oAuthClientId": "9aa9faa9d9eb4eb08d9f783497462896",
"oAuthClientSecret": "$.secrets.a816cfe5-578f-441f-b6a8-27108d86c58b",
"oAuthCredentialLocation": "oAuthInHeader",
"oAuthScope": "",
"oAuthTokenUrl": "https://partner399.api.identitynow-demo.com/oauth/token",
"requestContentType": "json",
"requestHeaders": {},
"url": "https://partner399.api.identitynow-demo.com/v2025/workflows/{{$.loop.loopInput}}/executions",
"urlParams": {
"filters": "status eq \"Failed\""
}
},
"displayName": "",
"nextStep": "HTTP Request 2",
"type": "action",
"versionNumber": 2
},
"HTTP Request 2": {
"actionId": "sp:http",
"attributes": {
"authenticationType": "OAuth",
"headerAuthName": "Authorization",
"method": "get",
"oAuthClientId": "9aa9faa9d9eb4eb08d9f783497462896",
"oAuthClientSecret": "$.secrets.a816cfe5-578f-441f-b6a8-27108d86c58b",
"oAuthCredentialLocation": "oAuthInHeader",
"oAuthScope": "",
"oAuthTokenUrl": "https://partner399.api.identitynow-demo.com/oauth/token",
"requestContentType": "json",
"requestHeaders": {},
"url": "https://partner399.api.identitynow-demo.com/v2025/workflows/{{$.loop.loopInput}}",
"urlParams": null
},
"displayName": "",
"nextStep": "Verify Data Type",
"type": "action",
"versionNumber": 2
},
"Verify Data Type": {
"actionId": "sp:compare-unary",
"choiceList": [
{
"comparator": "IsPresent",
"nextStep": "Compare Timestamps",
"variableA.$": "$.hTTPRequest.body[-1]"
}
],
"defaultStep": "End Step - Success 1",
"displayName": "",
"type": "choice"
}
}
},
"displayName": "",
"nextStep": "Send Email",
"type": "action",
"versionNumber": 1
},
"Send Email": {
"actionId": "sp:send-email",
"attributes": {
"body": "<p>hello </p>\n<p>Here is the recently failed worklfow ID's in the past 24 hr. </p>\n<p>{{$.loop.loopOutput.successfulItems[*].defineVariable1.workflows1}}</p>",
"context": {},
"recipientEmailList": [
"shmi@gmail.com",
"6@gmail.com"
]
},
"displayName": "",
"nextStep": "End Step - Success",
"type": "action",
"versionNumber": 2
}
}
},
"creator": {
"type": "IDENTITY",
"id": "",
"name": ""
},
"trigger": {
"type": "SCHEDULED",
"attributes": {
"cronString": "0 * * * *",
"frequency": "cronSchedule",
"id": "idn:cron-schedule",
"timeZone": "Asia/Calcutta"
}
}
}
I would appreciate any suggestions or alternative approaches to help achieve my requirement. Please let me know.
Thanks!



