Skip to content

Weekly

Check that your Fly volumes have recent snapshots

Once a week you see the newest snapshot date for each volume, with any that are falling behind flagged.

Runs
Weekly
Apps
Fly.io
AI
Not needed
Access
org or deploy token (read)

Send this to your assistant

Create a ClickRuntime automation: every Monday, email me each volume in my Fly app 'db' with its newest snapshot date, and flag any older than 2 days.

Paste it into your assistant. It tells you what it will send or change before it runs live.

First time? Adding ClickRuntime to your assistant takes about two minutes.

Why use it

Why teams use this automation

Fly.io volumes hold the data that matters, such as a Postgres database or user uploads, and snapshots are the only protection against corruption or an accidental delete. Fly takes snapshots automatically, but when retention is changed, a volume is new, or snapshots fail, nobody gets a warning. The first time you learn that the last snapshot is a month old is the day you need to restore. Hope is not a strategy.

Every week, ClickRuntime lists the volumes of your app, lists the snapshots for each, flags any volume whose newest snapshot is older than a limit you set, and emails you the result. If all volumes are covered, the email says so in one line.

It is worth having for any app with persistent data, particularly where one person looks after infrastructure.

What you get out of it

  • Find missing snapshots before you need them

    A weekly check shows a volume whose newest snapshot is stale. You fix it now rather than finding out in the middle of an incident. That means fewer nasty surprises and a calmer recovery.

  • Confirm new volumes are protected

    A volume created last week might not have a snapshot yet. The report shows it right away so you can take one manually. A manual snapshot takes seconds and closes the gap right away.

  • Back up your restore plan

    Knowing the date of the latest snapshot per volume tells you how much data you could lose. That number is what you need for planning recovery objectives. Clear numbers help you decide whether daily snapshots are frequent enough for your data.

  • Reduce the chance of silent failure

    Automation fails quietly when settings change. A separate check that reads the actual snapshots tells you the truth, not just that a feature is enabled. Verification beats assumption every time.

  • Provide proof for customers

    Customers asking about backups get a dated record that snapshots exist. That helps with procurement questionnaires and security reviews. Clear answers make questionnaires faster to complete. Dated reports also satisfy auditors.

How it works

What happens, step by step

  1. Once a week, ClickRuntime lists the volumes in your Fly.io app.

  2. For each volume it finds the date of the newest snapshot and flags any that are too old.

  3. You get one email listing every volume with its newest snapshot date, with a warning sign next to the ones falling behind.

Before it runs live

  • Connect Fly.io

What you get

RunsWeekly
Check that your Fly volumes have recent snapshotstoday, 9:00Succeeded
Email · Volume snapshotspg_data (vol_4y5…, ams): newest snapshot 2026-10-19 ⚠ pg_data (vol_9k2…, iad): newest snapshot 2026-10-14

Build your own

Need it to work differently?

This template is a starting point. Copy the prompt and change it, or describe a different automation from scratch, with your own conditions, more apps or an AI step. Your assistant writes it, tests it and runs it on ClickRuntime.
  • Your own rules

    Conditions, thresholds, filters and exceptions, written the way you'd explain them to a colleague.

  • Any number of apps

    One automation can read from one app and update several others. Over 248 apps are ready, and anything with an API works too.

  • AI where it helps

    Summaries, classification, extraction and drafts use ClickRuntime's built-in AI, with no extra key.

  • On a schedule or on each event

    Runs as often as every 5 minutes, or the moment an app sends an event, and keeps track of what it already handled.

Changes you can ask for

  • Run it at a different time, more or less often, or only on weekdays
  • Add an AI step, for example to summarize, sort or draft a reply
  • Add another app, for example also send it to Slack
  • Combine it with other Fly.io steps into one automation

Under the hood

The code that runs this automation

This is the Python script that runs each time the automation starts. Your AI assistant writes it for you when you send the prompt, and you allow each step in your assistant. To change how the automation works, describe the change to your assistant and it updates the script for you. For every function it can use, see the script reference.
get_a_weekly_volume_snapshot_check.pyexample
from datetime import datetime, timedelta, timezone
from clickruntime import on_trigger, credentials, http, notify

APP = "db"
API = f"https://api.machines.dev/v1/apps/{APP}/volumes"

@on_trigger
def run(event):
    headers = {"Authorization": f"Bearer {credentials.secret('FLY_API_TOKEN')}"}
    cutoff = datetime.now(timezone.utc) - timedelta(days=2)
    lines, flagged = [], 0
    for vol in http.get(API, headers=headers).json():
        snaps = http.get(f"{API}/{vol['id']}/snapshots", headers=headers).json()
        newest = max((s["created_at"] for s in snaps), default=None)
        old = newest is None or datetime.fromisoformat(newest.replace("Z", "+00:00")) < cutoff
        flagged += old
        lines.append(f"{'⚠ ' if old else ''}{vol['name']} ({vol['id']}, {vol['region']}): "
                     f"newest snapshot {newest[:10] if newest else 'none'}")
    notify.email_me(f"Fly volume snapshots for {APP} ({flagged} flagged)", "\n".join(lines))
    return {"flagged": flagged}

FAQ

Common questions

How old is too old for a snapshot?
Fly keeps daily snapshots by default, so more than two days is a warning sign. You can set your own threshold, such as 36 hours, to match how much data loss your business can tolerate.
Does a snapshot guarantee I can restore?
A snapshot is a copy of the volume at a point in time, which you can use to create a new volume. It does not test your restore procedure, so practice restoring into a staging app now and then.
Can it take a snapshot automatically?
The flow checks and reports. It can be extended to create a snapshot when one is stale, but that should be a deliberate choice, since snapshots can add storage cost and are best taken at calm moments.
What permissions does it need?
org or deploy token (read). Nothing else in your accounts is used.
Does it need AI?
No. It runs without AI, so it doesn't use your plan's AI allowance.
How many runs does it use?
One run each time it runs (weekly). Checks that find nothing to do and stop right away aren't counted.
Can I change how it works?
Yes. Describe the change to your AI assistant, for example a different schedule, channel or filter. It updates the automation, tests it and tells you what changed.

Set up “Check that your Fly volumes have recent snapshots” from your assistant

Copy the prompt above, or connect your assistant first. Free plan, no credit card.