Skip to content

Session setup

Complete four checks before the workshop: tools, account, deployed starter, and Docker. Your first working result is a browser page that says pong.

Bring your own Cloudflare account with Workers Paid. Create an account if needed. Workers Paid starts at $5 USD/month, plus applicable usage; AI and container usage is billed to your account. No model API keys are needed.

One setup, two ways to follow it

Already comfortable with your tools? Run the commands and compare the results. Open any help you need.

0 of 4 checks confirmedYour finish line ↓
Tick each check after it succeeds. Your place is saved in this browser.

Use Git Bash on Windows, Terminal (zsh) on macOS, or Bash on Ubuntu. Call this window Terminal A.

Terminal window
node --version
npm --version
git --version
curl --version

Look for: Node 24.11+ within Node 24 (recommended), or 22.19+ within Node 22; the other commands each print a version. Missing something? Install only the missing tools.

Help me choose a terminal and Node version

On Windows, open Git Bash from Start; in VS Code choose the Git Bash terminal profile. The commands in this guide use Bash-style syntax, not PowerShell. On macOS use the default Terminal app; on Ubuntu use Terminal.

Already have a supported Node version? Keep it. Volta is the recommended installer if you need Node, not an extra requirement for an existing setup. Node 23 and other major versions are not supported for this workshop. Run one command block at a time and wait for the terminal prompt to return.

Download the starter and check it builds:

Terminal window
cd "$HOME"
git clone --branch main https://github.com/omkarkhair/field-trip-agent.git
cd field-trip-agent
npm ci && npm run typecheck && npm run build
git status --short

Look for: installation, typecheck, and build finish successfully; git status --short prints nothing. Open field-trip-agent in your editor.

What am I installing, and where do I run commands?

npm ci installs the exact lab dependencies, including Wrangler 4.143.0. Use the project-local npx wrangler throughout the session; no global Wrangler installation is needed. Audit notices do not require changing the workshop’s lockfile or pinned versions.

In VS Code, use File → Open Folder and select field-trip-agent in your home folder. Run the remaining commands from this folder. If that folder already exists, ask a facilitator to check it is a clean main starter before reusing it.

In the dashboard, select your workshop account and confirm Billing → Subscriptions → Workers Paid. Then, in Terminal A:

Terminal window
npx wrangler login && npx wrangler whoami

Authorize Wrangler in the browser using the login for that same account.

Run this block after saving your account ID:

Terminal window
export CLOUDFLARE_ACCOUNT_ID="<your-account-id>"
npm run check && npx --no-install wrangler whoami --account "$CLOUDFLARE_ACCOUNT_ID"
npx --no-install wrangler ai models list --search gemma-4-26b-a4b-it --json
npx --no-install wrangler containers list --json

Look for: All good, your chosen account/membership, the model @cf/google/gemma-4-26b-a4b-it, and a successful Containers JSON response (an empty list is fine). Resolve any errors before ticking the check.

Help me confirm billing, permissions, and the account ID
  • Account ID: copy all 32 characters beside your workshop account in the whoami table. If several accounts appear, use the one you prepared for this session. Saving it here fills command snippets; you still need to run the export in each terminal.
  • Billing: a website Pro/Business plan is separate from Workers Paid, which Containers requires. If you cannot view billing, ask your account administrator to confirm an active Workers Paid subscription for your saved account ID. Wrangler has no subscription-check command.
  • Permissions: your membership must allow Worker/Durable Object deployment, Workers AI use, and Container/image management. If Wrangler cannot display your roles, confirm them in the dashboard or with your account administrator.

These API commands confirm read access. A real AI reply is tested in checkpoint 1; container image upload and execution are tested in checkpoint 5’s Live deploy tab. Neither an API list nor pong proves those runtime permissions.

Your deployment URL

Set your workers.dev subdomain once

Find Your subdomain in Workers & Pages. Save the part before .workers.dev, or paste your full deployed URL.

No workers.dev subdomain shown yet?

Follow the workers.dev setup prompt in Workers & Pages. Choose an available name and complete registration. Once the dashboard shows your registered address, copy its subdomain into the field below.

Saving a name on this workshop page fills the guide's commands and browser-test links; it does not register that name with Cloudflare.

https://field-trip-agent.<subdomain>.workers.dev

Help me find my URL and open the second terminal

In your workshop account, open Workers & Pages. Register a workers.dev subdomain if prompted. If it shows your-team.workers.dev, save your-team above. This is different from your 32-character Account ID. Your preview should read https://field-trip-agent.your-team.workers.dev.

Open a second window with the same shell. In VS Code use Terminal → New Terminal. Call it Terminal B: it runs deployment and verification commands. Terminal A runs the local server when you use Local dev. Keeping these two windows is useful throughout the workshop.

Open a second terminal with the same shell: Terminal B. Select the lab folder and your account:

Terminal window
cd "$HOME/field-trip-agent"
export CLOUDFLARE_ACCOUNT_ID="<your-account-id>"

In Terminal B:

Terminal window
npm run deploy
sleep 5
curl https://field-trip-agent.<subdomain>.workers.dev/api/ping

Look for: pong in the terminal and at this browser link:

Save your workers.dev subdomain to open this test ↗https://field-trip-agent.<subdomain>.workers.dev/api/ping

If deployment prints a different URL, save that full URL above and rerun the curl command with the updated address.

The chat UI gets its agent in checkpoint 1. For now, pong is the goal.

Start Docker Desktop (or Docker Engine on Ubuntu). In Terminal B:

Terminal window
docker info --format '{{.OSType}}' && docker buildx version

Look for: linux and a Buildx version. Then download the lab’s image:

Terminal window
docker pull --platform linux/amd64 cloudflare/sandbox:0.12.10

Look for: Downloaded newer image or Image is up to date. Keep Docker running for the session.

Why do I need Docker now, and what if it fails?

Docker is used for the Sandbox in checkpoint 5. Downloading its image before the session avoids a long wait during the lab. The explicit linux/amd64 platform also works on Apple Silicon; 0.12.10 matches the workshop’s Sandbox SDK.

If Docker is missing, use your operating system’s installation instructions. If the daemon cannot be reached, open Docker Desktop and wait for the engine to start, then retry. On Windows choose Linux containers / WSL 2. On Ubuntu, docker info must work as your ordinary user, without sudo, for Wrangler to use it.

If a check fails, keep the output visible and contact the facilitator before the session. Share your operating system, failing command, and full error; for account issues include the account ID too.

Find the fix for a common error
What you see What to do next
command not found or wrong Node version Install the missing tool, reopen the correct terminal, and rerun its check.
field-trip-agent already exists Ask a facilitator to confirm it is a clean main starter.
Wrangler’s browser does not open Open the authorization URL printed by Wrangler in your Cloudflare browser.
Wrong account, missing account, or 401 Rerun npx wrangler login with the correct login. Check for a CLOUDFLARE_API_TOKEN environment value overriding it.
403, upgrade prompt, or product disabled Confirm Workers Paid, AI/Containers access, and membership permissions with your account administrator. Complete any dashboard setup prompts.
Quota or rate-limit error Check account usage/quota; wait and retry if it is a temporary rate limit.
npm run check has a red failure Follow the hint below it, then rerun the check.
Docker cannot connect Start Docker, wait for its engine, and rerun the Docker check.
Use port 5180 if 5173 is busy

In Terminal A, stop the server with Ctrl+C, then run:

Terminal window
npm run dev -- --port 5180

In Terminal B:

Terminal window
curl http://localhost:5180/api/ping

Use http://localhost:5180 in the browser and in later local smoke-test commands.

Prefer to read ahead? Download the workshop deck →

Open installation instructions for Windows, macOS, or Ubuntu

Choose one operating-system tab. Install only the tools you are missing; run each block in order and wait for its prompts to finish. Return to step 1 after Node, npm, Git, and curl are ready. Complete the Docker steps before the workshop as well; VS Code is optional if you already have an editor.

On a managed computer where installation is blocked, show the output to a facilitator for the session’s installation path. Installers may request an administrator password. Docker Desktop’s commercial-use terms may require your organization’s paid subscription.

Use Windows PowerShell (5.1 or 7) on a supported Windows 11 x64 computer. The installation commands below are PowerShell commands; the rest of the guide uses Git Bash, which comes with Git for Windows.

1. Install Volta. If winget is missing, install or update App Installer from the Microsoft Store.

Terminal window
winget install --id Volta.Volta --exact --source winget --accept-source-agreements --accept-package-agreements

Close PowerShell, open a new PowerShell window, and install the tested Node release:

Terminal window
volta install node@24.19.0

2. Install Git:

Terminal window
winget install --id Git.Git --exact --source winget --accept-source-agreements --accept-package-agreements

Close PowerShell and open Git Bash from Start. Return to step 1 to check Node, npm, Git, and curl.

3. Install Docker Desktop before the workshop. Back in PowerShell:

Terminal window
winget install --id Docker.DockerDesktop --exact --source winget --accept-source-agreements --accept-package-agreements

4. Enable WSL 2 if Docker asks for it. In PowerShell → Run as administrator:

Terminal window
wsl --install --no-distribution

Restart Windows if prompted. If WSL is already installed but Docker asks for a newer version, run wsl --update in administrator PowerShell instead. Hardware virtualization must be enabled; a facilitator can help with Docker’s Windows requirements.

Open Docker Desktop from Start, complete its first-run prompts, use the Linux containers / WSL 2 backend, and wait for the engine to be running. Close your old terminals and open Git Bash from Start for the Docker check and all remaining workshop commands. In VS Code, select Git Bash as the terminal profile. Do not run the Linux installation tab inside WSL for this Windows setup.

Optional: install VS Code if you need an editor. In PowerShell:

Terminal window
winget install --id Microsoft.VisualStudioCode --exact --source winget --accept-source-agreements --accept-package-agreements

After installation, reopen the shell listed in step 1 and rerun the failed check. Return to step 1 for Node, npm, Git, and curl, or Prepare Docker for Docker.

Finish these four checks before the session

Use the checkboxes above to track your results. This page cannot inspect your computer or account.

Next: 1. Hello agent →