Skip to Content
LakerunnerCLI ReferenceClaude Code Skill

Claude Code Skill

The Lakerunner CLI ships with a Claude Code  skill that lets Claude query your logs directly. Once installed, Claude will know when to invoke the CLI, which flags to reach for, and how to shape output for the task at hand.

Prerequisites

  • Claude Code  installed and working. Claude Code stores its config under ~/.claude on macOS/Linux and %USERPROFILE%\.claude on Windows.
  • lakerunner-cli installed and on your PATH.
  • Your Lakerunner deployment’s query URL and an API key on hand — the installer will prompt for both. Ask whoever runs your Lakerunner deployment if you don’t know them.

Install

macOS / Linux

Run the install script — it drops the skill into ~/.claude/skills/lakerunner-cli/ and prompts for credentials:

curl -fsSL https://raw.githubusercontent.com/cardinalhq/lakerunner-cli/main/scripts/install-claude-skill.sh | bash

You’ll be asked for LAKERUNNER_QUERY_URL and LAKERUNNER_API_KEY (the key input is hidden). The script then offers to append export lines to your shell profile (~/.zshrc, ~/.bashrc, or ~/.config/fish/config.fish) so the credentials are picked up in future shells. Decline and you’ll get copy-pasteable exports instead. If either value is already set in your environment, the current value is offered as the default — press Enter to keep it.

From a checkout of lakerunner-cli, you can also run:

make install-skill

Both paths do the same thing: create ~/.claude/skills/lakerunner-cli/SKILL.md and run the credential prompt. To install into a non-default location, set CLAUDE_SKILLS_DIR before running the script. In non-interactive contexts (e.g. piped installs without a TTY) the prompt is skipped and you’ll be reminded to set the env vars yourself.

Windows

Run the PowerShell installer — it drops the skill into %USERPROFILE%\.claude\skills\lakerunner-cli\ and prompts for credentials:

iex (irm https://raw.githubusercontent.com/cardinalhq/lakerunner-cli/main/scripts/install-claude-skill.ps1)

You’ll be asked for LAKERUNNER_QUERY_URL and LAKERUNNER_API_KEY (the key input is hidden). The script then offers to persist both to your user environment via setx, so future shells and other processes pick them up automatically. Decline and you’ll get the setx commands to run yourself. If either value is already set in your environment, the current value is offered as the default — press Enter to keep it.

From a checkout of lakerunner-cli, you can also run:

pwsh scripts\install-claude-skill.ps1

Works in both PowerShell 7+ (pwsh) and Windows PowerShell 5.1 (powershell.exe). To install into a non-default location, set $env:CLAUDE_SKILLS_DIR before running. In non-interactive contexts (e.g. running the script from CI) the prompt is skipped and you’ll be reminded to set the env vars yourself.

Use

In Claude Code, type /lakerunner-cli to explicitly load the skill, or just ask Claude a log question — the skill’s description tells Claude when to reach for it automatically. Examples of prompts the skill handles well:

  • “Any ERROR logs in the last hour?”
  • “Show me the top failing services this morning.”
  • “What attributes are available on logs from cartservice?”
  • “Export yesterday’s auth-service logs to CSV.”

Under the hood, Claude will invoke commands like:

lakerunner-cli --quiet logs get -l ERROR -s e-1h -o json --limit 200 lakerunner-cli --quiet logs get-attr -s e-24h lakerunner-cli --quiet logs get-values service

See the CLI Reference for the full command surface.

What the skill tells Claude

The skill instructs Claude to:

  • Confirm the binary and credentials before running anything.
  • Default to --quiet --output json when it needs to parse results.
  • Use logs get-attr and logs get-values to discover fields before crafting complex filters.
  • Avoid unbounded exports (raising --limit above ~10k or pulling multi-day ranges) without asking.
  • Redact obvious secrets from any log content it pastes back into chat.
  • Never fabricate log lines — if a query returns nothing, say so.

The skill source lives in the lakerunner-cli repo.

Uninstall

macOS / Linux:

rm -rf ~/.claude/skills/lakerunner-cli

Windows (PowerShell):

Remove-Item -Recurse -Force "$env:USERPROFILE\.claude\skills\lakerunner-cli"

Reach out to support@cardinalhq.io for support or to ask questions not answered in our documentation.

Last updated on