How Samsung Health Sensor SDK verifies your app

In order to utilize Samsung Health Sensor SDK in your publicly distributed app, a prior registration in Samsung’s systems is required. This process involves submitting a request for becoming a Samsung’s partner, being granted an approval and having your app registered.

Otherwise, if your app tries to call Samsung Health Sensor SDK without a registered signature, the SDK will block the connection for security reasons, resulting in SDK Policy Error.

To have your app registered, it is necessary to provide a combination of your app's package name and signature (SHA-256). However, if you are still during development process, for your convenience you can test Samsung Health Sensor SDK without the need for providing such information yet.

Depending on your current scenario, choose one of the suggested ways to let your app use Samsung Health Sensor SDK

Development & testing

During development stage, you could build and test the app locally without a need to register your signature yet. Instead, you could use developer mode. Enabling it lets to temporarily bypass the signature check for your application.

App distribution

When the development stage is finished and you are ready to distribute your app, please proceed with registering your app in Samsung’s systems. To do this, create a partnership request and provide your app's package name and signature (SHA-256).

When you distribute your app via Galaxy Store or Google Play Store, pay attention to providing the correct SHA-256 in the partnership request.

How can I verify my app's signature?

If you are unsure which signature your app is actually using, try to use these methods.

Check via command line

This method verifies the app installed on your device:

  1. Check the path of the app on the device.
adb shell pm path com.example.yourappname
  1. Use the path to download the APK from the mobile device to your computer.
adb pull /path/to/the/apk /path/to/a/local/folder
  1. Verify the signature of a specific APK file.
apksigner verify --print-certs your-app-release.apk

Check Google Play Console

In common scenario, Google Play Console requires you to initially sign your app with SHA-256 (e.g., via Android Studio’s Generate Signed Bundle/APK option), which becomes an upload key. Then, this key is used for verifying your identity and your application gets signed by Google with app signing key. This lets to distribute your app securely.

For apps distributed via Google Play Store follow these steps:

  1. Log in to Google Play Console.
  2. Go to Release > Setup > App integrity.
  3. Look for the "App signing key certificate" section.
  4. Copy the SHA-256 certificate fingerprint.