Ruby
Ruby

Reputation: 378

Fetching the name of the APIs or Proxy in WSO2 Integration Studio

I want to fetch the name of the Proxy or APIs in WSO2 Integration Studio and store it in Property mediator so that they can be printed in the custom Error Sequences and Templates. Are there How can I do that?

Upvotes: 0

Views: 139

Answers (1)

tmoasz
tmoasz

Reputation: 1331

To get proxy name, use expression="get-property('proxy.name')", and for API you can use expression="get-property('SYNAPSE_REST_API')"

There is one more, "uniwersal property" like expression="get-property('ARTIFACT_NAME')". It gives you concatenation of type proxy or api and the artifact name, for example: proxySampleMyService or apiexample

Upvotes: 2

Related Questions