Ok, I want the response to be a plain string, not JSON.
Ex. this object
let obj = {
foo: 'bar',
baz: 1
}
Should be returned as
"{foo: 'bar', baz: 1}"
Instead of
{"foo": "bar", "baz": 1}
Why? I need to use the string as a link in quickchart
<img src="https://quickchart.io/chart?c={type:'line',data:{labels:['January','February', 'March','April', 'May'], datasets:[{label:'Dogs', data: [50,60,70,180,190], fill:false,borderColor:'blue'},{label:'Cats', data:[100,200,300,400,500], fill:false,borderColor:'green'}]}}">
The double quotes in JSON break the image link.
Or, maybe suggest a better way.
"{foo: 'bar', baz: 1}"isn't JSON)"{foo: 'bar', baz: 1}", as you said, isn't JSON, but it is what the OP wants.