LiteMaaS is a proof-of-concept application for managing LLM subscriptions, API keys, and usage tracking. It seamlessly integrates with LiteLLM to provide a unified interface for accessing multiple LLMs with comprehensive budget management.
- Self-Service: Users can independently manage subscriptions and API keys
- Multi-Model Access: One API key can access multiple models
- Budget Control: Set spending limits at user, team, and API key levels
- Usage Analytics: Comprehensive tracking with dual views:
- User View: Personal usage, token consumption, and costs
- Admin View: System-wide analytics with trends, multi-dimensional filtering (users/models/providers/API keys), and data export
- Role-Based Access Control: Three-tier hierarchy (admin/adminReadonly/user) with OpenShift group integration
- Restricted Access Models: Models can be restricted to admin approval.
- Enterprise Security: OAuth2 authentication with JWT tokens and audit logging
- Easy Deployment and Usage: Automated deployment on OpenShift with PatternFly 6 UI
Note: Screenshots below show core functionality. Admin-specific features (,model, subscription, user management, tools,...) are available but not captured in screenshots.
And more...
LiteMaaS supports multiple deployment methods:
Quick OpenShift Deployment: Readme
Deploy to OpenShift or Kubernetes using the provided manifests and Kustomize configuration:
# Deploy to OpenShift
oc apply -k deployment/openshift/
# Access at:
# - LiteMaaS: https://litemaas-<namespace>.<cluster-domain>
# - LiteLLM UI: https://litellm-<namespace>.<cluster-domain>π Complete Guide: OpenShift Deployment Guide
Deploy using containers with Docker Compose for local development:
# Local deployment with containers
docker-compose up -d
# Or with Podman
podman-compose up -dFor detailed container deployment instructions, see Container Deployment Guide.
For traditional deployment instructions, see the Production Guide.
# Build both packages
npm run build
# Build output locations:
# - Backend: backend/dist/
# - Frontend: frontend/dist/Build container images for deployment using the automated build script:
π¦ Custom Registry: To use a different container registry, edit the
REGISTRYvariable inscripts/build-containers.shbefore building:# Change this line in scripts/build-containers.sh: REGISTRY="your-registry.com/your-org"
# Build both backend and frontend container images
npm run build:containers
# Build and push to registry (default: quay.io/rh-aiservices-bu)
npm run build:containers:push
# Push existing images to registry
npm run push:containersFeatures:
- π·οΈ Centralized versioning - Uses version from root package.json
- π³ Multi-runtime support - Works with Docker or Podman
- π Flexible workflow - Separate build and push operations
- ποΈ Platform support - Build for different architectures
- π§ Registry flexibility - Easy to configure for any container registry
Script options:
# Build without cache
./scripts/build-containers.sh --no-cache
# Build for ARM64
./scripts/build-containers.sh --platform linux/arm64
# Build with local tags only (no registry prefix)
./scripts/build-containers.sh --local- ποΈ Architecture Overview - System design and data flows
- π API Reference - Complete REST API documentation
- ποΈ Project Structure - Complete file organization map
- π§ Configuration Guide - Environment variables and setup
- π οΈ Development Guide - Local development setup
- π Production Deployment - Production deployment options
- π¨ UI Guidelines (PatternFly 6) - Frontend development standards
- π Admin Usage Analytics - Comprehensive system-wide analytics with caching
- π RBAC & User Roles - Three-tier role hierarchy and permissions
- π Multi-Model API Keys - API key architecture
# Install dependencies
npm install
# Start development servers (both backend and frontend)
npm run dev
# Backend only (http://localhost:8081)
npm run dev:backend
# Frontend only (http://localhost:3000)
npm run dev:frontend- Node.js 18.x or 20.x
- PostgreSQL 12+
- npm 8+
- LiteLLM instance (optional, has mock fallback)
LiteMaaS is a monorepo using npm workspaces with two main packages:
- Backend (
@litemaas/backend): High-performance Fastify API server with PostgreSQL - Frontend (
@litemaas/frontend): Modern React application with PatternFly 6 UI
graph TB
subgraph "Frontend"
UI[React + PatternFly 6]
end
subgraph "Backend Services"
API[Fastify API Server]
Auth[OAuth2/JWT Auth]
DB[(PostgreSQL)]
end
subgraph "External Services"
LiteLLM[LiteLLM Gateway]
OAuth[OpenShift OAuth]
end
UI <--> API
API <--> Auth
API <--> DB
API <--> LiteLLM
Auth <--> OAuth
style UI fill:#e3f2fd
style API fill:#fff3e0
style LiteLLM fill:#f3e5f5
-
Clone the repository
git clone https://github.com/rh-aiservices-bu/litemaas.git cd litemaas -
Set up environment variables
# Copy example environment files cp backend/.env.example backend/.env cp frontend/.env.example frontend/.env -
Configure your environment
- See Configuration Guide for all available options
- Minimum required:
DATABASE_URL,JWT_SECRET, OAuth credentials
-
Start PostgreSQL (using Docker)
docker compose -f dev-tools/compose.yaml up -d postgres
-
Run the application
npm run dev
First time running backend tests? You need to set up the test database first:
# Create test database
psql -U pgadmin -h localhost -p 5432 -d postgres -c "CREATE DATABASE litemaas_test;"
# Initialize schema and seed data
cd backend && npm run test:db:setupRun tests:
# Run all tests
npm run test
# Backend tests
npm run test:backend
# Frontend tests
npm run test:frontend
# E2E tests
npm run test:e2e
# Performance tests
npm run test:perfBackend integration tests use a separate litemaas_test database to prevent contamination of development data. See Development Setup Guide for details.
We welcome contributions! Please see our Contributing Guide for details on:
- Code style and conventions
- Development workflow
- Submitting pull requests
- Reporting issues
This project is licensed under the MIT License - see the LICENSE file for details.
- LiteLLM - The AI model proxy that LiteMaaS integrates with
- PatternFly - The UI framework used in the frontend
- π Documentation - Comprehensive guides and references
- π Issue Tracker - Report bugs or request features
- π€ Contributing - Join the development community
Built with β€οΈ by the CAI Team





