Prometheus Api
Provides API guidance and assistance for agent workflows.
Install on your platform
We auto-selected Claude Code based on this skill’s supported platforms.
Run in terminal (recommended)
claude mcp add prometheus-api npx -- -y @trustedskills/prometheus-api
Or manually add to ~/.claude/settings.json
{
"mcpServers": {
"prometheus-api": {
"command": "npx",
"args": [
"-y",
"@trustedskills/prometheus-api"
]
}
}
}Requires Claude Code (claude CLI). Run claude --version to verify your install.
About This Skill
What it does
This skill enables AI agents to interact with Prometheus monitoring systems via their HTTP API at /api/v1. It provides access to various endpoints for querying metrics, formatting PromQL queries, discovering series and labels, and retrieving metadata and status information about the Prometheus server itself. The responses are formatted as JSON, including potential error details.
When to use it
- Troubleshooting performance issues by querying specific metrics in real-time.
- Analyzing trends over time using range queries to identify anomalies.
- Discovering available labels within a Prometheus environment.
- Retrieving the status of targets and alerts managed by Prometheus.
- Formatting complex PromQL queries for clarity or optimization.
Key capabilities
- Instant Query: Retrieves metric values at a specific point in time using
curl. - Range Query: Fetches metric data over a defined time range with specified step intervals.
- PromQL Formatting: Formats PromQL queries to improve readability or identify errors.
- Series Discovery: Finds series of metrics based on label matching.
- Label Listing & Value Retrieval: Lists available labels and retrieves their values.
- Metadata Access: Retrieves information about targets, alerts, rules, and the Prometheus server's configuration and runtime status.
Example prompts
- "Run an instant query for CPU usage on my Prometheus server."
- "Give me a range query of memory utilization over the last 5 minutes."
- "Format this PromQL query:
up{job="my-app"} == 1" - "List all available labels related to network traffic."
Tips & gotchas
- Requires access to a Prometheus server running on port 9090 (or the configured port).
- The skill returns raw HTTP responses in JSON format. You may need additional processing to extract and interpret the data.
- Admin endpoints require
--web.enable-admin-apito be enabled on the Prometheus server.
Tags
TrustedSkills Verification
Unlike other registries that point to live repositories, TrustedSkills pins every skill to a verified commit hash. This protects you from malicious updates — what you install today is exactly what was reviewed and verified.
Security Audits
| Gen Agent Trust Hub | Pass |
| Socket | Pass |
| Snyk | Pass |
🌐 Community
Passed automated security scans.