Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add skills/secondsky/claude-skills/cloudflare-nextjsnpx skills add secondsky/claude-skills --skill cloudflare-nextjsgit clone --depth 1 https://github.com/secondsky/claude-skillsWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/secondsky/claude-skills/cloudflare-nextjs)<a href="https://agentmods.dev/skills/secondsky/claude-skills/cloudflare-nextjs"><img src="https://agentmods.dev/badge/skills/secondsky/claude-skills/cloudflare-nextjs.svg" alt="Measured on agentmods" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00089 | $0.05789 |
| Opus 5 | $0.00044 | $0.02894 |
| Sonnet 5 | $0.00018 | $0.01158 |
| Haiku 4.5 | $0.00009 | $0.00579 |
Grade A, and why
cloudflare-nextjs scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 322 lines — stays where its author put it; the contents beside it link to each section on GitHub.
OpenNext Cloudflare Adapter — Next.js on Workers
Deploy Next.js applications to Cloudflare Workers using the OpenNext adapter (@opennextjs/cloudflare). The adapter takes a standard Next.js build, runs package.json build script, then transforms the output to run on the Workers runtime using the Node.js compatibility layer (nodejs_compat) — not the Edge runtime.
Critical Requirements (get these wrong and the build/runtime fails)
| Requirement | Value | Why |
|---|---|---|
| Runtime | Node.js (default). Remove every export const runtime = "edge"; |
Edge runtime is unsupported; OpenNext uses nodejs_compat. |
compatibility_flags |
["nodejs_compat", "global_fetch_strictly_public"] |
Node APIs + allow fetch() in app code. |
compatibility_date |
≥ 2024-09-23; ≥ 2025-05-05 recommended (FinalizationRegistry) |
Older dates break FinalizationRegistry, DOs, and more. |
| Wrangler | ≥ 3.99.0 to deploy; ≥ 4.13.0 for keep_names; ≥ 4.36.0 for stable remote bindings |
Feature gates in the docs. |
| Next.js | v16 all minors/patches supported; latest minors of v14 and v15; v14 dropped Q1 2026 | Stated on the overview page. |
| Worker size (gzip) | 3 MiB Free / 10 MiB Paid (compressed only) | Hard Cloudflare limits. |
Windows: not fully guaranteed (Next.js tooling issues). Use WSL, a Linux VM, or Linux/macOS CI. See known issue #1305.
Disambiguation: this skill vs nextjs
nextjsskill → framework/App Router/Server Components/Cache Components patterns, any platform (Vercel, self-hosted, ...). Use forasync params,proxy.tsmigration,"use cache".- THIS skill (
cloudflare-nextjs) → deploying Next.js to Workers via the OpenNext adapter:wrangler.jsonc,open-next.config.ts,getCloudflareContext, caching tiers, bindings, skew protection, multi-worker, the Workers-specific errors.
proxy.ts caveat (Next 16): Next 16 renamed
middleware.ts→proxy.ts, but@opennextjs/cloudflaredoes not recognizeproxy.tsyet (issue #1277) — on Cloudflare, keep usingmiddleware.ts. This is the one place thenextjsskill's guidance does NOT apply here.
What ships with it
16 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
- assets/workflow-diagram.md 16 KB
- references/advanced.md 10 KB
- references/bindings-and-services.md 6.7 KB
- references/caching.md 6.4 KB
- references/database-client-example.ts 3.8 KB runs code
- references/dev-deploy-and-env.md 3.7 KB
- references/error-catalog-extended.md 7.5 KB
- references/feature-support.md 13 KB
- references/known-issues.md 2.1 KB
- references/open-next.config.ts 7.3 KB runs code
- references/package.json 871 B
- references/troubleshooting.md 4.3 KB
- references/wrangler.jsonc 6.1 KB
- scripts/analyze-bundle.sh 3.9 KB runs code
- scripts/setup-existing-project.sh 3.1 KB runs code
- scripts/setup-new-project.sh 1.1 KB runs code
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 2d ago First seen · 322 lines · 89 tokens per session scan A f7fe21ea00e6
cloudflare-nextjs is a skill published in the GitHub repository secondsky/claude-skills (214 stars, last pushed 3d ago), licensed MIT. It adds 89 tokens to every session and 5,789 once invoked, about $0.0004 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.
Other skills, from other repositories
remember
Record why something is the way it is — a decision and its reasoning, a lesson that cost time, or a standing constraint. Use when the reasoning behind a choice would be expensive to reconstruct later.
resume
Write down where this stretch of work stopped, so the next session continues instead of restarting. Use at the end of a working session, or when handing the repository to someone else.
bootstrap
Set up chamnan in this repository for the first time — build the architecture index, measure how well the code describes itself, fill in missing file comments, and record a baseline. Run once per repo.
milestone
Record a change that reshaped the repository — what moved, why it was worth doing, and which areas it touched. Use after a migration, a rewrite, or a decision that changed how part of the system works.
capture
Write down a procedure worth keeping — a multi-step process, a trap that cost real time, or something that has now come up three times. Use it the moment you finish such a task, while the details are still exact.
promote
Turn a scratch script into a permanent tool this repo keeps. Use when a check, report, or analysis has proved worth running more than once.