quiet robot

Agent Playground

Recipe: First look at an alert

Pulls the logs for an alert, asks Claude for likely causes, runs read-only checks, and asks a person before any restart. What it does, when to use it, how to make it yours, and what a run costs.

View as Markdown

Takes the first look at an alert the way a careful person would: pulls the recent logs, asks Claude for the likely causes, runs checks that can't change anything, and asks a person before the one step that can, a restart. Either way, it writes a summary.

At a glanceNotes
CategorySafety
ShapeAI, checks, and a person before a restart
PlanFree and up
Needs a Claude keyYes
Limits it comes with1 loop, 900 seconds, $0.10
First look at an alert, as it is on the canvas.Pull the logs (Run command), Likely causes (Ask AI), Run read-only checks (Run command), Is a restart needed? (Decide), Restart the worker (Run command), Leave it running (Run command), Write the summary (Run code). Arrows: Pull the logs to Likely causes; Likely causes to Run read-only checks on Either way; Run read-only checks to Is a restart needed?; Is a restart needed? to Restart the worker on Yes; Is a restart needed? to Leave it running on No; Restart the worker to Write the summary on Either way; Leave it running to Write the summary.Either wayYesNoEither way>_ RUN COMMANDPull the logs✦ ASK AILikely causes>_ RUN COMMANDRun read-only checksno internet◆ DECIDEIs a restart needed?>_ RUN COMMANDRestart the workerno internet · asks a person first>_ RUN COMMANDLeave it running{ } RUN CODEWrite the summary
First look at an alert, as it is on the canvas.
The First look at an alert recipe open in the builder, ready to run.
The recipe in the builder. It needs your Claude key before it can run.

When to use it

  • An alert fires at 2 a.m. and you'd like the first ten minutes of looking done before anyone wakes up.
  • You want AI to suggest causes, but nothing changed on a real system without a person's OK.
  • A monitoring tool can call a webhook when it alerts.

Run it

  1. Open Agent Playground in the dashboard and find First look at an alert under Start from a recipe. In the builder, Recipes in the toolbar lists them too.
  2. Choose Use this recipe. It becomes a flow of your own, so changing it never changes the recipe.
  3. If you haven't yet, save your Claude key under Policies → Secrets. The builder offers Go to Secrets if it's missing.
  4. Choose Simulate to see the forecast, then Run.
  5. When the run waits for a person, approve or deny it from the banner, from Approvals, or from the approval email.

What you'll see: Claude lists three likely causes, the read-only checks find a stuck job, and the run waits before Restart the worker. Whether you approve or deny, Write the summary writes up the alert, the likely causes, the checks and what was done, because the arrow from the restart uses Either way.

Make it yours

  1. Fetch your real logs and status in Pull the logs, using a key saved under Policies → Secrets for any service it calls, so the key never enters the sandbox.
  2. Keep every check in Run read-only checks read-only.
  3. Keep Ask a person first on Restart the worker, and on anything else that changes a system.
  4. Start it from your monitoring tool with a Webhook trigger, and pass the alert in. Claude can read it as {{trigger}}.
  5. Send the summary to your team chat or ticket system.

What a run costs

These are the builder's own forecast for the recipe as it comes, with its limits, rounded. Simulate shows the same numbers for your version, and they change as you change the flow.

NotesTypical1 in 10 runsAt most
Sandbox time$0.0002$0.0003$0.03
Claude, on your key$0.0022$0.0022the run's spend limit
How long it takes20 seconds23 seconds900 seconds

A typical run uses $0.0002 of sandbox time, so about 4,000 runs cost $1, and every plan includes $5 of usage a month. The time includes a person taking a minute or two to answer the approval. The clock, and the sandbox, keep running while the run waits. Claude is billed by Anthropic to your own key, at their usual prices. The run counts it toward its spend limit, so it can't overspend, but we don't charge you for it. At most is the most a run could cost with these limits: it stops at $0.10 or 900 seconds, whichever comes first.

  • Agent PlaygroundQuickstart: build and run your first flow
  • Agent PlaygroundBlocks
  • Agent PlaygroundRecipes
  • SandboxesQuickstart: your first sandbox
  • SandboxesMCP server
  • SandboxesAPI reference