cancel
Showing results for 
Search instead for 
Did you mean: 

JSON to XML converter cannot pass element by SOAP

allysajohn
Explorer
0 Kudos
541

Hi Experts,

I'm trying to implement converting payload of JSON using JSON to XML standard converter. However, it was giving this error message on the standard converter. I have tried with both type of protocols SOAP 1.x and SOAP RM. But, still does not work.

Does SOAP does not support using JSON to XML standard converter?

Thank you in advance!

Accepted Solutions (1)

Accepted Solutions (1)

Sriprasadsbhat
Active Contributor

hello ,

SOAP always uses xml and thats the reason you are able to see this error.Use http sender adapter instead of soap then you can use jsontoxml coverter.

Regards,

Sriprasad

MortenWittrock
SAP Mentor
SAP Mentor

Actually also a case where the error message is quite clear and straightforward; the SOAP sender channel does not output JSON, which is what the next step requires.

Regards,

Morten

allysajohn
Explorer
0 Kudos

Thanks all! My requirement needs me to use soap adapter. I had change to groovy script to convert json to xml.

Ryan-Crosby
Active Contributor
0 Kudos

allysajohn you'll want to address the requirement because using SOAP to send JSON is a contradiction by definition as Sriprasad and 7a519509aed84a2c9e6f627841825b5a have already pointed out.

allysajohn
Explorer
0 Kudos

Hi ryan.crosby and 7a519509aed84a2c9e6f627841825b5a,

I tried using groovy script as mentioned here https://blogs.sap.com/2020/10/02/custom-json-to-xml-converter-in-cpi/ but however, when tested using SOAP adapter, it seems does not work. I used the same groovy script but using HTTPS adapter it is able to work. But, my requirement need to use SOAP as the sender adapter by taking JSON format. Is it not possible for SOAP to take JSON as the input?

Answers (0)