Skip to main content

Hey zapier folk,

I had the problem that for a customer a Zap has to be executed every two weeks. I would like to present my solution to you and I'am open to alternative solutions or issues I haven't considered. 

First I used the trigger "Schedule by Zapier" and selected "Every Week" as the event.

Schedule by Zapier - Every WeekIn a code block I determine the weeks between the current day and the beginning of time (1970 😀). After that I determine with the modulo operation whether the week is even (0) or odd (1). 

import datetime

date_delta = datetime.date.today() - datetime.date.fromtimestamp(0)

return {"continue" : int(date_delta.days/7)%2}

Then I check with a filter if the Zap should be continued in even (0) or odd (1) weeks. 

Zapier Filter Text exactly matches 1I hope the description is sufficient.


Nicely done, @tweiland!