Get SDK Version

🧾 Ditto ID SDK API Documentation: getSdkVersion

šŸ“˜ Overview

The getSdkVersion API returns the current version of the Ditto ID SDK integrated into the mobile application. This is essential for debugging, support, and ensuring version compatibility.

šŸŽÆ Purpose

Use this API to:

  • Identify the specific SDK version in use.
  • Validate environment setup across dev/test/prod environments.
  • Include in support logs or bug reports for faster issue resolution.

šŸ” API Flow

  1. Initialize the SDK.
  2. Call getSdkVersion().
  3. Use the returned string in logs or diagnostic output.

🧾 Response

Returns the SDK version as a String value.

šŸ”§ Example Response:

25.04.01

šŸ’» Code Snippets

React Native
RdnaClient.getSdkVersion((response) => {
  const version = response.response;
});
Flutter
final version = await rdnaClient.getSdkVersion();
Cordova
com.uniken.rdnaplugin.RdnaClient.getSdkVersion(successCallback, errorCallback);
Native iOS
NSString* sdkVersion = [rdnaClient getSdkVersion];
Native Android
String sdkVersion = rdnaClient.getSdkVersion();

āš ļø Error Codes

CodeErrorAction
0SuccessUse the returned value
4RDNA_ERR_INVALID_ARGSLikely due to improper init
88RDNA_ERR_RDNA_ALREADY_INITIALIZEDTypically ignorable

🧠 Developer Notes

  • Version should be recorded during crash reports or SDK failure debugging.
  • It is recommended to expose this value in developer settings/debug builds.