I have a centrally defined endpoint that points to a RESTful API. At the moment it's a HTTP endpoint, but I can also work with an address endpoint if required.
My issue is that I can't seem to find a way to access the endpoint URI in a property mediator (much like you would be able to with a LocalEntry). I need to embed the URI in a subsequent request, so I'd like to do something like:
<property name="api_endpoint" expression="get-property('ApiEndpoint')"/>
Where ApiEndpoint
is the centrally defined endpoint in the ESB. I later can then use a PayloadFactory mediator to embed this in further requests.
Any help with this would be greatly appreciated.
Strainy
Update 11/01
Something similar to the following answer would do nicely:
https://stackoverflow.com/a/15265345/1784962
If I could access the configuration registry and get the endpoint XML configuration similar to the below property, that would be fantastic:
<property name="test"
expression="string(get-property('registry', 'conf:/endpoints/Drupal_Endpoint.xml')//@uri-template)"/>