fjhorrillo / homebridge-airzone-cloud

Homebridge Airzone Cloud
Apache License 2.0
21 stars 3 forks source link

Confirmation on DKN Cloud NA support? #15

Open PhilM-IT opened 2 years ago

PhilM-IT commented 2 years ago

Describe Your Problem: I use the "DKN Cloud NA" app which relates to a different URL (dkncloudna.com) than all other solutions that use these adapters. In the app I can control my unit which seems to be powered by the same "airzone" system this plugin supports. None of the existing "system" options appear to work and manually changing the config to the previous mentioned URL doesn't work either.

API integration docs I can find are here: https://backend.daikincomfort.com/docs/default-source/product-documents/residential/manuals/othermanual/im-dknapi.pdf

Logs: [AirzoneCloud] Unable to login to Daikin AirzoneCloud. Request: {"url":"https://dkn.airzonecloud.com/users/sign_in","method":"POST","mode":"cors","headers":{"Content-Type":"application/json;charset=utf-8","User-Agent":"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_6) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/14.0.2 Safari/605.1.15"},"body":"{}"} {"size":0,"timeout":0}

Plugin Config: { "name": "AirzoneCloud", "system": "https://dkn.airzonecloud.com", "login": { "email": "", "password": "" }, "debug": false, "user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_6) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/14.0.2 Safari/605.1.15", "platform": "AirzoneCloud" }

Environment: running on raspberry pi 3 B

fjhorrillo commented 2 years ago

Hi @PhilM-IT,

This looks like an Aidoo system, I'm planning to adapt to it, but I don't know how it will be done. I'll work on it as soon as I have time.

Regards.

PhilM-IT commented 2 years ago

Thanks for confirming. Happy to test it out once you get around to adjusting the plugin.

lavoiesl commented 2 years ago

I'm also interested in support for NA. You can find the documentation at https://backend.daikincomfort.com/docs/default-source/product-documents/residential/manuals/othermanual/im-dknapi.pdf

I can also help with the coding

fjhorrillo commented 2 years ago

Added support for Aidoo in version 0.3.0

PhilM-IT commented 2 years ago

Not sure if anyone else has tried but I'm unable to get the new Aidoo setup working... the error is also causing homebridge to go into a restart loop and never go online unless I disable the plugin. I'm using the same username and password that works via my iOS app.

[4/1/2022, 8:16:55 AM] [AirzoneCloud] Error calling to AirzoneCloud. Status: 400 Bad Request Response: {"_id":"userNotExist","msg":"No user registered with provided data","reqId":"a78f8bc9-fe2b-4327-b748-a0bc886dc718#14054857"} [4/1/2022, 8:16:55 AM] [AirzoneCloud] Error in login Error: Status: 400 Bad Request [4/1/2022, 8:16:55 AM] Error: Error in login Error: Status: 400 Bad Request at AirzoneCloudApi._login (/homebridge/node_modules/homebridge-airzone-cloud/src/AirzoneCloudApi.ts:92:13) at processTicksAndRejections (node:internal/process/task_queues:96:5) at Function.createAirzoneCloudApi (/homebridge/node_modules/homebridge-airzone-cloud/src/AirzoneCloudApi.ts:63:5) at AirzoneCloudHomebridgePlatform.discoverDevices (/homebridge/node_modules/homebridge-airzone-cloud/src/platform.ts:122:28)

If I try the curl example in the API document with my actual username and password it returns a successful response.

curl --location --request POST "https://www.dkncloudna.com/api/v1/auth/login/dknUsa" \ --header "Accept: application/json" \ --header "Content-Type: application/json" \ --data "{\"email\": \"user@email.com\", \"password\": \"examplePassword\"}

fjhorrillo commented 2 years ago

Hello @PhilM-IT, what I added is the support via https://m.airzonecloud.com which the plugin use if you chose "New AirzoneCloud". Your error is regarding this, your user doesn't have access to https://m.airzonecloud.com and I didn't implement it.

I will check the documentation that you provide to check how to implement support for it.

fjhorrillo commented 2 years ago

Fixed the error handling problem that caused the reboot loop in v0.3.1

PhilM-IT commented 2 years ago

Thanks for the confirmation. It seemed like maybe what you did add support for is a different option/service than what we're using.

0.3.1 does seem to fix the crashing loop FYI.

AG7GN commented 2 years ago

Thanks very much for this plugin!

I am interested in seeing DKN Cloud NA supported as well. I'm seeing the same behavior as @PhilM-IT in version 0.3.1. I'm happy to test as well.

githubatbaronecloud commented 1 year ago

I would like to request this as well please and I'm also willing to help test. With the default settings set to DKN I'm getting "Error calling to AirzoneCloud. Status: 404 Not Found.

sundar2012 commented 1 year ago

+1 on DKN NA support

PhilM-IT commented 1 year ago

@CrazyDymond88 / @sundar2012 try https://github.com/plecong/homebridge-dkncloudna

It supports this, been using for a while now. Seems to work fine.

lavoiesl commented 1 year ago

https://github.com/plecong/homebridge-dkncloudna worked for me 👍🏼

sundar2012 commented 1 year ago

@PhilM-IT @lavoiesl Thanks all. I tested that one last night and had some issues - working with the developer directly. I wanted to see if this plugin could be adapted to work.

P.S. Are our Airzone devices locked to the DKN NA app? my HVAC installer did not explain this - after initial setup I tried resetting and adding to the Airzone app and the device just kept re-appearing in DKN NA.

PhilM-IT commented 1 year ago

@PhilM-IT @lavoiesl Thanks all. I tested that one last night and had some issues - working with the developer directly. I wanted to see if this plugin could be adapted to work.

P.S. Are our Airzone devices locked to the DKN NA app? my HVAC installer did not explain this - after initial setup I tried resetting and adding to the Airzone app and the device just kept re-appearing in DKN NA.

I'm on iOS and only use dkn NA. From what I could tell the "airzone" branded app won't work with these units.