k6-cloud-investigate-test
Installation
SKILL.md
k6 Cloud test investigator
Structured 9-step workflow for investigating a Grafana Cloud k6 test or run.
This skill is workflow-only. All API calls go through gcx api against the plugin proxy, using v6 for REST and v5 for metrics. For the underlying mechanics (gcx auth, path conventions, endpoint discovery, log queries, script editing, threshold semantics, gotchas), see the k6-manage skill — every step below references it.
The content unique to this skill is:
- the ordered investigation flow (Steps 1-9 below)
- the date-alignment check ("last 7 days" ≠ "last 7 runs")
- the 3-layer pass/fail determination (
resultvsstatusvs per-checkchecksquery) - a worked example with realistic numbers (
references/worked-example.md)
Core principles
- Read before write. Always GET the script before any PUT.
gcx k6 load-tests update-scriptis a write that replaces the live script with whatever file you pass — running it "just to see the URL it hits" has cost users their production scripts. If you need to learn URLs, run any non-mutating command with-vvv --log-http-payloadinstead. - Paginate when enumerating runs. The
/test_runsendpoint caps at 1000 rows andgcx k6 runs list --limit 0does not auto-follow@nextLink. Use thegcx apiloop documented ink6-manage§3. - Verify date framing. When the user says "last 7 days", "this week", "recent runs" — confirm the most-recent run's
createdactually falls in that window. Surface the gap if not. check()doesn't fail runs; onlythresholdsdo. And thresholds with zero observations are reported as ✓ pass. See "Threshold semantics" below for the full deep dive; the per-checkchecksmetric query in Step 5 catches both cases.