Docs
Getting started

Core concepts

Screen, placement, package, publish and screen types, and how the SDK decides which screen a visitor gets.

For short definitions, see the glossary.

The big picture

Your team designs a screen in the dashboard editor and publishes it. A placement is a named slot (upgrade_button) that points at a screen. Your code asks the SDK for the placement by key, and the SDK shows whatever the placement says. You change the screen, test another one or run a promotion without changing your code.

Screen (draft) --publish--> Screen (published version)
                                   |
Placement "upgrade_button" --------+  display, audience, A/B test, schedule
        ^
        | asks for the key
Your website or app + SDK

Screen

A screen is one thing a visitor sees. It is stored as JSON in the PaywallData format and rendered by the SDK. You never write that JSON by hand. The API and some pages still call a screen a paywall; they are the same thing.

Screen types

The type only groups templates in the dashboard. All types use the same editor, the same JSON and the same SDK calls.

TypeUse it forHow your code takes part
PaywallSelling plansPass products by package ID and run checkout in onPurchase.
Upgrade or promotionBanners, sales, announcementsA Run your code button calls onAction with its action ID.
OnboardingWelcome, goals, setup stepsA flow of linked screens; answers arrive in onAnswer and answers.
Survey and feedbackRatings, NPS, cancel reasonsSame as onboarding.
Permission promptExplain a request before the system asksThe main button runs your code, which then asks the system.
Account momentTrial ending, payment failed, win-backonAction or onPurchase.

A screen that sells nothing needs no purchase button. Every screen needs a way out, so it has a button with the action Close the screen; the SDK adds no close button.

Draft, version and publish

Every screen has a draft (edited, never shown to visitors) and, once published, a published version. Publish runs the editor's checks on the server too, so a broken screen cannot reach your site. Visitors get a new version within about a minute. An earlier version can be made live again. See Publish and versions.

Package

A package is a plan card on a screen. Each has a package ID you choose, such as monthly. Your code passes a price for every package ID, and the SDK fills in the price text. When a visitor taps buy, your onPurchase gets the package ID. See Packages and pricing.

Placement

A placement decides which screen shows in a slot, how it displays, when it shows by itself, and to whom. Its display, trigger, audiences, frequency limit, holdout, A/B test and schedule are explained in Placements. They are not part of the screen's JSON.

Which screen a visitor gets

  1. A schedule in force replaces the placement's screen and pauses the A/B test.
  2. If the frequency limit is reached, nothing shows.
  3. Audiences in order: the first match shows its screen, or nothing.
  4. Otherwise the placement's screen shows, split between A and B if a test runs.
  5. A visitor in the holdout sees nothing.
  6. Otherwise the screen opens and a view is counted.

Flow

A flow is a chain of screens linked by Go to another screen buttons. The placement returns the first screen, so its audience, test and schedule apply to the whole flow. Questions in a flow send answers to your code. See Flows and questions.

On this page