Skip to content

Adapty SDK 4.0: migrate from Paywall to Flow#25

Open
yauch-dev wants to merge 1 commit into
mainfrom
release/4.0.0
Open

Adapty SDK 4.0: migrate from Paywall to Flow#25
yauch-dev wants to merge 1 commit into
mainfrom
release/4.0.0

Conversation

@yauch-dev

@yauch-dev yauch-dev commented Jul 19, 2026

Copy link
Copy Markdown
Collaborator

Adopt the 4.0 cross-platform contract. A placement now returns an AdaptyFlow with a list of paywall variations instead of a single AdaptyPaywall.

  • New models: AdaptyFlow, AdaptyFlowPaywall (+ ProductReference), AdaptyUIFlowView; AdaptyPaywall and its ViewConfiguration are removed
  • API renames: GetFlow / GetFlowForDefaultAudience (locale parameter dropped), LogShowFlow, CreateFlowView / PresentFlowView / DismissFlowView; OpenWebPaywall and CreateWebPaywallUrl accept AdaptyFlowPaywall
  • Flow views are single-use and destroyed on dismiss; purchases and errors no longer auto-dismiss the view
  • Events: IAdaptyFlowsEventsListener replaces AdaptyPaywallsEventsListener (flow_view_* ids, did_receive_error, analytic events); new IAdaptyUISystemRequestsHandler for permission ask/answer and app review round-trips, IAdaptyUIObserverModeResolver for Observer-mode purchases and restores
  • Listener interfaces follow the C# I-prefix convention (IAdaptyEventListener, IAdaptyOnboardingsEventsListener, ...); no legacy aliases are kept
  • iOS native SDK 4.0.1 ships via Swift Package Manager only: declared as remoteSwiftPackage for External Dependency Manager 1.2.187+; a new editor build validator enforces iOS deployment target 15.0+
  • Android native SDK and crossplatform bumped to 4.0.0, unity-wrapper AAR rebuilt against them
  • iOS Kids Mode (App Store Kids Category / COPPA): the ADAPTY_KIDS_MODE scripting define enables the KidsMode SPM trait on the AdaptySDK-iOS package via a post-build step (strips IDFA / AdSupport / AppTrackingTransparency) and forces apple_idfa_collection_disabled in the runtime config
  • Legacy onboarding API deprecated in favor of Flows; pre-4.0 deprecated members removed (SetFallbackPaywalls, IDFA collection aliases)
  • report_transaction success response decoded as boolean (was incorrectly parsed as a profile and always surfaced a decoding error)
  • Demo migrated to the Flow API: Paywalls tab renamed to Flows, dead locale input removed; the Editor Noop stub now returns a readable "not available in the Editor" error instead of a null-parse failure
  • Demo fallback files are empty placeholders: real 4.0 fallbacks weigh ~177 MB and exceed GitHub's file size limit, download your own from the Dashboard before testing SetFallbacks
  • Demo build settings: bundleVersion 4.0.0, iOS bundle id aligned, simulator profile fixed (arm64, Input System), Android locked to OpenGL ES 3 because Vulkan fails to initialize on emulators

Adopt the 4.0 cross-platform contract. A placement now returns an
AdaptyFlow with a list of paywall variations instead of a single
AdaptyPaywall.

- New models: AdaptyFlow, AdaptyFlowPaywall (+ ProductReference),
  AdaptyUIFlowView; AdaptyPaywall and its ViewConfiguration are removed
- API renames: GetFlow / GetFlowForDefaultAudience (locale parameter
  dropped), LogShowFlow, CreateFlowView / PresentFlowView /
  DismissFlowView; OpenWebPaywall and CreateWebPaywallUrl accept
  AdaptyFlowPaywall
- Flow views are single-use and destroyed on dismiss; purchases and
  errors no longer auto-dismiss the view
- Events: IAdaptyFlowsEventsListener replaces
  AdaptyPaywallsEventsListener (flow_view_* ids, did_receive_error,
  analytic events); new IAdaptyUISystemRequestsHandler for permission
  ask/answer and app review round-trips, IAdaptyUIObserverModeResolver
  for Observer-mode purchases and restores
- Listener interfaces follow the C# I-prefix convention
  (IAdaptyEventListener, IAdaptyOnboardingsEventsListener, ...); no
  legacy aliases are kept
- iOS native SDK ships via Swift Package Manager only (pinned 4.0.1):
  declared as remoteSwiftPackage for External Dependency Manager
  1.2.187+; a new editor build validator enforces iOS deployment
  target 15.0+
- Android native SDK and crossplatform bumped to 4.0.0, unity-wrapper
  AAR rebuilt against them
- iOS Kids Mode (App Store Kids Category / COPPA): the ADAPTY_KIDS_MODE
  scripting define compiles in a post-build step that enables the
  KidsMode SPM trait on the AdaptySDK-iOS package (strips IDFA /
  AdSupport / AppTrackingTransparency); the same define forces
  apple_idfa_collection_disabled in the runtime config so the two can
  never disagree. Demo carries an "iOS (Simulator) Kids" build profile
  that sets the define
- Legacy onboarding API deprecated in favor of Flows; pre-4.0 deprecated
  members removed (SetFallbackPaywalls, IDFA collection aliases)
- report_transaction success response decoded as boolean (was
  incorrectly parsed as a profile and always surfaced a decoding error)
- Demo migrated to the Flow API: Paywalls tab renamed to Flows, dead
  locale input removed; the Editor Noop stub now returns a readable
  "not available in the Editor" error instead of a null-parse failure
- Demo activates against the production environment API key: the
  dev-environment key stopped resolving placements (backend returned
  404 Placement Not Found)
- Demo fallback files are minimal parseable placeholders (empty data
  plus the meta header the native parsers require, including
  response_created_at): real 4.0 fallbacks weigh ~177 MB and exceed
  GitHub's file size limit, download your own from the Dashboard before
  testing SetFallbacks
- Demo build settings: bundleVersion 4.0.0, iOS bundle id aligned,
  simulator profile fixed (arm64, Input System), Android locked to
  OpenGL ES 3 because Vulkan fails to initialize on emulators
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants