Stripe.Entitlements reference
EntitlementsFeature
Section titled “EntitlementsFeature”Source:
src/Stripe/EntitlementsFeature.ts
A Stripe Entitlements Feature — a monetizable ability you attach to
Products. When a customer purchases a product with this feature, Stripe
creates an entitlement for them. lookup_key is unique among active
features and immutable (changing it replaces the feature). Name and
metadata update in place.
Stripe does not hard-delete features; destroying this resource
deactivates it (active: false). Archived features cannot be edited
or unarchived. An archived lookup key can be reused — a later create
with the same key provisions a new feature.
EntitlementsFeature: Creating a Feature
Section titled “EntitlementsFeature: Creating a Feature”Generated lookup key
const seats = yield* Stripe.EntitlementsFeature("seats");Named feature with lookup key
const seats = yield* Stripe.EntitlementsFeature("seats", { lookupKey: "seats", name: "Seat licenses",});EntitlementsFeature: Updating a Feature
Section titled “EntitlementsFeature: Updating a Feature”const seats = yield* Stripe.EntitlementsFeature("seats", { lookupKey: "seats", name: "Seat licenses (updated)", metadata: { plan: "pro" },});EntitlementsFeature: Deactivating a Feature
Section titled “EntitlementsFeature: Deactivating a Feature”// stack.destroy() / resource removal sets active: falseconst seats = yield* Stripe.EntitlementsFeature("seats", { lookupKey: "seats", name: "Seat licenses",});RetrieveEntitlementsFeature
Section titled “RetrieveEntitlementsFeature”Source:
src/Stripe/RetrieveEntitlementsFeature.ts
Retrieve a bound Stripe Entitlements Feature over HTTP.
RetrieveEntitlementsFeature: Reading a Feature
Section titled “RetrieveEntitlementsFeature: Reading a Feature”const retrieve = yield* Stripe.RetrieveEntitlementsFeature(seats);const live = yield* retrieve();RetrieveEntitlementsFeatureHttp
Section titled “RetrieveEntitlementsFeatureHttp”Source:
src/Stripe/RetrieveEntitlementsFeatureHttp.tsKind: Layer · Provides:Stripe.RetrieveEntitlementsFeature
HTTP implementation of RetrieveEntitlementsFeature.