Using Conditions in Assignment Rules
When using conditions in assignment rules, you will need to send each condition in a separate API call. This is because each condition is creating a different rule, and only one rule can be sent per API.
In this example, we are using the account currency (GBP or USD) to set the value for a numerical field (test_number). In the first call, our body will look like this:
Here, we are setting the condition that if the ‘currency_a’ field is equal to ‘GBP’ then the field should be set to ‘100’. For the second rule, below, we are setting the condition to ‘if currency_a equals USD then test_number is 500’.
The return messages are the same as for the other assignment rule calls. In TDO, after running both of these calls, the assignment rules page now reflects this. Each rule is shown individually on the page and sets the value per the rule only if the condition is equal to what was stated.
Last updated
Was this helpful?