Can't get Google Sheets API v4 to return multiple range values using batchGet. It is giving the following error (although the documentation says it needs valueRanges[], all the ranges and spreadsheetId are correct): "Extra args block must be a javascript object literal. (line 2, file "Code")"
Could you please help sort it out? Thank you. Here is the code:
function readRange(spreadsheetId) {
var response = Sheets.Spreadsheets.Values.batchGet("someSpreadSheetID", ["Sheet1!D7:F7", "Sheet1!J7:L7"]);
Logger.log(response.values);
}