'send-request' Policy Statement
How to use the "send-request" Policy statement to call an extra web service for an Azure API service operation?
The "send-request" Policy Statement allows you to call an extra web service and store the response in a given variable.
The "send-request" statement has the following syntax:
<send-request mode="new|copy" response-variable-name="" timeout="60 sec" ignore-error="false|true"> <set-url>...</set-url> <set-method>...</set-method> <set-header name="" exists-action="override|skip|append|delete">...</set-header> <set-body>...</set-body> </send-request>
For example, the following inbound policy makes an extra web service call. The response of the call will be stored a context variable called "loginResponse":
<inbound> <send-request mode="new" response-variable-name="loginResponse" timeout="20" ignore-error="true"> <set-url>http://dev.fyicenter.com/api/authorization</set-url> <set-method>POST</set-method> <set-header name="Authorization" exists-action="override"> <value>basic dXNlcm5hbWU6cGFzc3dvcmQ=</value> </set-header> </send-request> </inbound>
2018-01-13, 2375👍, 0💬
Can Multiple Paragraphs Be Included in a List Item? Yes. You can include multiple paragraphs in a si...
How to use "xsl-transform" Azure API Policy Statement? The "xsl-transform" Policy Statement allows y...
How to install .NET Framework in Visual Studio Community 2017? I have the Visual Studio Installer in...
Where to find tutorials on RSS specifications? I want to learn it to describe my API services. Here ...
What is Azure API Management Gateway? Azure API Management Gateway is the Azure Web server that serv...