Enterprise Integration Zone is brought to you in partnership with:

Mark O'Neill is VP Innovation at Axway. Previously, he was CTO and co-founder at Vordel, acquired by Axway in 2012. He is the author of the McGraw-Hill book "Web Services Security" and is frequent speaker at conferences including Java One, the RSA Security Conference, and Oracle Open World. Mark is based on Boston, Massachusetts. Mark is a DZone MVB and is not an employee of DZone and has posted 64 posts at DZone. You can read more from them at their website. View Full User Profile

How to Read in REST Parameters in the Axway Vordel API Server

02.07.2013
| 2334 views |
  • submit to reddit
The Axway Vordel API Server allows you to read in REST API parameters from an incoming request, and then use these parameters for a variety of purposes, for example to pass them into a SOAP message, or use them to call a method of a Java class via the Scripting Filter. 

The key to this is the "Extract REST Request Attributes" filter. If I type in "REST" into the search box on Policy Studio, it helpfully narrows down the filter list to just the filters related to REST.


When I drag in an "Extract REST Request Attributes" filter, I see this configuration below. As you can see, you can have the API Server read API parameters from the querystring or from HTTP POST parameters.


Once I place this filter into a policy which is mapped to a REST endpoint on the API Server (e.g. a relative path), I can then access the REST parameters in other filters.  Let's say a parameter is passed like this: https://apiserver.companyx.com/orders/purchaseorder?product=1234&customerID=AcmeInc I can now access the content of the "customerID" parameter like this:  ${http.querystring.customerID}
Published at DZone with permission of Mark O'neill, author and DZone MVB. (source)

(Note: Opinions expressed in this article and its replies are the opinions of their respective authors and not those of DZone, Inc.)