Skip to main content

Migrating from 0.x to 1.0

Version 1.0 is a major rewrite of the AppDNA SDK with breaking changes across all platforms. This guide walks you through every change you need to make to upgrade from 0.x.

Overview of Changes


1. Initialization

The initialize() method has been replaced with configure(), which now requires an explicit API key parameter and accepts an options object.
The projectId is no longer needed. The API key encodes both the organization and app identifiers.

2. Module Namespaces

In 0.x, all methods lived directly on the AppDNA singleton. In 1.0, methods are organized into module namespaces:
Onboarding step tracking is fully automatic in 1.0 — there is no trackStep method. The SDK emits step events (onboarding_flow_started, step_viewed, step_completed, …) for you.

3. Delegates

In 0.x, there was a single AppDNADelegate protocol/interface that handled callbacks for all modules. In 1.0, each module has its own delegate:

4. Config Bundles (New in 1.0)

Version 1.0 introduces config bundle embedding, a key part of the offline-first architecture. You can now embed a JSON config file in your app binary during CI/CD so the SDK has a complete configuration available on first launch without any network request. This is a new feature with no 0.x equivalent. See the Config Bundles in CI/CD guide for setup instructions.

5. API Key Format

API keys have changed format to clearly distinguish environments:
Old appdna_ prefixed keys are not compatible with 1.0 SDKs. Generate new API keys in Console > Settings > SDK > API Keys.

6. Identity

The setUserId() method has been replaced with identify(), which now accepts user traits for segmentation and targeting:
Traits are merged with previously set traits on each call. You only need to pass traits that have changed, not the full set every time.

7. Events

The logEvent() method has been replaced with track(), which accepts structured properties:
In 1.0, event properties support typed values (numbers, booleans, strings, arrays) rather than being limited to string-only metadata. This enables richer analytics and segmentation in the dashboard.

Platform-Specific Migration Notes

iOS

  • Minimum deployment target raised from iOS 13 to iOS 16.
  • Swift version requirement is now Swift 5.9+.
  • SPM package name changed from AppDNA to AppDNASDK. Update your import statements: import AppDNASDK.
  • Concurrency: Several async methods now use Swift concurrency (async/await) instead of completion handlers.

Android

  • Minimum SDK raised from API 21 to API 24 (Android 7.0).
  • Kotlin version requirement is now 1.9+.
  • Artifact coordinates changed from ai.appdna:core to ai.appdna:sdk-android.
  • Coroutines: Suspend functions are now used instead of callback-based APIs.

Flutter

  • Dart version requirement is now Dart 3.0+.
  • Flutter version requirement is now Flutter 3.10+.
  • Package name changed from appdna to appdna_sdk. Update your pubspec.yaml and import statements.

React Native

  • React Native version requirement is now >=0.76.9 (New Architecture required).
  • Package name changed from react-native-appdna to @appdna-ai/react-native-sdk. Update your package.json and import statements.
  • New Architecture: Full support for the React Native New Architecture (TurboModules/Fabric).

Deprecation Timeline

We strongly recommend migrating to 1.0 as soon as possible. After the 6-month deprecation window, 0.x SDKs will no longer receive security patches and may stop functioning if server-side API changes are made.