Usage decisions belong inside your product.
Who can use what, how much, and at what price. When one task is dozens of calls across models, tools, and vendors, the answer depends on everything happening in your product at that moment. So that is where Limitr decides it.
From shore, you can't see the details.
Billing and entitlement tools run outside your product and see usage one event at a time. But a single task in your product is now dozens of calls across models, tools, and vendors, and what it costs only adds up when you see them together.
- One eventA single call can't tell you what the whole task cost, or whether it's still worth running.
- No contextWhich customer, which plan, what this run has spent so far. That lives in your product.
Limitr puts the helm on board.
The engine runs inside your product, where the context already is. It sees every call a task makes, across every vendor, the moment it happens, so it can price the task, limit it, and know its margin while it runs.
- SeesEvery call in a task, across models, tools, and vendors.
- DecidesBefore each step runs, against what the task has cost so far.
Your team still sets the course.
Plans, prices, and customer contracts are managed in Limitr Cloud, and it stores every customer and their usage for you. Publish a change and every running copy of your product follows it on the next request, with no release. Billing and margin come from the same place.
Out of range, still steering.
If your product loses its connection to Limitr Cloud, it keeps deciding with the rules it already has, or pauses usage, whichever you choose. Usage syncs when the connection comes back.
Start by watching. Steer when you're ready.
Every limit has a mode, and you can change it without touching code. Most teams start in observe, learn what their usage really looks like, then turn on limits one at a time.
Your product, your rules.
The engine is open source, and your rules are a document you can keep in your own repo. Limitr Cloud manages that document and everything around it. If you ever leave, your product keeps running the same rules.
On board · yours
- The engineOpen source under Apache 2.0. Read it, run it, fork it.
- Your rulesOne versioned document with your plans, prices, and limits. Commit it like code.
- What happens offlineKeep deciding, or pause usage. One setting.
- Your customers' dataPrompts, responses, and payloads never leave your product.
- Your UIPlans, limits, and usage as plain JSON, for any screen you build.
In the harbor · Limitr Cloud
- Editing and historyChange plans and prices, see every version, roll back in one click.
- Instant publishEvery running copy of your product gets the change. No deploy.
- Customer stateEvery customer, meter, and balance stored and synced. No database to run.
- BillingUsage recorded, charged, and rolled into invoices, with Stripe or your own rails.
- Usage intelligenceLive margin by customer, feature, and vendor, with alerts and forecasts.
Headless where your customers see it. Managed where your team works.
Plans, limits, and each customer's usage are available inside your product. Build the usage meter, the upgrade prompt, or the pricing page any way you like, by hand or with an AI coding tool, and it always matches what Limitr enforces.
{ "customer": "Acme", "plan": { "id": "pro", "label": "Pro" }, "features": ["chat", "search", "export"], "ai_token": { "remaining": 340000, "limit": 2000000 }, "upgrade": { "id": "scale", "label": "Scale" }}
Built from limitr.features() and limitr.remainingCredit(), read where your app runs.
One package. A few lines.
Install it like any dependency. A single allow() call checks, prices, and meters each use, inside your process. What happens offline is one setting.
import { Limitr } from '@formata/limitr';
// Runs in this process. Rules and customers come from Limitr Cloud.
const limitr = await Limitr.cloud({
token: process.env.LIMITR_TOKEN,
denyUnconnected: false, // keep deciding if Cloud is out of reach
});
if (await limitr.allow(user.id, 'chat', estimatedTokens)) {
// run the model call
}