Skip to main content
skill CX Codex

k6-docs — Claude Code skill: what it does, how to install

A skill to write, edit, and review documentation, TypeScript definitions, and release notes across k6 repositories.

Install into Claude Code · Skills CLI (Vercel) All methods and platforms ↓
npx skills add grafana/skills --skill k6-docs -a claude-code
Open on GitHub

What k6-docs does

The skill standardizes documentation across three repositories: k6-DefinitelyTyped, k6-docs, and the core k6 repo. It drafts user documentation, generates TypeScript types, and structures changelog notes. Internal implementation details are excluded by rule: only user-facing features get documented.

Every code example must pass validation against k6@master before committing. You need a local checkout of k6 to run go run . run /path/to/script.js. Chaining commands with && or ; is prohibited so errors are never masked. The guidelines also forbid automatic git pushes and ban Co-Authored-By: Claude attribution trailers in commit messages.

What it helps with

  • draft and review user documentation in k6-docs
  • generate TypeScript type definitions for k6-DefinitelyTyped
  • prepare changelog entries and release notes in the k6 repository
  • validate script examples against the latest k6@master build

Example prompts for the agent

  • Review the new API guide in the k6-docs repository
  • Generate TypeScript types for the updated module in k6-DefinitelyTyped
  • Draft release notes for the upcoming k6 release and test the examples

How to install k6-docs

1Skills CLI (Vercel)

npx skills add grafana/skills --skill k6-docs -a claude-code

2Manually: put the files in place

~/.claude/skills/k6-docs/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/k6-docs/

Step by step, with commands for each platform: How to install skills in Claude Code: five ways

Questions about k6-docs

How to install k6-docs in Claude Code?

Run npx skills add grafana/skills --skill k6-docs -a claude-code in your terminal.

What does k6-docs do?

It guides writing and reviewing k6 documentation, generating TypeScript definitions, and drafting changelog notes across three repositories.

How does k6-docs validate code snippets?

It runs each snippet separately via go run . run in a local k6 repository checked out to the latest master. Commits are blocked if any example fails.

Source text

SKILL.md · Apache-2.0
---
name: k6-docs
license: Apache-2.0
description: Write or review k6 documentation across the three k6 repositories - k6-DefinitelyTyped (TypeScript types), k6-docs (user documentation), and k6 (release notes / changelog). Applies k6 doc style conventions, generates TypeScript type definitions, drafts release notes, and validates examples by running them against k6@master. Use when working on k6 documentation, the k6 changelog, the k6 release notes, k6 API reference, k6 TypeScript types, load testing docs, or when the user asks to write, edit, or review anything in the k6, k6-docs, or k6-DefinitelyTyped repos - even if they don't explicitly say "documentation".
---

# k6 Documentation

Document or review k6 features across three repositories: k6-DefinitelyTyped (TypeScript types), k6-docs (user documentation), and k6 (release notes).

## Workflow

Pick the workflow that matches the user's intent:

- **Write documentation:** follow [references/workflows/write.md](references/workflows/write.md)
- **Review documentation:** follow [references/workflows/review.md](references/workflows/review.md)

## Quick References

- [Repository structure & feature type identification](references/repository-structure.md)
- [TypeScript patterns & troubleshooting](references/typescript-patterns.md)
- [Testing workflow with parallel subagents](references/testing-workflow.md)
- [agent-browser command reference](references/agent-browser-reference.md)
- [Troubleshooting guide](references/troubleshooting.md)

## Critical Rules

- **Never push automatically** - always ask first
- **Never chain commands with `&&` or `;`** - run each command separately (prevents failures)
- **Only document user-facing features** - not internal implementation
- **Use `1.` for every numbered list item** (not `1.`, `2.`, `3.`)
- **Test every code example** against k6@master before committing
- **No `Co-Authored-By: Claude` or AI attribution** in commits

## Validating examples (always run before committing)

Every code example in k6 documentation **and release notes** must execute cleanly against `k6@master`. The minimum loop:

```bash
# 1. cd into the k6 repo (not k6-docs or k6-DefinitelyTyped)
cd ~/path/to/k6

# 2. Make sure you're on master at the latest commit (the contract is k6@master)
git checkout master
git pull

# 3. Run each example as a separate command (no &&)
go run . run /path/to/script.js
```

If the run fails: read the error, fix the example in the source (doc or release note), re-run. Do not commit a change whose example doesn't run clean against current `master`. For the full multi-example workflow with parallel subagents, see [references/testing-workflow.md](references/testing-workflow.md).

© grafana · Apache-2.0 · grafana/skills

Similar skills

Everything for Writing and docs →

From the same set47

Project sponsors

Companies that keep this analytics open
Gold sponsor

Impressions, clicks and code copies — open statistics. We keep the numbers public for the same reason NeBlask itself is public. Become a sponsor