Claude Code adds Routines to automate repo workflows in the cloud

Anthropic has rolled out Claude Code Routines in research preview, letting teams package prompts, repos, and connectors into automations that run on schedules, APIs, or GitHub webhooks. It runs on Claude’s web infrastructure, with plan-based daily limits.

claude cover

TL;DR

  • Claude Code routines (research preview): Automation layer for Claude workflows; define prompt, repo, connectors; runs on Claude Code web
  • Triggers: Scheduled, API, and GitHub webhook routines; run by cadence, HTTP POST, or repo events
  • Scheduled routines: Hourly/nightly/weekly prompts; replaces CLI /schedule scheduled tasks; example nightly Linear bugfix draft PR
  • API routines: Per-routine endpoint and auth token; POST returns session URL for deploy hooks, alerts, internal tools
  • Webhook routines (GitHub): Filtered repo events create per-PR sessions; PR comments and CI failures feed follow-up handling
  • Availability and limits: Pro/Max/Team/Enterprise with Claude Code web enabled; daily caps 5/15/25 runs; extra usage available

Claude Code routines are landing in research preview as a new automation layer designed to run Claude-driven workflows without the usual background babysitting. The idea is straightforward: define an automation once—prompt, repo, and connectors—then run it on a schedule, trigger it via an API call, or fire it from an event. Because routines run on Claude Code’s web infrastructure, they don’t depend on a local machine staying online.

In practice, routines package up work that previously meant owning the glue: cron, infrastructure, and extra tooling such as MCP servers. With routines, that packaging also includes access to repositories and connectors, so the automation can act with the same context Claude Code already uses interactively.

Three ways to trigger a routine

Claude Code routines come in three flavors, each aimed at a different “automation entry point” teams tend to build around.

Scheduled routines

Scheduled routines run on a cadence—hourly, nightly, weekly—based on a prompt. Anthropic notes that tasks previously scheduled via /schedule in the CLI are now considered scheduled routines.

A representative example: a nightly job that pulls the top bug from Linear, attempts a fix, and opens a draft PR.

API routines

API routines are designed for systems that can make an HTTP request. Each routine gets its own endpoint and auth token; a POST returns a session URL, which makes it possible to pipe in payloads from deploy hooks, alerting systems, or internal tools.

One example prompt focuses on operational triage: ingesting an alert payload, identifying the owning service, then posting a summary and proposed first step to an on-call channel.

Webhook routines (starting with GitHub)

Webhook routines can subscribe to GitHub repository events and run automatically based on filters, creating a new session per matching PR. Claude Code also continues to feed PR updates—like comments and CI failures—into that session for follow-up handling. Anthropic says webhook-based routines will expand to additional event sources over time.

Common patterns emerging in early usage

Anthropic points to a few routine “shapes” that early users are building:

  • Backlog management and docs drift checks as scheduled routines
  • Deploy verification, alert triage, and feedback resolution via API-triggered routines
  • GitHub-triggered workflows like cross-language library ports and team-specific code review checklists, with inline comments produced before a human reviewer steps in

Across these examples, the through-line is tooling that stays close to the repo while also reaching outward through connectors and event triggers.

Availability and limits

Routines are available to Claude Code users on Pro, Max, Team, and Enterprise plans, as long as Claude Code on the web is enabled. Creation happens at claude.ai/code, and scheduling can also be initiated via /schedule in the CLI.

Usage follows subscription limits like interactive sessions, with additional daily routine caps:

  • Pro: up to 5 routines/day
  • Max: up to 15 routines/day
  • Team/Enterprise: up to 25 routines/day

Additional runs beyond the daily limits are available with extra usage, with more details in the routines docs.

Original source

Continue the conversation on Slack

Did this article spark your interest? Join our community of experts and enthusiasts to dive deeper, ask questions, and share your ideas.

Join our community