Skip to main content
Entitlements control what a customer can do based on subscription and usage state.

Two decision types

  1. Feature gates — boolean access, such as analytics or SSO.
  2. Usage limits — numeric caps, such as monthly requests or generated reports.
In a plan family (for example the monthly and yearly versions of one plan), feature gates are the same on every billing interval, but each plan keeps its own usage limit. Usage is counted per billing period, so set the yearly plan’s limit separately, for example 1,000 a month and 12,000 a year.

Server-side enforcement

Call can() immediately before protected work. Deny only when allowed is false. overage: true never denies by itself: a soft limit is reached and the usage is billed as overage, so warn or notify instead of blocking. The response can include usage and margin context in addition to the allow/deny decision.

React presentation

Fetch entitlement state through your authenticated backend and pass it into presentational gates:
The React component improves the interface; your backend check remains the authorization boundary.

Updates

Refresh entitlement state after checkout, subscription, or usage changes. For push-based updates, issue a separate server-authorized realtime token or publish through your own authenticated channel. Never send pk_ or sk_ credentials to a browser WebSocket connection.

Margin-aware decisions

can() can return an economics estimate (cost, revenue and margin of the call) and a policy object with the decision of an optional margin policy. Use them for observability or merchant-defined policy without exposing them to customers unless required. Nozle sends no margin notifications; see Monitor margin yourself.

The can() endpoint

React feature gates

Node.js entitlements

Python entitlements

Go entitlements