Legacy Documentation
You're viewing legacy documentation for API Fortress (deployed via an on-premises container).
To view documentation for the new SaaS version of API Fortress — now known as Sauce Labs API Testing and Monitoring (with Sauce Connect tunnels) — see
API Testing on the Sauce Labs Cloud.
Allows you to run a specific piece of code only if a specific condition is met.
Parameters:
Name |
Type/Value |
Required |
Expression |
Expression |
Yes |
Expression: The condition that evaluates if the code must be executed or not.
Examples:

if payload.success is equal to true then the code within the element is executed, otherwise is skipped.

if _1.intermediate exists then the code within the element is executed, otherwise is skipped. This is useful when the element is not always present.