Using Unlock With Tap
This feature enables your app to scan for nearby door readers and unlock authorized doors.
Unlock With Tap in mobile apps functions similarly to using a traditional proximity card. The app launches an unlock scanning process. When the user holds their phone close to the lock they wish to open, the phone communicates wirelessly with the lock and transmits an access credentials. Once the lock verifies these credentials and confirms access is granted, it unlocks.
In your app, you use seam.phone.native.unlockWithTap.launch to initiate this unlock scanning process. Note that unlockWithTap automatically starts scanning whenever it is possible to scan and stops scanning whenever it is not possible to scan. That is, when an issue obstructs the phone from scanning, the can_scan capability changes to false, and Seam adds the resulting error to the error list. Further, the error explains to the user how to fix the causing issue.

Using the "Unlock With Tap" process involves the following steps:
1. Retrieve Mobile Credentials
Before initiating the "Unlock With Tap" process, the user's phone must have the necessary mobile credentials loaded onto it. To verify that the credentials are loaded, these credentials can be retrieved either explicitly or through an event handler.
2. Check the System Requirements
Before you launch the "Unlock With Tapping" process, verify that all the required permissions are enabled.
Check the error listβfor example, in an event handlerβto identify any current obstructions.
3. Launch the "Unlock With Tap" Process
Once the required permissions are enabled, the app can launch the "Unlock With Tap" Process.
4. Handle Unlock Status Updates
Use an event handler to handle unlock-related status updates. Use these events to initiate changes to the user interface.
5. Stop the "Unlock With Tap" Process
unlockWithTap continues attempting to scan, until you explicitly stop this function. For example, you may want to disable scanning if the user changes the focus on their phone to a different app. Or after an unlock has been completed successfully.
Last updated
Was this helpful?

