Tools, FAQ, Tutorials:
'find-and-replace' Policy Statement
How to use the "find-and-replace" Policy Statement for an Azure API service operation?
The "find-and-replace" Policy Statement allows you to find and replace a sub string in the request body or response body.
For example, the following inbound policy will replace "$id" by the template parameter "id" value in the request body:
<inbound> <find-and-replace from="$id" to="@(context.Request.MatchedParameters["id"]" /> </inbound>
The following outbound policy will replace "$key" by "xxxxxx" in the response body:
<outbound> <find-and-replace from="$key" to="xxxxxx" /> </outbound>
For some reason, the "find-and-replace" statement in the inbound policy will cause issues for some backend services. So use it only in outbound policy.
â‡’ 'xml-to-json' Policy Statement
â‡ Policy to Modify Request and Response Body
â‡‘ Policy to Modify Request and Response Body
2018-01-19, 2682👍, 0💬
dev.FYIcenter.com is a Website for software developer looking for software development technologies,...
How To Pad an Array with the Same Value Multiple Times in PHP? If you want to add the same value mul...
Where to find tutorials on how to create Your Own Functions in PHP? A collection of tutorials to ans...
How to create a new API on the Publisher Dashboard of an Azure API Management Service? If you are ne...
Where to find tutorials on RSS specifications? I want to learn it to describe my API services. Here ...