EntitlementsFeature
The EntitlementsFeature resource lets you create and manage Stripe Entitlements Features for controlling access to product features.
Minimal Example
Section titled “Minimal Example”Create a basic feature for API access:
import { EntitlementsFeature } from "alchemy/stripe";
const apiFeature = await EntitlementsFeature("api-access", { name: "API Access", lookupKey: "api_access_v1",});
Analytics Feature
Section titled “Analytics Feature”Create a feature for advanced analytics:
import { EntitlementsFeature } from "alchemy/stripe";
const analyticsFeature = await EntitlementsFeature("advanced-analytics", { name: "Advanced Analytics", lookupKey: "analytics_advanced", metadata: { tier: "enterprise", category: "analytics", },});
Custom Integrations Feature
Section titled “Custom Integrations Feature”Create a feature for custom integrations:
import { EntitlementsFeature } from "alchemy/stripe";
const integrationsFeature = await EntitlementsFeature("custom-integrations", { name: "Custom Integrations", lookupKey: "integrations_custom", metadata: { tier: "enterprise", category: "integrations", limit: "unlimited", },});