# \[APP\]\[Pro\] TuyAPI / Neo Coolcam wall plug WIFI app

**URL:** <https://community.homey.app/t/app-pro-tuyapi-neo-coolcam-wall-plug-wifi-app/15811>\
**Category:** Apps\
**Tags:** app, wifi, homey-pro\
**Created:** [July 20, 2019, 1:22pm UTC](https://community.homey.app/t/app-pro-tuyapi-neo-coolcam-wall-plug-wifi-app/15811 "2019-07-20T13:22:50Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![Rens\_Brandwijk](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/rens_brandwijk/32/12640_2.png) [@Rens\_Brandwijk](https://community.homey.app/u/Rens_Brandwijk)\
**Post date:** [July 20, 2019, 1:22pm UTC](https://community.homey.app/t/app-pro-tuyapi-neo-coolcam-wall-plug-wifi-app/15811/1 "2019-07-20T13:22:50Z")

</div>

Since there was no app for the WIFI NEO COOLCAM plugs ive put one together for myself based on the TUYAPI by codetheweb. Because i saw some app requests for these plugs i’ve supmitted it to the appstore aswell. I Realize that this is not something for everyone since getting the ID and Keys for the devices is takes some doing and the API is community work to but if you don’t like IFTTT like me this might be a option for you.

 ![afbeelding](https://us1.discourse-cdn.com/flex025/uploads/athom/original/2X/3/30b1029817ec0d3c3ba9a82edfc7c4e49852ad9b.png)

**Git:** [GitHub - rebtor/nl.rebtor.tuya: TuyAPI implementation for homey](https://github.com/rebtor/nl.rebtor.tuya/)  
**Store** : [Tuya | Homey](https://apps.athom.com/app/nl.rebtor.tuya) (awaiting approvel of athom)

# Tuya devices homey app

A implementation of [TuyAPI](https://github.com/codetheweb/tuyapi/) for use with homey.

## CHANGELOG

- 1.0.0
  - Initial version with support for NEO Coolcam smartplug 2000W

## Basic Usage

See the [setup instructions](https://github.com/codetheweb/tuyapi/blob/master/docs/SETUP.md) for how to find the needed parameters.

Once these parameters (ID and Key) are known you can use this information to create a device in homey to communicate with the Tuya cloud network without the use of IFTT.

Warning: This app is not plug and play finding the ID and Key needed tot communicate with the tuya cloud takes some doing.

## 📝 Notes

- Only one TCP connection can be in use with a device at once. If using this, do not have the app on your phone open.
- Some devices ship with older firmware that may not work with `tuyapi` . If you’re experiencing issues, please try updating the device’s firmware in the official app.
- I think other smartplugs from tuya may work to with this app. The 3600 watt version from NEO Coolcam is on its way from China.

## DEVICES

- NEO Coolcam 2000 watt smartplug

---

<div class="post-metadata">

**Author:** ![Mohta-yemoh](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/mohta-yemoh/32/13973_2.png) [@Mohta-yemoh](https://community.homey.app/u/Mohta-yemoh)\
**Post date:** [July 20, 2019, 3:19pm UTC](https://community.homey.app/t/app-pro-tuyapi-neo-coolcam-wall-plug-wifi-app/15811/2 "2019-07-20T15:19:19Z")

</div>

Hey Rens.

Great work, I think a lot of people like this.

I am wondering, are you planning to add more Neo Coolcam wifi devices? (Like the motion/door sensor).

Bought the wifi devices by mistake. 😉

---

<div class="post-metadata">

**Author:** ![Rens\_Brandwijk](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/rens_brandwijk/32/12640_2.png) [@Rens\_Brandwijk](https://community.homey.app/u/Rens_Brandwijk)\
**Post date:** [July 20, 2019, 4:54pm UTC](https://community.homey.app/t/app-pro-tuyapi-neo-coolcam-wall-plug-wifi-app/15811/3 "2019-07-20T16:54:55Z")

</div>

What kind do you have?

I’m planning on adding the 3600 watt plug when i get that from china.

I use zwave an zigbee sensors myself and i don’t realy like wifi devices myself. These plugs are just so cheap that it makes it worth while. But why buy a 12 dollar wifi sensor if a 9 dollar zigbee does the same job…

---

<div class="post-metadata">

**Author:** ![Mohta-yemoh](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/mohta-yemoh/32/13973_2.png) [@Mohta-yemoh](https://community.homey.app/u/Mohta-yemoh)\
**Post date:** [July 20, 2019, 9:39pm UTC](https://community.homey.app/t/app-pro-tuyapi-neo-coolcam-wall-plug-wifi-app/15811/4 "2019-07-20T21:39:06Z")

</div>

To be honest I prefer zigbee/z-wave as well.  
But I bought them by accident, didnt want to throw them in the bin so have them working now with IFTTT and it got a huge delay.

I am planning to replace them with wifi devices, but then I saw this post and thought ‘lets ask’. 😉

I am talking about the wifi neo coolcam doorsensor and motion sensors.

---

<div class="post-metadata">

**Author:** ![Rens\_Brandwijk](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/rens_brandwijk/32/12640_2.png) [@Rens\_Brandwijk](https://community.homey.app/u/Rens_Brandwijk)\
**Post date:** [July 21, 2019, 6:45am UTC](https://community.homey.app/t/app-pro-tuyapi-neo-coolcam-wall-plug-wifi-app/15811/5 "2019-07-21T06:45:52Z")

</div>

What you can do is install this app and add them as powerplugs. Big chance that if you trigger the sensor the plug in homey turns on and off. If that is the case i will add an sensor device aswell. I might even order a door sensor from china but that takes a couple of weeks before they are here.

---

<div class="post-metadata">

**Author:** ![Rens\_Brandwijk](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/rens_brandwijk/32/12640_2.png) [@Rens\_Brandwijk](https://community.homey.app/u/Rens_Brandwijk)\
**Post date:** [August 7, 2019, 5:15pm UTC](https://community.homey.app/t/app-pro-tuyapi-neo-coolcam-wall-plug-wifi-app/15811/6 "2019-08-07T17:15:14Z")

</div>

I have checked it. The battery powered devices cant be controlled by the tuyapi libery. So that won’t work

---

<div class="post-metadata">

**Author:** ![harryd](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/harryd/32/13169_2.png) [@harryd](https://community.homey.app/u/harryd)\
**Post date:** [August 10, 2019, 3:51pm UTC](https://community.homey.app/t/app-pro-tuyapi-neo-coolcam-wall-plug-wifi-app/15811/7 "2019-08-10T15:51:56Z")

</div>

Hi Rens!

I have followed the instructions to the point, but in the console the text “waiting for request…” remains.  
When I refresh the app Smart Life app its says “network is unavailable”.

![Capture](https://us1.discourse-cdn.com/flex025/uploads/athom/original/2X/e/e7a6192d296912ae4a62bde775099d6d63dff098.png)

Any ideas.

I should add that this is the first time I am doing anything like this. But I have managed to do everything in the list you have provided here: [https://github.com/codetheweb/tuyapi/blob/master/docs/SETUP.md](https://github.com/codetheweb/tuyapi/blob/master/docs/SETUP.md)

BR  
Harryd

---

<div class="post-metadata">

**Author:** ![Rens\_Brandwijk](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/rens_brandwijk/32/12640_2.png) [@Rens\_Brandwijk](https://community.homey.app/u/Rens_Brandwijk)\
**Post date:** [August 10, 2019, 8:52pm UTC](https://community.homey.app/t/app-pro-tuyapi-neo-coolcam-wall-plug-wifi-app/15811/8 "2019-08-10T20:52:24Z")

</div>

Hi Harryd,

I know this list is a bit messy. Wish they would just put the key in the smartlife app that would be so much easyer.

I’m not to sure how it works exacly on iphone because i used my android phone. But be sure to install the cetificate ( by scanning the QR code . And don’t forget to remove it when your done) and setup the proxy to the ip and port.

Also make sure your firewall on your pc is not blocking the requests from your phone. Mine did that (i use ESET and it blocks almost any port except the ports for mail and web).

Good luck.

---

<div class="post-metadata">

**Author:** ![harryd](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/harryd/32/13169_2.png) [@harryd](https://community.homey.app/u/harryd)\
**Post date:** [August 11, 2019, 6:55am UTC](https://community.homey.app/t/app-pro-tuyapi-neo-coolcam-wall-plug-wifi-app/15811/9 "2019-08-11T06:55:28Z")

</div>

Hi!

Might add that I am running this on a Windows 10 computer. I also came to think of the firewall. But even with the FW completely turned off I still get the same results.

On the iPhone/iPad the certificate is trusted and the proxy settings have been added.

Really strange. Can’t think of something else that would block the connection.

//Harryd

---

<div class="post-metadata">

**Author:** ![harryd](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/harryd/32/13169_2.png) [@harryd](https://community.homey.app/u/harryd)\
**Post date:** [August 11, 2019, 9:01am UTC](https://community.homey.app/t/app-pro-tuyapi-neo-coolcam-wall-plug-wifi-app/15811/10 "2019-08-11T09:01:32Z")

</div>

Hi Again!

Once more question, this key which I am looking for, how does it look like? How many digits, etc?

BR  
Harryd

---

<div class="post-metadata">

**Author:** ![Rens\_Brandwijk](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/rens_brandwijk/32/12640_2.png) [@Rens\_Brandwijk](https://community.homey.app/u/Rens_Brandwijk)\
**Post date:** [August 11, 2019, 11:26am UTC](https://community.homey.app/t/app-pro-tuyapi-neo-coolcam-wall-plug-wifi-app/15811/11 "2019-08-11T11:26:51Z")

</div>

It comes out something like this:

{ id: ‘24212176ecfabcaXXXXf’, key: 'XXXX5e60d767XXXX },  
{ id: ‘XXXX488bcddc29573eb’, key: ‘XXXXb1eXXXXXXXX’ }

Digits and numbers. Key is 16 in length.

---

<div class="post-metadata">

**Author:** ![harryd](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/harryd/32/13169_2.png) [@harryd](https://community.homey.app/u/harryd)\
**Post date:** [August 11, 2019, 12:10pm UTC](https://community.homey.app/t/app-pro-tuyapi-neo-coolcam-wall-plug-wifi-app/15811/12 "2019-08-11T12:10:34Z")

</div>

Hi!

I initially used Windows 10 and iPhone/iPad. And it didnt work.  
Then I remembered that I had an old Android tablet. After one hour of banging my head into the table because of the slowness of the old tablet I finaly managed to install everything…and…it worked! 🙂

![Capture](https://us1.discourse-cdn.com/flex025/uploads/athom/original/2X/2/2ee9da0f818eed2b9f4184e5f45a57fa35a6dbf1.png)

so, it looks like it only works if you use an Android device… Good to know for other people 🙂

//Harryd

---

<div class="post-metadata">

**Author:** ![harryd](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/harryd/32/13169_2.png) [@harryd](https://community.homey.app/u/harryd)\
**Post date:** [August 11, 2019, 2:20pm UTC](https://community.homey.app/t/app-pro-tuyapi-neo-coolcam-wall-plug-wifi-app/15811/13 "2019-08-11T14:20:37Z")

</div>

Hi

For everyone not doing stuff like this on regular basis…This is how I did it.

This was done on Windows 10 and an Android tablet. With my iOS devices it didn’t work.  
Windows defender firewall was activated but I opened port 8001 (not sure if it is necessary).  
You can find how to open a port here: [https://www.tomshardware.com/news/how-to-open-firewall-ports-in-windows-10,36451.html](https://www.tomshardware.com/news/how-to-open-firewall-ports-in-windows-10,36451.html))

1. Downloaded Node.js ([https://nodejs.org/dist/v10.16.2/node-v10.16.2-x64.msi](https://nodejs.org/dist/v10.16.2/node-v10.16.2-x64.msi))
2. Installed it without any custom settings.
3. Once installed, I opened up “Node.js command prompt” from the windows start menu and followed Rens instructions.  
3.1 Typed “ **npm i @tuyapi/cli -g** ” command prompt and waited for it to complete.  
3.2 Typed “ **npm i anyproxy -g** ” in the command prompt and waited for it to complete.  
3.3 Typed “ **anyproxy-ca** ” in the command prompt , answered “ **Y** ” on the question.  
3.4 Typed “ **tuya-cli list-app** ” in the command prompt. This generated a QR code and started the proxy server.
4. Picked up an **Android Device** _(Didn’t work with my iOS devices)_ with the Smart Life app on it. and scanned the QR code.  
4.1 Installed the certificate.  
4.2 Updated the WiFi settings on the Android device with the proxy settings provided in the command prompt.
5. Opened the Smart Life app and the command prompt returned below:  
 ![neo6](https://us1.discourse-cdn.com/flex025/uploads/athom/original/2X/2/264641c0e03d17342c526a22d9a782728fc3987c.png)

(I only had once device, but I imagine if more devices are in the Smart Life app there will be more rows with ID’s and keys.)

Hope it helps!

---

<div class="post-metadata">

**Author:** ![Colin\_Foster](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/colin_foster/32/12929_2.png) [@Colin\_Foster](https://community.homey.app/u/Colin_Foster)\
**Post date:** [August 12, 2019, 12:49pm UTC](https://community.homey.app/t/app-pro-tuyapi-neo-coolcam-wall-plug-wifi-app/15811/14 "2019-08-12T12:49:20Z")

</div>

Hey Rens ive managed to add a colour light globe with your app. Little experience in doing this but with the help of harryd as i was on android to managed to add the device. With the device i can change the colour in the Tuya app but when i added the device i selected the plug and inputted the id/key. Its added to only as a plug obviously, this only allows the on/off function (which works) but no colour change or dim function. Is this not possible or did i add it wrong? thanks and great work.

---

<div class="post-metadata">

**Author:** ![kuiperonline](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/kuiperonline/32/14339_2.png) [@kuiperonline](https://community.homey.app/u/kuiperonline)\
**Post date:** [August 14, 2019, 7:33am UTC](https://community.homey.app/t/app-pro-tuyapi-neo-coolcam-wall-plug-wifi-app/15811/15 "2019-08-14T07:33:38Z")

</div>

> [@harryd](#):
>
> npm i @tuyapi/cli -g

I never did this cmd stuff before. So appoligize for that. I got the whole thing working. My laptop shows the qr code. I installed the certificate on my iphone. But what should i do next? What do you mean by "adjusting my wifi settings on my smartphone?

When i try to visit the ip adres with port number i get this message on my phone and on my laptop

# # AnyProxy Inner Error

### Oops! Error happend when AnyProxy handle the request.

This is an error occurred inside AnyProxy, not from your target website.

Error:

Error: connect ECONNREFUSED 127.0.0.1:80

---

<div class="post-metadata">

**Author:** ![harryd](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/harryd/32/13169_2.png) [@harryd](https://community.homey.app/u/harryd)\
**Post date:** [August 14, 2019, 8:14am UTC](https://community.homey.app/t/app-pro-tuyapi-neo-coolcam-wall-plug-wifi-app/15811/16 "2019-08-14T08:14:31Z")

</div>

Hi!

You should use the IP address and the port number displayed below the QR code and enter them as proxy on your phone.

Here is a guide if you don’t know how to do that.

> **[How to configure proxy on Android device](https://limeproxies.zendesk.com/hc/en-us/articles/115004526474-How-to-configure-proxy-on-Android-device)**
>
>  
> Android devices allow configuring proxy settings for each Wi-Fi network. This might be required if you need to access the Internet on a specific network (like  a business or school network, for e...

//Harryd

---

<div class="post-metadata">

**Author:** ![kuiperonline](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/kuiperonline/32/14339_2.png) [@kuiperonline](https://community.homey.app/u/kuiperonline)\
**Post date:** [August 14, 2019, 1:46pm UTC](https://community.homey.app/t/app-pro-tuyapi-neo-coolcam-wall-plug-wifi-app/15811/17 "2019-08-14T13:46:16Z")

</div>

ok Harry. Thanks for helping. I changed the proxy on my iphone. What is the last step i have to do?  
when i open the Tuya app it says: network faillure

---

<div class="post-metadata">

**Author:** ![harryd](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/harryd/32/13169_2.png) [@harryd](https://community.homey.app/u/harryd)\
**Post date:** [August 15, 2019, 5:50am UTC](https://community.homey.app/t/app-pro-tuyapi-neo-coolcam-wall-plug-wifi-app/15811/18 "2019-08-15T05:50:19Z")

</div>

Make sure you have opened up port 8001 in your firewall, Norton Internet Security more or less blocks everything. If you don’t have any 3rd party security software you still have Windows Defender which might block the connection.

//Harryd

---

<div class="post-metadata">

**Author:** ![Maurits](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/maurits/32/8884_2.png) [@Maurits](https://community.homey.app/u/Maurits)\
**Post date:** [August 16, 2019, 7:27am UTC](https://community.homey.app/t/app-pro-tuyapi-neo-coolcam-wall-plug-wifi-app/15811/19 "2019-08-16T07:27:33Z")

</div>

Have you tried connecting the Action products already?

> **[Zoek binnen Action.com](https://www.action.com/nl-nl/search/?q=connect)**
>
> Alles bij Action kun je vinden met onze zoekmachine. Vind het product dat je zoekt, of meer informatie over Action en onze winkels.

Packaging of a Action socket  
 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/2X/f/f2320a17e312fe3ac75d0dc68aa7cf4eb2c2e476.jpeg)

---

<div class="post-metadata">

**Author:** ![Rocodamelshekima](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/rocodamelshekima/32/8209_2.png) [@Rocodamelshekima](https://community.homey.app/u/Rocodamelshekima)\
**Post date:** [August 16, 2019, 9:27am UTC](https://community.homey.app/t/app-pro-tuyapi-neo-coolcam-wall-plug-wifi-app/15811/20 "2019-08-16T09:27:51Z")

</div>

Tried a plug but could not add it to the smartphone app. Gonna try again later today and keep u posted.

[Next page](https://community.homey.app/t/app-pro-tuyapi-neo-coolcam-wall-plug-wifi-app/15811.md?page=2)
