Closed bragg2012 closed 1 month ago
Hi, have you changed the key and secret in the script above line:
I have - I am using the creds generated using this script
https://github.com/mmiller7/ecoflow-withoutflow/blob/main/cloud-mqtt/ecoflow_get_mqtt_login.sh
It gets the details from https://api.ecoflow.com/iot-auth/app/certification
I still don't have access to the ecoflow developer portal, taking them a while to approve - not sure if they require a different set of creds?
its required - the script is not using mqtt. so please create first you api access otherwise you cannot us this script.
Thanks - got the keys this morning and all working as expected.
Hi - seem to be getting an error below when executing the script. I have redacted key/secret/SN from the below
2024-05-13 10:04:30.406 DEBUG (MainThread) [custom_components.pyscript.eval] file.set_ef_powerstream_custom_load_power.set_ef_powerstream_custom_load_power: calling encode("utf-8", {}) 2024-05-13 10:04:30.406 DEBUG (MainThread) [custom_components.pyscript.eval] file.set_ef_powerstream_custom_load_power.set_ef_powerstream_custom_load_power: calling new(b'SECRETREDACTED', b'params.quotas[0]=20_1.permanentWatts&sn=HWSERIAL&accessKey=app-KEYREDACTED&nonce=495497×tamp=1715591070398',, {})
2024-05-13 10:04:30.407 DEBUG (MainThread) [custom_components.pyscript.eval] file.set_ef_powerstream_custom_load_power.set_ef_powerstream_custom_load_power: calling digest(, {})
2024-05-13 10:04:30.407 DEBUG (MainThread) [custom_components.pyscript.eval] file.set_ef_powerstream_custom_load_power.set_ef_powerstream_custom_load_power: calling hexlify(b"\xef\xaa\xd3=x'\x01\xb0Rb W\xc7\x15V`~>\x010=\xc4\xe9\x8b1\x07\xcc%U\xf9\x85y", {})
2024-05-13 10:04:30.407 DEBUG (MainThread) [custom_components.pyscript.eval] file.set_ef_powerstream_custom_load_power.set_ef_powerstream_custom_load_power: calling decode("utf-8", {})
2024-05-13 10:04:30.407 DEBUG (MainThread) [custom_components.pyscript.eval] file.set_ef_powerstream_custom_load_power.set_ef_powerstream_custom_load_power: calling executor(<function post at 0x7f57b02d9ee0>, "https://api.ecoflow.com/iot-open/sign/device/quota", {'headers': {'accessKey': 'app-KEYREDACTED', 'nonce': '495497', 'timestamp': '1715591070398', 'sign': 'REDACTED'}, 'json': {'sn': 'HWSERIAL', 'params': {'quotas': ['20_1.permanentWatts']}}})
2024-05-13 10:04:30.589 DEBUG (MainThread) [custom_components.pyscript.eval] file.set_ef_powerstream_custom_load_power.set_ef_powerstream_custom_load_power: calling json(, {})
2024-05-13 10:04:30.590 DEBUG (MainThread) [custom_components.pyscript.eval] file.set_ef_powerstream_custom_load_power.set_ef_powerstream_custom_load_power: calling info("Error accessing data in payload:", 'data', {})
Here is what my service call looks like in the automation.