Starts a Stripe Checkout and returns the URL to send the browser to.
The caller names a package, never a price: the amount is resolved server-side from the offering, so a page that lies about what something costs changes nothing about what is charged.
Redirect URLs must be on one of the key's allowed origins (exact scheme, host and port) or a verified custom domain over https.
Attempts every queued event once. Called automatically on unload.
Last-known entitlements, or null if nothing has been fetched yet.
Synchronous and network-free, so a first paint can render the truth the server gave last time instead of a flash of the paywall a subscriber has already paid to remove. It is a cache, never an authorization decision: the storage behind it is viewer-editable.
The cache entry with its timestamp, for callers that need staleness.
Client-local. Merging subscribers is a server-side, secret-key operation.
Flushes queued events under the current identity, then rotates it.
Records that a subscriber was shown an experiment variant.
Assignment alone is invisible to the analytics: a visitor bucketed into
an arm but missing from exposure_events still contributes revenue while
being absent from the denominator, which biases conversion rates and
breaks the sample-ratio check. The native path fires this immediately
after the draw; so does the web one.
The wire identity for this browser.
Registers the unload listeners that flush queued events.
Not called by configure(): configure() also runs during server rendering, where there is nothing to listen to. The React provider calls this in an effect; a non-React host calls it once after construction.
Queues an event for at-least-once delivery.
Returns immediately: the event is persisted and sent by the queue, which retries across page loads and flushes when the tab is hidden or closing.
Escape hatch for endpoints without a typed wrapper yet.