Skip to content

Latest commit

 

History

13 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

TuyaAPIFlask

Using the TuyaSmart url request to create an API with Flask and Python3 to turn on/off you own switch

Steps

  1. Buy WiFi TECKIN 16A 3300W
  2. Download Tuya Smart APP in your mobile
  3. Pair device with your mobile APP
  4. Change with your credentials
data={
      "userName": "xxxxxx@gmail.com", # change with your email Tuya Smart APP
      "password": "xxxxxxxxxx", # change with your password Tuya Smart APP
      "countryCode": "1",
      "bizType": "tuya",
      "from": "tuya",
}
  1. Get you ID device
    5.1 Edit you device
    5.2 Device information
    5.3 Copy ID Virtual and paste into switchId value
switchId = "xxxxxxxxxxx"

Usage

 pip3 install -r requirements.txt 

To switch on/off

 python3 main.py 

Results

License

MIT

About

Using the TuyaSmart url request to create an API with Flask and Python3 to turn on/off you own switch

Resources

Stars

2 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages