When I am using "Google App Script" in order to retrieve a json page, I face with the following message: Please turn JavaScript on and reload the page.
I am not sure how to handle this, hence I can open the same page on my web-browser.
[Q] How could I fix this in order retrieve json-page's information only using "Google App Script"?
function getJsonFromUrl(strUrl) {
let _options = {
method: 'GET',
muteHttpExceptions: true,
contentType: 'application/json',
};
let _res = UrlFetchApp.fetch(strUrl, _options);
Logger.log(_res.getContentText());
return JSON.parse(_res.getContentText());
}