Adding maintenance windows to Oh Dear

We've just released a new feature: maintenance windows!

You can now place your site in maintenance which will mute all notifications during that period.

Setting maintenance windows

You can add a maintenance period per website. You set the start and end date, and during that timeframe the notifications will be muted.

We'll still perform our checks, so you can see in your website history when the site was unavailable, but all notifications will be stopped so no one will be disturbed.

Maintenance Periods

In your dashboard you can click through on any site and find the Maintenance periods menu item on the left.

Setting on-demand maintenance windows

One implementation we've always frowned upon (a bit) was the idea of recurring maintenance windows. A fixed time where all alerts would be muted.

Sure, in some cases actual maintenance would happen. But how often would a recurring maintenance window be configured where nothing happens?

And if there was real downtime during that time, would anyone know?

For that reason we took a different approach. On the maintenance overview, we give the actual API commands you could use to implement this in your deploy or maintenance script. It's super easy.

$ OHDEAR_TOKEN="your API token"

$ curl -X POST \
    -H "Authorization: Bearer $OHDEAR_TOKEN" \
    -H 'Accept: application/json' \
    -H 'Content-Type: application/json'
$ curl -X POST \
    -H "Authorization: Bearer $OHDEAR_TOKEN" \
    -H 'Accept: application/json' \
    -H 'Content-Type: application/json'

The first API call starts a maintenance window for that site (which defaults to 60 minutes, but you can customize that), the second API call stops the maintenance window.

If you add this as the first & last steps in your deploy scripts, you've just configured on-demand maintenance windows. No matter when you deploy or how long it might take, the maintenance window will be timed just right.

More API commands

Of course the API also allows for pre-defined maintenance windows (as does our dashboard). You can still configure a start- and end date manually for alerts to be muted.

You can find all API calls related to maintenance windows right in our documentation, as well as updated information on using the PHP SDK to start/stop a maintenance window for a site.

Want to get started? We offer a no-strings-attached 10 day trial. No credit card required.

Start monitoring »

You're all set in
less than a minute!