aalmazanarbs / hassio_aldes

7 stars 5 forks source link

No entities and module notfound error #10

Closed DKFR67 closed 1 year ago

DKFR67 commented 1 year ago

First off all many thanks for your great and useful integration.

Since last update, my VMC has no entities and I have the errors while loading the module. All worked fine with your March update. I tried your last updated code without results.

Can you give me advices to fix my problem, or perhaps can you fix your code?

Thanks in advance Error Log No Entity

aalmazanarbs commented 1 year ago

Hi @DKFR67,

The error you are reporting is very weird.

Please, check you files, HA version and other general installation problems and come back with news :)

DKFR67 commented 1 year ago

Hi @aalmazanarbs

Thank you for your answer. The error was fixed by renaming the directory as "aldes" instead of "hassio_aldes-master" (with older versions of home assistant this gave no errors ...)

To see my VMC "EASY_HOME_PREMIUM", I had to use an old part of your code, without the "is_product_supported" parts VMC .

aalmazanarbs commented 1 year ago

@DKFR67 nice, good news

So, if your product if fully compatible with this integration I can add as supported product. Could you tell the real name of your product or the output for the endpoint /aldesoc/v5/users/me/products. Is your product compatible with these five modes: Holidays, Daily, Boost, Guest and Air Prog?

DKFR67 commented 1 year ago

Where can I find the output for the endpoint /aldesoc/v5/users/me/products ? My product is compatible with the five modes: Holidays, Daily, Boost, Guest and Air Prog.

Le mer. 19 avr. 2023 à 11:44, Alejandro Almazán @.***> a écrit :

@DKFR67 https://github.com/DKFR67 nice, good news

So, if your product if fully compatible with this integration I can add as supported product. Could you tell the real name or you product or the output for the endpoint /aldesoc/v5/users/me/products. Is your product compatible with these five modes: Holidays, Daily, Boost, Guest and Air Prog?

— Reply to this email directly, view it on GitHub https://github.com/aalmazanarbs/hassio_aldes/issues/10#issuecomment-1514440436, or unsubscribe https://github.com/notifications/unsubscribe-auth/A5LAPYZAWGU62YVGZZV3MYLXB6XZVANCNFSM6AAAAAAXC3L3VM . You are receiving this because you were mentioned.Message ID: @.***>

aalmazanarbs commented 1 year ago

@DKFR67 you need to make a curl with your credentials to https://aldesiotsuite-aldeswebapi.azurewebsites.net/oauth2/token to get an access token. Then with the credentials make a curl to https://aldesiotsuite-aldeswebapi.azurewebsites.net/aldesoc/v5/users/me/products to get information about your products in order to get reference and display name for your product.

DKFR67 commented 1 year ago

@aalmazanarbs/hassio_aldes @.***>

I tried, but aldes API returns the code above when I request the token ...

{ "error": "invalid_request", "error_description": "The specified HTTP method is not valid.", "error_uri": "https://documentation.openiddict.com/errors/ID2084" }

My syntax is : curl -v -u 'my_user_name:my_password' https://aldesiotsuite-aldeswebapi.azurewebsites.net/oauth2/token

Le mer. 19 avr. 2023 à 17:41, Alejandro Almazán @.***> a écrit :

@DKFR67 https://github.com/DKFR67 you need to make a curl with your credentials to https://aldesiotsuite-aldeswebapi.azurewebsites.net/oauth2/token to get an access token. Then with the credentials make a curl to https://aldesiotsuite-aldeswebapi.azurewebsites.net/aldesoc/v5/users/me/products to get information about your products in order to get reference and display name for your product.

— Reply to this email directly, view it on GitHub https://github.com/aalmazanarbs/hassio_aldes/issues/10#issuecomment-1514957630, or unsubscribe https://github.com/notifications/unsubscribe-auth/A5LAPY6WW3BINJHGTEBGUO3XCABRTANCNFSM6AAAAAAXC3L3VM . You are receiving this because you were mentioned.Message ID: @.***>

aalmazanarbs commented 1 year ago

@DKFR67 here you have the curls

curl --location 'https://aldesiotsuite-aldeswebapi.azurewebsites.net/oauth2/token' \
--header 'Content-Type: application/x-www-form-urlencoded' \
--data-urlencode 'grant_type=password' \
--data-urlencode 'username=your-user-name' \
--data-urlencode 'password=your-password'
curl --location 'https://aldesiotsuite-aldeswebapi.azurewebsites.net/aldesoc/v5/users/me/products' \
--header 'Authorization: Bearer the-access-token-of-previous-request'
Saeglopur76 commented 1 year ago

Hello @DKFR67, Did you fix your problem? Are you able to discover your Aldes product with the last @aalmazanarbs release? If yes, could you confirm and share your fix with the HA community. If not, I guess you only have to add your product name in the product.py file. You could try something like :

_DISPLAY_NAMES: Final = { 'INSPIRAIR_HOME_S' : 'InspirAIR® Home S', 'EASY_HOME_CONNECT' : 'EASYHOME PureAir Compact CONNECT', 'DEE_FLY_CUBE' : 'Dee Fly Cube', 'EASY_HOME_PREMIUM' : 'EasyHOME PREMIUM'

(don't forget the coma at the end of the previous line!) ;)

Best Regards

DKFR67 commented 1 year ago

Hello,

With last release and adding the line 'EASY_HOME_PREMIUM' : 'EASYHOME Premium' into the code, all work perfect.

Le jeu. 1 juin 2023 à 22:34, Saeglopur76 @.***> a écrit :

Hello @DKFR67 https://github.com/DKFR67, Did you fix your problem? Are you able to discover your Aldes product with the last @aalmazanarbs https://github.com/aalmazanarbs release? If yes, could you confirm and share your fix with the HA community. If not, I guess you only have to add your product name in the product.py file. You could try something like :

_DISPLAY_NAMES: Final = { 'INSPIRAIR_HOME_S' : 'InspirAIR® Home S', 'EASY_HOME_CONNECT' : 'EASYHOME PureAir Compact CONNECT', 'DEE_FLY_CUBE' : 'Dee Fly Cube', 'EASY_HOME_PREMIUM' : 'EasyHOME PREMIUM'

(don't forget the coma at the end of the previous line!) ;)

Best Regards

— Reply to this email directly, view it on GitHub https://github.com/aalmazanarbs/hassio_aldes/issues/10#issuecomment-1572740157, or unsubscribe https://github.com/notifications/unsubscribe-auth/A5LAPY4LID6WYM74YKYC5MLXJD4DZANCNFSM6AAAAAAXC3L3VM . You are receiving this because you were mentioned.Message ID: @.***>

aalmazanarbs commented 1 year ago

Hi @DKFR67, please create a pull request with your product since you have tested it works :)