Limits
Use Limits to cap what your Organization spends. You can set a spending limit for the whole Organization, for a Workspace, for a user group, for each user, and for each API key.
When spend reaches a limit, requests under it fail with HTTP status 402 until the limit resets or an admin raises it. The error message names the limit and when it resets. For other 402 errors, see the error glossary.
Spending limits are different from the other controls on your usage:
Control | What it does | Where to set it |
|---|---|---|
| Spending limits | Stop requests once spend reaches an amount you choose, per Organization, Workspace, user group, user, or API key | Admin Panel Limits page |
| Monthly overage spending cap | Caps the pay-as-you-go spend billed after your included monthly usage | Subscription |
| Rate limits | Cap how fast requests can be sent | Usage and rate limits |
Before you start
- Members with the Admin or Billing Organization role can see spending limits.
- Members with the Admin Organization role can add, change, and remove them.
- A Workspace admin can add, change, and remove that Workspace's limits from its Limits tab.
Add a spending limit
1.
Open Admin Panel › Billing › Limits.2.
Open the tab for the kind of limit: Organization, Workspaces, Groups, Users, or API keys.3.
Click Add limit.4.
Choose who the limit applies to, for example one user, a group, or Every user (default).5.
Choose what it applies to in Applies to, its Window, its Amount, and in Emails who gets an email when spend reaches 90% and 100% of it.6.
Click Save.
You can also set a limit when you create a Workspace or an API key, and from a Workspace's Limits tab in Admin Panel › Administration › Workspaces.
To change a limit, click Edit. Only its amount and emails can change. To change its window, add a new limit and remove the old one.
Kinds of spending limits
Limit | What it counts |
|---|---|
| Organization | Everything the Organization spends. |
| Workspace | Everything spent in the Workspace, by any member or API key. |
| User group | What the group's members spend together (a shared group limit), or what each member spends (a limit per member). |
| User | Everything one user spends, including through the API keys they created. Keys created by a service account count toward no user. |
| API key | Everything spent with one API key, whoever uses it. |
Limits for every user or one user
On the Users tab, a limit applies to every user or to one user:
- Every user (default) gives each user their own limit. For example, €50 a day lets each user spend up to €50 a day.
- A limit for one user replaces the default for that user, on the same window and for the usage it applies to. For example, €200 a day for one user replaces the €50 daily default for them, but a monthly default still applies to them.
- To let one user spend without a limit, add a limit for that user and check No limit: exempt this user from the default.
Limits for every API key or one key
On the API keys tab, a limit applies to every API key or to one key:
- All API keys (default) gives each API key its own limit, including keys created later. It counts API usage only. Vibe keys belong to one user each, so user limits cover them.
- A limit for one API key replaces the default for that key, on the same window.
- To let one key spend without a limit, add a limit for that key and check No limit: exempt this key from the default.
Limits for user groups
On Enterprise plans, you can also limit user groups:
- A shared group limit, on the Groups tab, caps what the group's members spend together, members of its nested groups included. It applies on top of each member's own limits.
- A limit per member, added on the Users tab by choosing a group, gives each member of the group their own limit. It replaces the default for those members, like a limit for one user. A user's own limit replaces their group's limit per member.
- A nested group's limit per member replaces its parent group's. A member of several groups that aren't nested in one another is held to the smallest limit.
- To exempt a group's members from the default, add a limit for the group and check No limit: exempt the members from the default. Shared group limits still apply to them.
When your Organization has groups, the default for every user is called Default (no user group).
How limits combine
A request must fit every limit that applies to it: its Organization's, its Workspace's, the shared limits of its user's groups, its user's, and its API key's. The first limit that is reached stops it.
For example, an Organization has these limits:
- Organization: €5,000 a month.
- Workspace Production: €2,000 a month.
- Every user (default): €50 a day, and €200 a day for Alex.
When Alex calls the API with a key in Production, the request is stopped as soon as Alex's spend today reaches €200, Production's spend this month reaches €2,000, or the Organization's reaches €5,000. Other users stop at €50 a day.
What a limit counts
- Applies to chooses the usage a limit counts: All usage, API, or Vibe & Studio. They follow your plan's included usage: API counts what your included API usage covers, and Vibe & Studio what your included Vibe & Studio usage covers, such as Vibe Code. Usage in other parts of Vibe, such as chat, isn't counted yet.
- A limit counts all spend, including spend covered by your included monthly usage and by credits.
Windows
A limit's Window sets how long spend adds up before the limit resets: up to 24 hours, 31 days, 52 weeks, 12 months, or 1 year. Never resets (fixed amount) counts spend from when you save the limit and never resets.
Resets sets when each window starts:
Option | Windows start | Example |
|---|---|---|
| On the calendar | On the UTC clock and calendar: on the hour, at midnight, on Mondays, on the 1st, on January 1 | A monthly limit resets on the 1st at 00:00 UTC. |
| From a date | Every window from that date, at 00:00 UTC. From when it's saved starts from the save. | A 30-day limit from March 10 resets on April 9, then on May 9. |
| From first request | At each user's, key's, or Workspace's first request after the previous window ended | A 1-day limit starts when a user sends their first request and resets 24 hours later. |
A new monthly limit on the calendar counts this month's spend so far. Other new limits count spend from when you save them. The Add limit dialog says which applies.
Troubleshooting
- Requests fail with 402 and a spending limit message. A limit is reached. Wait until it resets, or ask an admin to raise it on the Limits page.
- I can't see Limits in the Admin Panel. You need the Admin or Billing Organization role.
- I can't change a limit's window. Add a new limit with the window you want, then remove the old one.