promql-cli

promql-cli is a skill for Claude Code from hssh8917/cc-skills. It costs 89 tokens per session (1,285 once invoked), scanned B, a copy of promql-cli, MIT.

A command-line tool for querying Prometheus, a system that stores time-series monitoring data, and compatible systems using PromQL, its query language.

In plain words
What is it for?
Running instant or time-range metric queries, discovering available metrics and labels, exporting results as tables, CSV, or JSON, and viewing terminal charts.
Why use it?
It avoids switching between web dashboards or writing custom scripts to find metrics, inspect labels, run queries, and investigate performance problems.

Skill for Claude Code

Written for Claude Code: allowed-tools in frontmatter. Also seen: names the AskUserQuestion tool; built for openclaw.

Good fit Running instant or time-range metric queries, discovering available metrics and labels, exporting results as tables, CSV, or JSON, and viewing terminal charts.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/hssh8917/cc-skills/promql-cli
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add hssh8917/cc-skills --skill promql-cli
Clone the repo
git clone --depth 1 https://github.com/hssh8917/cc-skills

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for promql-cli

README.md
[![agentmods](https://agentmods.dev/badge/skills/hssh8917/cc-skills/promql-cli/github.svg)](https://agentmods.dev/skills/hssh8917/cc-skills/promql-cli)
Your own site
<a href="https://agentmods.dev/skills/hssh8917/cc-skills/promql-cli"><img src="https://agentmods.dev/badge/skills/hssh8917/cc-skills/promql-cli/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for promql-cli

Your own site · 80×15
<a href="https://agentmods.dev/skills/hssh8917/cc-skills/promql-cli"><img src="https://agentmods.dev/badge/skills/hssh8917/cc-skills/promql-cli.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 89 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,285 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 1 finding. A grade says what 26 rules found in the file — not that it is safe.
Origin 98% copy Near-identical to another mod in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00089 $0.01285
Opus 5.5 $0.00036 $0.00514
Sonnet 5.5 $0.00018 $0.00257
Haiku 4.5 $0.00009 $0.00128

Measured 1mo ago against content hash 2434aacbb5f3, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade B, and why

promql-cli scanned grade B with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Asks for rootmediumPrivilege escalation

A mod that escalates privileges can change anything on the machine, not only the project.

6. **Store credentials in `~/.promql-cli.yaml` and `~/.promql_token`, chmod 600** — passing tokens as CLI args exposes them in shell history and process listings.
Origin

This is a copy

98% identical to promql-cli — 20 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

skills/promql-cli/SKILL.md · 97 lines

How it starts

The opening of the file, as written. The whole thing — 97 lines — stays where its author put it; the contents beside it link to each section on GitHub.

promql-cli — Prometheus Query CLI Skill

promql-cli (github.com/nalbury/promql-cli) is a Go CLI for querying, analyzing, and visualizing Prometheus metrics, plus PromQL fundamentals.

Reference Files

Read the relevant reference file(s) before executing tasks:

File When to read
references/installation.md User needs to install promql-cli or set up configuration (hosts, auth, token, password, multi-host)
references/usage.md User wants to discover metrics/exporters/labels, run queries, or choose output formats
references/graphing.md User wants to visualize Prometheus data as an ASCII chart in the terminal
references/debugging.md User is investigating a performance issue, latency, errors, or saturation
references/promql-reference.md User needs help writing PromQL, understanding metric types, functions, or aggregations

For most tasks, read references/usage.md. For PromQL help, read references/promql-reference.md. When debugging, read both references/debugging.md and references/promql-reference.md.

Setup Check

Before running any query, verify that a host is configured:

promql 'up'   # succeeds if host is reachable; fails with connection error if not configured
# or
promql --host xxx 'up'

Recognize these errors as a configuration/auth problem and refer to references/installation.md:

Error Cause
dial tcp ... connection refused No host running at the configured address
dial tcp ... no such host Hostname not resolved — wrong host in config
error querying prometheus: ...401... Bearer token missing or invalid
error querying prometheus: ...403... Token valid but insufficient permissions
please specify an authentication type Auth flags partially set — use config file instead

If any of these appear, do not create config files on behalf of the user — config files may contain credentials (tokens, passwords) that must never pass through an LLM. Instead, guide the user to set it up themselves:

Read the full file on GitHub · 97 lines

Files

What ships with it

6 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago First seen · 97 lines · 89 tokens per session scan B 2434aacbb5f3

Subscribe to this mod's changes

promql-cli is a skill published in the GitHub repository hssh8917/cc-skills (2 stars, last pushed 5d ago), licensed MIT. It adds 89 tokens to every session and 1,285 once invoked, about $0.0004 per session on Opus 5.5. A static security scan graded it B with 1 finding (asks for root). It is 98% identical to promql-cli, differing in 20 lines, and is treated as a copy.

Related

Other skills, from other repositories

dingtalk_channel_connect

Use a headed browser to automatically complete DingTalk channel integration for QwenPaw. Applicable when the user mentions DingTalk, developer console, Client ID, Client Secret, bot, Stream mode, binding or configuring a channel. Supports pausing when a login page is detected and resuming after the user logs in.

agentscope-ai/QwenPaw · 69 tokens

make_plan

For external plan request scenarios, guides the Agent to request a clear, actionable, step-by-step plan from a stronger Agent via listagents and chatwithagent, emphasizing that the plan is executed by the requester, not by the consulted Agent.

agentscope-ai/QwenPaw · 51 tokens

pdf

A set of instructions for working with PDF files, which are documents designed to preserve their layout across devices.

agentscope-ai/QwenPaw · 95 tokens

knowledge-org

A guide to organising large bodies of knowledge so an AI system can navigate relationships, summaries, and layers instead of searching only flat text chunks. It covers tree indexes, knowledge graphs, file-like structures, incremental updates, and long-term memory layouts.

bojieli/ai-agent-book · 96 tokens

memory-system

A guide to giving an AI agent persistent, user-specific memory across conversations. It covers what to remember, how to store it, how to update or compress it, and when to use memory instead of a shared knowledge base.

bojieli/ai-agent-book · 95 tokens

writing

A writing guide for turning verified facts and calculations into finished text for a specific audience. It follows the requested language, structure, and length.

bojieli/ai-agent-book · 27 tokens