Last Updated on : 2023-10-09 01:57:19
After a WeChat mini program is created, proceed to develop and launch the WeChat mini program on the Tuya IoT Development Platform.
From the list of WeChat mini programs, find and click the newly created WeChat mini program.
Enter the App Secret as instructed. WeChat mini programs are integrated with Tuya IoT capabilities.
Get Tuya’s cloud plug-ins for your WeChat mini programs. The smart pairing plug-in, automation plug-in, generic panel plug-in, and message center plug-in are supported.
Open the WeChat DevTools, go to the Tuya IoT Development Platform, open your WeChat Mini Program SDK project, and then click Run Demo.
Open the WeChat DevTools, change the AppID to that of your WeChat mini program, and then click Import.
After the local project passes the debugging with WeChat DevTools, you can scan the QR code on the Tuya IoT Development Platform to test the mini program on a real app. To upload the trial version of the WeChat mini program, you can manage the current version on the Versions page, and upload the code package. Then, a QR code is automatically generated for you to preview the trial version of the WeChat mini program.
On the Versions page, click Update App and enter the version number to create a version. Click Upload Code Package to upload the package of the local project.
Before the upload, compress the package. Right-click the root directory of the package and compress it into a .zip file.
Upload the compressed package to the newly-created version. According to WeChat’s strict requirements on the format and size of code packages, upload a .zip file of less than 10 MB. A single subpackage or main package cannot exceed 2 MB. Any package of more than 2 MB must be subpackaged. For more information about subpackaging, see Subpackage Loading. The following figure shows the layout of the code package.
After the code package is uploaded, click Submit Code Package to generate a QR code. The administrator can scan the QR code and preview the trial version. To allow other users to preview it, follow the subsequent step and add them to Trial Members.
You can go to Add Trial Member and add trial members who can test the WeChat mini program. The trial members can scan the QR code on the Versions page to test and accept the mini program.
After the development and testing of the WeChat mini program, go to the Versions page, and click Submit for Review to submit the version and code branch to the WeChat platform for review.
After the mini program passes the WeChat review, the Submit for Review button is changed into the Release Version button. After the version is launched, the WeChat mini program will be generally available and the QR code of the official version is generated.
Check whether cloud functions are deployed on the Tuya IoT Development Platform. If cloud functions are deployed, check whether the AppID of the imported code is the same as that displayed on the Tuya IoT Development Platform.
Both processes work the same way. The Tuya IoT Development Platform has been granted access to your WeChat mini program, so you can upload the code, submit the trial version, submit for review, and then launch the mini program on the platform.
Yes, it does. Your WeChat Mini Program SDK project must meet WeChat’s strict requirements on the format of the code package.
uni-appto develop WeChat mini programs with the help of Tuya’s cloud functions?
Yes, you can. But you need to pay attention to compilation and packaging differences. In addition, the code to be uploaded must be the code in the compressed
The size of the code package is limited by WeChat. The total size of all subpackages of a mini program cannot exceed 10 MB. If the upper limit is exceeded, the WeChat mini program might have lags.
WeChat requires that each subpackage or main package be up to 2 MB in size. If a code package exceeds 2 MB, it must be subpackaged. For more information, see Subpackage Loading.
Check whether you have submitted the demo code of the WeChat mini program. If the demo code is not submitted, check whether you have run into any of the situations as described in Common Rejections by WeChat.
Is this page helpful?YesFeedback
Is this page helpful?YesFeedback