Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>As of WSO2 API Manager version 1.3.0, support for invoking secured back-end services has been added. Please see below synapse configuration of a sample API which invokes a secured back-end service. Currently support is only available for services secured over Basic Auth.</p> <pre><code>&lt;api xmlns="http://ws.apache.org/ns/synapse" name="admin--SecuredAPI" context="/secure" version="1.0.0" version-type="url"&gt; &lt;resource methods="POST GET OPTIONS DELETE PUT" url-mapping="/*"&gt; &lt;inSequence&gt; &lt;property name="Authorization" expression="fn:concat('Basic ', base64Encode('username:password'))" scope="transport"/&gt; &lt;property name="POST_TO_URI" value="true" scope="axis2"/&gt; &lt;filter source="$ctx:AM_KEY_TYPE" regex="PRODUCTION"&gt; &lt;then&gt; &lt;send&gt; &lt;endpoint name="admin--SecuredAPI_APIEndpoint_0"&gt; &lt;address uri="https://securebackend.com/search"&gt; &lt;timeout&gt; &lt;duration&gt;30000&lt;/duration&gt; &lt;responseAction&gt;fault&lt;/responseAction&gt; &lt;/timeout&gt; &lt;suspendOnFailure&gt; &lt;errorCodes&gt;-1&lt;/errorCodes&gt; &lt;initialDuration&gt;0&lt;/initialDuration&gt; &lt;progressionFactor&gt;1.0&lt;/progressionFactor&gt; &lt;maximumDuration&gt;0&lt;/maximumDuration&gt; &lt;/suspendOnFailure&gt; &lt;markForSuspension&gt; &lt;errorCodes&gt;-1&lt;/errorCodes&gt; &lt;/markForSuspension&gt; &lt;/address&gt; &lt;/endpoint&gt; &lt;/send&gt; &lt;/then&gt; &lt;else&gt; &lt;sequence key="_sandbox_key_error_"/&gt; &lt;/else&gt; &lt;/filter&gt; &lt;/inSequence&gt; &lt;outSequence&gt; &lt;send/&gt; &lt;/outSequence&gt; &lt;/resource&gt; &lt;handlers&gt; &lt;handler class="org.wso2.carbon.apimgt.gateway.handlers.security.APIAuthenticationHandler"/&gt; &lt;handler class="org.wso2.carbon.apimgt.usage.publisher.APIMgtUsageHandler"/&gt; &lt;handler class="org.wso2.carbon.apimgt.usage.publisher.APIMgtGoogleAnalyticsTrackingHandler"/&gt; &lt;handler class="org.wso2.carbon.apimgt.gateway.handlers.throttling.APIThrottleHandler"&gt; &lt;property name="id" value="A"/&gt; &lt;property name="policyKey" value="gov:/apimgt/applicationdata/tiers.xml"/&gt; &lt;/handler&gt; &lt;handler class="org.wso2.carbon.apimgt.gateway.handlers.ext.APIManagerExtensionHandler"/&gt; &lt;/handlers&gt; &lt;/api&gt; </code></pre> <p>Thanks, Nuwan.</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload