MCP ExplorerExplorer

Mcp Cost Bot

@parth01032000on a year ago
1 MIT
FreeCommunity
AI Systems
Python bot to automatically stop (and optionally start) Azure VMs on a schedule using Azure SDK, reducing cloud costs for idle resources.

Overview

What is Mcp Cost Bot

mcp-cost-bot is a Python bot designed to automatically stop and optionally start Azure Virtual Machines (VMs) on a scheduled basis, utilizing the Azure SDK to help reduce cloud costs associated with idle resources.

Use cases

Use cases for mcp-cost-bot include automating the shutdown of development VMs after hours to save costs, managing resources in student labs to prevent unnecessary charges, and scheduling VMs for periodic use in testing scenarios.

How to use

To use mcp-cost-bot, install the required packages using ‘pip install -r requirements.txt’, ensure you are logged into Azure CLI with ‘az login’, and then run the bot with ‘python bot.py’.

Key features

Key features of mcp-cost-bot include the use of Azure SDK with CLI credentials, scheduled shutdowns using the ‘schedule’ library, logging of every action to ‘bot.log’, and extensibility for start/stop automation.

Where to use

mcp-cost-bot is particularly useful in development and testing environments, as well as in educational settings such as student labs, where cost management of cloud resources is essential.

Content

🤖 MCP Project 4 – Azure Cloud Cost Control Bot

This Python bot automates cloud cost-saving by automatically stopping Azure VMs on a daily schedule — ideal for dev/test environments or student labs.


💡 Features

  • ✅ Uses Azure SDK with CLI credentials
  • ⏰ Scheduled shutdown using schedule
  • 📝 Logs every action to bot.log
  • 🚀 Extensible for start/stop automation

⚙️ Tech Stack

  • Python
  • Azure SDK (azure-identity, azure-mgmt-compute)
  • schedule for job automation
  • logging for audit trail

🧪 How to Run

pip install -r requirements.txt
az login  # make sure you're logged into Azure CLI

python bot.py

Tools

No tools

Comments

Recommend MCP Servers

View All MCP Servers