There are a couple of options available to solve this problem:
- 1. Ask your service provider to be inline and request to send the correct content-type header
- 2. Implement HTTP based proxy process logic to transform the service response inline with the client request.
HTTP based proxy process:The first option is quite simple but will always not work as service could be the external one, and they will not address the request instantly.
If this is the case then you need to create an alternative option till the service team implements the required change.
With creating HTTP receiver, HTTP Request, and HTTP Response in the process you will be creating a proxy server for your actual client process. So your client will call the HTTP Receiver server then HTTP request activity will pick the request from HTTP receiver and forward it to actual service and payload will be passed back using HTTP response activity.
Here, you'll drop or change the 'Content-Type' header in response mapping.
Flow diagram: Actual Client -> HTTP Proxy Service -> External Service
(vice versa for response)Please find attached the sample workaround application.
[NOTE: The attached sample has only HTTP based process for reference, other processes are removed due to security & compliance reasons.]