Upgrade Guide

Last Updated on : 2023-04-24 02:31:36download

Tuya upgrades Smart Life App SDK and makes the latest version generally available. Based on the optimized business architecture, you can benefit from the neutral software development service and take your unique and proprietary application business to the next level. This topic describes how to upgrade your SDK from a legacy version to v5.x.x by using the automatic upgrade script.


  • If this is the first time you integrate with Smart Life App SDK, the SDK version is v5.x.x. In this case, you can ignore the steps in this topic.

  • If you have already integrated Smart Life App SDK into your app, the following legacy versions can be upgraded to v5.x.x:

    • Smart Life App SDK v3.x.x and v4.x.x
    • UI BizBundle SDK v3.x.x and v4.x.x


  1. Copy and paste the mapping table thingMapping.json and script thingMapping.gradle to the app module directory.

  2. Choose app > build.gradle and reference the script thingMapping.gradle.

    apply plugin: 'com.android.application'
    // References the script plug-in.
    apply from : "thingMapping.gradle"
  3. Open the file thingMapping.gradle, find replaceThing, and then click the green triangle to start automatic modifications.

    Upgrade Guide
  4. Go to Tuya IoT Development Platform > App SDK > SDK Development > Details page of your SDK-based app > Get SDK, and get the latest key information, including AppKey and AppSecret.

    Upgrade Guide
  5. Replace the key information in your project with the new one. For more information, see Configure AppKey, AppSecret, and certificate signature.

Things to note

  • If you have called non-open SDK methods by using reflection, you need to manually finish the required modifications.
  • If you have called non-API entity classes or methods, you also need to manually finish the required modifications. Alternatively, you can put the name of this type of class or method in the mapping table thingMapping.json and rerun the script to implement automatic modifications.