Gates

Use Plandalf gates to check access before showing a checkout, upgrade, or protected product action.

Gates let you centralize “can this customer access this?” checks around a named action and fallback offer.

Register a gate

plandalf.addGate("export-csv", "upgrade-pro", async () => {
  const user = await getCurrentUser();
  return user.plan === "pro";
});

Check a gate

const { access } = await plandalf.gate("export-csv");

if (!access) {
  await plandalf.present("upgrade-pro");
}

Use cases

  • unlock a paid feature after purchase
  • show an upgrade offer when a user reaches a limit
  • check subscription state before a protected action
  • reuse the same upgrade offer across multiple feature gates

Identity

For account-specific gates, call identify(jwt) before evaluating the gate so the checkout and the access check refer to the same customer context.

Builder context

Move from SDK setup to the commerce surface.

SDK docs cover install, identity, gates, events, and React integration. The linked product surfaces show what the SDK is presenting or listening for.

The Numi API Keys settings page used to create organization API keys.
API keys and SDK configuration should be set before wiring checkout into an app.
The Numi Developer API documentation with sidebar navigation and SDK method reference.
SDK reference owns method details; builder resources explain the business path.
The Numi checkout requirements screen showing gate controls.
Gates decide when an offer or buying surface should be available.

Feature detail