validate

validate is a command for coding agents from superbenefit/sb-marketplace. It costs 14 tokens per session (614 once invoked), scanned A, original, CC0-1.0.

A command that checks a Cloudflare project against platform practices and SDK patterns. It reviews configuration, dependencies, MCP server code, Agent code, bindings, and deployment-related settings.

In plain words
What is it for?
Use it to inspect wrangler.jsonc and package.json, verify required packages and bindings, review MCP and Agent patterns, and check OAuth, vector search, Workflows, and observability settings.
Why use it?
It identifies missing or outdated project details before they become runtime or deployment issues.

Command

Part of the cloudflare-dev plugin — 1 skill, 4 commands, 3 agents shipped together

Install

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.

agentmods
npx agentmods add commands/superbenefit/sb-marketplace/validate
Clone the repo
git clone --depth 1 https://github.com/superbenefit/sb-marketplace

Or install cloudflare-dev, the plugin that ships this one along with the rest of its 1 skill, 4 commands, 3 agents.

Wrote 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.

agentmods badge for validate

README.md
[![agentmods](https://agentmods.dev/badge/commands/superbenefit/sb-marketplace/validate.svg)](https://agentmods.dev/commands/superbenefit/sb-marketplace/validate)
Your own site
<a href="https://agentmods.dev/commands/superbenefit/sb-marketplace/validate"><img src="https://agentmods.dev/badge/commands/superbenefit/sb-marketplace/validate.svg" alt="Measured on agentmods" height="20"></a>
Per session 14 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 614 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5 $0.00014 $0.00614
Opus 5 $0.00007 $0.00307
Sonnet 5 $0.00003 $0.00123
Haiku 4.5 $0.00001 $0.00061

Measured 4d ago against content hash dd0ed1018800, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

validate 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 4d 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.

cloudflare-dev/commands/validate.md · 77 lines

How it starts

The opening of the file, as written. The whole thing — 77 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Validate Cloudflare Implementation

Run a comprehensive validation of the current project against Cloudflare best practices.

Validation Steps

1. Configuration Check (wrangler.jsonc)

Verify:

  • compatibility_date is set and appropriate (>= "2025-03-07" for Agents SDK)
  • compatibility_flags includes "nodejs_compat"
  • observability: { "enabled": true } is present
  • migrations block has new_sqlite_classes for every Agent/DO class
  • All required bindings are declared (KV, R2, D1, Vectorize, DO, AI, Queues)
  • No stale or orphaned bindings

2. Dependencies Check (package.json)

Verify:

  • agents package installed (for Agents SDK projects)
  • @modelcontextprotocol/sdk installed (for MCP servers)
  • workers-oauth-provider installed (if using OAuth)
  • No known deprecated packages
  • TypeScript and wrangler are dev dependencies

3. MCP Server Pattern Check

If the project has MCP servers, verify:

  • Uses createMcpHandler for stateless servers (recommended pattern)
  • If using McpAgent: server is a class property, tools registered in init()
  • Tool parameters use Zod schemas with .describe() annotations
  • Error responses include isError: true
  • OAuth uses workers-oauth-provider with proper KV binding

4. API Pattern Check

Verify:

  • Reranker uses batch API: { query, contexts: [{text}], top_k }
  • Vectorize queries respect topK limits per returnMetadata setting
  • WebSocket uses hibernation API (not legacy addEventListener)
  • SQL uses tagged template literals (this.sql\...``)
  • D1 uses prepared statements
  • R2 accessed via bindings (not REST API)

5. Workflow Pattern Check (if applicable)

Verify:

  • All step.do() calls are awaited
  • Steps are idempotent (safe to retry)
  • No side effects outside steps
  • Bindings accessed via this.env (not closures)
  • Return values are JSON-serializable

Output

Report findings as:

  • Compliant: Follows best practices
  • Non-compliant: Must fix (with file:line reference and suggested fix)
  • ⚠️ Warning: Should consider (with recommendation)

Read the full file on GitHub · 77 lines

Changes

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.

  1. 4d ago First seen · 77 lines · 14 tokens per session scan A dd0ed1018800

Subscribe to this mod's changes

validate is a command published in the GitHub repository superbenefit/sb-marketplace (5 stars, last pushed 7mo ago), licensed CC0-1.0. It adds 14 tokens to every session and 614 once invoked, about $0.0001 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-08-31.