The API response body is missing when the status code is not 200. I've encounter the issue on production (Azure) only. It works fine on local machine
I've tried and able to reproduce it on a simple api as follows:
router.get('/testJsonResp', (req, res) => {
res.status(400).json({ test: 'testResp' });
});
when I read the response text, it returned me "Bad Request"
let resp = await fetch(...);
await resp.text();
Same goes with postman as well.
Anyone have any idea what went wrong?