1. 主要ページへ移動
  2. メニューへ移動
  3. ページ下へ移動

QES ブログ

記事公開日

[Kiro FinOps] Automating AWS Pricing Collection with AWS Pricing MCP Server

  • このエントリーをはてなブックマークに追加

Key Takeaways

This article explains how to streamline AWS cost estimation by combining the AI agent "Kiro" with the "AWS Pricing MCP Server."

  • Leveraging AWS Pricing MCP Server: Access real-time AWS service pricing for complex filtering and cost analysis.
  • Natural Language Pricing Queries: Obtain instance rates and monthly estimates through conversation without manual Pricing Calculator entry.
  • Accuracy Verification: Highlights the importance of comparing AI-generated results with the actual Calculator to ensure precision.

Introduction

Hello, I'm Miura from the DX Solution Division.

How do you handle AWS cost estimations? Manually clicking through the Pricing Calculator can be tedious, given the numerous parameters required.

Even when asking an AI, you might find significant gaps compared to actual prices or a lack of clear evidence. In this post, I will introduce a method to calculate accurate costs by integrating the AWS Pricing MCP Server with Kiro.

What is AWS Pricing MCP Server?

The AWS Pricing MCP Server is an MCP server that provides access to real-time AWS pricing information and cost analysis capabilities.

Key Features

  • Service Exploration: Discover and retrieve pricing for all AWS services.
  • Attribute Identification: Pinpoint conditions like instance types, regions, and storage classes.
  • Real-time Queries: Access the latest price data using advanced filtering.
  • Cross-region Comparison: Compare prices across different regions with a single query.
  • Cost Analysis Reports: Generate detailed reports including unit prices and calculation breakdowns.
  • Infrastructure Project Analysis: Automatically identify AWS services from CDK or Terraform projects.

For installation and configuration details in Kiro, please refer to the links below.

Getting Started

Before using the server, ensure the following prerequisites are met:

  • AWS CLI configuration file is created (~/.aws/credentials).
  • The "AWS_PROFILE" in the MCP server settings is set to the appropriate profile.
Screen showing MCP is enabled

Querying EC2 Pricing

Let's retrieve the On-Demand pricing (USD/h) for a specific instance type (e.g., t3.micro) and have it calculate a monthly estimate (assuming 730h/month).

Prompt

Use the MCP `awslabs.aws-pricing-mcp-server` to get EC2 On-Demand pricing.
Conditions:
- region: ap-northeast-1 (Tokyo)
- instanceType: t3.micro
- operatingSystem: Linux
- SP/RI: NA

Format the output as:
- Unit Price (JPY/hour) **1USD=160JPY**
- Monthly Cost (JPY/month) *Estimated at 730 hours/month
- Specify region, currency, and source (PriceList API/SKU)
- List prerequisites at the end (hours, currency, tax excluded/included, etc.)

Calling MCP
Calculation result provided by Kiro

Kiro called the MCP and calculated the price instantly. The evidence is clear as detailed information is included.

Verifying AI Results (Bonus)

Instead of blindly trusting the AI, let's verify the results with the actual Pricing Calculator.

Verification results in AWS Pricing Calculator

The On-Demand cost per hour (0.0136 USD) matched. However, checking the monthly calculation...

Formula: 9.93(USD/month) × 160 = 1,588.8(JPY/month)

Kiro's answer was "15,885 JPY/month," meaning it misplaced a decimal point.

Requesting correction and Kiro's updated response

AI can make mistakes like this. If something feels off, it's crucial to point it out and have it corrected immediately.

Summary

By introducing the AWS Pricing MCP Server to Kiro, you can now calculate usage fees instantly just by providing the necessary parameters. This is expected to significantly reduce the man-hours involved in AWS operations.

The possibilities are broad, from fixing output formats with AGENT STEERING to deep-diving into conditions through dialogue. However, given the risk of hallucination, always double-check for critical estimates.

 We aim to become Japan's #1 resource for Kiro! Our mission is to evangelize this technology by empowering end-users with top-tier education and technical support. 



If you would like to learn more about this service or have requests regarding AWS environment construction or migration, please feel free to contact us via our Contact Form. For complex inquiries, our sales representative will reach out to you directly. Also, please check out the links below!
<QES Related Solutions/Blogs>

<The AWS Security Promotion Consortium, in which QES participates, has released a white paper>

*Amazon Web Services, the "Powered by Amazon Web Services" logo, and other AWS trademarks used in the blog are trademarks of Amazon.com, Inc. or its affiliates in the United States and other countries.

  • このエントリーをはてなブックマークに追加

お問い合わせ

Contact

ご質問やご相談、サービスに関する詳細など、何でもお気軽にご連絡ください。下記のお問い合わせフォームよりお気軽に送信ください。

お問い合わせ

資料ダウンロード

Download

当社のサービスに関する詳細情報を掲載した資料を、下記のページよりダウンロードいただけます。より深く理解していただける内容となっております。ぜひご活用ください。

資料ダウンロード