What is Flexprice?
Flexprice is a usage metering, pricing and billing engine for AI-native and SaaS companies, developed by the company of the same name and published as open source on GitHub. Applications, AI agents, data warehouses or analytics pipelines send usage events to Flexprice; the platform aggregates them in real time, prices them against each customer's plan, applies prepaid or promotional credits, enforces feature limits and produces invoices. According to the architecture documentation, it sits between the customer's application and its payment providers rather than replacing them, and it can run on top of an existing Stripe or Chargebee setup or as the full billing layer.
The software is offered in two ways. Flexprice Cloud is the hosted service, with a dashboard, API endpoints in four regions (US, India, Canada and EU) and paid plans listed on the pricing page. The community edition can be self-hosted: the self-hosting guide covers a Docker Compose setup on one machine and a production layout on AWS, and a separate guide covers building the dashboard frontend against a self-hosted API. The documentation states that the same artifacts that run Flexprice Cloud also ship as Helm charts.
The backend is written in Go. A single codebase runs in three roles: an API service (the only internet-facing component, serving more than 200 REST endpoints), a Kafka consumer that processes usage events asynchronously, and a background worker. Transactional state lives in PostgreSQL, usage events are stored in ClickHouse, Kafka carries the event stream, Redis is used as a cache and Temporal orchestrates long-running workflows. On Flexprice Cloud, webhooks are delivered through Svix with signatures; a self-hosted instance uses native delivery by default and can be configured to use Svix as well.
Releases are published frequently on the GitHub releases page. The latest release is v2.1.48, published on November 5, 2026. Its notes list billing terms and instalments for commitments, automatic charging of Razorpay card and UPI mandates, skipping the Stripe invoice sync for marketplace subscriptions, smallest-unit conversion for amounts in invoices and payments, and a four-digit year in invoice PDF dates. The previous release, v2.1.47 of November 4, 2026, added plan price and subscription line item history endpoints and prorated allowances that never reset.
Flexprice describes itself as a commercial open source company using an open core model. The README states that about 99% of the code is licensed under the AGPLv3, while the Enterprise Edition directories (ee and internal/ee) are under a commercial license. The pricing page states that every paid plan includes all Flexprice features and that the open source version does not include some of them.
Flexprice screenshots
Explore the interface. Open a screenshot to view it at full size.

Customer portal Overview tab from the Flexprice docs, with demo data for a fictional company: a failed payment notice, next billing, amount due, credit balance, payment methods and active and trial subscriptions.

Customer portal Usage tab from the Flexprice docs: 30-day spend, daily cost trend, quotas for API calls and AI tokens with overage, and a breakdown of usage, unit cost and share of spend per feature.

Open architecture figure from the Flexprice README: usage sources on the left feed the metering, credits, pricing and billing core, which connects to payment, CPQ, CRM and accounting systems.

System architecture figure from the Flexprice architecture docs: events arrive via SDK or a collector sidecar, pass a load balancer and WAF, and are processed by the API, consumer and worker services with managed data stores, ClickHouse, Temporal and Svix.
Source: official Flexprice project page.
Key capabilities
- Usage metering Applications send usage events with an event name, an external customer ID and arbitrary properties through the REST API, the SDKs, the CLI or an HTTP ingestion source. A metered feature carries a meter that selects events by name, filters them by property values and aggregates them, for example a SUM over an
input_tokensproperty.POST /eventsreturns 202 as soon as an event is queued, and anevent_iddeduplicates retried events. The features documentation notes that a meter's event name and aggregation cannot be changed after creation. - Feature types and entitlements Features come in four types: metered (usage counted from events, with a usage limit and reset period), boolean (on or off access such as SSO), static (a fixed text value such as a support tier) and config (a JSON object of settings such as rate limits). Entitlements attach these features to plans or individual customers, and an application can query Flexprice to check what a customer is allowed to use. The type of a feature is fixed at creation.
- Plans and prices Plans carry prices, entitlements and credit grants that are copied to subscriptions. Prices use one of three billing models: FLAT_FEE (an amount per unit), PACKAGE (an amount per block of units) and TIERED (tiers with a tier mode such as SLAB). The README lists seat-based subscriptions, pay-as-you-go, volume tiers, free tiers with overage and hybrid models, plus per-customer price overrides and plan versioning.
- Credits, wallets and top-ups Customers can hold wallets with prepaid or promotional credits. Credit grants can be attached to plans, unused credits can expire, and automatic top-ups can be configured at balance thresholds. Credits are applied to charges when invoices are computed, and the customer portal shows the balance and the credit history.
- Subscriptions and billing cycles Subscriptions bill on a configured cadence and handle proration, overages, add-ons, coupons, trials and schedules. Line items can be added or ended on a subscription, and commitments are supported; v2.1.48 added billing terms and instalments for commitments. The pricing page lists billing in the customer's timezone, invoice grace periods and multi-currency billing among the plan features.
- Invoices, credit notes and taxes Flexprice generates invoices with line items tied to tracked usage or defined prices, renders them as PDFs and can send them by email. Credit notes, editable draft invoices and tax rates with tax associations are part of the API. Tax can also be calculated through Stripe Tax for VAT, GST and sales tax on invoices and credit notes, as described in the integrations overview.
- Payment and invoicing integrations Integrations built and maintained by Flexprice connect to Stripe (card payments, payment links, customer and invoice sync), Razorpay, Paddle, Nomod, Moyasar, Whop and Chargebee. When an invoice is finalized, it can be synced to the connected processor so that the customer is charged there. The pricing page lists dunning and payment retries for Stripe payments.
- Accounting, CRM and marketplaces Invoices, items and customers can be synced to QuickBooks Online and Zoho Books. The HubSpot and Attio integrations import customers from won deals and write invoices, quotes or subscription values back to the CRM. Marketplace integrations for AWS Marketplace, Google Cloud Marketplace and Azure Marketplace register buyer agreements and report usage so that the marketplace bills the buyer.
- Customer portal Each customer can get a hosted billing portal, opened with a customer-scoped session token or a copied link. The customer portal documentation shows tabs for overview (next billing date, amount due, credit balance, payment methods and subscriptions), usage (spend, usage trend, quotas and a breakdown by feature), credits and invoices with download and pay actions.
- REST API and webhooks The API uses API keys sent in the
x-api-keyheader; secret keys are for server code and publishable keys can only perform customer-level actions. The OpenAPI document is hosted at swagger.flexprice.io and also shipped in the repository. Webhooks deliver invoice, payment, subscription, wallet and usage events, with signature verification and retries documented for Flexprice Cloud. - SDKs for Go, Python and TypeScript The official SDKs are generated from the same OpenAPI document:
github.com/flexprice/go-sdk/v2(Go 1.25 or newer, with an async event batcher),flexpriceon PyPI (Python 3.10 or newer, sync and async clients) and@flexprice/sdkon npm (Node.js 18 or newer, Bun, Deno and browsers). All three cover every public endpoint, offer opt-in retries for 429 and 5xx responses and include typed webhook payload models. - Command-line interface The Flexprice CLI sends usage events, shows how they were metered and manages customers, plans, subscriptions, wallets, invoices and other resources. It installs on macOS or Linux with
curl -fsSL https://cli.flexprice.io | sh, throughgo install, or from release archives for macOS, Linux and Windows on amd64 and arm64. It produces stable JSON output with documented exit codes for CI use and accepts a--base-urlfor self-hosted instances. - MCP server and agent tooling A hosted MCP server exposes the Flexprice API as tools for MCP clients such as Claude Code, Cursor, VS Code and Windsurf, with browser login or an API key. It is hosted for the US and India regions; the npm package
@flexprice/mcp-servercan be run locally against a self-hosted instance and limited to read operations with--scope read. The documentation also describes agent skills and a Slack app for billing questions. - UI kit The
@flexprice/uipackage publishes React components taken from the Flexprice dashboard: pricing tables and cards, metric cards, usage trend charts, usage breakdowns, quota bars, credit balances and credit history. The components are presentational and accept data from the SDK, the REST API or any other source, with light and dark themes and server-side rendering support in Next.js, Remix and Astro. - Self-hosting with Docker Compose The community edition runs on Linux, macOS or WSL with Go 1.23 or newer, Docker with Docker Compose and make. Running
make dev-setupafter cloning the repository starts PostgreSQL, Kafka, ClickHouse and Temporal, builds the Flexprice image, runs migrations, seeds a default tenant and starts the API, consumer and worker services. The API then listens on port 8080 and the Temporal UI on port 8088. - Self-hosting on AWS and the dashboard A separate guide describes a production deployment on AWS with ECS on ARM64 EC2 instances, Aurora PostgreSQL, Amazon MSK, ClickHouse on EKS installed with Helm, ElastiCache Redis, DynamoDB and S3. The dashboard (
flexprice-front) is a static single-page app built with Vite that can run with Docker Compose, a manual build served by nginx, or Vercel; in self-hosted mode it uses the backend's own login and signup endpoints instead of Supabase. - Flexprice Cloud regions and compliance Flexprice Cloud runs in US, India, Canada and EU regions, each with its own API base URL, and a tenant's data stays in the region where it was created. The status page at status.flexprice.io tracks the Cloud API and admin portal. The documentation states that Flexprice is SOC 2 Type II, ISO 27001 and GDPR compliant, with reports available through the trust centre.
- Flexprice Cloud plans The pricing page lists a Launch plan at $99 per month as a flat subscription covering up to $300K of billing volume, a Growth plan from $500 per month plus 0.40% of billing with up to 50M usage events per month, and a Scale plan with custom pricing, no revenue share and VPC, on-prem or air-gapped deployment. Scale adds SAML SSO, SCIM, role-based permissions and a custom SLA. The open source version is listed separately for self-hosting.
Where Flexprice fits
Billing AI products per token or per request
The documentation's pricing teardowns model per-token API pricing with separate metered features for input, output and cached tokens, billed per million tokens. The application sends one event per request with token counts as properties, each feature sums one property, and usage prices on the plan turn those quantities into charges. The usage-based pricing recipe walks through the same pattern for a voice AI platform.
Hybrid plans with a base fee, allowances and overage
A plan combines a fixed recurring price with usage prices and entitlements. Included allowances are set as entitlement usage limits with a reset period, and usage beyond them is billed at an overage rate, as in the hybrid pricing recipe. Boolean and static features gate capabilities such as SSO or a support tier per plan, and per-customer overrides cover negotiated contracts.
Prepaid credits and wallet top-ups
In a credit-based model, customers buy credits up front and each action deducts a defined number of credits. Wallets hold the balance, plan credit grants add recurring credits, promotional credits can expire, and automatic top-ups refill the wallet at a threshold using a saved payment method. The credit-based pricing recipe shows the setup, and the customer portal shows the remaining balance.
Feature access checks inside the product
The application asks Flexprice which entitlements a customer has before allowing an action, for example whether an API call quota for the month is exhausted or a feature flag is enabled. Config features return a JSON object, such as rate limits, that the application reads directly. For browser and mobile clients, the documentation describes customer-scoped portal sessions or a backend proxy so that secret API keys stay on the server.
Collecting payments through an existing processor
Flexprice computes the invoice and pushes it to the connected provider, such as Stripe, Razorpay, Paddle or Chargebee, which collects the payment. Stripe Tax can calculate VAT, GST or sales tax on the invoice, and finalized invoices can be synced to QuickBooks or Zoho Books. Similar iThub listings for the payment side include Stripe; CRM sync covers HubSpot and Attio.
Selling through cloud marketplaces
For software sold on AWS Marketplace, Google Cloud Marketplace or Azure Marketplace, Flexprice registers each buyer agreement and reports subscription usage to the marketplace, which then bills the buyer and pays out the seller. The integrations overview describes the shared marketplace workflow and the connection setup for each provider.
Install
git clone https://github.com/flexprice/flexprice && cd flexprice && make dev-setupReviews of Flexprice
Be the first to share your experience with Flexprice.
Write a review
Loading review form…

