skills/devtool-documentation/SKILL.md
Expert in developer tool documentation as a product. Activate on: docs site, getting started guide, API reference, developer documentation, Docusaurus, Mintlify, Nextra, ReadMe, migration guide, troubleshooting page, docs information architecture, documentation testing, llms.txt. NOT for: marketing copy (use seo-content-blogging), API design itself (use api-architect), general technical writing (use technical-writer).
npx skillsauth add curiositech/windags-skills devtool-documentationInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Expert in the specific art of documenting developer tools — the "documentation as product" philosophy where docs are the UI of your API.
Activate on: "docs site", "getting started guide", "API reference", "developer documentation", "Docusaurus", "Mintlify", "Nextra", "ReadMe", "migration guide", "troubleshooting page", "docs information architecture", "documentation testing", "llms.txt", "docs-as-code", "quickstart"
NOT for: Marketing copy -> seo-content-blogging | API design itself -> api-architect | General technical writing -> technical-writer
Every developer docs site organizes content into four quadrants. Mixing them is the #1 cause of bad docs.
PRACTICAL THEORETICAL
┌─────────────────┬─────────────────┐
LEARNING │ TUTORIALS │ EXPLANATION │
(acquiring) │ "Learning" │ "Understanding" │
│ by doing │ why it works │
├─────────────────┼─────────────────┤
WORKING │ HOW-TO GUIDES │ REFERENCE │
(applying) │ "Achieving" │ "Information" │
│ a goal │ lookup │
└─────────────────┴─────────────────┘
| Type | Reader State | Structure | Example | |------|-------------|-----------|---------| | Tutorial | "I'm learning" | Step-by-step, controlled, no choices | "Build your first app in 5 minutes" | | How-To | "I need to do X" | Goal-oriented, assumes knowledge | "How to deploy to Kubernetes" | | Reference | "I need the specifics" | Exhaustive, structured, no narrative | API method signatures, config options | | Explanation | "I want to understand" | Discursive, contextual, conceptual | "How authentication works under the hood" |
A tutorial that stops to explain theory loses the learner. A reference page with narrative loses the person who just needs the method signature. Keep them separate; link between them.
| Platform | Best For | Cost | Setup | AI Features | |----------|----------|------|-------|-------------| | Docusaurus | Open-source projects, full control | Free (MIT) | Medium (React) | Plugin ecosystem | | Mintlify | Startups wanting Stripe-quality docs fast | $150-$500/mo | Low (MDX, Git) | AI search, llms.txt | | Nextra | Next.js projects, content-heavy docs | Free (MIT) | Low (Next.js) | Via plugins | | ReadMe | API-first companies, interactive docs | $99-$399/mo | Low (dashboard) | AI chat, auto-gen | | GitBook | Team wikis, knowledge bases | Free-$199/mo | Very low | AI search | | Starlight (Astro) | Performance-critical, static sites | Free (MIT) | Medium (Astro) | Plugin ecosystem |
The getting started page has the highest bounce rate and the highest conversion potential. It must be flawless.
# Getting Started
<Prerequisites callout>
- Node.js 18+
- A Supabase account (free tier works)
</Prerequisites>
## 1. Install
\`\`\`bash
npm install @your-tool/cli
\`\`\`
## 2. Initialize
\`\`\`bash
npx your-tool init
\`\`\`
<Expected output>
✓ Created config file at ./your-tool.config.ts
✓ Connected to your-tool cloud
</Expected output>
## 3. Your First [Thing]
\`\`\`typescript
import { YourTool } from '@your-tool/sdk'
const client = new YourTool({ apiKey: process.env.YOUR_TOOL_KEY })
const result = await client.doTheThing({ input: "hello" })
console.log(result)
// => { output: "Hello, world!", latency: 42 }
\`\`\`
## What Just Happened?
[2-3 sentences explaining the mental model. Link to Explanation page.]
## Next Steps
- **[Build a real app](/tutorials/build-a-chat-app)** — 15 min tutorial
- **[API Reference](/reference/client)** — All available methods
- **[How auth works](/explanation/authentication)** — Under the hood
"hello" is fine. "sk_test_abc123" is better than "YOUR_API_KEY".Stripe's API reference is the gold standard because of:
"cus_NffrFeUfNV2Hib" not "CUSTOMER_ID".# create(params)
Creates a new [resource].
## Parameters
| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `name` | `string` | Yes | Display name (1-100 chars) |
| `email` | `string` | Yes | Must be valid email format |
| `metadata` | `Record<string, string>` | No | Up to 50 key-value pairs |
## Returns
A `Resource` object on success. Throws `ValidationError` if params invalid.
## Example
\`\`\`typescript
const user = await client.users.create({
name: "Ada Lovelace",
email: "[email protected]",
metadata: { role: "engineer" }
})
// => { id: "usr_abc123", name: "Ada Lovelace", ... }
\`\`\`
## Errors
| Code | Meaning |
|------|---------|
| `validation_error` | Invalid parameters (see `details` array) |
| `conflict` | Email already exists |
| `rate_limited` | Too many requests (retry after `Retry-After` header) |
Author (MDX/MD) → Git Commit → PR Review → CI Checks → Deploy
# .github/workflows/docs-ci.yml
name: Docs CI
on: [pull_request]
jobs:
docs-checks:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Lint prose
run: npx vale docs/ # Prose linting (style guide)
- name: Check links
run: npx linkinator docs/ # Dead link detection
- name: Validate code blocks
run: npx ts-check-md docs/ # TypeScript code blocks compile
- name: Spell check
run: npx cspell docs/**/*.md
- name: Build docs
run: npm run docs:build # Catch build errors
| Tool | Purpose | Command |
|------|---------|---------|
| Vale | Prose linting (Microsoft, Google style) | vale docs/ |
| linkinator | Dead link detection | linkinator docs/ --recurse |
| cspell | Spell checking with tech dictionaries | cspell "docs/**/*.md" |
| ts-check-md | Validate TypeScript code blocks compile | ts-check-md docs/ |
| remark-lint | Markdown formatting consistency | remark docs/ --use preset-lint-recommended |
| Algolia DocSearch | Docs search (free for OSS) | Apply at docsearch.algolia.com |
docs/
├── index.md # Landing → quickstart CTA
├── getting-started/
│ ├── quickstart.md # 5-min tutorial (THE most important page)
│ ├── installation.md # All platforms, all package managers
│ └── key-concepts.md # Mental model before diving in
├── tutorials/
│ ├── build-a-chat-app.md # End-to-end, 15-30 min each
│ ├── real-time-dashboard.md
│ └── deploy-to-production.md
├── guides/ # How-to guides (goal-oriented)
│ ├── authentication.md
│ ├── error-handling.md
│ ├── testing.md
│ ├── migration-from-v1.md
│ └── performance-tuning.md
├── reference/ # API reference (exhaustive)
│ ├── client.md
│ ├── config.md
│ ├── cli.md
│ └── errors.md
├── explanation/ # Conceptual docs
│ ├── architecture.md
│ ├── how-auth-works.md
│ └── data-model.md
└── resources/
├── troubleshooting.md # Common errors + solutions
├── faq.md
├── changelog.md
└── community.md
Migration guides are the most underinvested doc type. They determine whether users upgrade or leave.
# Migrating from v2 to v3
**Estimated time**: 15-30 minutes for most projects
**Breaking changes**: 3 (listed below)
## Before You Start
- [ ] You're on v2.8+ (run `your-tool --version`)
- [ ] Your tests pass on v2
- [ ] You've read the [v3 announcement blog post](/blog/v3)
## Step 1: Update Dependencies
\`\`\`bash
npm install @your-tool/sdk@3
\`\`\`
## Step 2: Breaking Change — `createClient()` signature
**Before (v2):**
\`\`\`typescript
const client = createClient("your-api-key")
\`\`\`
**After (v3):**
\`\`\`typescript
const client = createClient({ apiKey: "your-api-key" })
\`\`\`
**Why**: Object params are extensible. We need to add `region` and `timeout`.
**Codemod**: `npx @your-tool/codemod v2-to-v3`
## Step 3: [Next Breaking Change]
[Same pattern: before/after/why/codemod]
## Deprecations (Non-Breaking)
| Deprecated | Replacement | Removal |
|-----------|-------------|---------|
| `client.query()` | `client.sql()` | v4 |
| `Config.debug` | `Config.logLevel` | v4 |
## Verification
Run your test suite. If you see these specific errors, here's what they mean:
- `TypeError: createClient is not a function` → You imported from the wrong path
- `AuthError: invalid key format` → Wrap your key in the object param
## Need Help?
- [Discord #migration channel](https://discord.gg/...)
- [GitHub Discussion](https://github.com/...)
Structure every troubleshooting entry as: exact error message (H2, so search engines and users find it) -> When (context) -> Why (builds trust) -> Fix (copy-pasteable commands, not "adjust your configuration"). Users paste error messages into search. Make your H2 headings match what they paste.
Modern docs need to serve both humans and LLMs. Mintlify, Vercel, and Supabase lead here.
# Your Tool Name
> One-line description of what it does.
## Docs
- [Getting Started](https://docs.your-tool.com/quickstart): Install and run your first query
- [Authentication](https://docs.your-tool.com/auth): API keys, OAuth, service accounts
- [API Reference](https://docs.your-tool.com/reference): All endpoints and methods
## Optional
- [GitHub](https://github.com/your-tool)
- [Status](https://status.your-tool.com)
Symptom: Getting started page is 2000 words before the first code block. Fix: First code block within 30 seconds of scrolling. Move context to Explanation pages.
Symptom: Examples use deprecated APIs, wrong import paths, old syntax.
Fix: Test code examples in CI. Use ts-check-md or pytest-codeblocks.
Symptom: Users get Error: E4012 with no explanation anywhere in docs.
Fix: Every error code gets a troubleshooting entry. Link from error messages to docs.
Symptom: Pages end with 15 "See also" links, none obviously relevant. Fix: Max 3 next steps, each with a clear reason why the reader would go there.
Symptom: Method signature documented, but no usage example. Fix: Every method gets at least one example with realistic data and expected output.
Symptom: Page titled "Tutorial" but is really a concept explanation or a how-to guide. Fix: Tutorials are step-by-step, start-to-finish, and the reader makes no decisions.
[ ] Diataxis quadrants are separated — tutorials, how-tos, reference, explanation
[ ] Getting started guide tested by a newcomer (not the author)
[ ] Time-to-hello-world measured and under 5 minutes
[ ] Every API method has at least one working example
[ ] Code examples tested in CI pipeline
[ ] Prose linted with Vale or equivalent
[ ] Dead links checked automatically
[ ] Search implemented and failed searches tracked
[ ] llms.txt deployed for AI discoverability
[ ] Migration guide exists for every breaking version
[ ] Troubleshooting covers top 10 error messages
[ ] Feedback mechanism on every page
[ ] Mobile and dark mode tested
data-ai
license: Apache-2.0 NOT for unrelated tasks outside this domain.
development
Use when designing caching strategies (cache-aside, write-through, write-behind), implementing distributed locks, building rate limiters, leaderboards, real-time streams (XADD/consumer groups), pub/sub, or tuning eviction policies. Triggers: thundering-herd on cache miss, dogpile on key expiry, Redlock vs SET-NX-PX choice, sliding-window rate limiter, hot-key on a single cluster slot, big-key blowup, MULTI/EXEC across slots, KEYS in production. NOT for Redis Cluster operations/admin (different domain), embedded KV (SQLite, leveldb), in-process LRU caches, or Memcached.
tools
Drawing the `'use client'` boundary correctly in React Server Components apps (Next.js App Router, RSC frameworks) — leaf-pushing, slot composition, serialization rules, and environment poisoning prevention. Grounded in react.dev and Next.js 16 docs.
development
Use when designing rate limiting for an API, choosing between token bucket / sliding window / leaky bucket / fixed window, implementing it in Redis, deciding edge (Cloudflare/Upstash) vs origin enforcement, sizing per-user vs per-IP vs per-endpoint quotas, returning the right 429 response with Retry-After, or fixing the boundary-burst bug in fixed-window limiters. Triggers: 429 too many requests, INCR + EXPIRE, ZADD + ZREMRANGEBYSCORE + ZCARD, X-RateLimit-Remaining header, Cloudflare WAF rate limiting rules, Upstash @upstash/ratelimit, leaky bucket shaping vs policing, distributed rate limiter consistency. NOT for DDoS mitigation specifically (different scale), CAPTCHA / bot management, full WAF design, or per-user quota billing.