In case anyone comes across this and hasn’t found an answer. Some things that i think were tripping me up.
- seems like the page needs to be published for the changes to work
- the script name can only have letters. I was using an underscore and seemed like this affected it.
- the js file needed all the parts below
- output the time in javscript with the code below to check what time your job should shedule (check against your own time and set the job to activate 2 mins before the current time to test):
var d = new Date();
console.log(d.toLocaleTimeString());
my final working jobs config code. runs every hour:
{
"jobs": [
{
"functionLocation": "/binance/binance.start",
"executionConfig": {
"cronExpression": "0 * * * *"
}
}
]
}
the js file located at the backend/binance/binance.js has the following that seem to be needed:
export function start() {
// do your stuff here
}
/*
$w.onReady(function () {
start();
});
*/