Dear Gents,
I have a complex workflow which I wanted to adjust, I wanted to have an “string operator” action changed by using the Variable Selector.
But for some days, it is throwing an strange exception now.
If I try to test the workflow, it throwing sometimes following exception.
Find in here the workflow export, the issue occurs with “Compare Strings 13”:
{
"name": "LXS - YYY - Approval Workflow",
"description": "",
"modified": "2026-01-09T13:02:47.551671065Z",
"modifiedBy": {
"type": "IDENTITY",
"id": "1a0910985fe34c87a8dfe0d886aef6b0",
"name": "Test Test"
},
"definition": {
"start": "Get Pending Access Requests",
"steps": {
"End Step - Success 2": {
"actionId": "sp:operator-success",
"displayName": "",
"type": "success"
},
"Get Pending Access Requests": {
"actionId": "sp:get-pending-approvals",
"attributes": {
"filter": "accessRequestId eq \"ff5eb033ef8249ec80153ccfe938aabe\"",
"id": null
},
"description": null,
"displayName": "",
"nextStep": "Loop",
"type": "action",
"versionNumber": 1
},
"Loop": {
"actionId": "sp:loop:iterator",
"attributes": {
"context.$": "",
"input.$": "$.getPendingAccessRequests.pendingApprovals",
"start": "Define Variable 2",
"steps": {
"Approve Access Request": {
"actionId": "sp:approve-request",
"attributes": {
"approvalId.$": "$.loop.loopInput.id",
"comment": "Auto approval by successful training: {{$.hTTPRequest.body[0].name}}"
},
"displayName": "",
"nextStep": "Compare Strings 7",
"type": "action",
"versionNumber": 1
},
"Compare Numbers 1": {
"actionId": "sp:compare-numbers",
"choiceList": [
{
"comparator": "NumericGreaterThanEquals",
"nextStep": "Compare Strings 3",
"variableA.$": "$.hTTPRequest.body.length()",
"variableB": 1
}
],
"defaultStep": "Send Email 2",
"displayName": "Role has audienceType entitlement?",
"type": "choice"
},
"Compare Strings": {
"actionId": "sp:compare-strings",
"choiceList": [
{
"comparator": "StringStartsWith",
"nextStep": "Compare Strings 1",
"variableA.$": "$.loop.loopInput.name",
"variableB": "Workgroup:d15763f9-1c12-46f1-a06b-9d7350f93c75"
}
],
"defaultStep": "End Step - Success 1",
"displayName": "Is YYY approval?",
"type": "choice"
},
"Compare Strings 1": {
"actionId": "sp:compare-strings",
"choiceList": [
{
"comparator": "StringEquals",
"nextStep": "Send Email 9",
"variableA.$": "$.defineVariable2.isDebugMode",
"variableB": "true"
}
],
"defaultStep": "Define Variable",
"description": null,
"displayName": "Is Debug Mode?",
"type": "choice"
},
"Compare Strings 10": {
"actionId": "sp:compare-strings",
"choiceList": [
{
"comparator": "StringEquals",
"nextStep": "Send Email 8",
"variableA.$": "$.defineVariable2.isDebugMode",
"variableB": "true"
}
],
"defaultStep": "End Step - Success 1",
"displayName": "Is Debug Mode?",
"type": "choice"
},
"Compare Strings 11": {
"actionId": "sp:compare-strings",
"choiceList": [
{
"comparator": "StringContains",
"nextStep": "Define Variable 1",
"variableA.$": "$.getAccess.accessItems[*]",
"variableB": "$.hTTPRequest.body[0].id"
}
],
"defaultStep": "Compare Strings 13",
"displayName": "",
"type": "choice"
},
"Compare Strings 12": {
"actionId": "sp:compare-strings",
"choiceList": [
{
"comparator": "StringContains",
"nextStep": "Get Access",
"variableA.$": "$.getIdentity.attributes.cloudLifecycleState",
"variableB": "active"
}
],
"defaultStep": "End Step - Success 1",
"displayName": "Is Identity Active?",
"type": "choice"
},
"Compare Strings 13": {
"actionId": "sp:compare-strings",
"choiceList": [
{
"comparator": "StringEquals",
"nextStep": "Send Email 7",
"variableA.$": "$.defineVariable2.isDebugMode",
"variableB": "true"
}
],
"defaultStep": "HTTP Request 2",
"displayName": "Is Debug Mode?",
"type": "choice"
},
"Compare Strings 2": {
"actionId": "sp:compare-strings",
"choiceList": [
{
"comparator": "StringEquals",
"nextStep": "Send Email 10",
"variableA.$": "$.defineVariable2.isDebugMode",
"variableB": "true"
}
],
"defaultStep": "HTTP Request",
"displayName": "Is Debug Mode?",
"type": "choice"
},
"Compare Strings 3": {
"actionId": "sp:compare-strings",
"choiceList": [
{
"comparator": "StringEquals",
"nextStep": "Send Email 11",
"variableA.$": "$.defineVariable2.isDebugMode",
"variableB": "true"
}
],
"defaultStep": "Get Identity",
"displayName": "Is Debug Mode?",
"type": "choice"
},
"Compare Strings 4": {
"actionId": "sp:compare-strings",
"choiceList": [
{
"comparator": "StringEquals",
"nextStep": "Approve Access Request",
"variableA.$": "$.defineVariable5.curriculumResult",
"variableB.$": "$.hTTPRequest.body[0].name"
}
],
"defaultStep": "Compare Strings 8",
"displayName": "Has curriculum done?",
"type": "choice"
},
"Compare Strings 5": {
"actionId": "sp:compare-strings",
"choiceList": [
{
"comparator": "StringEquals",
"nextStep": "Send Email 5",
"variableA.$": "$.defineVariable2.isDebugMode",
"variableB": "true"
}
],
"defaultStep": "HTTP Request 4",
"displayName": "Is Debug Mode?",
"type": "choice"
},
"Compare Strings 6": {
"actionId": "sp:compare-strings",
"choiceList": [
{
"comparator": "StringEquals",
"nextStep": "Send Email",
"variableA.$": "$.defineVariable2.isDebugMode",
"variableB": "true"
}
],
"defaultStep": "Compare Strings 9",
"displayName": "Is Debug Mode?",
"type": "choice"
},
"Compare Strings 7": {
"actionId": "sp:compare-strings",
"choiceList": [
{
"comparator": "StringEquals",
"nextStep": "Send Email 3",
"variableA.$": "$.defineVariable2.isDebugMode",
"variableB": "true"
}
],
"defaultStep": "End Step - Success 1",
"displayName": "Is Debug Mode?",
"type": "choice"
},
"Compare Strings 8": {
"actionId": "sp:compare-strings",
"choiceList": [
{
"comparator": "StringEquals",
"nextStep": "Send Email 4",
"variableA.$": "$.defineVariable2.isDebugMode",
"variableB": "true"
}
],
"defaultStep": "End Step - Success 1",
"displayName": "Is Debug Mode?",
"type": "choice"
},
"Compare Strings 9": {
"actionId": "sp:compare-strings",
"choiceList": [
{
"comparator": "StringEquals",
"nextStep": "Approve Access Request",
"variableA.$": "$.defineVariable5.certResult",
"variableB.$": "$.hTTPRequest.body[0].name"
}
],
"defaultStep": "Compare Strings 4",
"displayName": "Has certificate done?",
"type": "choice"
},
"Define Variable": {
"actionId": "sp:define-variable",
"attributes": {
"id": "sp:define-variable",
"variables": [
{
"description": "",
"name": "entitlementsUrl",
"transforms": [
{
"id": "sp:transform:concatenate:string",
"input": {
"variableB.$": "$.loop.loopInput.requestedObject.id"
}
},
{
"id": "sp:transform:concatenate:string",
"input": {
"variableB": "/entitlements?filters=attribute eq \"audienceTypes\""
}
},
{
"id": "sp:transform:replace:string",
"input": {
"pattern": "\\s",
"replacement": "%20"
}
}
],
"variableA": "https://YYY-sb.api.identitynow.com/beta/roles/"
}
]
},
"displayName": "Set entitlement url",
"nextStep": "Compare Strings 2",
"type": "Mutation"
},
"Define Variable 1": {
"actionId": "sp:define-variable",
"attributes": {
"id": "sp:define-variable",
"variables": [
{
"description": "",
"name": "getCurriculumURL",
"transforms": [
{
"id": "sp:transform:replace:string",
"input": {
"pattern": "user-name",
"replacement.$": "$.getIdentity.attributes.userId"
}
},
{
"id": "sp:transform:replace:string",
"input": {
"pattern": "cert-name",
"replacement.$": "$.hTTPRequest.body[0].name"
}
},
{
"id": "sp:transform:replace:string",
"input": {
"pattern": "\\s",
"replacement": "%20"
}
}
],
"variableA": "https://YYY-YYY-qa-api.sabacloud.com/v1/learning/heldlearningevent?type=curriculum&isAdmin=true&q=(username==user-name,status==100,cert_name==cert-name)"
},
{
"description": "",
"name": "getCertURL",
"transforms": [
{
"id": "sp:transform:replace:string",
"input": {
"pattern": "user-name",
"replacement.$": "$.getIdentity.attributes.userId"
}
},
{
"id": "sp:transform:replace:string",
"input": {
"pattern": "cert-name",
"replacement.$": "$.hTTPRequest.body[0].name"
}
},
{
"id": "sp:transform:replace:string",
"input": {
"pattern": "\\s",
"replacement": "%20"
}
}
],
"variableA": "https://YYY-YYY-qa-api.sabacloud.com/v1/learning/heldlearningevent?type=certification&isAdmin=true&q=(username==user-name,status==100,cert_name==cert-name)"
},
{
"description": "",
"name": "escape",
"transforms": [
{
"id": "sp:transform:replace:string",
"input": {
"pattern": "\\s",
"replacement": "%20"
}
}
],
"variableA.$": "$.hTTPRequest.body[0].name"
}
]
},
"displayName": "Define Certificate Url",
"nextStep": "Compare Strings 5",
"type": "Mutation"
},
"Define Variable 2": {
"actionId": "sp:define-variable",
"attributes": {
"id": "sp:define-variable",
"variables": [
{
"description": "",
"name": "isDebugMode",
"transforms": [],
"variableA": "true"
}
]
},
"displayName": "Set: is debug mode",
"nextStep": "Compare Strings",
"type": "Mutation"
},
"Define Variable 5": {
"actionId": "sp:define-variable",
"attributes": {
"id": "sp:define-variable",
"variables": [
{
"description": "",
"name": "certResult",
"transforms": [],
"variableA.$": "$.hTTPRequest4.body.results[*].displayName"
},
{
"description": "",
"name": "curriculumResult",
"transforms": [],
"variableA.$": "$.hTTPRequest1.body.results[*].displayName"
}
]
},
"displayName": "Define cert result",
"nextStep": "Compare Strings 6",
"type": "Mutation"
},
"End Step - Success 1": {
"actionId": "sp:operator-success",
"displayName": "",
"type": "success"
},
"Get Access": {
"actionId": "sp:access:get",
"attributes": {
"accessprofiles": false,
"entitlements": true,
"getAccessBy": "specificIdentity",
"identityToReturn.$": "$.getIdentity.id",
"roles": false
},
"displayName": "",
"nextStep": "Compare Strings 11",
"type": "action",
"versionNumber": 1
},
"Get Identity": {
"actionId": "sp:get-identity",
"attributes": {
"id.$": "$.loop.loopInput.requestedFor.id"
},
"displayName": "",
"nextStep": "Compare Strings 12",
"type": "action",
"versionNumber": 2
},
"HTTP Request": {
"actionId": "sp:http",
"attributes": {
"authenticationType": "OAuth",
"method": "get",
"oAuthClientId": "8d147bd6ce124ff8938f9fbfa26fbbfe",
"oAuthClientSecret": "$.secrets.125e20e8-8779-489e-a491-628d906562a4",
"oAuthCredentialLocation": "oAuthInHeader",
"oAuthTokenUrl": "https://YYY-sb.api.identitynow.com/oauth/token",
"requestHeaders": {
"Accept": "application/json"
},
"url.$": "$.defineVariable.entitlementsUrl"
},
"catch": [
{
"next": "Compare Strings 10"
}
],
"displayName": "HTTP Request: Get audienceType entitlement",
"nextStep": "Compare Numbers 1",
"type": "action",
"versionNumber": 2
},
"HTTP Request 1": {
"actionId": "sp:http",
"attributes": {
"authenticationType": "header",
"headerAuthName": "SabaCertificate",
"headerAuthValue": "$.secrets.52c2080d-3653-4de0-84b7-2f7652665bce",
"method": "get",
"requestContentType": null,
"requestHeaders": null,
"url.$": "$.defineVariable1.getCurriculumURL",
"urlParams": null
},
"catch": [
{
"next": "Send Email 6"
}
],
"description": null,
"displayName": "HTTP Request - YYY - Get user curriculum",
"nextStep": "Define Variable 5",
"type": "action",
"versionNumber": 2
},
"HTTP Request 2": {
"actionId": "sp:http",
"attributes": {
"authenticationType": "OAuth",
"headerAuthName": "Authorization",
"headerAuthValue": "$.secrets.d9378a48-36b0-46a7-a8b7-cdac86a6ab9e",
"jsonRequestBody": {
"input": {
"audienceTypeId": "{{{{$.hTTPRequest.body[0].id}}",
"audienceTypeName": "{{$.hTTPRequest.body[0].name}}",
"audienceTypeSourceId": "{{$.hTTPRequest.body[0].source.id}}",
"audienceTypeValue": "{{$.hTTPRequest.body[0].value}}",
"identityId": "{{$.loop.loopInput.requestedFor.id}}",
"requestFor": "{{$.getIdentity.attributes.userId}}",
"sabaCertificate": "{{$.defineVariable3.sabaCertificate}}"
}
},
"method": "post",
"oAuthClientId": "7d7f94bb-3539-4c0d-804d-5ab4b21811b5",
"oAuthClientSecret": "$.secrets.3dba7597-7def-4db4-b757-eaab39dc8230",
"oAuthCredentialLocation": "oAuthInHeader",
"oAuthTokenUrl": "https://YYY-sb.api.identitynow.com/oauth/token",
"requestContentType": "json",
"requestHeaders": null,
"url": "https://YYY-sb.api.identitynow.com/v2024/workflows/execute/external/53ef3363-4a88-4c82-99da-258d22bb455e"
},
"catch": [
{
"next": "Wait 1"
}
],
"description": null,
"displayName": "Invoke workflow \"assign audienceType\"",
"nextStep": "Wait",
"type": "action",
"versionNumber": 2
},
"HTTP Request 4": {
"actionId": "sp:http",
"attributes": {
"authenticationType": "header",
"headerAuthName": "SabaCertificate",
"headerAuthValue": "$.secrets.a97fd671-96f7-407b-a14c-aea90d7d0dda",
"method": "get",
"requestContentType": null,
"requestHeaders": null,
"url.$": "$.defineVariable1.getCertURL",
"urlParams": null
},
"catch": [
{
"next": "Send Email 12"
}
],
"description": null,
"displayName": "HTTP Request - YYY - Get user certificate",
"nextStep": "HTTP Request 1",
"type": "action",
"versionNumber": 2
},
"Send Email": {
"actionId": "sp:send-email",
"attributes": {
"body": "<p>{{$.hTTPRequest4.body.results[*].displayName}}</p>\n<p><strong>Has certificate done query:</strong><br>{{$.defineVariable5.certResult}} <strong>equals</strong><br>{{$.hTTPRequest.body[0].name}}</p>\n<p><strong>Has curriculum done query:</strong><br>{{$.defineVariable5.curriculumResult}} <strong>equals</strong><br>{{$.hTTPRequest1.body[0].name}}</p>",
"context": {},
"recipientEmailList": [
"AAA@AAA.com"
],
"subject": "DEBUG: YYY - Approval Workflow - Training done?"
},
"description": null,
"displayName": "Debug: Send Email - Get Training Status",
"nextStep": "Compare Strings 9",
"type": "action",
"versionNumber": 2
},
"Send Email 1": {
"actionId": "sp:send-email",
"attributes": {
"body.$": "$.hTTPRequest2.error.workflowErrorMessage",
"context": {},
"recipientEmailList": [
"AAA@AAA.com"
],
"subject": "DEBUG: YYY - Approval Workflow - Error workflow execution"
},
"displayName": "Debug: Send workflow error \"audiencetype\"",
"nextStep": "Define Variable 1",
"type": "action",
"versionNumber": 2
},
"Send Email 10": {
"actionId": "sp:send-email",
"attributes": {
"body.$": "$.defineVariable.entitlementsUrl",
"context": {},
"recipientEmailList": [
"AAA@AAA.com"
],
"subject": "DEBUG: YYY - Approval Workflow - Calculated EntitlementUrl"
},
"displayName": "Debug: Send Email - Calculated EntitlementUrl",
"nextStep": "HTTP Request",
"type": "action",
"versionNumber": 2
},
"Send Email 11": {
"actionId": "sp:send-email",
"attributes": {
"body": "<p><strong>Length:</strong></p>\n<p>{{$.hTTPRequest.body.length()}}</p>\n<p><strong>Body:</strong> </p>\n<p>{{$.hTTPRequest.body}}</p>",
"context": {},
"recipientEmailList": [
"AAA@AAA.com"
],
"subject": "DEBUG: YYY - Approval Workflow - Has AudienceType"
},
"displayName": "Debug: Send Email - Has audienceType",
"nextStep": "Get Identity",
"type": "action",
"versionNumber": 2
},
"Send Email 12": {
"actionId": "sp:send-email",
"attributes": {
"body.$": "$.hTTPRequest1.error.workflowErrorMessage",
"context": {},
"from": null,
"recipientEmailList": [
"AAA@AAA.com"
],
"subject": "Get Certificate error"
},
"displayName": "Send Email - Error get certificate ",
"nextStep": "HTTP Request 1",
"type": "action",
"versionNumber": 2
},
"Send Email 2": {
"actionId": "sp:send-email",
"attributes": {
"body": "<p><strong>Length:</strong></p>\n<p>{{$.hTTPRequest.body.length()}}</p>\n<p><strong>Body:</strong> </p>\n<p>{{$.hTTPRequest.body}}</p>",
"context": {},
"recipientEmailList": [
"AAA@AAA.com"
],
"subject": "DEBUG: YYY - Approval Workflow - No AudienceType"
},
"displayName": "Debug: Send Email - Has no audienceType",
"nextStep": "End Step - Success 1",
"type": "action",
"versionNumber": 2
},
"Send Email 3": {
"actionId": "sp:send-email",
"attributes": {
"body.$": "",
"context": {},
"recipientEmailList": [
"AAA@AAA.com"
],
"subject": "DEBUG: YYY - Approval Workflow - Training successfully done"
},
"displayName": "Debug: Send Email - Certificate successful finished",
"nextStep": "End Step - Success 1",
"type": "action",
"versionNumber": 2
},
"Send Email 4": {
"actionId": "sp:send-email",
"attributes": {
"body.$": "",
"context": {},
"recipientEmailList": [
"AAA@AAA.com"
],
"subject": "DEBUG: YYY - Approval Workflow - Certificate not done"
},
"displayName": "Debug: Send Email - Certificate not done",
"nextStep": "End Step - Success 1",
"type": "action",
"versionNumber": 2
},
"Send Email 5": {
"actionId": "sp:send-email",
"attributes": {
"body.$": "$.defineVariable1.getCertURL",
"context": {},
"recipientEmailList": [
"AAA@AAA.com"
],
"subject": "DEBUG: YYY - Approval Workflow - Calculated certificateUrl"
},
"displayName": "Debug: Send Email - calculated certificateUrl",
"nextStep": "HTTP Request 4",
"type": "action",
"versionNumber": 2
},
"Send Email 6": {
"actionId": "sp:send-email",
"attributes": {
"body.$": "$.hTTPRequest1.error.workflowErrorMessage",
"context": {},
"from": null,
"recipientEmailList": [
"AAA@AAA.com"
],
"subject": "Get Curriculum error"
},
"displayName": "Send Email - Get Curriculum",
"nextStep": "Define Variable 5",
"type": "action",
"versionNumber": 2
},
"Send Email 7": {
"actionId": "sp:send-email",
"attributes": {
"body": "<p><strong>Role AudienceType:</strong></p>\n<p>{{$.getAccess.accessItems[*].id}}</p>\n<p><strong>Identity Access:</strong></p>\n<p>{{$.hTTPRequest.body[0].id}}</p>",
"context": {},
"recipientEmailList": [
"AAA@AAA.com"
],
"subject": "Invoke WF audienceType"
},
"displayName": "Send Email - Has audienceType?",
"nextStep": "HTTP Request 2",
"type": "action",
"versionNumber": 2
},
"Send Email 8": {
"actionId": "sp:send-email",
"attributes": {
"body.$": "$.hTTPRequest.error.workflowErrorMessage",
"context": {},
"recipientEmailList": [
"AAA@AAA.com"
],
"subject": "DEBUG: YYY - Approval Workflow - Error get entitlement list"
},
"displayName": "Debug: Send Email - workflow error get entitlement list",
"nextStep": "End Step - Success 1",
"type": "action",
"versionNumber": 2
},
"Send Email 9": {
"actionId": "sp:send-email",
"attributes": {
"body.$": "$.loop.loopInput.name",
"context": {},
"recipientEmailList": [
"AAA@AAA.com"
],
"subject": "DEBUG: YYY - Approval Workflow - Is YYY approval"
},
"displayName": "Debug: Send Email - pending approval is YYY entitlement",
"nextStep": "Define Variable",
"type": "action",
"versionNumber": 2
},
"Wait": {
"actionId": "sp:sleep",
"attributes": {
"duration": "4m",
"type": "waitFor"
},
"displayName": "",
"nextStep": "Define Variable 1",
"type": "action",
"versionNumber": 1
},
"Wait 1": {
"actionId": "sp:sleep",
"attributes": {
"duration": "4m",
"type": "waitFor"
},
"displayName": "",
"nextStep": "Send Email 1",
"type": "action",
"versionNumber": 1
}
}
},
"displayName": "",
"nextStep": "End Step - Success 2",
"type": "action",
"versionNumber": 1
}
}
},
"creator": {
"type": "IDENTITY",
"id": "1a0910985fe34c87a8dfe0d886aef6b0",
"name": "Test Test"
},
"trigger": {
"type": "SCHEDULED",
"attributes": {
"cronString": "0 * * * *",
"frequency": "cronSchedule",
"id": "idn:cron-schedule",
"timeZone": "Europe/Berlin"
}
}
}

