Lakshan Thilakarathne
Lakshan Thilakarathne

Reputation: 55

WSO2 APIM - Retrieve Information about an API call in fault sequence

Trying to get the API name in the fault sequence(ex: auth_failure_handler.xml).

Tested as below and it is not working,

<sequence name="_auth_failure_handler_" xmlns="http://ws.apache.org/ns/synapse">
      <property name="error_message_type" value="application/xml"/> 
      <log level="custom">  
          <property name="ApiName" scope="transport" expression="$ctx:API_NAME"/> 
      </log>  
</sequence>

Upvotes: 0

Views: 154

Answers (1)

tmoasz
tmoasz

Reputation: 1340

I think you can try with this:

<property name="ApiName" expression="$ctx:api.ut.api"/>

There are, some other useful properties, witch You can find on github: APIMgtGatewayConstants

Upvotes: 4

Related Questions