Tranforms issue

Reaching out to all the community for help

{
                "attributes": {
                    "negativeCondition": "active",
                    "positiveCondition": "inactive",
                    "input": {
                        "attributes": {
                            "name": "market"
                        },
                        "type": "identityAttribute"
                    },
                    "operator": "eq",
                    "value": "ABC"
                },
                "type": "stringCompare"
            },

Does the stringcompare attribute work with the transform or that needs to be pre-created before using it in the transforms?

Regrads,
Soundarya

Hi @Soundary ,
I don’t see “stringCompare” type transform in ISC. I have also checked ISC page for transform guide Operations | SailPoint Developer Community, I don’t find it there also.
Instead of this , you can use static type of transform to handle this kind of use cases. Static | SailPoint Developer Community
Also I believe conditional transform can be used as it supports eq/ lt / gt: Conditional | SailPoint Developer Community

1 Like

Great! thank you for the information

{
“attributes”: {
“expression”: “$market eq ‘ABC’”,
“positiveCondition”: {
“status”: “inactive”,
“identity”: "Google
},
“negativeCondition”: {
“status”: “active”,
“identity”: “amazon”
}
},
“type”: “conditional”
}
Can i use this condition instead of the above?

It should work like this “expression”: “$market eq ABC" .
Please follow the conditional transform documentation for exact format: Conditional | SailPoint Developer Community

You will likely need to define the market variable:

{
    "attributes": {
        "expression": "$market eq 'ABC'",
        "market": {
            "attributes": {
                "name": "market"
            },
            "type": "identityAttribute"
        },
        "positiveCondition": {
            "status": "inactive",
            "identity": "Google"
        },
        "negativeCondition": {
            "status": "active",
            "identity": "amazon"
        }
    },
    "type": "conditional"
}
1 Like

{
“attributes”: {
“expression”: “$Market eq ‘ABC’”,
“positiveCondition”: “inactive”,
“negativeCondition”: “active”,
“Market”: {
“attributes”: {
“name”: “market”
},
“type”: “identityAttribute”
}
},
“type”: “conditional”
},
Is there any issue with this code? This doesn’t seem to work in SailPoint

Hello,

There seems to be some issues with your transform syntax, hence, that’s is the reason its not working in SailPoint ISC.

Refer the below sample code.

{
  "attributes": {
    "expression": "$Market eq ABC",
    "positiveCondition": "true",
    "negativeCondition": "false",
    "Market": {
      "attributes": {
        "name": "market"
      },
      "type": "identityAttribute"
    }
  },
  "type": "conditional",
  "name": "Test Conditional Transform"
}

There is also another approach which you can use to achieve the above using static transform.

{
  "name": "Test Transform",
  "type": "static",
  "attributes": {
    "GetMarketValue": {
      "type": "identityAttribute",
      "attributes": {
        "name": "market"
      }
    },
    "value": "#if($GetMarketValue.equalsIgnoreCase('ABC'))true#{else}false#end"
  }
}

Try above and let us know whether it works.

1 Like

Hi @Soundary

Can you please share your transform by masking the customer details.
Or else I can see in transform there is comma in the end can you please try by removing the comma. Please check below screenshot.

Thank you.

3 Likes

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.