DEV Community

Shlok Madhekar
Shlok Madhekar

Posted on

Stop paying for your users' AI usage

There is a specific moment every AI product hits. The feature works, people like it, and then you open the provider billing page and realize your most engaged users are your least profitable ones. Every other kind of software rewards engagement. Inference punishes it. Your costs scale with usage and your revenue scales with seats, and those two lines were never going to stay on the same side of each other.

Teams standardly reach for one of three escapes, and all three have the same flaw.

Raise prices. Now your median user, who runs a handful of prompts a week, is subsidizing your p95 user, who runs an agent loop all day. The median user eventually notices they are overpaying and churns, which makes the math worse, which suggests raising prices again.

Sell credits. Metered billing is honest, but now you are a token reseller. Users can see the markup, compare you to the provider's list price, and ask why they are paying you 3x for the same tokens. You have also just signed up to build a billing engine, which is its own product.

Rate limits. The cheapest option and the most expensive one. The users who hit your limits are by definition your power users. Walls are how you convert them into someone else's power users.

The fourth option

The fourth option is to stop owning the bill.

Your user very likely already pays for AI. They have a ChatGPT Plus or Claude Pro subscription, or an API key with credit sitting on it. Right now that spend and your infrastructure bill are two separate worlds, and you are financing the bridge between them out of your margin.

BYOK (bring your own key) collapses the two. The user plugs their own account or key into your app. Their usage runs on their credential and counts against their subscription or their credit, not yours. Your inference cost for that user goes to approximately zero, and "unlimited" becomes a word you can safely put on a pricing page, because the marginal request is not yours to fund.

This is not a fringe pattern. Developer tools normalized it years ago. Nobody expects their CI provider to pay for their AWS bill. AI is the one place where products still default to bundling the compute, mostly because the first wave of AI apps launched before anyone had a subscription worth bringing.

So why doesn't everyone do it

Because the standard implementation is a <input type="password"> that says "paste your OpenAI key," and that input is doing a lot of unexamined work.

From the user's side: they are handing a live, spendable credential to a website they met twenty minutes ago, with no idea how it is stored, no scoping, and no revoke button other than rotating the key at the provider.

From your side: you are now warehousing other people's billing credentials. Stored badly, that is a breach headline. Stored well, it is real engineering: encryption, key management, redaction, rotation, revocation, per-user usage attribution. And then again for the next provider, because their key format and auth quirks differ.

None of that work is your product. It is load-bearing plumbing that every BYOK app rebuilds separately, usually to about 60 percent completeness. I have spent the last month reading GitHub issues where maintainers describe their own BYOK implementations as a liability, in those words.

What good BYOK looks like

Users already know exactly one flow for delegating account access to a third party: OAuth. Connect button, consent screen that says what the app gets, revoke from one place, done. "Sign in with Google" and Stripe Connect trained everyone.

BYOK should feel identical. Connect GPT. Connect Claude. A consent page that says "usage counts against your subscription," an Allow button, and a revoke switch that works instantly. No raw key ever visible to the app, so the app has nothing to leak.

Being upfront about my stake: this is what I build. Monet is that flow as a service. Hosted connect page where users link ChatGPT Plus, Claude Pro, or paste a provider key. Credentials are AES-256-GCM encrypted into a vault your app never touches. Your app holds an opaque token and calls one OpenAI-compatible endpoint, and Monet proxies to the provider, streams the response, and logs real token counts per user so you can meter or pass costs through. It is free through the beta, and there is a working demo at demo.monet.gg.

BYOK fits best where your users are developers, AI power users, or teams that already hold provider accounts, which is exactly the audience that runs up the biggest inference bills. Dev tools, agent platforms, prosumer software: your heaviest users are the most likely to have a subscription to bring, which means the users who cost you the most today are the cheapest ones to convert.

The margin problem is not that AI is expensive. It is that you volunteered to pay for something your users already own.

Related: How to let users bring their own OpenAI or Anthropic API keys (without storing them in plaintext), the implementation half of this argument.


I'm Shlok, 15, building Monet solo. Replies and disagreement welcome: shlokmadhekar88@gmail.com, github.com/shlok-madhekar, @shlokbuilds.

Top comments (0)