6.9 KiB
title, description, ha_category, ha_iot_class, ha_release, ha_config_flow, ha_domain, ha_codeowners, ha_platforms
title | description | ha_category | ha_iot_class | ha_release | ha_config_flow | ha_domain | ha_codeowners | ha_platforms | |||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Tuya | Instructions on how to setup the Tuya hub within Home Assistant. |
|
Cloud Push | 0.74 | true | tuya |
|
|
The Tuya integration allows integrating all Powered by Tuya devices you have added to the Tuya Smart and Tuya Smart Life apps. This integration is officially maintained by Tuya.
Supported platforms
- Climate: air conditioner, heater, thermostat.
- Fan: fan, air purifier, humidifier, dehumidifier.
- Light: light, light strip, ambient light, light string, humidifier's light, ceiling light.
- Scene: smart scene.
- Switch: switch, socket, power strip, smart kettle, breaker, pet water feeder, air purifier, diffuser.
Configuration of the Tuya IoT Platform
Prerequisites
- Your devices need to first be added in the Tuya Smart or Smart Life app.
- You will also need to create an account in the Tuya IoT Platform. This is a separate account to the one you made for the app. You cannot log in with your app's credentials.
Create a project
- Log in to the Tuya IoT Platform.
- In the left navigation bar, click
Cloud
>Development
. If this is your first time setting up an account you will be asked to subscribe to a Cloud Development Plan. You can select and "purchase" the Trial Edition (it's free). - On the page that appears, click
Create Cloud Project
. - In the
Create Project
dialog box, configureProject Name
,Description
,Industry
, andData Center
. For theDevelopment Method
field, selectSmart Home
from the dropdown list. For theData Center
field, select the zone you are located in. - Click
Create
to continue with project configuration. - In Configuration Wizard, make sure you add
Device Status Notification
API. The list of API should look like this: - Click
Authorize
.
Link devices by app account
- Navigate to the
Devices
tab. - Click
Link Tuya App Account
>Add App Account
. - Scan the QR code that appears using the
Tuya Smart
app orSmart Life
app. - Click
Confirm
in the app. - To confirm that everything worked, navigate to the
All Devices
tab. Here you should be able to find the devices from the app. - If zero devices are imported, try changing the DataCenter.
Get authorization key
Click the created project to enter the Project Overview
page and get the Authorization Key
. You will need these for setting up the integration. in the next step.
{% include integrations/config_flow.md %}
{% configuration_basic %} Country: description: Choose the country you picked when signing up.
"Tuya IoT Access ID": description: Go to your cloud project on Tuya IoT Platform. Find the Access ID under Authorization Key on the Project Overview tab.
"Tuya IoT Access Secret": description: Go to your cloud project on Tuya IoT Platform. Find the Access Secret under Authorization Key on the Project Overview tab.
Account: description: Tuya Smart or Smart Life app account.
Password: description: The password of your app account.
{% endconfiguration_basic %}
Error codes and troubleshooting
{% configuration_basic %}
"1004: sign invalid": description: Incorrect Access ID or Access Secret. Please refer to Tuya credential table.
"1106: permission deny": description: >- - App account not linked with cloud project: On the Tuya IoT Platform, you have linked devices by using Tuya Smart or Smart Life app in your cloud project. For more information, see Link devices by app account.
- Incorrect username or password: Enter the correct account and password of the Tuya Smart or Smart Life app in the **Account** and **Password** fields. Note that the app account depends on which app (Tuya Smart or Smart Life) you used to link devices on the [Tuya IoT Platform](https://iot.tuya.com/cloud/).
- Incorrect availability zone: See [Availability Zone](https://github.com/tuya/tuya-home-assistant/wiki/Tuya-IoT-Platform-Configuration-Guide-Using-Smart-Home-PaaS#region--available-zone-correspondence) and select the correct availability zone.
"1100: param is empty": description: Empty parameter of username or app. Fill the parameters refer to Tuya credential table.
"2406: skill id invalid": description: Make sure that your cloud project on the Tuya IoT Platform should be created after May 25, 2021. Otherwise, you need to create a new project or migrate data to a new project. For more information, see Operation on the Tuya IoT Platform.
"28841105: No permissions. This project is not authorized to call this API": description: > Some APIs are not authorized, please Subscribe then Authorize. The following APIs must be subscribed for this tutorial:
- Authorization
- Smart Home Devices Management
- Smart Home Family Management
- Smart Home Scene Linkage
- Smart Home Data Service
- Device status notification
{% endconfiguration_basic %}