analyze-costs
Installation
Review the source and dependencies with a prompt. A package is available to download.
Install with an AI assistant
Copy the prompt so your assistant can review the pinned revision and dependencies first.
View promptHide prompt
Check whether SkillPI Skill Finder is installed for your current agent. If it is missing, install and enable it using the official instructions at https://github.com/Findskills/skillpi. Then use Skill Finder to locate and install "analyze-costs" from this exact SkillPI detail page: https://skillpi.com/skills/deepskill-93fbe1d45f197eec28e5670ac651c32bfaf565d2161c06233f12c2f1bacb5a88. Verify the upstream source and version against https://github.com/harness/harness-skills before installing. If they do not match, stop and report the mismatch. Report the installed path and source version.
Source and setup
github.com
Setup guidance pending
See the original source for supported tools, dependencies, and permissions.
Installation test pending
Analyze cloud costs via MCP using Harness CCM to identify optimization opportunities and track anomalies. Use when users mention “cloud costs,” “cost analysis,” “cost optimization,” “reduce spending,” “cost reports,” or ask questions about cloud billing.
Introduction source: third_party · harness · 2.0.0 Reference
SkillPi interpretation
- Tasks
- Analyze cloud costs, find optimization opportunities, and track anomalies using Harness CCM via MCP. Use when user says "cloud costs", "analyze costs", "cost optimization", "reduce spending", "cost report", or asks about cloud bills.
- Audience
- Not specified in the source documentation.
- Inputs and outputs
- Not specified in the source documentation.
- Software, accounts and paid services
- Not specified in the source documentation.
- Limits and differences
- Not specified in the source documentation.
- Testing
- Not tested
Browse files
Frontmatter
name: analyze-costs
description: Analyze cloud costs, find optimization opportunities, and track anomalies using Harness CCM via MCP. Use when user says "cloud costs", "analyze costs", "cost optimization", "reduce spending", "cost report", or asks about cloud bills.
metadata:
author: Harness
version: 2.0.0
mcp-server: harness-mcp-v2
license: Apache-2.0
compatibility: Requires Harness MCP v2 server (harness-mcp-v2)Analyze Costs
Analyze cloud costs and identify savings using Harness Cloud Cost Management (CCM) via MCP.
Instructions
Step 1: Get Cost Overview
Call MCP tool: harness_get
Parameters:
resource_type: "cost_account_overview"
Returns total spend, provider breakdown, and trend vs previous period.
Step 2: Get Cost Breakdown
Call MCP tool: harness_get
Parameters:
resource_type: "cost_breakdown"
Multi-dimensional breakdown by service, environment, team, region.
Step 3: Explore Perspectives
Call MCP tool: harness_list
Parameters:
resource_type: "cost_perspective"
Then get detailed data for a specific perspective:
Call MCP tool: harness_get
Parameters:
resource_type: "cost_perspective"
resource_id: "<perspective_id>"
Step 4: Get Cost Trends
Call MCP tool: harness_get
Parameters:
resource_type: "cost_timeseries"
Step 5: Get Optimization Recommendations
Call MCP tool: harness_list
Parameters:
resource_type: "cost_recommendation"
For detailed recommendation info:
Call MCP tool: harness_get
Parameters:
resource_type: "cost_recommendation_detail"
resource_id: "<recommendation_id>"
Summary statistics:
Call MCP tool: harness_get
Parameters:
resource_type: "cost_recommendation_stats"
Step 6: Check for Anomalies
Call MCP tool: harness_list
Parameters:
resource_type: "cost_anomaly"
To dismiss a known anomaly:
Call MCP tool: harness_execute
Parameters:
resource_type: "cost_anomaly"
action: "report_feedback"
resource_id: "<anomaly_id>"
body: { feedback: "FALSE_ANOMALY" } # or TRUE_ANOMALY / NOT_RESPONDED
Step 7: Commitment Analysis
Call MCP tool: harness_get
Parameters:
resource_type: "cost_commitment"
Report Format
## Cloud Cost Analysis
**Period:** Last 30 Days
### Summary
| Provider | Spend | vs Previous |
|----------|-------|-------------|
| AWS | $X | +X% |
| GCP | $X | +X% |
| Azure | $X | -X% |
### Top Recommendations
1. **Rightsize <resource>** - Save $X/month (95% confidence)
2. **Convert to Reserved** - Save $X/month
3. **Delete unused resources** - Save $X/month
### Anomalies
- <date>: <service> spiked $X above expected
### Actions
- [ ] Rightsize instance X
- [ ] Purchase reserved capacity
- [ ] Clean up unused volumes
Cost Resource Types Reference
| Resource Type | Operations | Description |
|---|---|---|
cost_account_overview |
get | Account-level total spend summary |
cost_summary |
get | Perspective-scoped cost summary |
cost_timeseries |
get | Cost trends over time |
cost_breakdown |
get | Multi-dimensional breakdown |
cost_perspective |
list, get | Custom cost views |
cost_recommendation |
list | Optimization suggestions |
cost_recommendation_detail |
get | Detailed recommendation |
cost_recommendation_stats |
get | Summary statistics |
cost_anomaly |
list, get, execute(report_feedback) | Cost spikes |
cost_anomaly_summary |
get | Anomaly aggregate summary |
cost_category |
list, get | Cost allocation |
cost_commitment |
get | Commitment coverage/utilisation/savings |
cost_filter_value |
get | Available filter values |
Examples
- "How much are we spending on cloud?" - Get cost_account_overview
- "Find $5,000 in monthly savings" - List cost_recommendations, prioritize by savings
- "Why did our bill spike last week?" - List cost_anomaly
- "Break down costs by team" - Get cost_breakdown or cost_perspective
- "Are we using our reserved instances?" - Get cost_commitment
Performance Notes
- Gather data from all relevant perspectives before drawing cost conclusions. Partial data leads to incorrect recommendations.
- Cross-reference recommendations with anomaly data to distinguish trends from spikes.
- Quality of cost analysis is more important than speed. Verify savings estimates before presenting.
Troubleshooting
No Cost Data
- Check cloud connectors are configured and syncing
- Initial sync takes 24-48 hours
- Verify billing access permissions (Cost Explorer, Billing API)
No Recommendations
- Resources need sufficient usage history for analysis
- Small savings may be filtered out
- Check minimum running time requirements
Current listing version
2.0.0
Safety and assessment details
Quality assessment
Out of 100 · Assessment report from SkillPi LAB.
Areas to improve
-
缺少 When to Use 显式章节 Reported severity: Minor
文档未设置独立 When to Use 章节说明典型使用场景
Recommendation: 建议在 Instructions 前增加 When to Use 章节,列举3-5个典型用户提问示例
Highlights
- 企业级云成本分析刚需场景
- 覆盖多云厂商(AWS/GCP/Azure)完整分析链路
- 提供从数据获取到优化建议的端到端闭环
Areas to improve
-
触发词未覆盖中文长尾变体 Reported severity: Minor
未包含"账单异常"、"支出优化"等中文常见表述
Recommendation: 建议在 description 中补充更多中文长尾触发词如"账单异常"、"支出优化"、"费用分析"
Highlights
- 中英文触发词覆盖完整
- 边界清晰不易误触
- frontmatter description 位置规范
Areas to improve
-
Report Format 示例数据未脱敏 Reported severity: Minor
示例中使用 $X 占位符但部分字段如日期未统一格式
Recommendation: 建议统一示例数据格式,如使用具体示例日期"2024-03-15"增强可读性
Highlights
- 7步式清晰执行流程
- 包含 Troubleshooting 和 Performance Notes
- Resource Types 参考表完整
Areas to improve
-
未说明 MCP 服务器连接失败处理 Reported severity: Minor
Troubleshooting 未覆盖 MCP 服务器不可用场景
Recommendation: 建议在 Troubleshooting 增加 MCP 连接失败的处理建议,如检查服务器状态、重试机制等
Highlights
- 所有工具调用参数完整明确
- 异常场景覆盖全面(数据缺失/无推荐)
- 不可逆操作有反馈确认机制
The arithmetic mean of the first four original scores, rounded to a whole number.
Static text checks
100 / 100 · skillpi-20261123-no-r3-v1
No current rules matched the text.
This score reflects rule matches in the text and is provided for reference before use. It excludes attachments and runtime behavior.
Permissions and checks before use
Automatically summarized from this main document. Matches may be examples or defensive advice; they are not actual permission declarations. Attachments, external dependencies and runtime behavior are not covered.
These common operations were not identified in the main document. This does not mean no permissions or risks exist.
Security rating and access scope
safe · Static evidence review; not a runtime safety guarantee.
Not specified in the source documentation.
Before use, confirm and authorize actual file access, external services and network destinations in your host. This review grants no runtime permissions.
User discussion
No verified reviews yet.