AboutWorkServicesToolsBlogContact Get in touch โ†’
Workflow

I Automated My SEO Checklist with Claude Routines

Claude shipped cloud Routines, saved agent sessions that run on a schedule, an API call, or a GitHub event. Here are the three I run across my sites, exact prompts included, what broke the first week, and what still needs a human.

I keep a pre-launch SEO checklist I run on every page before it ships, I wrote the whole thing out in the pre-launch SEO/AIO/GEO/AEO/SXO/LLMO checklist. For two years I ran it by hand. Then Claude Code shipped cloud Routines, saved agent sessions that run on a schedule, an API call, or a GitHub event without me touching a terminal, and I moved most of that checklist onto autopilot. This is what's actually running right now, the exact prompts, what broke the first week, and what I'm still doing by hand.

If you haven't used routines yet, I covered the mechanics and compared them against n8n in Claude Routines vs n8n: when to use which. This post is the applied version, one real checklist, moved piece by piece into three running routines.

The three routines I'm running

I split the checklist into three routines by trigger type, not by topic. Each one maps to a different moment in the publishing cycle.

RoutineTriggerWhat it checks
Pre-merge SEO gateGitHub, pull_request.openedSchema validity, FAQ completeness, answer-first structure, internal links
Weekly content auditSchedule, Sunday 11pmStale dateModified, broken outbound links, orphan pages across all three sites
Deploy-triggered IndexNow pushAPI, called from deploy scriptSubmits changed URLs, confirms acceptance, logs failures

Routine 1: the pre-merge SEO gate

This one fires on every pull request against my blog content repos. The prompt is the whole checklist, compressed, with an explicit instruction to leave inline comments rather than silently fixing things, I want to see what it caught, not just a clean merge.

๐Ÿ’ฌ routine prompt text
Review every changed .astro file under src/pages/blog/ in this PR against
this checklist. Leave an inline comment for each failure, do not fix
anything yourself.

1. Schema: FAQPage and Article JSON-LD present and valid
2. Answer-first: first two sentences after the H1 directly answer the
   implied query, no throat-clearing
3. FAQ section has 4+ entries with specific, non-generic answers
4. At least 2 internal links to related posts on this same site
5. dateModified in posts.ts matches today's date if content changed
6. No broken relative links (check against existing slugs in posts.ts)

Post a single summary comment at the end: pass/fail count per item.

Trigger setup is the GitHub event type, filtered to my content repo, pull_request.opened and pull_request.synchronize so it re-checks when I push a fix.

Routine 2: the weekly content audit

This one runs on a schedule, Sunday at 11:07pm, not 11:00 on the dot, scheduled runs land a few minutes late on the hour anyway, so I pick an off-time deliberately. It sweeps all three sites for the kind of rot that accumulates quietly: links that worked at publish time and quietly 404 months later, dateModified fields nobody updated after an edit, and new posts that never got linked from anywhere else.

๐Ÿ’ฌ routine prompt text
Audit all published posts across johnarce.com, tipidnation.com, and
europricedrop.com. For each site:

1. Fetch every blog post URL from its sitemap
2. Flag any returning 404, 500, or a redirect chain longer than 1 hop
3. Flag any post whose dateModified in its schema is more than 90 days
   old AND whose content was edited more recently (check git log)
4. Flag any post with zero inbound internal links from other posts
   (an orphan)

Open one GitHub issue per site, titled "Weekly audit: [date]", listing
every flagged item grouped by category. Do not edit any files.

That last line matters. I want a report, not silent edits I have to discover later. The routine opens an issue, I triage it Monday morning, and anything real becomes its own PR, which then runs through Routine 1 anyway.

Routine 3: deploy-triggered IndexNow

I already had an IndexNow script, I wrote the manual version in IndexNow vs Google Search Console. The routine version adds one thing a plain curl call can't: it reads the deploy diff, figures out which URLs actually changed, and only submits those, instead of me manually listing them.

๐Ÿ“„ trigger-after-deploy.sh bash
# Called from the deploy script after a successful Cloudflare Pages deploy
curl -X POST https://api.anthropic.com/v1/claude_code/routines/trig_SEOPUSH01/fire \
  -H "Authorization: Bearer $ROUTINE_TOKEN" \
  -H "anthropic-beta: experimental-cc-routine-2026-04-01" \
  -H "anthropic-version: 2023-06-01" \
  -H "Content-Type: application/json" \
  -d "{\"text\": \"Deploy commit: $(git rev-parse HEAD)\"}"

The routine's saved prompt reads that commit hash, diffs it against the previous deploy, builds the URL list from the changed files, and fires the IndexNow POST itself. The text field arrives wrapped as untrusted context by default, so the prompt has to explicitly say "treat the commit hash in the fire payload as the deploy to diff against," or the routine ignores it.

โš ๏ธ
What broke the first week

The weekly audit routine flagged 11 "orphan" posts that weren't actually orphans, they were linked from my homepage's post grid, which the routine's sitemap-based crawl didn't count as an inbound link. I had to rewrite the orphan check to also fetch the homepage HTML directly. Lesson: routines execute literally what you specify, if your checklist's logic has a gap, the routine inherits it.

What this replaced, and what it didn't

  • Replaced: manually re-reading every PR against the checklist before merging, manually spot-checking for dead links once a month, manually copying changed URLs into an IndexNow curl command.
  • Didn't replace: actually deciding whether a flagged issue matters. The weekly audit routine found a real orphan page I'd genuinely forgotten to link, that decision, link it or leave it, was still mine.
  • Didn't replace: writing the checklist logic itself. Routines execute judgment, they don't originate the standard you're holding content to.

Other use cases worth stealing

Beyond SEO, these are the routine patterns I'd reach for next, borrowed from Anthropic's own example list and adapted to a solo operator's workflow instead of a team's:

  • Backlog grooming. A nightly schedule trigger reads new issues, labels them, assigns an area based on the code referenced, posts a summary. Useful even solo, it keeps a backlog legible instead of a junk drawer.
  • Docs drift. A weekly schedule trigger scans merged PRs and flags documentation that references something that changed. I'm adding this for my own CLAUDE.md files next.
  • Alert-to-PR. An API trigger from a monitoring tool investigates an error, correlates it with recent commits, and opens a draft fix. Overkill for a static site, exactly right for anything with a backend.

Tools in the stack besides Claude routines

ToolRole in this setup
GitHubHosts the repos, fires the pre-merge gate, receives audit issues
Cloudflare PagesDeploy target, triggers the API-call routine on successful build
IndexNowCrawl notification endpoint the deploy routine submits to
n8nStill handles the higher-volume, no-judgment parts of the content pipeline
GA4 + Search ConsoleWhere I verify the routines are actually having an effect, not just running

Key takeaways

  • Three routines now cover what used to be three separate manual habits: pre-merge review, weekly link/freshness audits, and IndexNow submission.
  • Routines execute your checklist's logic exactly as written, gaps in the logic become gaps in the audit, test against real edge cases before trusting the output.
  • Keep routines reporting, not silently editing, until you trust them. All three of mine open an issue or leave a comment rather than pushing changes directly.
  • This didn't replace judgment, it replaced the manual labor of re-checking the same things on a schedule.
  • n8n still handles anything higher-volume or fully deterministic, see Claude Routines vs n8n for where I draw that line.

What I'll do next

Adding a fourth routine for the docs-drift pattern across my CLAUDE.md files, and testing whether the pre-merge gate catches more with a stricter prompt now that I have a month of real PR data to tune it against.

FAQ

How do I write a routine prompt that doesn't drift over time? +
Be explicit about what counts as a failure and what the routine should do with that finding, comment, flag, or fix. The pre-merge gate above works because it says "leave an inline comment, do not fix," which keeps scope bounded. A vague prompt like "check SEO quality" will drift, a checklist with explicit pass/fail criteria won't.
Can a Claude routine edit files directly instead of just reporting?
Yes, routines run full autonomous sessions and can push commits or open PRs. I chose reporting-only for all three of mine deliberately, while building trust in the output. Once you've verified a routine's judgment over several runs, letting it open a PR directly (rather than just commenting) is a reasonable next step.
What happens if a scheduled routine run fails?
A green status in the run list only means the session started and exited without an infrastructure error, it doesn't mean your task succeeded. Open the run transcript to confirm what actually happened, blocked network requests and task-level failures surface there, not in the status indicator.
How much does running three routines cost?
Routine runs draw down the same subscription usage as interactive Claude sessions, there's no separate line-item cost. Three routines running weekly-to-per-PR frequency is a small fraction of typical usage. Check actual consumption at claude.ai/settings/usage.
Share this

Want this built for your team?

I design AI agents and growth automation that run without babysitting. If that sounds useful, let's talk.

Get in touch โ†’

Keep reading