Skip to content

feat: add GitHub pricing tools (github_pricing + github_cost_estimate)#32

Merged
msftnadavbh merged 4 commits intomainfrom
feature/github-pricing-tool
Mar 3, 2026
Merged

feat: add GitHub pricing tools (github_pricing + github_cost_estimate)#32
msftnadavbh merged 4 commits intomainfrom
feature/github-pricing-tool

Conversation

@msftnadavbh
Copy link
Copy Markdown
Owner

Summary

Adds two new MCP tools for GitHub product pricing, bringing the total tool count from 13 to 15.

New Tools

Tool Description
github_pricing Full catalog lookup for Plans, Copilot, Actions runners, Advanced Security (GHAS), Codespaces, Git LFS, and Packages
github_cost_estimate Monthly/annual cost estimation based on team size and usage (seats, Copilot licenses, Actions minutes, Codespaces hours, LFS packs, GHAS committers)

Key Design Decisions

  • Static pricing table — GitHub pricing is not available via the Azure Retail Prices API, so prices are maintained as verified constants in config.py with a GITHUB_PRICING_DATA_VERSION stamp (2026-03-03)
  • No auth required — all lookups are offline
  • Natural-language aliases — e.g., ci/cd → Actions, pair programmer → Copilot, ghas → Security
  • Follows Databricks package pattern — config → service → handlers mixin → formatters → tool definitions

Files Changed (14)

New (6):

  • src/azure_pricing_mcp/services/github_pricing.pyGitHubPricingService with get_pricing() + estimate_cost()
  • src/azure_pricing_mcp/github_pricing/__init__.py — package exports
  • src/azure_pricing_mcp/github_pricing/tools.py — tool definitions
  • src/azure_pricing_mcp/github_pricing/handlers.pyGitHubPricingHandlers mixin
  • src/azure_pricing_mcp/github_pricing/formatters.py — Markdown formatters
  • tests/test_github_pricing.py — 47 tests

Modified (8):

  • src/azure_pricing_mcp/config.py — static pricing tables (Plans, Copilot, Actions, Security, Add-ons, aliases)
  • src/azure_pricing_mcp/services/__init__.py — export GitHubPricingService
  • src/azure_pricing_mcp/tools.py — append GitHub tool definitions
  • src/azure_pricing_mcp/handlers.py — add GitHubPricingHandlers to mixin chain + dispatch
  • src/azure_pricing_mcp/server.py — dispatch routes
  • docs/TOOLS.md — new section, tool count 13 → 15
  • docs/FEATURES.md — new GitHub Pricing Tools feature section
  • CHANGELOG.md — v3.5.0 entry

Testing

All 235 tests pass (188 existing + 47 new):

  • Config validation (table structure, required keys)
  • Alias resolution (known aliases, unknown input, edge cases)
  • Service logic (full catalog, filtered queries, cost calculations including free-tier deduction)
  • Formatter output (Markdown structure, section filtering)
  • Handler integration (end-to-end through mixin)

Add two new MCP tools for GitHub product pricing:

- github_pricing: Full catalog lookup for Plans, Copilot, Actions runners,
  Advanced Security (GHAS), Codespaces, Git LFS, and Packages
- github_cost_estimate: Monthly/annual cost estimation based on team size
  and usage (seats, Copilot licenses, Actions minutes, Codespaces, LFS, GHAS)

Static pricing table verified against github.com/pricing — no API calls
or authentication required. Natural-language aliases supported (e.g.,
'ci/cd' → Actions, 'pair programmer' → Copilot).

Follows the Databricks package pattern: config constants, service class,
handlers mixin, formatters, tool definitions, and 47 new tests.

Total tools: 15 (was 13). All 235 tests pass.
@msftnadavbh msftnadavbh merged commit 4169123 into main Mar 3, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant