Trigger a scenario the last day of the month with Make (ex Integromat)

This is some text inside of a div block.
May 11, 2024
Make tutorial - set up scenario at the end of every month

This guide aims to show you how to schedule a scenario in Make (formerly Integromat) to run on the last day of each month, a common requirement for monthly reporting and data processing tasks.

What is Make (Ex Integromat)?

Make is a powerful, no-code automation tool that connects your apps and services to work together. It's particularly useful for whose who need to regularly gather data, use different api, or update databases.

Why Schedule for the Last Day of the Month?

Scheduling tasks for the last day of each month is crucial for activities like generating monthly reports, billing, or data back-ups. It ensures that all data from the month is included and processed timely.

The main challenge to solve

The problem is that the last day of each month is different every month. Même si on pourrait définir un scenario qui finirait le 30 du mois un mois sur deux et le 31 les autres mois, il resterait toujours février qui constitue une exception difficilement solvable de cette manière.

The Step-by-Step Guide

Configure Make module to trigger the end of the month

Step 1: Tick the possible days for the end of the month

  • Click on the clock icon to open the schedule settings.
  • Set the scenario to run ‘Once a month’.
  • To target the last day of the month, select the 28, 29, 30,31
February generally has 28 days and every 4 years 29 days.

Set up Make filter after first module

Step 2: Create a filter after the trigger module

  • Copy paste the formulas
  • {{formatDate(addDays(addMonths(setDate(now; 1); 1); -1); DD)}}
  • {{formatDate(now; DD)}}
  • Don’t forget to rewrite “DD” to make the parameter works

Understand the conditional filter :

1) Set Initial Date:

The setDate function is used to initialize the date to the first day of the current month. This is our starting point.

2) Move to Next Month:

Next, the addMonths function adds one month. This adjustment moves the date to the first day of the following month.

3) Find Month's End:

To find the last day of the current month, we use addDays -1. This subtracts one day from our date, which is now the first day of the next month, thus taking us back to the last day of the current month.

4) Determine Day Number:

The formatDate function, with the DD token, gives us the numeric date of the last day of the current month. This tells us whether it's the 28th, 29th, 30th, or 31st.

5) Comparison with Current Date:

We then compare the result of these four functions against the current date, using {{formatDate(now; “DD”)}}.

6) Monthly Check Execution:

This entire scenario runs on the 28th, 29th, 30th, and 31st of each month. It checks if it's the last day of the month. If it is, the filter is successfully passed

Step 3 : Turn on your scenario !

Advanced Tips

  • Conditional Logic: Implement filters or conditional statements for more complex scenarios.
  • Error Handling: Set up notifications for any errors during the scenario run.

Find your no code stack and get started on your project today !