module

package module
v0.0.9 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 6, 2026 License: AGPL-3.0 Imports: 6 Imported by: 0

README

Go Report Card GitHub Actions

xk6-docs

Look up any k6 doc instantly, right from your terminal.

An official k6 extension for developers and AI agents who want to stay in the terminal.

  • Stay in the flow: never leave the terminal to look something up
  • Works offline: no network needed after first use
  • Always the right version: docs match your k6 build, not just "latest"
  • Find what you need: search by any word
  • Pretty output: built-in markdown rendering for terminals

Usage

k6 x docs                              # See all available topics
k6 x docs http                         # Learn about the k6/http module
k6 x docs http get                     # Look up a specific function
k6 x docs browser page click           # Dig into nested topics
k6 x docs using-k6 scenarios           # Explore k6 concepts
k6 x docs search threshold             # Find docs by keyword
k6 x docs search "close context"       # Don't worry about exact names
k6 x docs best-practices               # Get best practices guidance

Agent Skill

An agent skill is included so AI coding agents can look up k6 docs efficiently — fewer commands, no guessing paths, no wasted tokens.

Works with Claude Code, Cursor, Codex, Gemini CLI, OpenCode, GitHub Copilot, and 35+ other agents.

Install the skill directly from your k6 binary:

k6 x docs skill ~/.claude/skills    # Claude Code
k6 x docs skill ~/.agents/skills    # Cursor, Codex, Gemini CLI, etc.

Run k6 x docs skill without arguments to see all supported agents.

Install (for k6 below 1.7.0)

[!NOTE] For k6 1.7.0+, k6 x docs is automatically available. You don't need to install anything besides k6.

Download a pre-built binary from releases and use it as your k6. It's a drop-in replacement — everything k6 does, plus k6 x docs. Or build it yourself with xk6:

xk6 build --with github.com/grafana/xk6-docs

Contribute

To report bugs or suggest features, open an issue.

make test                                               # Run tests
make lint                                               # Run linter
make build                                              # Build k6 with this extension
make prepare K6_VERSION=v1.5.x K6_DOCS_PATH=~/k6-docs   # Prepare docs bundle locally

Documentation

Overview

Package module contains the xk6-docs extension.

Directories

Path Synopsis
cmd
prepare command
Command prepare processes the k6-docs repository into a doc bundle suitable for embedding.
Command prepare processes the k6-docs repository into a doc bundle suitable for embedding.
docs module
internal
cli
Package cli implements the k6 docs terminal UI.
Package cli implements the k6 docs terminal UI.
clitest command
Command clitest is a real k6 binary with the xk6-docs extension registered.
Command clitest is a real k6 binary with the xk6-docs extension registered.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL