Initializing the Seam Mobile SDK
1. Install the Seam SDK
The Seam SDK is available for download on request, and is fully documented.
To install the Seam Android SDK:
Copy the Seam Android SDK
.aarfile (for example,seam-phone-sdk-android.aar) into thelibsdirectory for your project.Add the Android Archive (AAR) name (for example,
seam-phone-sdk-android) to thedependenciesblock of theapp/build.gradlefile for your app.There may be additional dependencies required for your specific access control system. For details, see the appropriate system integration guide.
plugins {
id("com.android.application")
}
android { ... }
dependencies {
// ...
// Add the Seam Android SDK.
implementation(project(":seam-phone-sdk-android"))
}To install the Seam iOS SDK, add the SeamSdk.podspec to the target block of your Podfile.
use_frameworks!
platform :ios, '...'
target 'YourApp' do
// ...
// Local pod install with file path to SeamSdk.podspec
pod 'SeamSdk', :path => './SeamSdk.podspec'
end2. Implement any Manufacturer- and Mobile OS-Specific Requirements
Note the following manufacturer- and OS-specific requirements:
Manufacturer-Specific Requirements
See the device or system integration guide for the access control system or device for which you are planning to develop. Further, you may need to register for developer access with the ACS that you have chosen to use.
iOS Requirement
If you are developing an iOS app, add requestAutomaticPassPresentationSuppression() to your app to prevent the user's phone from displaying Apple Wallet while scanning for Bluetooth low energy (BLE) or similar locks. This method suppresses Apple Wallet while your mobile app is in the foreground.
3. Configure a User Identity for your App User and Generate a Client Session Token
A user identity enables the application to request a user's mobile access permissions and use the app to unlock doors.
First, use the Seam API to create a user identity that will correspond to the App User Account using your internal user ID or other identifying information.
Then, using the user identity, create a client session and capture the resulting client session token. This token will be used to authenticate the user on your application.
4. Configure the User Identity for an Access Platform or Lock Brand
To enable a user identity to utilize mobile credentials from different platforms or unlock various lock brands through our SDK, you may need to launch an enrollment automation for each system or brand you wish to include. Please refer to system integration guides for more details on how to launch an enrollment automation for a particular system.
To launch an enrollment automation, include the user_identity_id, and include the system-specific settings, such as the credential_manager_acs_system_id.
5. Initialize the Mobile SDK with the Client Session Token
Use the client session token generated earlier to initialize the Seam Mobile SDK. This initializes the Mobile SDK for the app user, and retrieves the relevant provider-specific settings. This also launches a background process that will continually poll for any updates to the access permissions.
Initialization and Handling Configuration Errors
The initialization process may fail if the Seam workspace or provider-specific settings are not configured properly. If the initialization process encounters any irrecoverable errors, this block will catch these exceptions, specifically those identified as SeamError. These errors point to development errors, and should be addressed by making sure that your Workspace and User Identity is configured properly.
Handling Provider Initialization Errors from the Background Process
Any failures during the background process will produce errors. These errors can be accessed from the error list, and events will also be emitted. To handle these operational errors, you may log the error in logs or displaying a message to the user.
Last updated
Was this helpful?

