MCPcopy Index your code
hub / github.com/getlago/lago

github.com/getlago/lago @v1.49.0

Chat with this repo
repository ↗ · DeepWiki ↗ · release v1.49.0 ↗ · + Follow
527 symbols 1,967 edges 77 files 53 documented · 10% 50 cross-repo links updated 2d agov1.50.0 · 2026-07-07★ 10,18614 open issues
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

Lago

Lago

The AI-native billing platform



Open-source metering, billing & revenue infrastructure for product-led companies.






<a href="https://doc.getlago.com">Docs</a>
·
<a href="https://getlago.com">Website</a>
·
<a href="https://www.getlago.com/slack">Slack</a>
·
<a href="https://github.com/getlago/lago/issues">Issues</a>
·
<a href="https://getlago.canny.io/">Roadmap</a>

Github Stars Release License Slack YC


Trusted by

PayPal Mistral AI Groq Synthesia Laravel


What is Lago?

Lago is the open-source billing platform for usage-based, subscription-based, and hybrid pricing models. If you can track it, you can bill for it.

  • Open-source — self-host for full control over your data, or use Lago Cloud to get started faster. Either way, the code is transparent
  • Payment-agnostic — works with Stripe, Adyen, GoCardless, or any payment gateway
  • API-first — every feature available via REST API
  • SOC 2 Type II certified

Features

Feature Description
Usage Metering Real-time event ingestion and aggregation for any pricing dimension
Billing & Invoicing Automated invoice generation for subscriptions, usage, and hybrid plans
Entitlements Feature access management tied directly to your billing plans
Cash Collection Payment orchestration with dunning, retries, and multi-gateway support
Revenue Analytics Cross-stream visibility into MRR, usage trends, and revenue drivers
Lago Embedded White-label billing for platforms and marketplaces
Lago AI AI-powered billing intelligence and MCP server for AI agents
Integrations NetSuite, Xero, Salesforce, HubSpot, Avalara, AWS/Azure/GCP Marketplace, and more

Get Started

Cloud (fastest)

Start billing in minutes — no infrastructure to manage.

Sign up for Lago Cloud or email hello@getlago.com

Self-hosted

Requirements

  • Docker & Docker Compose
  • Git

Quick start

# Clone the repo
git clone --depth 1 https://github.com/getlago/lago.git
cd lago

# Generate RSA key
echo "LAGO_RSA_PRIVATE_KEY=\"$(openssl genrsa 2048 | openssl base64 -A)\"" >> .env
source .env

# Start Lago
docker compose up

Open http://localhost for the UI. The API is at http://localhost:3000.

After an update

docker compose up

Configuration

If your server is not at localhost, set these in your .env:

LAGO_API_URL="http://your-server:3000"
LAGO_FRONT_URL="http://your-server"

For the full list of environment variables and advanced configuration (S3/GCS storage, SMTP, SSL, dedicated workers for high-volume), see the self-hosted docs.

Find your API key

  1. Open the Developer section in the sidebar
  2. Go to the API keys tab
  3. Click Copy

Documentation

SDKs & Client Libraries

Language Package
Node.js lago-javascript-client
Python lago-python-client
Ruby lago-ruby-client
Go lago-go-client

Full OpenAPI spec: lago-openapi

Stay up to date

Contributing

We welcome contributions! See our contributing guide and the development environment setup.

Look for issues labeled beginner or help-wanted to get started.

License

Distributed under the AGPLv3 License. Why we chose AGPLv3.

Analytics & Tracking

Lago tracks basic actions on self-hosted instances by default. No customer PII or financial data is collected. Learn more or opt out.

Extension points exported contracts — how you extend this code

Core symbols most depended-on inside this repo

Shape

Function 218
Method 218
Struct 76
Interface 8
TypeAlias 6
FuncType 1

Languages

Go100%

Modules by API surface

events-processor/processors/events_processor/processor_test.go38 symbols
events-processor/cache/cache_test.go29 symbols
events-processor/utils/result.go28 symbols
events-processor/config/tracing/datadog_tracer.go21 symbols
events-processor/config/tracing/otel_tracer.go19 symbols
events-processor/config/tracing/tracing.go17 symbols
events-processor/models/stores.go15 symbols
events-processor/config/kafka/consumer.go15 symbols
events-processor/utils/time.go14 symbols
events-processor/config/tracing/empty_tracer.go14 symbols
events-processor/utils/result_test.go13 symbols
events-processor/models/flat_filters.go13 symbols

Datastores touched

lagoDatabase · 1 repos
lago_testDatabase · 1 repos

For agents

$ claude mcp add lago \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact

Ask about this repo answers extend the page