Quota
Scheduled-reset per-subject allowances as a Bijection component — calendar, rolling, or epoch windows with readable remaining
git clone https://github.com/bijectionhq/quota.git
cd quota
git checkout e15196de18be568ddc4768e831268fc632aa647bBijection repository access is required. Request access.
Description
Scheduled-reset per-subject allowances as a Bijection component — calendar, rolling, or epoch windows with readable remaining
Explore the package README for API concepts, configuration, and examples. Check the Bijection source for adaptation-specific setup.
Review the source and its dependencies before adopting this package. Source availability does not establish npm publication or runtime qualification.
Getting started
- Get the source at the revision above and read its package documentation.
- Check the required Bijection SDK version, dependencies, and external service credentials.
- Follow the package setup instructions and the guide to using components.
- Exercise the component in your deployment according to your project’s verification rules.
Open source
Maintained source: bijectionhq/quota. Based on vllnt/convex-quota. License: MIT. Consult the repository for license terms, notices, and contributor attribution.
From the upstream publisher
Scheduled-reset per-subject allowances as a Convex component — calendar, rolling, or epoch windows with readable remaining
Explore the demo ↗Upstream package FAQ
What is the difference between @vllnt/convex-quota and @convex-dev/rate-limiter?
@convex-dev/rate-limiter covers general request throttling with fixed windows, token buckets, readable status, and React hooks. @vllnt/convex-quota focuses on the narrower use case of calendar-aligned, timezone-aware reset windows and a privileged refund surface for adjusting allowances after failed operations. The README explicitly recommends using the official rate-limiter for general throttling.
What window types does @vllnt/convex-quota support?
@vllnt/convex-quota supports three window kinds: calendar windows (day, week, or month aligned to an IANA timezone), rolling windows that start from the first allowed consume, and epoch windows computed as floor(now / durationMs). The window policy for a given (scope, subjectRef, key) combination must remain stable; changing it throws a POLICY_MISMATCH error.
Is consume idempotent in @vllnt/convex-quota?
No. quota.consume is not idempotent. If your mutation retries due to Convex OCC conflicts, each successful execution will consume allowance. The README recommends wrapping retried operations with @vllnt/convex-idempotency to avoid double-counting. Never pass limit or amount values from the end-user; the host must supply them.
How do you isolate quotas for multiple tenants or products in the same Convex app?
@vllnt/convex-quota supports two isolation mechanisms. Multiple mounts (app.use(quota, { name: 'webQuota' })) give each mount its own sandboxed database tables. Within a single mount, the scope parameter namespaces records at runtime, which is useful for separating tenants or product lines without separate deployments.
Does @vllnt/convex-quota handle authentication or billing?
@vllnt/convex-quota is auth-agnostic. The host resolves identity and passes an opaque subjectRef string to the component. The component does not implement billing metering, persistent balances, or purchased reset credits. Any auth checks, purchased allowance systems, or audit logging must be implemented in the host application.
Use with agents and CLI
Give your coding agent the component’s source identity and setup guidance.
Help me integrate Quota with Bijection.
Read: https://bijection.com/components/quota/SKILL.md
Check SDK compatibility and dependency availability.
Follow this project's execution and verification rules.Upstream README.md
View repository ↗Documentation from vllnt/convex-quota at its recorded upstream revision. APIs and setup may differ in the Bijection adaptation.
Loading package documentation…