ClawKit Logo
ClawKitReliability Toolkit
Back to Registry
Official Verified

amg-check-azure-spend

Run only when the user explicitly asks for a monthly Azure subscription cost analysis — lists all accessible subscriptions, lets the user choose which to analyze, then queries last billing month's cost breakdown by resource type, region, and service category for each subscription. Queries subscriptions sequentially with 1-minute waits between calls to avoid billing API rate limits (429). On first run, auto-discovers datasource UID.

skill-install — Terminal

Install via CLI (Recommended)

clawhub install openclaw/skills/skills/1w2w3y/amg-check-azure-spend
Or
<!-- Auto-generated for OpenClaw by pack-openclaw. Notes for OpenClaw users: - Claude Code dynamic expressions (!`...`) in this file are NOT evaluated by OpenClaw and appear as literal text. Run them manually at the start of the workflow. - Invoke this skill only via slash command (e.g. /amg-check-azure-spend). Auto-invocation is disabled on Claude Code but not on OpenClaw. -->

OpenClaw Setup (one-time)

This skill calls MCP tools prefixed with mcp__amg__*, so OpenClaw must have an MCP server registered under the exact name amg. Run this once per workspace before invoking the skill:

openclaw mcp set amg '{"url":"https://<your-grafana-instance>/api/azure-mcp","transport":"streamable-http","headers":{"Authorization":"Bearer <your-token>"}}'

Replace <your-grafana-instance> with your Azure Managed Grafana endpoint and <your-token> with a valid Grafana service-account token (starts with glsa_). The server name must be amg — the skill's allowed-tools reference mcp__amg__* and will not find tools under any other name.

Verify the server is registered:

openclaw mcp list

Official skill source: https://github.com/Azure/amg-skills

Runtime Context

  • Current UTC time: !date -u +%Y-%m-%dT%H:%M:%SZ
  • Config: !cat memory/amg-check-azure-spend/config.md 2>/dev/null || echo "NOT_CONFIGURED"
  • Arguments: subscription-ids=$ARGUMENTS

Azure Subscription Cost Analysis

Analyze Azure subscription costs for the last full billing month using amgmcp_cost_analysis. Queries each subscription individually with mandatory waits between calls to respect the billing API rate limit.

Critical Constraints

  • No subagents for MCP. The Agent tool cannot access MCP tools — all MCP calls must be made from the main context.
  • Sequential queries only. Query one subscription at a time. Never query multiple subscriptions in parallel.
  • Mandatory 1-minute wait. After each amgmcp_cost_analysis call, run sleep 60 via Bash before the next call. This is non-negotiable — the billing API has a tight rate limit.
  • Recommend 5 subscriptions per run. The billing API has tight throttling — each subscription takes 1-3 minutes (wait time + potential 429 retries). Warn the user if they select more than 5 that the run will be slow, but allow it if they confirm.
  • 429 backoff. If you receive a 429 (Too Many Requests), wait 2 minutes (sleep 120), then retry. If 429 persists, wait 5 minutes (sleep 300) and retry once more. If still failing, skip that subscription and note it in the report.

Progress Tracking

Update checkboxes as you complete each phase:

  • Phase 1a: Datasource validated
  • Phase 1b: Subscriptions listed
  • Phase 1c: Subscriptions selected
  • Phase 2: Cost queries completed (0/N)
  • Report presented
  • Report saved to memory/amg-check-azure-spend/report.md

Configuration

Metadata

Author@1w2w3y
Stars4473
Views0
Updated2026-05-01
View Author Profile
AI Skill Finder

Not sure this is the right skill?

Describe what you want to build — we'll match you to the best skill from 16,000+ options.

Find the right skill
Add to Configuration

Paste this into your clawhub.json to enable this plugin.

{
  "plugins": {
    "official-1w2w3y-amg-check-azure-spend": {
      "enabled": true,
      "auto_update": true
    }
  }
}
Safety NoteClawKit audits metadata but not runtime behavior. Use with caution.

Related Skills

amg-check-storage-account

Run only when the user explicitly asks for a fleet-wide Azure Storage Account health check — pulse check for availability, latency, transactions, and error rates across all accounts, then deep-dives into the top 7 most interesting accounts with metrics (E2E latency, server latency, capacity, ingress/egress) and resource logs. Tracks known issues across sessions via persistent report. On first run, auto-discovers datasource UID and prompts for subscription ID.

1w2w3y 4473

amg-check-key-vault

Run only when the user explicitly asks for a fleet-wide Azure Key Vault health check — pulse check for availability, API latency, throttling (429s), auth failures (401/403), and vault saturation across all vaults, then deep-dives into the top 7 most interesting vaults with metrics and resource logs. Tracks known issues across sessions via persistent report. On first run, auto-discovers datasource UID and prompts for subscription ID.

1w2w3y 4473

amg-check-cosmosdb-mongo-ru

Run only when the user explicitly asks for a fleet-wide Cosmos DB for MongoDB (RU) health check — scans NormalizedRU consumption, service availability, server-side latency, throttling (429s), and replication metrics across all accounts, then deep-dives into abnormal accounts with resource logs and correlation analysis. Tracks known issues across sessions via persistent report. Uses AMG-MCP pulse check for Tier 1 triage, then batched Azure Monitor queries for Tier 2 investigation. On first run, auto-discovers datasource UID and prompts for subscription ID.

1w2w3y 4473

amg-check-pg-flex

Run only when the user explicitly asks for a fleet-wide PostgreSQL Flexible Server health check — scans CPU, memory, storage, IOPS, disk bandwidth, and connection metrics across all servers, then deep-dives into abnormal servers with resource logs and correlation analysis. Tracks known issues across sessions via persistent report. Uses AMG-MCP pulse check for Tier 1 triage, then batched Azure Monitor queries for Tier 2 investigation. On first run, auto-discovers datasource UID and prompts for subscription ID.

1w2w3y 4473