I have some code which needs to execute one function based on an hourly trigger, then another function exactly one hour after the first one. Like this:
function main() {
firstFunction();
ScriptApp.newTrigger('secondFunction')
.timeBased()
.after(60 * 60 * 1000) // 60 mins * 60 s * 1000 ms
.create();
}
This is working fine. I just noticed though that the triggers build up in "my triggers" of the google apps script console. Is there any way to delete the trigger after execution?