Skip to main content
Pricing templates show how to rebuild a well-known pricing model with Lago, from billable metric to contract. Use them as a starting point when your pricing looks like one of these companies’ and you bill with contracts. Each template follows the same flow: billable metric, product, rate card with rates, plan, customer, contract, then events with external_contract_id. Code samples use cURL against /api/v2. The pricing logic matches the v1 templates, so you can compare both versions side by side. Legacy (v1): Pricing templates with subscriptions.

Per-token pricing (AI)

Mistral.ai

Build a transparent per-token pricing like Mistral, the famous AI company, with multiple dimensions per model and token type.

OpenAI

Replicate OpenAI’s per-token pricing, the famous AI company behind GPT models, with multiple dimensions based on models and action types.

Hybrid pricing

Segment

Build a hybrid pricing and billing system like Segment, the CDP leader, combining a fixed platform fee with a graduated usage component that grows revenue with your users.

Per-transaction pricing

Stripe

Implement a per-transaction pricing model like Stripe, the leading payments infrastructure company, including fees based on the total amount and number of transactions.

Pay-as-you-go pricing

Algolia

Discover how Algolia, the search and discovery platform, increases conversion with commitment-free pricing options that adapt to customers’ needs.

Google BigQuery

Implement a pay-as-you-go pricing model with a free first tier like Google BigQuery, the data analytics platform.

Per-seat pricing

Notion

Set up a per-user pricing like Notion, the collaboration software for innovative teams, with a prorated price per active user.

Contracts vs subscriptions

How v2 objects map to v1.

Your first invoice

From product to contract to invoice.