Preparation

Last Updated on : 2022-02-17 07:15:51download

Before you get started with a specific development solution, on the Tuya IoT Development Platform, you must register a developer account, create a product, define data points (DPs), and continue with subsequent steps. For more information, see Quick Start.

Create an SDK-based app

  1. Log in to the Tuya IoT Development Platform. In the left-side navigation pane, choose App > App SDK > SDK Development and click Create App.

    Preparation

  2. In the dialog box that appears, select the Smart Protect App SDK category.

    Preparation

  3. Enter the required app information and click OK.

    • App Name: Enter your app name.
    • Bundle ID for iOS: Enter your iOS app bundle ID. The recommended format is com.xxxxx.xxxxx.
    • Package Name for Android: Enter your Android app package name. It is not necessary to be consistent with the iOS app bundle ID.
    • Channel ID: optional. If you do not set the value, the system automatically generates a channel ID according to the package name.
  4. Select SDK solutions as per your actual requirements, and integrate the SDK according to Podfile and Gradle. The Podfile and Gradle file will be created for the iOS SDK and Android SDK respectively.

  5. Get the key.
    Click the Get Key tab to get the values of AppKey and AppSecret and the security image of the App SDK.

    Preparation

    1. After the app is created on the Tuya IoT Development Platform, you must provide the package name of the created app to Tuya’s account manager who will take care of the follow-up steps. The SDK can be normally used only after your app project is created in the cloud.
    2. For the app for Android, add one or more SHA256 hash values. For more information, see How to Get SHA1 and SHA256 Keys.

    This allows you to call the SDK as expected.