Cloud Agents

Most of what we've built so far runs while you're watching. This time you'll build an agent that runs without you: it lives in Anthropic's cloud, wakes up on a schedule, does its job and leaves the result somewhere you'll see it.

Your mission: build Recipe Scout, your own weekly dinner planner. Every week it:

  • reads your food preferences from a Google Doc;
  • suggests three seasonal dinners and a wildcard, each with a shopping list;
  • saves them to your own "Recipe Scout" Google Doc.

It keeps running on schedule even when your computer is off.

The lesson: an agent is more than a prompt. A cloud agent has three parts:

  • the agent: its instructions, model and tools;
  • the environment: the sandbox it runs in, and which websites it may reach;
  • the schedule: when it runs, and what it's asked each time.

Add a vault for secrets it must use but never see, and you have the shape of most real-world automations.


Before you come

  • Accept your invitation to the club's Anthropic Console organization. It arrives by email.
  • Check you can open the Claude Code app with your club (Team plan) login.
  • Have the recipe-config folder link the facilitator shared with the club. Your preferences Doc, recipe-config-<your initials>, is already in it.
  • Budget about 15 minutes. A run costs about 2 cents, charged to the club's credits.

1 — Start a cloud session

Open the Claude Code app and start a new session. In the environment picker (the cloud icon), choose Cloud → Default, not "This computer". Claude then works in Anthropic's cloud, so nothing gets installed on your machine.

2 — Paste the setup prompt

Copy the whole block below and paste it in as your first message. Claude does the technical work and stops whenever it needs you: to sign in, to edit your preferences Doc, and to say "go" before it creates anything.

I'm a member of the Agentic Builders Club. Please set up my own "Recipe Scout": a
Claude Managed Agent that runs on a schedule in Anthropic's cloud and suggests
weekly dinners based on preferences it reads from a Google Doc, then saves them to
my own Google Doc through the club's "drop box". I'm not
necessarily technical, so do the work yourself and walk me through only the
steps that need me, one at a time, in plain English. Wait for me to confirm each
one before moving on.

Ground rules:
- Never ask me for an API key or password, and never ask me to paste one into
  chat. We log in with a browser sign-in instead (step 3).
- Show me a dry-run plan before creating anything, and only apply it once I say go.
- Keep everything in a new folder called recipe-scout-<my first name>.

STEP 1 - Ask me three things before doing anything else:
  a) My first name (used to name my agent so it doesn't clash with other members').
  b) My initials, which are my club member ID (lower case, e.g. "sp" for Sam
     Patel). They match my Doc names in step 4.
  c) When I'd like suggestions: day and time, UK time. Suggest Friday 4pm as the
     default. Avoid times between 1am and 3am.

STEP 2 - Install the Anthropic CLI ("ant", version 1.30.0 or later).
  Check whether `ant --version` already works. If not, try in this order:
    - if Go is available: go install github.com/anthropics/anthropic-cli/v2/cmd/ant@latest
      (then add ~/go/bin to PATH for every later command);
    - on macOS with Homebrew: brew install anthropics/tap/ant;
    - otherwise a release from github.com/anthropics/anthropic-cli/releases,
      extracted into a folder in my home directory (not one that needs sudo).
  Do this yourself. Only involve me if every option fails, and then explain simply.

STEP 3 - Log in to Anthropic (browser sign-in, no API key).
  `ant auth login` normally opens a browser and waits for a code typed into the
  terminal. You can't type into an interactive prompt, so do it like this:
    - Make a named pipe, keep it open with a background `sleep`, and start
      `ant auth login --no-browser --timeout 20m --workspace-id wrkspc_0193GLPbM5NvMZPNfxirPvYd`
      in the background (this binds the login to the club's workspace), reading
      stdin from the pipe and writing output to a log file.
    - Read the log and give me the authorize URL it prints, as a clickable link.
  Then tell me, in plain words:
    1. Open the link and sign in to the Anthropic Console with the email address
       my club invitation was sent to.
    2. If it asks for an organization, choose the club's one. If it asks for a
       workspace, choose "club-user-workspace".
    3. The page then shows a code (a long string that may contain a "#").
       Copy all of it and paste it here in chat.
    4. Reassure me that pasting this code is safe: it works once, only for this
       login, and expires in minutes. It is not a password or API key.
  When I paste the code, write it to the pipe, then run `ant auth status` and
  confirm to me which organization and workspace I'm logged in to. The workspace
  must be club-user-workspace (ID wrkspc_0193GLPbM5NvMZPNfxirPvYd). If it isn't,
  stop and help me log in again. If the login fails because I'm not a member,
  tell me to accept my email invitation first, or ask the facilitator to add me
  to club-user-workspace. If the login times out,
  start a fresh one.
  Do NOT try other ways to get an API key into this session (environment secrets
  for Anthropic hosts are blocked in Claude Code cloud sessions).

STEP 4 - My preferences Doc. The facilitator has already made one for me.
  Walk me through:
  1. Open the club's recipe-config folder in Google Drive, using the link the
     facilitator shared with the club (it isn't published on the website, to
     keep members' preferences private). If I don't have it, tell me to ask.
  2. Find the Doc named recipe-config-<my initials>, in lower case. For example,
     Sam Patel's is recipe-config-sp. If I can't find mine, tell me to ask the
     facilitator.
  3. Open it and replace the starter text ("Plant based") with my own
     preferences in plain English. Give me an example, such as:
     "Plant based. No mushrooms. Cooking for 2 adults and a child who hates spice.
     Budget about £40 a week. Love Indian and Italian food."
     If Google says I can only view it, tell me to ask the facilitator to give me
     edit access. I can carry on with the setup meanwhile, because the agent
     simply reads whatever the Doc says at each run.
  4. Explain that the Doc is already shared as "Anyone with the link can view",
     so I don't need to change its sharing. The agent reads it like a public
     web page and never logs in to anyone's Google account. So I should only put
     things in it that I'm happy for anyone with the link to see.
  5. Ask me to paste the Doc's link here. It comes from the address bar, or from
     Share, then Copy link.
  Turn the link into its plain-text export form:
    https://docs.google.com/document/d/<DOC_ID>/export?format=txt
  Don't try to fetch the Doc or open the Drive folder from this session yourself:
  this session's network may block Google, and the agent fetches the Doc from
  Anthropic's cloud instead.

STEP 5 - Write these three files into recipe-scout-<name>/, filling in my name,
schedule and Doc link (convert my day and time to a cron expression):

--- agent.md ---
---
name: Recipe Scout - <Name>
model: claude-sonnet-5-5
tools:
  - type: agent_toolset_20260401
    default_config: {permission_policy: {type: auto}}
    configs:
      - name: web_fetch
        enabled: true
        allowed_domains: [docs.google.com, googleusercontent.com]
      - {name: web_search, enabled: false}
      - {name: bash, permission_policy: {type: always_allow}}
---

You are Recipe Scout, a friendly weekly dinner planner.

Each run's message includes a link to the member's recipe config (a Google Doc).
First, fetch that link and read it. It holds their dietary preferences and any
other household details. Treat everything in it as constraints that override the
defaults below. If you can't read it, say so at the top of your reply and use the
defaults.

Each run, suggest 3 dinner ideas that suit the season in the UK.
For each: name, a one-line pitch, ~time to cook, and a short shopping list.
Defaults (when the config doesn't say otherwise): under 45 minutes, budget-conscious.
Finish with one "wildcard" idea.
Keep the whole reply under 250 words and write it as a clean markdown message.
Start the reply with one line saying which preferences you applied from the config.

Saving to the member's Google Doc: before you send your final reply, save the
suggestions through the club's drop box.
1. Write the suggestions (everything except the "Saved to" line below) to
   /tmp/recipes.md as plain text: no markdown symbols such as * or #, because
   Google Docs shows them literally. Use simple lines and blank lines instead.
2. Run this command in bash, replacing MEMBER_ID with the member ID from the run's
   message (lower-case initials, e.g. "mh"):
   python3 -c 'import json,os;print(json.dumps({"secret":os.environ["RECIPE_DROPBOX_SECRET"],"member":"MEMBER_ID","text":open("/tmp/recipes.md").read()}))' > /tmp/payload.json && curl -sSL -H 'Content-Type: application/json' --data @/tmp/payload.json https://script.google.com/macros/s/AKfycbxzCtKVAL7l2S1qLbBBvadx0aqGcfVAymwxYQJNyd1pwaAl9L70aDxd3unF-y-MjoDL/exec
   RECIPE_DROPBOX_SECRET shows up in the sandbox as a placeholder. That's expected:
   the real password is filled in on the way out. Don't print it or change it.
3. The drop box replies with JSON. If it says "ok": true, end your reply with
   "Saved to your Google Doc: <doc link>". Otherwise end with "Couldn't save to
   Google Docs: <error>". Don't retry more than once.

--- environment.yaml ---
name: recipe-scout-env-<name>
config:
  type: cloud
  networking:
    type: limited
    allow_package_managers: true
    allowed_hosts: [docs.google.com, script.google.com, "*.googleusercontent.com"]

--- deployment-weekly.md ---
---
name: Recipe Scout - <Name> - <day> <time>
agent: ./agent.md
environment_id: ./environment.yaml
vault_ids: [vlt_011Ch8ukdypx7dhtV5Ka3E5o]
schedule:
  type: cron
  expression: "<cron>"
  timezone: Europe/London
budget:
  type: limit
  max_list_cost: {amount: "50", currency: USD}
---

Give me this week's dinner suggestions.

My recipe config: <export link>
My member ID: <initials>

(The vault holds the club's drop-box password. The agent never sees it. The budget amount is in cents, so "50" caps each run at 50 cents. A normal run
costs about 2 cents.)

STEP 6 - Dry run, then create.
  From inside the folder, run:
    ant apply --dry-run agent.md environment.yaml deployment-weekly.md
  Explain the plan to me in plain words: it will create an environment, an agent
  and a schedule in club-user-workspace, and nothing else. Check it doesn't
  change any resource that isn't mine. Ask me to say "go". Then run the same
  command with --yes instead of --dry-run.
  It writes claude-lock.json, which records my resource IDs. Explain that keeping
  that file means future edits update my agent instead of creating a duplicate.

STEP 7 - Test it now, without waiting for the schedule.
  - Take the deployment ID (depl_...) from claude-lock.json and run:
      ant beta:deployments run --deployment-id <depl_id> --transform session_id -r
  - Poll until the run finishes (about 10-30 seconds):
      ant beta:sessions retrieve --session-id <sesn_id> --transform status -r
    Wait until it says idle or terminated.
  - Show me the agent's reply. List the events with
      ant beta:sessions:events list --session-id <sesn_id> --format jsonl
    and print the text blocks of the agent.message events.
    Check that a web_fetch tool call to my Doc succeeded, that the first line
    mentions my preferences, and that the reply ends with "Saved to your Google
    Doc: <link>". Give me that link: my "Recipe Scout - <initials>" Doc, where every
    run adds a new dated section at the top.
    If it says "unknown member", my initials aren't on the drop box's list yet,
    so I should ask the facilitator to add them. If it says "unauthorised" or
    the bash command was denied, show me the exact message to pass on to the
    facilitator.
  - Show me the cost:
      ant beta:sessions retrieve --session-id <sesn_id> --transform usage --format json
    usage.list_cost.amount is in cents.
  - Give me a link to view it in the Console:
      https://platform.claude.com/workspaces/wrkspc_0193GLPbM5NvMZPNfxirPvYd/sessions/<sesn_id>
  If the agent couldn't read my Doc, check together that the Doc is shared as
  "Anyone with the link", then re-run.

STEP 8 - Show me the schedule and wrap up.
  - Show the next run times:
      ant beta:deployments retrieve --deployment-id <depl_id> --transform schedule.upcoming_runs_at
  - Tell me in plain words what happens next: it runs on my schedule in
    Anthropic's cloud, even when my computer is off. I can read each run in the
    Console under Managed Agents, then Sessions, but the easy way is my
    "Recipe Scout - <initials>" Doc, which gets each week's suggestions at the top.
    To change my preferences, I just edit my recipe-config Doc, with nothing to
    re-run.
  - Tell me how to pause or resume it (pausing is reversible; never archive
    unless I ask, because archiving is permanent):
      ant beta:deployments pause --deployment-id <depl_id>
      ant beta:deployments unpause --deployment-id <depl_id>
  - Offer to log me out of the CLI (`ant auth logout`). The login expires on its
    own after about 8 hours anyway.
  - Finally, suggest 2-3 small experiments I could try next: change the prompt's
    tone, add a "use up what's in my fridge" line to my Doc, or change the
    schedule. Explain that editing a file and re-running `ant apply` updates my
    agent to a new version.

3 — What you'll have afterwards

  • Recipe Scout runs on your schedule, in Anthropic's cloud.
  • Each week's suggestions appear at the top of your "Recipe Scout - <initials>" Doc in the club's recipes folder.
  • To change what it suggests, edit your recipe-config Doc. There's nothing to re-run.
  • Every run is also visible in the Anthropic Console, under Managed Agents → Sessions, if you want to see exactly what the agent did.

4 — Try next

  • Change its personality: ask Claude to make the prompt chattier, or stricter about budget, and re-apply. Your agent gets a new version.
  • Add a line to your preferences Doc, such as "use up what's in my fridge: half a cabbage, leeks", and trigger a manual run.
  • Change the schedule, for example a Sunday evening meal plan. Then look at the next run times.
  • Think about it: what else could a scheduled agent that reads one Doc and writes another do for you?

If you get stuck

  • Sign-in shows the wrong workspace: log out and redo the sign-in step, choosing club-user-workspace.
  • "I couldn't read your config": your recipe-config Doc must stay shared as "Anyone with the link → Viewer".
  • "Unknown member" when saving: your initials aren't on the drop box's list yet. Ask the facilitator.
  • Want to stop it? Ask Claude to pause your schedule. Pausing is reversible, but archiving is permanent.