Directory Compare FCRS-1.0 /llms.txt
← Back to Directory

Grafana k6

$ k6 Official Med Risk
Grafana Labs · Code & DevOps · AGPL-3.0 · macos / linux / windows

Developer-friendly load and performance testing tool running JavaScript test scripts in an embedded Go engine. Supports k6 inspect to parse script options as JSON, --summary-export for structured JSON latency/error metrics, and --no-color clean logs.

FCRS-1.0 Score
88 /100
Good
Medium Confidence
Zero-Friction Install
brew install k6
CLI vs MCP Decision CLI Only

Generates controlled HTTP/gRPC/WebSocket load directly from local scripts against local or staging endpoints.

Agent-Readiness Checklist

✓ JSON Output
— Field Filtering
✓ Non-Interactive
— Dry-Run
— Read-Only Mode
✓ NO_COLOR Clean
✓ Self-Describing
— Official SKILL.md

Static evaluation (not yet probed on this host). Run npm run data:probe locally to capture live verification.

FCRS-1.0 6-Dimension Breakdown

Agent-Readiness 21 / 25

Provides k6 inspect JSON metadata, --summary-export=<file> JSON results, --no-color, and threshold exit codes.

  • k6 inspect prints script options and thresholds as JSON
  • --summary-export exports structured latency/error metrics
Trust & Safety 20 / 25

k6 inspect parses without sending traffic, though live k6 run can overwhelm endpoints if --vus/--duration are uncapped.

  • k6 inspect performs safe static option evaluation
  • Live runs send real network load to target URLs
Setup & Portability 15 / 15

Single static Go binary with embedded JS runtime across macOS, Linux, and Windows—zero Node.js dependency.

  • Self-contained Go binary with no external JS runtime required
Utility & Efficiency 14 / 15

Expressive JS scripting with built-in HTTP, WebSocket, gRPC, and threshold assertions for CI performance gates.

  • Built-in thresholds provide automated pass/fail exit codes
Maintenance & Lineage 9 / 10

Official Grafana Labs project under AGPL-3.0 with frequent releases.

  • First-party grafana/k6 repository
Docs & Verifiability 9 / 10

Excellent documentation at grafana.com/docs/k6/latest/ covering CLI flags and JS APIs.

  • Comprehensive reference at grafana.com/docs/k6/latest/

Security, Auth & Guardrails

Auth Modes
No Auth Env API Key Config File
Credential Storage

Local load tests need no auth; Grafana Cloud k6 uses K6_CLOUD_TOKEN or ~/.config/loadimpact/k6/config.json.

Side Effects
Read-Only Local Write Remote Write
Cost & Quotas

AGPL-3.0 open-source Go binary is free; optional Grafana Cloud k6 distributed runs are usage-billed.

Copyable Guardrail for CLAUDE.md / AGENTS.md
# Grafana k6 Agent Rules
- ALWAYS inspect scripts with `k6 inspect <file>` before running, and cap `--vus` and `--duration` during local tests.
- NEVER point `k6 run` at production endpoints without explicit user approval.

Agent-Ready Command Recipes

Safe Read-Only Queries

Inspect k6 test script options as JSON
k6 inspect script.js

Parses the test script and prints resolved VUs, stages, and thresholds in JSON without sending traffic.

Controlled Writes & Previews

Run a bounded smoke test with JSON summary
k6 run --vus 2 --duration 10s --no-color --summary-export=/tmp/k6-summary.json script.js

Runs a low-load 10-second smoke test and exports percentile latency and error metrics as JSON.

Strengths for Agents

  • + Single Go binary runs JS load tests without requiring Node.js.
  • + k6 inspect and --summary-export give agents clean JSON before and after runs.
  • + Built-in thresholds produce deterministic pass/fail exit codes.

Caveats & Pitfalls

  • ! Running scripts with high VU counts against live URLs can act as an accidental DoS if not bounded.
  • ! Uses an embedded ES module subset (soja/goja), not Node.js APIs.

Tested Agent Hosts

Claude Code Codex CLI Gemini CLI