Although I am specifying valueInputoption but still i am getting this error. I followed google sheet`s quickstart.js tutorial for authentication.
function appendData(auth) {
var sheets = google.sheets('v4');
values: [ ["Void", "Canvas", "Website"], ["Paul", "Shan", "Human"] ];
var body = {
values: this.values
};
sheets.spreadsheets.values.append({
auth: auth,
spreadsheetId: '13QPQj1Ot0oBJms2eQzrKahwzGt13JxQkqf54j2zk3jI',
range: 'Sheet1!A2:B', //Change Sheet1 if your worksheet's name is
//something else
valueInputOption: "USER_ENTERED",
insertDataOption: 'INSERT_ROWS',
resource: body
}, (err, response) => {
if (err) {
console.log('The API returned an error: ' + err);
return;
} else {
console.log("Appended");
}
});
}