cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

HTTP to HTTPs scenario in SAP CPI - Error 404

nidhi_srivastava22
Active Contributor
0 Likes
3,478

Hi Experts,

There is a requirement where we are sending a json payload to HTTPs receiver URL and getting the below error.

1) Added the P12 key with passphrase in the keystore. Connection tested and working fine.

2) While posting the json payload from Postman, it is working fine and getting a response 202 as accepted, but while triggering through CPI it is showing error.

Error Details com.sap.it.rt.adapter.http.api.exception.HttpResponseException: An internal server error occured: HTTP operation failed invoking https://13b6XXXXXX with statusCode: 400. The MPL ID for the failed message is : AF-Xsgygs

3) The payload format is mentioned as below.

Request:{ "ABC":"1111111", "MMM":[31,10,15,80,80,34,56,23,34], "XYZ":"2222222" }

Response: [ { "code": 202, "XYZ": "2222222", "ABC": "11111111" } ] -> this bracket can be an issue?

Please suggest where I am going wrong, and suggest to resolve the same.

Thanks,

Nidhi Srivastava

View Entire Topic

Hi nidhi.srivastava22,

In addition to what Sri suggested could you please check what is the Content-Type set before posting data.

thanks and regards,

Praveen T

nidhi_srivastava22
Active Contributor
0 Likes

The content type is set to application/json while triggering the data from Postman.

Content-Type: application/json

Thanks,

Nidhi Srivastava

nidhi_srivastava22
Active Contributor
0 Likes

Hi Praveen,

This is working fine, once we have added the Content-Type - application/json in the content modifier before passing it to the Receiver.

Thanks,

Nidhi Srivastava