numbers money calculating calculation

Money matters: Automating your Cloud Billing budgets

The bigger a cloud environment, the more important it is to have robust cost management tools, including budget automation capabilities. Budgeting tools can help you avoid unnecessary costs via proactive notifications of future (and actual) overages.

Source: Money matters: Automating your Cloud Billing budgets

 Billing automation can help you support multiple budgets, each with very granular filters (we have customers with thousands of individual budgets!), and customize your budget notifications. Here on the Cloud Billing team, we’ve been working hard to improve these capabilities based on your feedback, and are excited to announce several enhancements: 

  • General availability (GA) of the Budgets API (learn more)
  • Granular choice of credits – choose specific credits to include in your budget (learn more)
  • Customized budget alert email recipients – send email notifications to whoever you want, as well as remove billing admins and users from the default list (learn more)

Let’s take a look at these new features in greater depth. 

Cloud Billing’s latest budgeting features

Our goal with Cloud Billing is to create an enterprise-grade cost management suite, complete with all the tools you need to manage the largest and most complex of cloud environments. Read on to learn more about Cloud Billing’s new budgeting and automation capabilities. 

Budgets API

Earlier this month we announced the general availability of the Budgets API. The Budgets API allows you to do almost everything from within the Cloud Billing UI: create, edit and delete budgets, as well as use its scoping and filtering capabilities. You can interact with the API directly through REST calls, or with our Java, Node.JS, Python, GO, and .NET client libraries. 

Where the UI and API capabilities differ, know that those differences will be short-lived—our goal is to ultimately deliver feature parity between the UI and the API. 

The Budgets API is especially useful when you want to automate budget creation, i.e., create a budget when a team spins up a new project. It’s also great for editing budgets en masse. For example, if you know you’re about to have a spike in sales, you could increase all related budgets by 20%. 

Another great use for the Budgets API is to obfuscate and simplify your end users’ permission model for budget creation and editing. If your company already has a self-managed portal for cloud resource management, you can integrate simple budget experiences there, and then use a Service Account to create or edit the budgets. This way, you don’t need to give your users budget-related IAM permissions to allow them to do more than they were originally set up to do. Learn more in our documentation.

Previously, the credits setting was a simple checkbox that let you include available credits in your budget. Now, you can choose specific credit families, such as discounts or promotions, or even specific credit types (e.g., free tiers). For example, you can build a durable budget that excludes any one-time promotional credits that you may receive at the free tier level. 

SaleBestseller No. 1
Acer Aspire 3 A315-24P-R7VH Slim Laptop | 15.6" Full HD IPS Display | AMD Ryzen 3 7320U Quad-Core Processor | AMD Radeon Graphics | 8GB LPDDR5 | 128GB NVMe SSD | Wi-Fi 6 | Windows 11 Home in S Mode
  • Purposeful Design: Travel with ease and look great...
  • Ready-to-Go Performance: The Aspire 3 is...
  • Visibly Stunning: Experience sharp details and...
  • Internal Specifications: 8GB LPDDR5 Onboard...
  • The HD front-facing camera uses Acer’s TNR...
Bestseller No. 2
HP Newest 14" Ultral Light Laptop for Students and Business, Intel Quad-Core N4120, 8GB RAM, 192GB Storage(64GB eMMC+128GB Micro SD), 1 Year Office 365, Webcam, HDMI, WiFi, USB-A&C, Win 11 S
  • 【14" HD Display】14.0-inch diagonal, HD (1366 x...
  • 【Processor & Graphics】Intel Celeron N4120, 4...
  • 【RAM & Storage】8GB high-bandwidth DDR4 Memory...
  • 【Ports】1 x USB 3.1 Type-C ports, 2 x USB 3.1...
  • 【Windows 11 Home in S mode】You may switch to...

Last update on 2024-04-05 / Affiliate links / Images from Amazon Product Advertising API

Customized budget alert email recipients

Cloud Billing is now integrated with Cloud Monitoring so you can send notification emails to up to five notification channels; in addition you can decide whether or not to send budget notifications to billing users and admins. With these two features together, you can ensure that notifications are sent to the appropriate recipients.

Programmatic budget notifications

Just like the ability to automate budget creation, Cloud Billing can also alert Pub/Sub topics about changes to a budget. Unlike with email notifications, Cloud Billing notifies the Pub/Sub topics regardless of whether a budget threshold has been crossed, and that information can be easily incorporated into your business logic. You can see some examples of programmatic budget notifications here, including posting to a Slack channel.

A sample process

New
Naclud Laptops, 15 Inch Laptop, Laptop Computer with 128GB ROM 4GB RAM, Intel N4000 Processor(Up to 2.6GHz), 2.4G/5G WiFi, BT5.0, Type C, USB3.2, Mini-HDMI, 53200mWh Long Battery Life
  • EFFICIENT PERFORMANCE: Equipped with 4GB...
  • Powerful configuration: Equipped with the Intel...
  • LIGHTWEIGHT AND ADVANCED - The slim case weighs...
  • Multifunctional interface: fast connection with...
  • Worry-free customer service: from date of...
New
HP - Victus 15.6" Full HD 144Hz Gaming Laptop - Intel Core i5-13420H - 8GB Memory - NVIDIA GeForce RTX 3050-512GB SSD - Performance Blue (Renewed)
  • Powered by an Intel Core i5 13th Gen 13420H 1.5GHz...
  • Equipped with an NVIDIA GeForce RTX 3050 6GB GDDR6...
  • Includes 8GB of DDR4-3200 RAM for smooth...
  • Features a spacious 512GB Solid State Drive for...
  • Boasts a vibrant 15.6" FHD IPS Micro-Edge...
New
HP EliteBook 850 G8 15.6" FHD Laptop Computer – Intel Core i5-11th Gen. up to 4.40GHz – 16GB DDR4 RAM – 512GB NVMe SSD – USB C – Thunderbolt – Webcam – Windows 11 Pro – 3 Yr Warranty – Notebook PC
  • Processor - Powered by 11 Gen i5-1145G7 Processor...
  • Memory and Storage - Equipped with 16GB of...
  • FHD Display - 15.6 inch (1920 x 1080) FHD display,...
  • FEATURES - Intel Iris Xe Graphics – Audio by...
  • Convenience & Warranty: 2 x Thunderbolt 4 with...

Last update on 2024-04-05 / Affiliate links / Images from Amazon Product Advertising API

How might you use these features together? Here’s a sample process that you could implement in your organization to create a budget for a project, monitor it, and automatically disable the project if it reaches a certain threshold.

  1. Initiate infrastructure deployment using your tool of choice, for example Terraform or another Infrastructure as Code tool.
  2. That in turn calls into Google Cloud Build to deploy your custom workflows across multiple environments, including VMs, serverless, Kubernetes, or Firebase.
  3. Using the Google Cloud Budget API, create an overall budget for the new project, using actual amounts, as well as forecasted thresholds.You can send notifications to: 
    1. Billing admins and specific employees via Cloud Monitoring channels
    2. A Pub/Sub topic
  4. Create a cloud function to monitor the Pub/Sub topic, which automatically disables billing if spend is over 150% of budget. This happens if (and only if), this is a test environment, as determined by the environment label. For all other environments publish a message to the team Slack channel.
Click to enlarge

See code examples here

Your budget, your way

Every organization is different, and you need the ability to customize the rate at which you consume your cloud resources. We continue to add features to Cloud Billing that allow any organization—from the smallest business to the largest enterprise—to manage their budget how they want, with programmatic methods that enable granular budgets and automated cost controls. To learn more and get started with budgeting on Cloud Billing, check out the documentation.