next-sanity-starter CLAUDE.md

next-sanity-starter CLAUDE.md is an instructions file for coding agents from backendforth/next-sanity-starter. It costs 316 tokens per session, scanned A, original, ISC.

Project-specific instructions for Claude Code, an AI coding assistant, in a Next.js website connected to Sanity, a content management system. They explain which project rules apply in each folder.

In plain words
What is it for?
Guiding AI-assisted work in the repository, wiring new content modules, regenerating types after schema changes, checking module connections, and running type checks.
Why use it?
They reduce mistakes when adding or renaming content modules, changing schemas, or running checks. They also clarify which generated files and localization rules must not be edited.

Instructions file

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 instructions/backendforth/next-sanity-starter/claude-md
Clone the repo
git clone --depth 1 https://github.com/backendforth/next-sanity-starter

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 next-sanity-starter CLAUDE.md

README.md
[![agentmods](https://agentmods.dev/badge/instructions/backendforth/next-sanity-starter/claude-md.svg)](https://agentmods.dev/instructions/backendforth/next-sanity-starter/claude-md)
Your own site
<a href="https://agentmods.dev/instructions/backendforth/next-sanity-starter/claude-md"><img src="https://agentmods.dev/badge/instructions/backendforth/next-sanity-starter/claude-md.svg" alt="Measured on agentmods" height="20"></a>
Per session 316 This file is loaded in full into every session.
When invoked 316 The same file — it is already loaded in full.
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.00316 $0.00316
Opus 5 $0.00158 $0.00158
Sonnet 5 $0.00063 $0.00063
Haiku 4.5 $0.00032 $0.00032

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

Security

Grade A, and why

next-sanity-starter CLAUDE.md 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 3d 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.

CLAUDE.md · 21 lines

What it actually says

Claude Code — repo entrypoint

Project guardrails: @AGENTS.md (canonical for all AI coding tools).

Claude Code additionally auto-loads scoped rules from subtree CLAUDE.md files based on the current working directory. Each one focuses on subtree-specific gotchas; the canonical rules stay in AGENTS.md:

  • web/CLAUDE.md — Next.js app rules
  • studio/CLAUDE.md — Sanity Studio rules
  • studio/schemas/objects/modules/CLAUDE.md — schema half of the module pattern
  • web/src/components/modules/CLAUDE.md — component half of the module pattern
  • web/sanity/CLAUDE.md — query/type layer rules

IMPORTANT: When subtree rules conflict with AGENTS.md, AGENTS.md wins. Update AGENTS.md first, then propagate.

Quick reminders (the full versions live in AGENTS.md)

  • YOU MUST run all 8 module wiring points when adding/renaming a module. Skipping any is a bug.
  • YOU MUST run pnpm studio:generate after schema edits, then pnpm check:wiring, then pnpm typecheck.
  • NEVER edit studio/sanity.types.gen.ts, studio/schema.json, or any *.gen.* file.
  • NEVER filter locale inside GROQ. Locale resolves at render time via pickLocalizedString / parseLocalizedText.
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. 3d ago First seen · 21 lines · 316 tokens per session scan A 3a60131e8a51

Subscribe to this mod's changes

next-sanity-starter CLAUDE.md is an instructions file published in the GitHub repository backendforth/next-sanity-starter (4 stars, last pushed 27d ago), licensed ISC. It adds 316 tokens to every session, about $0.0016 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.