ianmaciel / dart_ewelink_api

MIT License
3 stars 3 forks source link

Add support for getting all devices #11

Closed guyluz11 closed 1 year ago

guyluz11 commented 1 year ago

I would like to implement this package in my open-source smart home system CyBear Jinni, but it will be drastically better and more convenient if I am able to show the user all of his devices without his need to search where to get the id in the app and add all of the ids one by one.

https://github.com/ianmaciel/dart_ewelink_api/blob/b5d945ae7c4b7ee8304e34a93462f63b07e17101/example/main.dart#L39

ianmaciel commented 1 year ago

I won't have time to work on this library soon.

Wouldn't you like to open a PR?

guyluz11 commented 1 year ago

Probably in the future, currently working on adding xiaomi device support with the help of another package.

guyluz11 commented 1 year ago

Found where the npm package that we are based on is doing the call to get all devices

Doc: https://github.com/skydiver/ewelink-api/blob/master/docs/available-methods/getdevices.md

Call in code: https://github.com/skydiver/ewelink-api/blob/master/src/mixins/getDevices.js

ianmaciel commented 1 year ago

Contradicting myself I have just created the method to get all devices. https://github.com/ianmaciel/dart_ewelink_api/pull/15

guyluz11 commented 1 year ago

That's so cool of you, thanks.

Will start implementing this package into cbj sooner than expected 😆

ianmaciel commented 1 year ago

Would you like to review?

guyluz11 commented 1 year ago

Done