Webhook icon
Schedule icon
Script icon
If icon
Log icon
SlackIncomingWebhook icon

Snapshot Pages to the Wayback Machine After Deploy

Auto-archive pages to the Internet Archive after deploys and alert Slack when the snapshot does not confirm.

Categories
CoreInfrastructure

Marketing ships a page, the legal team asks "what exactly did the terms page say in March?", and nobody knows. This blueprint saves a Wayback Machine snapshot of your URL on deploy, waits, verifies the archive confirmed it, and alerts only when it did not.

How it works

  1. save_page (io.kestra.plugin.scripts.python.Script) hits the Wayback Machine's save endpoint, waits wait seconds, then polls the availability API; it emits available and snapshot_url via the ::{"outputs": ...}:: protocol.
  2. verify_snapshot (io.kestra.plugin.core.flow.If) branches: confirmed → log_snapshot records the receipt URL; not confirmed → alert_no_snapshot says so in Slack.
  3. The errors block alerts Slack when the request itself fails.
  4. Triggers: a Webhook (archive-page) for the deploy pipeline plus a disabled weekly Schedule for drift history.

What you get

  • A durable, dated public archive of what you shipped.
  • Visible failure when archiving does not confirm — no silent gaps.
  • An archive_result JSON output for audit logs or compliance trails.

Who it's for

  • Teams with compliance or "what did the page say" obligations.
  • Docs and marketing teams who want automatic publication history.
  • Anyone tired of screenshotting pages by hand.

Why orchestrate this with Kestra

The Wayback save endpoint is one URL, but the verification poll, the branch, the alert, and the receipt logging are exactly the glue Kestra is for — and it is one away from your deploy pipeline.

Prerequisites

  • Outbound HTTPS to web.archive.org and archive.org from the Worker.
  • A Slack webhook.

Secrets

  • SLACK_WEBHOOK_URL: webhook for the no-snapshot and failure alerts.

Quick start

  1. Add the Slack webhook secret.
  2. Set url and give wait 30 seconds on first try.
  3. Run once and check archive_result.
  4. Wire the archive-page webhook into your deploy.

How to extend

  • Archive a sitemap's URLs with a ForEach.
  • Store snapshot_url in KV keyed by version.
  • Add a change-detection step before archiving to skip identical pages.

Links

See How

New to Kestra?

Use blueprints to kickstart your first workflows.