We follow this use case when we already have content in the payload, but it might not be in the format that we need; for example, when our service receives a request in a specific format but the backend is waiting for a different format, or the backend sends us a message and we need to modify it to format the response to the client.
The best way to do this is with the use of Message type.
Change the format of the content
Message type
Message type is a synapse property that defines the message format of the current payload.
Here's the syntax:
<property name="messageType" value="string" scope="axis2"/>
In our flight example, we will change the response of the EI service to return the...