Bedrock Budgeteer

A comprehensive serverless budget monitoring and control system for AWS Bedrock API usage.

Find this useful? Star the repo to follow updates and show support! ⭐ Star on GitHub

Deploy with CDKcdk deploy from the app/ directory. See Deployment Guide for all options.

Bedrock Budgeteer monitors every Bedrock API call in real-time, calculates token-based costs, and enforces per-user budgets through a progressive flow: warning, grace period, suspension, and automatic restoration on budget refresh.


What’s Inside


Key Features

  • Real-time cost tracking — Monitors every Bedrock API call and calculates token-based costs using the AWS Pricing API
  • Automated budget enforcement — Per-user spending limits with progressive controls (warnings, grace period, suspension)
  • Smart notifications — Multi-channel alerts via email, Slack, and SMS
  • Zero-touch operation — Fully serverless with automatic user setup and budget initialization
  • Enterprise-ready — Comprehensive audit trails, IAM-based access control, optional KMS encryption

Quick Start

Prerequisites

  • Python 3.11+, Node.js 18+, AWS CDK CLI v2, AWS CLI v2
  • AWS account with CDK bootstrapped

Deploy

cd app
python3 -m venv .venv
source .venv/bin/activate
pip install -r requirements.txt
cdk deploy

Verify

python -m pytest tests/unit/ -v

About

Bedrock Budgeteer is an open-source project by TEA/Branch.

Licensed under MIT.


Bedrock Budgeteer is an open-source project licensed under MIT.

This site uses Just the Docs, a documentation theme for Jekyll.