cloudflare/agents/reproduce
Claude Code and agent skill by cloudflare/agents
- vendor
Checking that the SKILL.md file is still in the repository.
Reproduce a cloudflare/agents GitHub issue by scaffolding a minimal Agents/Worker project and deploying it to a temporary Cloudflare account, then report findings back on the issue.
Install
npx vskill@latest install cloudflare/agents/reproduceSKILL.md
The same SKILL.md was published earlier as cloudflare/agents/reproduce.
The current user message contains an <agent-think-run> envelope with repository, issue, instruction, requested-by, and (when available) trigger-comment-id. Use those values exactly. Never infer or substitute another target from examples, workspace contents, GitHub searches, or concurrent issues. If the envelope or a required field is absent, stop without cloning/editing/posting and return a structured skipped result. When trigger-comment-id is present, your first container action is the liveness reaction:
Reproduce the bug end-to-end and post your findings as an issue comment.
The instruction is the free-form text the user typed after @agent-think (it may be empty). Treat it as an extra hint from the triggering user — e.g. additional reproduction steps, a specific version, or a pointer to the suspect area. Let it guide your reproduction, but the issue itself remains the source of truth.
All gh, git, npm, curl, and wrangler commands must run on the container backend (bash({ command, backend: "container" })) — the shell backend has no real binaries or network. gh is already authenticated as the app; use it directly (no token handling).
0. Clone the repo
Clone the target repo directly under /workspace using its repository name (cloudflare/agents → /workspace/agents):
1. Understand the issue
Read it carefully. Extract:
- the observed behavior (the bug),
- the expected behavior,
- any "To Reproduce" steps, code snippets, versions, or stack traces.
Decide if it is reproducible at all. If it is a feature request, a question, a pure-docs issue, or has no concrete runnable behavior, stop here: return skipped: true, reproduced: false, and a summary explaining why. Still post a short, polite comment saying the repro-agent skipped it and why; begin it with Requested by @<requestedBy> when the run envelope has a requester.
2. Understand the relevant code
With the repo cloned at $REPO_DIR, read the relevant parts of packages/agents, packages/think, or the closest focused example under examples/ to understand the area the issue touches. Match the user's versions where it matters.
3. Scaffold a minimal reproduction
Work in a scratch dir under /workspace, never touch the checkout. The read/write/edit tools use the Workspace VFS, and container bash uses its mounted view. Put long logs in /temp, which is outside the VFS mount and only visible through container bash.
Build the smallest project that can exhibit the bug — but every repro ships a minimal Vite frontend (next section) so a maintainer can click the deployed link and watch the issue happen in a UI. Keep the _backend_ tight: only the agent/worker code the bug needs, no auth, nothing unrelated. For Think-related bugs, lift the relevant backend logic from the closest focused example into the project shape below, keeping an explicit Worker entry and Wrangler bindings — the shape itself is non-negotiable.
If the bug needs extras (@cloudflare/think, worker_loaders for the execute tool, ai/KV bindings, …), add them to package.json, wrangler.jsonc, and Env on top of the base recipe. Use today's `compatibility_date` (date +%Y-%m-%d) unless the issue pins a version where the date matters.
Minimal frontend (required)
Every repro deploy MUST ship a minimal Vite + React page at the Worker's root URL so a human can open the deployed link, click a trigger button, and watch the failing behavior in visible output (status line / log area showing expected vs. actual). House style: one flat project, @cloudflare/vite-plugin (runs src/server.ts in workerd during dev, emits client + worker builds), agents SDK routing, Workers Assets with SPA fallback.
Steps
- In
$REPRO_DIR, create the 7 files below. mkdir -p /temp && npm install > /temp/install.log 2>&1; tail -15 /temp/install.log(pinagentsto the exact version under test if the bug is version-specific). Always redirect noisy commands to a container-local/tempfile like this — streaming megabytes of live output through the session can kill it.- Sanity-check the build before deploying:
npx vite build(catches config errors cheaply; do NOT runvite dev— it blocks waiting for a browser). - Deploy per the Deploy step below (
vite buildfirst is mandatory; the build writesdist/plus a.wrangler/deploy/config.jsonredirect thatwrangler deployfollows). - After deploy, confirm the root URL serves the page (the Verify step) and include the URL + click instructions in your report (the Report back step).
package.json
vite.config.ts — add agents() from "agents/vite" FIRST in the plugin list only if the server uses @callable() decorators (rolldown/oxc can't transform them without it).
index.html — must sit at project root; script src is the raw TS path.
src/client.tsx
src/server.ts
wrangler.jsonc
tsconfig.json
Rules (violating any of these breaks the deploy)
- Never set
assets.directoryand never run plainwrangler dev/wrangler deploywithoutvite buildfirst — the Vite plugin owns the client output and generated config. run_worker_firstis an allowlist: paths not listed get the SPA fallback (index.html), so agent HTTP/WS routes under/agents/*(and any custom Worker paths) must be listed.- Keep DO
name==class_name; the client'sagent:id is its kebab-case (routeAgentRequestserves/agents/<kebab-binding>/<instance>, HTTP + WebSocket). migrationsmust usenew_sqlite_classes(Agents require SQLite-backed DOs);"type": "module"in package.json is required.- Hand-written
type Envis fine;npx wrangler types env.d.ts --include-runtime falseregenerates it after binding changes. - If the bug needs extra bindings (
ai, KV, etc.), add them to wrangler.jsonc andEnv— everything else stays as above.
4. Deploy to a temporary Cloudflare account
The shell has no Cloudflare credentials, so use the temporary-account flow (requires wrangler >= 4.102.0). vite build must run first — it produces the client assets and the deploy-config redirect wrangler follows:
This creates/reuses a temporary preview account and deploys to a *.workers.dev URL. Capture the live https://...workers.dev URL from the output → liveUrl. Ignore the claim URL the deploy prints — it never goes in a report.
If the build/deploy itself fails in a way that is the bug, that is a valid reproduction — record the exact error. If it fails for an unrelated reason, fix the scaffold and retry (do not change SDK source).
5. Verify the reproduction
Actually exercise the deployed worker and confirm the reported symptom. First check the frontend is up, then hit the buggy path the same way the UI's trigger button does:
Compare against the expected behavior. Only set reproduced: true if you observed the bug (wrong output, error, crash, etc.). If it behaves correctly, set reproduced: false and explain — the issue may be fixed, version-specific, or need more detail. Either way the deployed page must demo the behavior a human should look at.
6. Push the repro to a branch
Publish the repro project as an orphan branch on the target repo so anyone (human or agent) can pull exactly what you built and run it:
Never do this inside $REPO_DIR — the clone must stay intact for the root-cause hypothesis and any follow-up PR work. Publish from a scratch dir:
This is the start of the file. Read the full SKILL.md on GitHub.
Security
- Security scanPassed, 100 of 100Pattern checks on the skill's files. Certified 18 Sep 2026.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingagent-think/skills/reproduce/SKILL.md
Popularity
- Repository stars
- 5,594
- Repository forks
- 719
- 7-day trend score
- 43
Stars and forks are for the whole GitHub repository, not this skill alone. Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/cloudflare/agents/reproduce)