Smart Lock SDK

Last Updated on : 2023-06-13 07:50:42download

Smart Lock SDK encapsulates the APIs to communicate with both smart locks and the cloud and accelerates lock app development.

Functional description

The SDK supports the following features:

  • Unlocking with passwords: unlock doors over Bluetooth connections, fingerprints, or cards, get dynamic passwords, and manage temporary passwords
  • Lock usage records: unlocking records, doorbell records, and alerts
  • Lock user system: manage lock users and associated passwords

Before you start

The Smart Lock SDK serves your development as an extension of Smart Life App SDK. For more information, see Preparation.

Fast integration

Use CocoaPods for fast integration

  1. Add the following code block to the Podfile:

    source 'https://github.com/tuya/tuya-industry-pod-specs'
    
    target 'your_target_name' do
    	pod "TuyaSmartLockKit", "2.0.3-cube.1"
    end
    
  2. In the root directory of your project, run pod update to integrate with a third-party library. For more information about CocoaPods, see CocoaPods Guides.

Import header files

To import header files, add the files where they are required depending on your project type.

  • Example for Objective-C:

    #import <TuyaSmartLockKit/TuyaSmartLockKit.h>
    
  • Example for Swift:

    import TuyaSmartLockKit