@revturbine/sdk 0.2.76 → 0.2.77

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -13585,7 +13585,7 @@ type RevTurbineThemeInput = {
13585
13585
  *
13586
13586
  * @example
13587
13587
  * ```ts
13588
- * import { initRevTurbine, PlacementController, EntitlementGate } from '@revt-eng/web-sdk/headless';
13588
+ * import { initRevTurbine, PlacementController, EntitlementGate } from '@revturbine/sdk/headless';
13589
13589
  *
13590
13590
  * const session = await initRevTurbine({
13591
13591
  * tenantId: 'tenant_abc',
@@ -13975,6 +13975,14 @@ declare class SdkSession {
13975
13975
  getUserContext(): ReturnType<RevTurbineCustomerSdk['getUserContext']>;
13976
13976
  /** Update usage balances (e.g. after a meter event). */
13977
13977
  updateUsage(balances: UsageBalances): void;
13978
+ /**
13979
+ * Patch the session-scoped user context — the whole-context-minus-`id`
13980
+ * upsert (`update({ plan: {...} })`, `update({ usage: {...} })`, …).
13981
+ * Alias of the SDK's `update()`, promoted onto the session facade so the
13982
+ * documented `session.update()` verb is real (plan 179 Q-1/Q-3 ruling).
13983
+ * Unrecognized keys dev-warn and drop, exactly as on the SDK.
13984
+ */
13985
+ update(patch: RevTurbineUpdateInput): void;
13978
13986
  /** Fetch full user context from the server (server runtime mode). */
13979
13987
  fetchUserContext(userId: string): Promise<UserTargetingContext>;
13980
13988
  /** Get the current trial status. */
@@ -14020,6 +14028,14 @@ declare class SdkSession {
14020
14028
  * prefer {@link entitlement} which returns a full controller.
14021
14029
  */
14022
14030
  checkEntitlement(handle: string, context?: RevTurbineEntitlementContext): Promise<EntitlementResult>;
14031
+ /**
14032
+ * The entitlement check as a `can` question — alias of
14033
+ * {@link checkEntitlement}, promoted onto the session facade so
14034
+ * `session.can('batch_export')` works without the `session.sdk` escape
14035
+ * hatch (plan 179 Q-1/Q-3 ruling). Read `.allowed` for the verdict; an
14036
+ * at-cap blocked limit resolves `limited` + `allowed: false`.
14037
+ */
14038
+ can(handle: string, context?: RevTurbineEntitlementContext): Promise<EntitlementResult>;
14023
14039
  /** Track a custom event. */
14024
14040
  trackEvent(name: string, data?: Record<string, JsonObject[string]>): Promise<void>;
14025
14041
  }
@@ -20758,7 +20774,7 @@ declare class ApiError extends Error {
20758
20774
  *
20759
20775
  * @example
20760
20776
  * ```ts
20761
- * import { BrowserRuntime } from '@revt-eng/web-sdk';
20777
+ * import { BrowserRuntime } from '@revturbine/sdk';
20762
20778
  * import { createStaticProviders } from '@revt-eng/core';
20763
20779
  *
20764
20780
  * const runtime = new BrowserRuntime({