I have a JSON String as below.
String Input = {"body":"<style>p{margin-top:0px; margin-bottom:0px;}</style><body class=\"setupTab\" style=\" background-color:#CCCCCC; bEditID:b1st1; bLabel:body;\">"}
When I try Map<String, Object> parsedJSONMap = (Map<String, Object>) JSON.deserializeUntyped(Input);
It throws error,
System.JSONException: Unexpected character ('s' (code 115)): was expecting comma to separate OBJECT entries at [line:1, column:76]
But if I change all \
to \\
in the String it works perfectly.
How can I replace all \
with \\
or is there any other way to achieve this?
String is generated locally not from any API.