Hi,
I am trying to create a workflow that will perform some action if user has the account assigned.
To check if the user has a specific account assigned I have tried multiple options but no luck:
Compare Numbers operator: $.getAccounts.accounts[?(@.sourceId==“<source_ID>”)].length() Greater than equals to 1
Both are not working. Could someone please help to identify what may be wrong or suggest any alternatives to check if user has a particular account assigned?
I see that you are using a compare numbers/compare strings so i believe you are going to check for the account first. that if the account exists.
So for this you can use the Operator (Verify Data Type)
This operator has a select field of Exists
And then in the JSON PAth you can simply say something like this: $.getAccounts.accounts[?(@.sourceId=="3241XXXXXXXXXXXXX'")].id