Oracle API Gateway JSON Remove Node Filter Does Not Accept Runtime Attribute

(Doc ID 2061725.1)

Last updated on OCTOBER 13, 2016

Applies to:

Oracle API Gateway - Version 11.1.2 and later
Information in this document applies to any platform.


The following example URL is meant to access a policy where user can specify the return field or fields they would like removed from a piece of JSON:


The example JSON being used is the following:

In this test, the intention would be to remove the cityName and streetName nodes from the JSON before returning the response.

In the policy being used, there is a "Validate REST Filter" filter being used extract the query string content to the "params.query.fields" attribute, which should then be used in the "JSON Remove Node" filter to remove the JSON nodes corresponding to the values in the attribute.  The following JSON Path is being specified in the filter: $.data.address.[${params.query.fields}]

The filter does not accept the attribute (wrong syntax error when an attempt is made to save the filter).

If the filter is used with a hard coded value instead, it works fine: $.data.address.[cityName,streetName].

Is it possible to achieve the functionality desired in this case?


Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms