npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@costglass/mcp

v1.0.0

Published

CostGlass Model Context Protocol (MCP) Server for FinOps and Cloud Cost Intelligence

Readme

CostGlass Model Context Protocol (MCP) Server

Connects AI coding assistants and LLM clients (such as Claude Desktop, Cursor, Claude Code, and Windsurf) directly to your CostGlass multi-cloud FinOps intelligence platform.

With the CostGlass MCP server, your AI agent can query cloud spend, investigate cost anomalies, inspect Kubernetes cluster efficiency, and uncover waste directly from your editor or chat terminal.


🚀 Features

  • Multi-Cloud Spend Queries: Ask natural language questions like "What were our top 5 cloud spenders last month?" or "How much did AWS DynamoDB cost in eu-west-1 over the last 30 days?".
  • Anomaly Detection & Diagnosis: Retrieve detected cost spikes with plain-English root causes and affected accounts.
  • Actionable Savings: Fetch rightsizing, idle resource recommendations, and potential monthly savings (£/$).
  • Kubernetes FinOps: Query cluster allocation, namespace costs, and pod efficiency.
  • Cloud Budgets: Inspect budget status and threshold alerts.
  • Prompts & Resources: Pre-built FinOps audit workflows and live spend resources.

🛠️ Quick Setup

1. Generate an API Key in CostGlass

Generate a CostGlass API Key with read scope:

  • In the CostGlass web app under Settings → API Keys
  • Or via the API:
    curl -X POST https://api.costglass.com/v1/api-keys \
      -H "Authorization: Bearer <your-session-token>" \
      -H "Content-Type: application/json" \
      -d '{"name": "Cursor MCP Key"}'
    (Returns cg_live_...)

2. Configure Your AI Client

A. Claude Desktop

Edit your claude_desktop_config.json:

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
  • Windows: %APPDATA%\Claude\claude_desktop_config.json
{
  "mcpServers": {
    "costglass": {
      "command": "node",
      "args": ["/absolute/path/to/OpsBeam/mcp-server/bin/costglass-mcp.js"],
      "env": {
        "COSTGLASS_API_URL": "https://api.costglass.com",
        "COSTGLASS_API_KEY": "cg_live_your_api_key_here"
      }
    }
  }
}

(Or via npx once published: "command": "npx", "args": ["-y", "@costglass/mcp"])


B. Cursor IDE

In your project root, add or update .cursor/mcp.json:

{
  "mcpServers": {
    "costglass": {
      "command": "node",
      "args": ["/absolute/path/to/OpsBeam/mcp-server/bin/costglass-mcp.js"],
      "env": {
        "COSTGLASS_API_URL": "https://api.costglass.com",
        "COSTGLASS_API_KEY": "cg_live_your_api_key_here"
      }
    }
  }
}

C. Claude Code CLI

Run:

claude mcp add costglass node /absolute/path/to/OpsBeam/mcp-server/bin/costglass-mcp.js -e COSTGLASS_API_URL=https://api.costglass.com -e COSTGLASS_API_KEY=cg_live_your_api_key_here

🧰 Available Tools

| Tool | Description | Key Parameters | |---|---|---| | costglass_query_costs | Query spend across AWS, Azure, GCP | dimension (SERVICE, REGION, LINKED_ACCOUNT), time_range (current_month, last_30_days, last_month, etc.), granularity (DAILY, MONTHLY), service, region, account, provider | | costglass_get_anomalies | Fetch cost spikes and AI root-cause explanations | status (open, resolved), severity (critical, high, medium), provider | | costglass_get_savings_recommendations | Retrieve idle resources & rightsizing opportunities | min_savings (optional float) | | costglass_get_kubernetes_costs | Inspect K8s cluster allocation and efficiency | view (summary, allocation, efficiency, rightsizing) | | costglass_get_budgets | Check budget status and threshold alerts | (None) | | costglass_get_connected_accounts | List connected AWS orgs, Azure, and GCP accounts | (None) | | costglass_get_cost_filters | Discover valid services, regions, and accounts | (None) |


📑 Resources & Prompts

Resources

  • costglass://summary/current-month: Live monthly spend summary.
  • costglass://anomalies/active: Real-time active cost anomalies.

Prompts

  • /finops_audit: Triggers a comprehensive multi-cloud review of spend drivers, anomalies, and quick-win savings.
  • /investigate_cost_spike: Step-by-step investigation to isolate sudden cloud spend spikes.

🧪 Testing

Run the test suite:

cd mcp-server
npm test