HTTP Request activity not working for SOAP call

I tried the following endpoint and body in postman and it is working perfectly fine, but when I try to do it in studio I get a 400 error.
Postman:
Endpoint “ Calculator Web Service
Body: “<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi=“http://www.w3.org/2001/XMLSchema-instance
xmlns:xsd=“XML Schema
xmlns:soap=“http://schemas.xmlsoap.org/soap/envelope/”>
soap:Body

5
9

</soap:Body>
</soap:Envelope>>”

UiPath Studio HTTP Request:
Endpoint:“Calculator Web Service
Body, I tried the following AND also in a single line:
“”<?xml version=""1.0"" encoding=""utf-8""?>" & vbCrLf &
“<soap:Envelope xmlns:xsi=”“http://www.w3.org/2001/XMLSchema-instance”“” & vbCrLf &
" xmlns:xsd=““XML Schema””" & vbCrLf &
" xmlns:soap=““http://schemas.xmlsoap.org/soap/envelope/””>" & vbCrLf &
" soap:Body" & vbCrLf &
" <Add xmlns=““http://tempuri.org/””>" & vbCrLf &
" 5" & vbCrLf &
" 3" & vbCrLf &
" " & vbCrLf &
" </soap:Body>" & vbCrLf &
“</soap:Envelope>”

I am getting a 400 status code and I am not sure about the reason, could you please guide me?
HTTP request.xaml (18.0 KB)
I am attaching my small file, could you please take a look? Thank you

@michelle.soto,

the issue comes because UiPath HTTP Request activity by default sends JSON, for SOAP you must set “BodyFormat = Raw” and “Content-Type = text/xml; charset=utf-8” and also add the SOAPAction header.
the 400 error is due to malformed XML in Studio string, fix by pasting the exact SOAP XML as raw string or from file without escaping.

(post deleted by author)