Claude Routines Just Dropped, And It's Perfect
607 segments
Well, Anthropic just launched routines,
which allows Claude to kick off
automations via schedule, trigger, or
even webhook. And this closes the loop
and basically turns Claude into a
dedicated automation platform competing
with no-code drag-and-drop builders like
n8n and others. In this video, I'm going
to show you guys how you can build
routines very quickly. I'm going to give
you guys a couple of demos. Then I'm
going to walk you through step-by-step
setting up your own routines on both the
Claude desktop interface as well as
behind the scenes via API. Okay, so for
the most prototypical example, I have a
daily mailbox summary plus draft
routine. And what I'm doing here is I
just clicked run now because they have a
little demo or test feature that allows
you to actually run it and then see the
inputs and outputs live. If I click on
this little runs button, you'll see that
all I've really done is I've just fed in
a prompt. And this is the exact same
thing as Claude Code. It's just
occurring on a standardized cloud
container, not on my computer. And in
this case, I'm just testing it using
their interface, but you can also
schedule it. You can have it triggered
based off webhook, and then you can also
send an API request to trigger it. And
so you can trigger it based on incoming
data, you can trigger it based on
outgoing data. It's very powerful. If
anybody has watched my previous video on
agentic workflows, this is basically the
standardized and enterprise version of
agentic workflows.
So this is now searching through Gmail
emails. It's actually doing everything
more or less that I would normally do if
running this locally on my computer. The
only difference being obviously that
because it's occurring on the cloud,
it's not something that I realistically
am going to want to have to steer.
Typically, you want to be a lot clearer
about the instructions and make sure
that it has all the information that it
needs. After that, it's just going to go
through various tool calls and
everything like that until it gets to
the definition of done, which in my case
is going to be, "Hey, once you're
finished, use a Slack connector to send
me an update." Now, on the Claude Code
docs page, the majority of the use cases
are what I'd consider to be overly
technical things like backlog
maintenance, alert triage, bespoke code
review. I mean, most people don't even
know what any of this stuff means. But I
want you to know this is basically a
stand-in replacement for automation. You
can automate anything using this tool.
And what's really cool is you can do it
using natural language. So what I've
done is I've developed a Claude skill
that you can import into your own
workspace. Then you can just give that
skill any pre-existing workflow, whether
it's in natural language, written as an
SOP, or it's something on a no-code tool
like n8n or make.com. Back to the skill
page here, you can see it's found two
unreads. The thing is, I don't really
care about this because if you think
about it, this is the conversation
thread. What I want to do is I want to
see this Slack update that was sent to
my DMs because, you know, if I'm using
this like a traditional automation,
that's where I'd probably
So if I go, I actually see I did receive
a notification at 12:01 where it pulled
my unreads and then it fed me the
information as well as like a high-level
summary along with a polite decline that
it drafted as well as an acceptance for
for this one. And I can go on to my
email and I can actually open up the
drafts and I could I could see them all
as well. And just because I'm trying not
to dox all of these people too hard, you
know, in this case, I immediately
drafted, "Hey Corey, thanks for reaching
out. Tell the other Net Kai own one.
Happy to come on. Send over a few time
slots that work on your end." And then I
just removed the two email that was
previously populated. Okay, so that's
probably the simplest example of a demo.
And I just did all this stuff
live using the test feature because I
wanted to show you that that's how it
works. But you can also schedule it, and
then you can also fire things off based
off webhooks and API calls. So what I'm
going to do next is I'm very quickly
going to show you how the scheduling
feature works. And then after I'm going
to show you how you can use triggers
like webhooks and so on and so forth to
run your routines. Once we're done with
that, I'll actually walk through like
the UX and show you guys more of the
deep dive behind how this works. So
anyway, for scheduling purposes, all you
need to do is go back to the routine
that I made a moment ago. Okay, click on
this little button here, and then I can
just select a different trigger. So in
this case, I have call via API, but I
could also click schedule. And as you
can see here, we have this little visual
interface where I can select hourly,
daily, and so on and so forth. Because
this is going to be an email triage
flow, I'm probably going to want to run
this pretty early before I wake up. I'm
waking up around 5:20 these days, so
it'll probably be about 5:10. And what I
should note is you can add multiple of
these triggers at any point in time. So
now, after saving, if I go back to
routines, you'll see there's a little
calendar feature here, and you can now
see that there's a daily mailbox summary
plus draft open at 5:10 as well as a
couple of other ones that I was playing
around with earlier today. You don't
have to pay attention to those. What
that means is without me having to do
anything, the exact same exercise is
going to occur. The agent is going to
check my mailbox using the Gmail
connector. It's going to run through
whatever SOP or logic that I gave it,
which in this case was just, "Hey, go
see if we had any previous email
communicate." And then it's going to
draft up the message and send it to me
in Slack. Okay, what I have here is
another routine. This one takes a
transcript that is generated using
Fireflies, which is a transcript service
that joins your call, listens to what
you say, and then basically stores it
all as text. And essentially, what I'm
going to do just for the purposes of
this demo is I'm going to do it via API
request, but I'm going to show you guys
as well how you can hook it up via
webhooks, which just fires
automatically. So I have my transcript
to proposal routine right over here, and
I could click run now, but there's no
actual transcript. The instructions here
are I give you a transcript via API
call. So what I'm going to do is I'm
going to open up a Claude Code, and
since I'm just going to have it send an
API request using
this transcript.
And then I'm just going to press enter.
And I'm not going to expand this because
I've just hardcoded an API key for demo
purposes, but you can see here what it's
going to start off by doing is basically
sending that curl request as a text
payload and then also generating the
proposal entirely on its own. And when
this occurs, it's actually going to
trigger that routine.
I guess I already just leaked my API
key, whatever the hell.
It's going to fire that routine, which
it's done right over here, and now it's
actually running in the cloud with the
full transcript and whatever the deal
terms are of the, you know,
conversation. And so I can actually open
this up, and then I can see what's going
on. So you can see, "I give you a
transcript via API call. I want you to
create a full proposal using one of my
other AI agents in a managed session."
And this is where managed sessions come
in handy, which if you guys didn't know
is just a similar way that you could set
up different endpoints out there that
allow AI to basically create an an
interconnected network of managed agents
or agents that all have their own siloed
containers both for security and then
safety purposes. So it's just verifying
that we actually have what we need for
Slack, and now it's going to go ahead
and generate a high-quality proposal.
Now, I just want to be clear about what
problem exactly this solves. The old way
of designing automations typically
involved some sort of event or outside
trigger like a schedule, maybe something
that occurred, you know, at 5:00 a.m.
every morning or whatever.
That event would be fed into a platform
like n8n, which was responsible for
basically proceeding through a chain of
logic that you created. You know, it'd
be a bunch of drag-and-drop nodes that
you put together to do some function. In
this case, this is a Reddit scraper for
a live build that I did for one of my
communities. And see, this whole section
in the middle here, this logic, this can
take a fair amount of time to put
together. You know, you have to drag and
drop all these nodes, you have to set up
all of these credentials, you have to do
all the authentication, you got to get
the data and and map the right variables
in the fields. This is really like where
the meat and potatoes of your work as
somebody that's looking to automate your
business um um came in.
Okay, and then from there, your n8n
system, typically it doesn't just like
work by itself. It does something to
some platform, right? So it would then
grab its output and then shove that into
Slack or maybe some sort of CRM
somewhere or whatever it is that you do,
some database. The new way is basically
the exact same thing. You have an event,
okay, and that event is either an API
call, it's a webhook, or it's some sort
of schedule. So again, you know, waking
it up at 5:00 a.m. every morning. It's
just instead of putting that into n8n
and then having to build all that stuff
yourself with those drag-and-drop nodes,
all you have to do, okay, is just give
it some natural language, which is far
easier obviously with some very
high-level instructions, and then it can
then output things as
n8n did before to, you know, some other
platform, Slack or CRM.
And so the reason why I'm equating it
like this is because routines
effectively solve that middle problem.
I've made some videos in the past to the
tune of n8n is over because XYZ thing is
now launched and it does it way better.
And you know, sometimes a specific
feature was missing that, you know, n8n
or some other no-code platform handled
that didn't make it an exactly
one-to-one overlap. But routines are
Claude's literal one-to-one overlap. It
replaces the exact same functionality.
It's capable of scheduling, it's capable
of orchestrating workflows, and so on
and so forth. And it really is like the
next step in agentic execution of
knowledge tasks. When all this stuff
finishes, I actually have the proposal
right over here. I can take a look at
that. Click this button to open it in
new page, and you can see I now have the
proposal, which is just part of the
template of the managed session that
generates this thing.
Pull out all of the data. So, you know,
we're we're an AI content writing
marketplace that matches business
clients with vetted freelancer writers.
And then this is Left Click, which, you
know, is pitching them. And so these are
the sorts of proposals that we actually
send day-to-day. And hopefully you guys
see how easy it is to actually like
integrate a routine or some sort of API
event-based system into your
infrastructure like 2 minutes.
Uh boy, have we come a long way from
back in the day when me designing that
proposal generator would have taken like
2 and 1/2 to 3 hours. The current UX for
routines looks like this. And in order
to get there, all you have to do is type
in claude.ai/code/routines.
You'll be given a page that looks
something like this where you can see
all routines stored in a grid-like
pattern over here alongside their title,
the time that they are running, and then
also the the next scheduled run, as well
as what looks like some category
listing, which they provide with or
without you. There's also a calendar
view, and so you can see the actual ones
that are going to be executed and
exactly which times they're going to be
executed. And so here I created a couple
of demos, daily unread mention scan,
morning inbox drafts, and news video
ideas. You can see that today, this
one's going to execute at 6:51, this one
at 7:43, and this one at 8:17. So you
also get a little bit of a visual aspect
there. When you click new routine up in
the top right, it'll immediately ask you
for some information like the name. So
I'm just going to provide a quick demo
here called mailbox drafter. Next, you
can describe what Claude should do in
each session. So this is where you
basically give it a prompt. And this
prompt is essentially analogous to a
skill. Just like in a skill, you have a
standardized list of steps that you need
the model to take in order to perform
some economically valuable piece of work
for you. Um so, too should you construct
this routine description like a list of
SOPs or steps to allow it to perform uh
tasks for you. It's just my
recommendation here is be a little bit
more precise than you were probably in
your skill because whereas in your
skill, you could modify things on the
fly, change your trajectory of the task,
and so on and so forth. Here, the
routine occurs entirely hands-off,
meaning that it basically needs to work
almost perfectly every time. So,
decrease the total scope of possible
mess-ups and screw-ups that it could
make by being as clear and precise as
possible. But for instance, I wrote pull
all of my unreads using the provided
Gmail connector, more on that in a sec.
For each unread, check if there's any
pre-existing conversations with that
contact. If so, pull those two for
context, then draft replies based on
what you know about me and the con- text
of the task. Once done, use the Slack
connector, more on that in a sec, to
send me an update. And so, as you can
see here, um you know, you can make this
about as long or as a short as you want.
I don't believe there's a length limit.
I went and I checked just by pasting
this a bunch of times, and I couldn't
find anything. So, uh I would definitely
lean on the side of more context as
opposed to less.
From there, you can select a repository.
So, whatever repository you want, I'm
just going to say this business one. You
can select a model type. So, I'm going
to use Opus 4.61 mil. And then you can
also select which cloud environment you
want to run it in. And so, you can here
basically create a cloud environment
with a bunch of environment variables,
keys, uh you know, API credentials, and
so on and so forth as needed. So, in my
case, I'm fine with default. I'm just
going to move on. You can then select a
trigger. So, you can schedule it. You
can go via GitHub event, or you can go
via API. Now, realistically, this is
probably something you're going to want
to do on a schedule since we are just
going to be going through unreads and
then drafting. But for demonstration
purposes, I'm just going to go via API.
And the whole idea is by doing this,
I'll be able to very quickly call and
then test in another Claude Code
instance to show you guys what's
happening live. So, I'm just going to
add a trigger.
And then once we've added said trigger,
we are going to receive a little curl
request, which is a snippet of code that
you can give any model. And finally, now
we just need to add our connectors. So,
here I'm going to click add connector,
and then I'm going to connect my own
Gmail. By the way, if you don't have a
connector, just head on down to Claude
Code settings, then go to connectors
over here. Then you can actually add uh
just clicking on this little connect
button. When you do, it'll ask to
connect Claude to your Gmail account.
click continue, and then you can sign
into the particular one that you want.
So, in my case, this. I'm also going to
need one other connector, if you guys
think about it, because I'm going to
want a Slack message sent. So, here I
can use this little search bar, and then
click a plus button. Then I'll just have
to perform again some OAuth in a new
browser tab. Here, I'm going to click
allow, and just like any simple OAuth
screen, we're now going to be connected.
So, now what we can do is we can go back
to the routine, and then I can add the
connector manually. From here, you'll be
given a token. You can copy that token,
store it somewhere safe. So, that's what
I'm going to do here.
And now we basically have our skill or
our routine ready to go. Okay, and then
once you're done, just head over to the
run now in the top right-hand corner to
basically start the workflow run. And uh
we're just going to do this here using
the GUI, graphical user interface, for
testing purposes. But you'll see a new
little run just populated. So, maybe go
down here, and you'll see all we're
really doing is we're just sending it
this message.
Once it's done, it'll use the Slack
connector to send me an update. You can
see it's already starting to fire off a
tool search. So, I'll just double back
when it's done. And I should note, I
mean, I'm watching it here, but the
whole idea is that I don't even know
what this thing's going on, right? This
was triggered uh ideally on a schedule
or something like that. And I just wake
up in the morning to my Slack uh message
with a bunch of different emails and
their various drafts. If I head back
over here, you can see that we actually
have both of those fed in. Um looks like
somebody invited me for a podcast
interview, and then somebody else asked
me a couple of questions about uh a few
things here. Finally, I want to show you
guys how easy it is to convert workflows
that you built on third-party tools like
n8n, for instance, into uh routines. And
what's really cool about n8n is they
allow you just to like mouse over if you
hold shift, and then hold command C, or
just right-click and press copy. And
then now you basically have access to a
bunch of JSON. And you could tell just
by me pasting it in, this is like JSON
or the uh syntax that these nodes are
represented in if we're talking through
text. Well, anyway, if I go back to
antigravity, which contains my little
Claude Code window, and then I type in
this JSON, and then at the very top, I
say use the routine generator to turn
this n8n workflow into a routine. Okay,
I'm just going to divide this to make it
really simple. Uh what this is going to
do is use the skill that I'm giving all
of you guys out of the box to basically
turn this into a flow that we can call
just using natural language. So, I'm not
necessarily going to encourage you to
use all of your workflows or to port
them over from n8n or some other no-code
tool to uh Claude's back end. Reason
being is, you know, when you're dealing
in the domain of tokens, things are
going to be a little bit more expensive
than dealing entirely in the domain of
compute. And really, the point is not,
"Hey, just turn all your n8n or make.com
workflows into routines." The point is
more like, you know, if you have
something you can build today that
previously would have taken you a couple
of hours in n8n, might make more sense
just to one-shot it as a routine.
But um you know, what this will do
really quickly is just go ahead and do
the creation. So, as you guys can see
here, it's doing some thinking, it's
loading the routines. In this case, it's
just going to schedule one cuz I didn't
provide any context as to how I wanted
to run it.
Um but yeah, here we go. It's now going
to fetch stories from the Hacker News
Algolia API, extract the hits, format
them into a markdown report, and commit
it, which was what the actual flow was
doing. And so, just like this one here,
if I click execute workflow, this goes
through the scraper. It then generates a
bunch of hits basically from um a
website called Hacker News. Hacker News
is the source here, which in this case
is going to contain a bunch of different
um comments like this one on how
open-source AI is the path forward.
Certainly not when Claude drops a
freaking update like this. Well, the
same routine is going to work here the
exact same way. And you can see it just
had routine created and fired. Hacker
News AI stories fetch, right? What's
really cool about this is, I mean, it's
it's just so easy for me to to change
things. Um so, I mean, right now, this
is obviously going to fetch that data,
right? And you know, fetching that data
is okay. But what am I going to do with
it? It's just sort of like stuck here,
right? You know, if I were in n8n, I'd
have to modify this. Uh it'd be
significantly harder to modify this.
Here, I can literally just go
connectors, Slack. Okay, save.
I can then set it to run on, you know,
7:33 MDT or via API request, which I'm
going to click done. And now what I can
also do is I can go back here, and I can
say, "Great, update this so that it
sends me a message in Slack with the
scrape after it's done." And now in 3
seconds, you know, we can make an HTTP
request over to the routine and just
edit it on the fly for me. I don't have
to drag and drop any nodes. It's much
easier and much faster. Okay, so
hopefully you guys can see that this has
a lot of potential, and you're likely to
see larger and larger flows be passed
off to agents in this manner.
Um I didn't really give you guys an
extraordinarily comprehensive look at
all the different things you could do
with us. But just off the top of my
head, some ways that I'm implementing
this in my agency today, some ways that
I've already done so, and some ways that
I can I'm going to continue to do so
after this video,
are I'm going to replace all of my
proposal generators with these built-in
routines. I'm going to connect a couple
of additional routines so that after a
call, like a sales call with a prospect,
um I'll receive a webhook with um
essentially like a transcript. I'm going
to feed that transcript into a routine
that's going to generate an immediate
post-call email, and then uh like a
workflow diagram draft based on our
conversations that I can also pin
alongside it just for the impression of
of more effort and higher perceived
quality
uh when we send out the proposal, I'm
going to be monitoring to see if
somebody signed. When they do, it's
going to write back to another routine
via a webhook, which is going to proceed
with the next step, which is sending
them a message uh with an email with an
onboarding uh you know, calendar
notification, as well as congratulating
them and thanking them on on coming
aboard.
You guys can automate more or less all
of the non like human face-time steps in
a business right now. And it's not like
you couldn't before. It's just in order
to do it before, it was pretty
laborious, and you needed a fair amount
of know-how. Um now, as long as you
understand sort of the routine spec and
more or less what I've showed you in
this video, you guys are good to go. So,
it's an exciting time to be in AI and
automation. Hopefully you guys
appreciated this video. Looking forward
to the next one. Catch y'all on it.
Ask follow-up questions or revisit key timestamps.
This video explores Anthropic's new 'Routines' feature for Claude, which enables users to build automated agentic workflows using natural language. The presenter demonstrates how routines can replace traditional no-code platforms like n8n by scheduling tasks, handling webhooks, and using API triggers. Key use cases discussed include automating email triage, transcript-to-proposal generation, and integrating connectors like Gmail and Slack to create end-to-end business automations.
Videos recently processed by our community