Skip to main content
POST
get current feature status

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json

Body of the request

customerId
string
required

The unprice customer ID

Example:

"cus_1H7KQFLr7RepUyQBKdnvY"

featureSlug
string
required

The feature slug

Example:

"tokens"

timestamp
number

Optional timestamp to inspect a recent point-in-time state. Defaults to the request start time.

Example:

1774094400000

Response

The current feature verification status

allowed
boolean
required

Whether the feature is currently usable for the requested customer and timestamp

Example:

true

featureSlug
string
required

The feature slug that was verified

Example:

"tokens"

rejectionReason
enum<string>

Why the feature is not usable. Omitted when allowed is true.

Available options:
CUSTOMER_NOT_FOUND,
EVENT_TOO_OLD,
INVALID_ENTITLEMENT_CONFIGURATION,
INVALID_AGGREGATION_PROPERTIES,
LIMIT_EXCEEDED,
LATE_EVENT_CLOSED_PERIOD,
NO_MATCHING_ENTITLEMENT,
RUN_BUDGET_EXCEEDED,
UNROUTABLE_EVENT,
WALLET_EMPTY
Example:

"LIMIT_EXCEEDED"

usage
number

Current usage in the active meter window. Present for usage features.

Example:

42

limit
number | null

Configured limit. For usage features this is the active meter-window limit; for tier/package features this is the subscribed quantity limit.

Example:

100

quotaWindow
object | null

The single reset window represented by usage and limit. Null when active grants use different windows.

spending
object

Current priced usage spend for usage-based features

message
string

Optional detail about the verification result

Example:

"Unable to resolve the current meter window for this feature"