I'm trying to invoke a remote Http Service with the HttpRequestExecutingMessageHandler (as an outbound-gateway and simple bean).
This rest service will not simply required the payload to be post as the requestBody, but as a form-data among with other params. For instance I need to post something like this :
text=The text which is the current payload (an expression value : payload)
profile=basic (a static value)
type=plain-text (a static value)
Right now I'm only able to provide those value as uri variables (with uriVariableExpressions) but as the text param may be long and need to be encoded as a url, this is not the right solution.
I guess (reading HttpRequestExecutingMessageHandler source code) I need to provide those values as a Map and setting the ContentType to multipart/form-data, but i'm not able to do this.
What is the right way to achieve this ?
Thanks for help,