OpenCloudCosts MCP
以下摘录自该仓库的 README(片段) · 在 GitHub 读完整 README →
Anchor AI FinOps to real, live cloud pricing.
Your LLM's cloud pricing knowledge was frozen at training cutoff. Cloud pricing wasn't.
**opencloudcosts** is an MCP server that gives your AI assistant live, structured access to AWS, GCP, and Azure pricing — 16 tools it can call directly, with results it can reason over rather than guess at. Ask it to compare a full multi-resource workload across all three clouds simultaneously. Ask it for your actual post-discount effective rates from Reserved Instances, Savings Plans, or Enterprise Discount Programs. Ask it to fan out across every region and return the cheapest option. None of that is possible from training data alone, and none of it is possible from a single-cloud pricing calculator.
The Problem
Ask any AI assistant what an m5.2xlarge costs in ap-southeast-2, whether AWS or GCP is cheaper for a three-tier web app, or what your effective hourly rate is after Savings Plans. You will get a confident answer. It will probably be wrong.
Cloud pricing is a poor fit for static model weights: instance families are added and retired, regional pricing diverges (the same instance type can differ 20–40% across regions), spot markets fluctuate, and commitment discounts are by definition unique to each account. A model answering from training data cannot know your negotiated EDP rate. It can barely reliably recall last year's list price. The problem is not that LLMs are bad — it's that real-time, account-specific pricing data is structurally outside what a model can know.
opencloudcosts fixes this by giving your AI assistant 16 MCP tools backed by live provider APIs. Instead of hallucinating numbers, the model calls a tool and gets a precise answer.
A Concrete Scenario
Your team asks: *"We're evaluating whether to migrate this workload from AWS to GCP. What does the full stack cost on-demand vs. three-year committed, across all three clouds, so I can make the case to leadership?"*
Without this tool, the model interpolates — possibly from pricing that is a year out of date — across three providers, multiple resource types, and at least four pricing tiers. The numbers will be plausible and wrong.
With opencloudcosts, the model calls compare_bom with the workload spec (compute + storage + database). The tool fans out **8 concurrent provider calls** across AWS, GCP, and Azure simultaneously, prices each resource category at public and committed rates, and returns a per-provider, per-term breakdown with savings analysis — in a single tool call.
No spreadsheet. No switching between three provider calculators. No manual SKU matching. No training-data approximation.
Why Not the Obvious Alternatives
**Asking a model without tools** — Training data has a cutoff. Cloud pricing changes constantly, varies 20–40% across regions for the same instance type, and includes account-level commitment discounts that are invisible at inference time. The model will approximate, confabulate, or recall stale numbers. There is no structured output, and the model cannot access your contracted rates under any circumstances.
**Cloud pricing calculators (AWS / GCP / Azure)** — Each covers exactly one cloud. They are UI-only with no API surface callable from an AI assistant. Cross-cloud comparison requires manually reproducing the same architecture three times across three separate calculators and reconciling exports by hand. They have no concept of unit economics and produce no programmatic output for agentic workflows.
**Infracost** — Excellent at estimating cost diffs against Terraform plans. It requires IaC files as input — it cannot answer "what does an n2-standard-8 cost in europe-west4?" without a Terraform plan in hand. It is not an MCP server and is not callable from a conversational AI context.
**Calling provider APIs directly** — AWS bulk pricing files are multi-GB and require targeted API access patterns to avoid downloading them in full. GCP's Cloud Billing Pricing API v1beta requires a multi-source ADC credential chain and provider-specific IAM. Azure's Retail Prices API needs pagination logic and SKU matching. Every provider uses different region naming conventions, SKU formats, and data schemas. opencloudcosts normalizes all of this behind a uniform MCP tool interface and handles credential chains, caching, and retry logic so the model does not have to.
Capabilities at a Glance