Skip to content
AI Primer
breaking

Claude Code ships Routines in research preview with API and webhook triggers

Anthropic introduced Claude Code Routines, a cloud-run automation layer that can execute on schedules, API calls, and GitHub events. The rollout moves scheduling from local runs to hosted, persistent automation and adds new trigger surfaces for plan-wide use.

5 min read
Claude Code ships Routines in research preview with API and webhook triggers
Claude Code ships Routines in research preview with API and webhook triggers
Claude Code ships Routines in research preview with API and webhook triggers

TL;DR

  • Anthropic launched Claude Code Routines in research preview on April 14, with the launch thread and the official announcement defining them as saved automations that run on Anthropic's infrastructure instead of your laptop.
  • According to Anthropic's trigger overview and the Routines docs, one routine can now be started three ways: on a schedule, from a per-routine API endpoint, or from GitHub events.
  • Anthropic says existing /schedule jobs are now routines with no migration, while the docs add that the CLI still creates scheduled routines only, with API and GitHub triggers managed on the web.
  • Anthropic's availability note and the blog post put the feature on all paid Claude Code plans with Claude Code on the web enabled, but the preview comes with changing behavior and daily run caps.
  • The practical shift is in the API example and the GitHub webhook example: Claude Code is moving from ad hoc local sessions to hosted automations that can sit behind alerts, deploy hooks, and PR workflows.

You can read Anthropic's announcement, skim the docs page, and even watch TestingCatalog's UI clip for the new routine editor. The docs also hide a few useful specifics: API triggers POST to a dedicated /fire endpoint with a bearer token, GitHub triggers already cover pull requests, pushes, issues, and workflow runs, and /schedule now doubles as the management surface for listing, updating, and manually running existing routines.

Routines

Anthropic's definition is simple: a routine is a saved Claude Code configuration made of a prompt, one or more repositories, and connectors, then replayed automatically on Anthropic-managed infrastructure. The blog post positions that as an escape hatch from homegrown cron jobs, custom infra, and extra MCP plumbing.

The new object is broader than the old scheduled task. Anthropic's follow-up says existing /schedule tasks were converted automatically, while TestingCatalog's summary describes routines as extended schedules with new trigger surfaces and a new UI.

Three trigger surfaces

The core mechanic is that one routine can carry more than one trigger. The docs explicitly allow combining them, so the same routine can run nightly, fire from a deploy script, and react to repo events.

  • Scheduled: hourly, daily, weekdays, or weekly in the UI, plus custom cron expressions via /schedule update in the CLI, with a minimum interval of one hour, according to the docs.
  • API: a per-routine HTTP endpoint plus a bearer token. Anthropic's API example says a POST returns a session URL; the docs add that the request body can include an optional freeform text field for alert payloads or logs.
  • GitHub: webhook routines respond to repository events. Anthropic's webhook post gives the PR-monitoring example, while the docs list pull requests, pushes, issues, and workflow runs as supported sources.

Anthropic's own examples are unusually concrete. The blog post suggests backlog grooming, docs drift detection, deploy verification, alert triage, bespoke PR review, and cross-language library porting.

Cloud sessions, not local jobs

The product line Anthropic is drawing is clearer in community explanations than in the announcement. Corey Ganim's comparison separates three modes: routines for set-and-forget cloud automation, desktop scheduled tasks for runs that need local access, and /loop for immediate foreground work.

That lines up with the fine print in the docs. Routines run as full Claude Code cloud sessions, with no permission-mode picker and no approval prompts during execution. They can run shell commands, use skills committed to the cloned repository, and call included connectors, but their reach is bounded by the selected repositories, environment settings, network access, variables, and connector list.

The same page also makes one operational detail explicit: a routine cloned from the web starts from each repository's default branch and creates claude/-prefixed branches for its changes.

Surfaces and migration

Anthropic shipped routines into several entry points at once. The docs say you can create them from the web, the Desktop app, or the CLI, and all three write to the same cloud account.

The surfaces are not symmetric:

  • The web app at claude.ai/code/routines is the full editor.
  • The Desktop app shows both local scheduled tasks and cloud routines in one grid.
  • The CLI command /schedule can create scheduled routines, then list, update, or run them manually.
  • API and GitHub triggers are edited on the web, not from the CLI, according to the docs.

That migration path is deliberately low drama. Anthropic says if you were already using /schedule, there is nothing to migrate.

Limits, identity, and preview caveats

The part worth bookmarking is not the marketing line, it is the accounting model. The blog post says routine runs consume normal subscription usage and also hit daily routine caps: 5 per day on Pro, 15 on Max, and 25 on Team or Enterprise, with extra usage available beyond that.

The docs add two details that materially shape how these runs behave. First, routines belong to an individual Claude account, not a shared team object. Second, anything they do through GitHub or connectors is attributed to the linked user identity, so commits, pull requests, Slack posts, and ticket updates all show up as that person.

Anthropic is also being fairly explicit about the instability budget. The docs label routines a research preview and say behavior, limits, and the API surface may change, while the launch thread's availability note limits access to paid plans with Claude Code on the web enabled.

🧾 More sources

TL;DR2 tweets
Top-line facts about what shipped, triggers, migration, availability, and the shift to hosted automation.
Routines1 tweets
Defines the new feature and its relation to prior /schedule tasks and the new UI.
Three trigger surfaces2 tweets
Covers the three ways routines can start, anchored to Anthropic's own examples.