I am trying to make an array like value1,value2,value3 that I can iterate through later.
I have the following so far:
var url = 'URL_STRING';
var headers = {
headers: {
Username: 'USERNAME',
"Authorization": "Bearer " + 'KEY'
},
contentType: "application/x-www-form-urlencoded",
};
var response = UrlFetchApp.fetch(url, headers);
var json = response.getContentText();
var obj = JSON.parse(json);
var audits = obj.audits;
Logger.log(audits)
The log shows:
[{
id = value1
}, {
id = value2
}, {
id = value3
}]
I thought I would be able to do something like var arr[] = obj.audits.id but this does not work.