Delete or empty a multivalued variable
search cancel

Delete or empty a multivalued variable

book

Article ID: 275838

calendar_today

Updated On:

Products

CA API Gateway

Issue/Introduction

Is there a way to delete or emtpy a multivalued context variable in runtime inside a policy?
We use looping with "Run assertions for Each Item" assertion, and before each iteration he needs to empty its values (or delete the variable)....

Environment

All supported API Gateway versions

Resolution

You can either set the context variable to null at the starting of the loop or use Split Variable assertion after assigning empty value with Set Context Variable assertion.