Tools, FAQ, Tutorials:
'send-one-way-request' Policy Statement
How to use the "send-one-way-request" Policy statement to call an extra web service for an Azure API service operation?
✍: FYIcenter.com
The "send-one-way-request" Policy Statement allows you to call an extra web service.
The "send-request" statement has the following syntax:
<send-request mode="new|copy"> <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>
Where, mode="new (default) | copy" - Indicates whether you want to start with new empty request of take a copy of the "context.Request" object.
For example, the following outbound policy makes an extra web service call to deliver an alert:
<outbound> <send-one-way-request mode="new"> <set-url>http://dev.fyicenter.com/api/alert</set-url> <set-method>POST</set-method> <set-body>{"alert": { "type": "warning", "message": "Someone called the API." }} </set-body> </send-one-way-request> </outbound>
Â
⇠'send-request' Policy Statement
2018-01-13, 2906👍, 0💬
Popular Posts:
How To Read Data from Keyboard (Standard Input) in PHP? If you want to read data from the standard i...
How to start Visual Studio Command Prompt? I have Visual Studio 2017 Community version with Visual C...
Where to see resource detailed information of my API Management Service on Azure Portal? Once you ha...
What is test testing area for? The testing area is provided to allow visitors to post testing commen...
What's Wrong with "while ($c=fgetc($f)) {}" in PHP? If you are using "while ($c=fgetc($f)) {}" to lo...