Ordainer vs API gateway quotas (Kong, Apigee and others)
The situation
You sell an API, and you want each customer held to the plan they bought. If you already run an API gateway, the first thing to try is its quota or rate limiting feature. Kong and Apigee both have one, and for many teams it is the right answer.
This page compares gateway quotas with Ordainer Cap, so you can tell which fits your setup. They solve overlapping problems from different places: a gateway sits in front of your traffic, and Ordainer is a check inside your handler.
What gateway quotas do
Kong Gateway. The Rate Limiting plugin limits how many HTTP requests can be made in a period of seconds, minutes, hours, days, months or years. It can apply to a Gateway Service, a Route or a Consumer. If an authentication plugin is configured, it counts per Consumer. Otherwise it counts per client IP address. Counters can be kept in memory on each node, in Kong's data store, or in Redis, and Kong's docs explain the tradeoff between accuracy and performance for each. Rate Limiting Advanced adds sliding windows. When a limit is reached, Kong answers HTTP 429 and sends headers that show the limit and what remains. Kong's AI Rate Limiting Advanced plugin can limit LLM traffic by tokens or cost.
Apigee. The Quota policy keeps counters of the requests an API proxy accepts over a period such as a minute, hour, day, week or month, so you can limit apps to, say, a set number of requests a month. The limit can be the same for every app, or differ by API product, app or developer. Apigee supports calendar, rolling window and flexi quota types. When a quota is reached, Apigee rejects calls with HTTP 429 until the counter resets. A separate SpikeArrest policy handles traffic spikes, and Apigee's docs say not to use Quota for that. An LLMTokenQuota policy counts tokens for LLM traffic.
Both vendors file these features under rate limiting, even for monthly quotas. Ordainer uses the term usage cap for a plan allowance over a period, and keeps rate limiting for protecting servers from bursts. See usage caps vs rate limiting.
What Ordainer Cap does
Your customers' integrations and AI agents call your API or MCP tool. At the top of your handler, you send the caller's agent key and the tool name to decide(). Cap checks that key's plan, answers allow or deny, counts the call in the same step, and writes one audit row. In enforce mode, on a deny, the work doesn't run, and only that key is stopped. Plans you create in the console start in shadow mode, which logs would-deny decisions and does not block, so you can see what would be denied before you enforce.
A plan is a count of allowed calls each month, day or minute, for one tool or for every tool. Each agent key counts on its own. Your traffic doesn't pass through us.
Side by side
| Gateway quotas (Kong, Apigee) | Ordainer Cap | |
|---|---|---|
| Where it runs | In your gateway, in front of your traffic | A check your handler calls. Traffic doesn't pass through |
| What you adopt | A gateway, if you don't already run one | One call per tool, from an SDK or plain HTTP |
| Who a limit applies to | Consumer, app, developer, API product, route or IP address, depending on the gateway | Each agent key, on the plan it is bound to |
| What it counts | Requests. Both also have limits for LLM traffic | Allowed calls |
| Periods | Kong: second to year. Apigee: minute to month, for example | Month, day or minute (UTC) |
| Protects against traffic spikes | Yes, with the gateway's rate limiting (Kong) or SpikeArrest (Apigee) | No. Keep your own rate limits |
| Works for traffic that doesn't cross the gateway | No | Yes. It's a call from your own code, so it covers background jobs and MCP tool handlers |
When a gateway quota is the better fit
- You already run Kong, Apigee or a similar gateway and each customer integration already has its own credential there. Its per consumer or per app quota may do the job, and you don't need a second system.
- You need to protect your servers from bursts. That is what a gateway's rate limiting is for, and Ordainer is not a rate limiter.
- You need limits on LLM tokens. Apigee has an LLMTokenQuota policy, and Kong's AI Rate Limiting Advanced plugin can limit by tokens or cost. Ordainer counts calls, not tokens.
- You want enforcement without touching your handlers. A gateway can enforce at the edge. Ordainer's check normally goes in your handler. You can also call it from an edge proxy you run yourself: our docs have an example NGINX recipe, which is not a plugin or a product.
When Ordainer fits better
- You don't run a gateway, and adopting one for plan limits is more than you want to take on. See Enforce plan limits without an API gateway.
- Your plans are per integration or per AI agent. You give each one its own agent key, and in enforce mode a deny stops that key only, not the customer's other integrations.
- You want an audit row for every decision, with a request ID, the reason and what was left, exportable as CSV or JSON.
- You want to try a limit before it blocks anyone. Shadow mode logs would-deny decisions and lets those calls run, and you switch a plan to enforce from the console when the numbers look right.
- Some of your traffic doesn't cross a gateway, such as an MCP server, a background job or an internal service.
Using them together
They fit side by side. Keep the gateway for routing, authentication and spike protection. Use Ordainer for the allowance each key has on its plan. For gateways that proxy calls to AI model providers, such as LiteLLM, Vercel AI Gateway and Cloudflare AI Gateway, see Ordainer vs AI gateways.
What to know during the beta
- Ordainer is in beta. During the beta you use test keys. Live keys are not available yet.
- Ordainer counts calls, not dollars or tokens.
- Each key counts on its own. One cap covering all of a customer's keys together isn't available today.
- It isn't a rate limiter, and it doesn't proxy your traffic.
- It doesn't send usage to a billing system.
Facts about Kong and Apigee come from their official docs as of December 2026. Other gateways have similar features, but names, limits and options differ, so check yours. If something here has changed, tell us at support@ordainer.ai and we'll fix it.
Common questions
Can Kong or Apigee already enforce plan limits?
Yes, for requests counted per consumer, app or developer over a period. If that fits your plans and you already run the gateway, it may be all you need. Ordainer helps when you don't run a gateway, when plans are per integration or AI agent, or when you want an audit row and a shadow mode.
Is Ordainer a replacement for an API gateway?
No. A gateway routes and protects your traffic. Ordainer answers one question before a tool runs: may this call run? Many teams will use both.
Does Ordainer protect against traffic spikes?
No. Ordainer is not a rate limiter. Keep your gateway's rate limiting or your own for bursts.
Does Ordainer cap AI agents and ordinary API integrations?
Both. Give each integration or agent its own agent key on a plan. For MCP, call decide() at the top of each tool handler.
Try it
Ordainer is free during the beta: sign up for test keys with 1,000 decisions a month, no credit card needed.
Get test keys · Produce a deny in the live demo
Using a gateway quota today and still seeing customers run past their plans? We'd like to hear how you handle it: support@ordainer.ai.