0f5e4…
{
“spreadsheetId”: “1H7PY4oK3xYJXEt91EcdOxC_Ie1kC-rlrnOI8Cznmn-o”,
“spreadsheetName”: “sName”,
“sheetId”: 1358862008,
“sheetName”: “Current Year”,
“rangeA1Notation”: “C19”,
“range”: {
"columnEnd": 3,
"columnStart": 3,
"rowEnd": 19,
"rowStart": 19
},
“oldValue”: “Test0”,
“value”: “Test1”,
“user”: {
"email": "x@g.com",
"nickname": "xxx"
},
“rowValues”: [
{
"0": "",
"1": "2025-07-24T15:26:59.932Z",
"2": "Test1",
"3": "",
"4": "p3@gmailx.com",
"5": "n/a",
"6": "n/a",
"7": "no",
"8": "305 XXXXX",
"9": "Yes",
"10": "I need a new roof if it is possible.",
"11": "",
"12": "Basic repairs, Roofing, Foundation",
"13": "Y",
"14": "On the street",
"15": "",
"16": "Evaluated",
"17": false,
"18": "",
"19": "",
"20": "",
"21": "",
"22": "",
"23": "",
"24": "",
"25": "",
"26": "",
"27": "",
"28": "",
"29": ""
}
]
}
ab7e…
{
“spreadsheetId”: “1H7PY4oK3xYJXEt91EcdOxC_Ie1kC-rlrnOI8Cznmn-o”,
“spreadsheetName”: “sName”,
“sheetId”: 1358862008,
“sheetName”: “Current Year”,
“rangeA1Notation”: “C19”,
“range”: {
"columnEnd": 3,
"columnStart": 3,
"rowEnd": 19,
"rowStart": 19
},
“oldValue”: “Test0”,
“value”: “Test1”,
“user”: {
"email": "x@g.com",
"nickname": "xxx"
},
“rowValues”: [
{
"0": "",
"1": "2025-07-24T15:26:59.932Z",
"2": "Test1",
"3": "",
"4": "p3@gmailx.com",
"5": "n/a",
"6": "n/a",
"7": "no",
"8": "305 XXXXX",
"9": "Yes",
"10": "I need a new roof if it is possible.",
"11": "",
"12": "Basic repairs, Roofing, Foundation",
"13": "Y",
"14": "On the street",
"15": "",
"16": "Evaluated",
"17": false,
"18": "",
"19": "",
"20": "",
"21": "",
"22": "",
"23": "",
"24": "",
"25": "",
"26": "",
"27": "",
"28": "",
"29": ""
}
]
}
script:
//For use with the Watch Changes module. Paste the webhook URL from your scenario here:
WATCH_CHANGE_WEBHOOK_URL = ‘https://hook.us2.make.com/wltx6adscrisat7nim370lbgbwig5ido’;
//OPTIONAL (for use with Watch Changes):
//SHEET = ‘’; //SHEET allows you to trigger updates only for the specified sheet (by name)
SHEET = ‘Current Year’
RANGE = ‘’; //RANGE allows you to trigger updates only for values within this range (by A1 notation)
//RANGE = ‘Q2:Q5000’
//For use with the Perform a Function module. Paste the webhook URL from your scenario here:
PERFORM_FUNCTION_WEBHOOK_URL = ‘’;
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////// DO NOT TOUCH BELOW!!! ////////////////////////////////////////////////////////////
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
function watchChanges(e) {
// REQUIRED
const UPDATE_WEBHOOK_URL = WATCH_CHANGE_WEBHOOK_URL;
if(!UPDATE_WEBHOOK_URL) {
console.log('Enter WATCH_CHANGE_WEBHOOK_URL');
throw new Error('Enter WATCH_CHANGE_WEBHOOK_URL');
}
// OPTIONAL
const sheetValue = SHEET;
const rangeValue = RANGE;
const ss = SpreadsheetApp.getActive();
const sheet = ss.getActiveSheet();
if (sheetValue && sheetValue !== ‘’ && sheetValue !== sheet.getName()) {
console.log('No triggering');
return null;
}
if (sheetValue && sheetValue && rangeValue !== ‘’ && !isWithinRange_(e.range.getA1Notation(), rangeValue)) {
console.log('No triggering');
return null;
}
var dataRange = sheet.getDataRange();
var dataArr = sheet.getRange(e.range.rowStart, 1, e.range.rowEnd - e.range.rowStart + 1, dataRange.getLastColumn()).getValues();
var rowValues = ;
dataArr.forEach(function (row) {
var out = {};
row.forEach(function (v, i) {
out\[i\] = v;
});
rowValues.push(out);
});
var payload = {
spreadsheetId: e.source.getId(),
spreadsheetName: e.source.getName(),
sheetId: e.source.getSheetId(),
sheetName: e.source.getSheetName(),
rangeA1Notation: e.range.getA1Notation(),
range: e.range,
oldValue: e.oldValue,
value: e.value,
user: e.user,
rowValues: rowValues
};
var options = {
method: 'post',
contentType: 'application/json',
payload: JSON.stringify(payload)
};
var response = UrlFetchApp.fetch(UPDATE_WEBHOOK_URL, options);
console.log(response);
}
function isWithinRange_(a1Notation, rangeToCheck) {
// arguments = [a1Notation, rangeToCheck]
var input = Array.prototype.map.call(arguments, function (e) {
return e.toUpperCase();
});
var rangeArgs = /^([A-Z]+)?(\d+)?:([A-Z]+)?(\d+)?$/.exec(input[1]);
var a1NotationArgs = /^([A-Z]+)(\d+)$/.exec(input[0]).map(function (e, i) {
return i == 1 ? (' ' + e).substr(-2) : e \* 1;
});
/* If range arguments are missing(like missing end column in “A1:1”), add arbitrary arguments(like “A1:ZZ1”)*/
rangeArgs = rangeArgs.map(function (e, i) {
return e === undefined ?
i % 2 === 0 ?
i > 2 ?
Infinity : -Infinity
: i > 2 ?
'ZZ' : ' A'
: i % 2 === 0 ?
e \* 1 : (' ' + e).substr(-2);
});
console.log(rangeArgs, a1NotationArgs);
return (a1NotationArgs[1] >= rangeArgs[1] &&
a1NotationArgs\[1\] <= rangeArgs\[3\] &&
a1NotationArgs\[2\] >= rangeArgs\[2\] &&
a1NotationArgs\[2\] <= rangeArgs\[4\]);
}