Entities do only update every 10 minutes
Hi, first of all I want to say thank you. I really like your integration. I do have a Zaptec Pro Charger installed with a load managment. All the entities only update every 10 minutes, i assume this is the Zaptec Cloud that blocks it? And also all the buttons like resume charging / stop charging do not work. When pressed it results in this error;
"Fehler beim Aufrufen des Diensts button/press. Running command 'deauthorize_and_stop' failed"
Am I doing something wrong with the installation or can I change something in the Zaptec Cloud i did not see?
Thank you
All the entities only update every 10 minutes, i assume this is the Zaptec Cloud that blocks it?
I assume you have configured the Zaptec component with either 30 or 60 seconds poll rate? If that's the case, I think it might be the Zaptec cloud which is slow to update.
And also all the buttons like resume charging / stop charging do not work. When pressed it results in this error;
"Fehler beim Aufrufen des Diensts button/press. Running command 'deauthorize_and_stop' failed"
The specific 'deauthorize_and_stop' failed command is a known bug in Zaptec portal. The command works despite it giving the error message. I've reached out to Zaptec, but until this has been fixed, this command will continue giving errors.
'Resume charging' should work if the charger does not require authentication. Is authentication required in your setup and if yes, what kind of authentication scheme are you using? It can be seen in Zaptec Portal and select the installation -> Settings -> Authentication. The mode must be "Native authentication" for authorization to work from HA. It won't work in "Web hooks authentication" or "OCPP-J 1.6 authentication".
'Stop charging' should work. Does this fail for you?
I assume you have configured the Zaptec component with either 30 or 60 seconds poll rate? If that's the case, I think it might be the Zaptec cloud which is slow to update.
Yes i did not change the standard setting of the 60 seconds poll rate.
And also all the buttons like resume charging / stop charging do not work. When pressed it results in this error; "Fehler beim Aufrufen des Diensts button/press. Running command 'deauthorize_and_stop' failed"
The specific 'deauthorize_and_stop' failed command is a known bug in Zaptec portal. The command works despite it giving the error message. I've reached out to Zaptec, but until this has been fixed, this command will continue giving errors.
'Resume charging' should work if the charger does not require authentication. Is authentication required in your setup and if yes, what kind of authentication scheme are you using? It can be seen in Zaptec Portal and select the installation -> Settings -> Authentication. The mode must be "Native authentication" for authorization to work from HA. It won't work in "Web hooks authentication" or "OCPP-J 1.6 authentication".
No authentication is required, it is not working though.
'Stop charging' should work. Does this fail for you?
Yes the stop charging does also not work, in the audi app i can see that the car is charging after i stopped it in HA.
Thanks for your help!
Zaptec automatically starts charging when a car willing to charge is connected and no authentication is required. Does the Audi start charging automatically when the charge cable is inserted? If not, chance is that its the car that holds back the charging process.
That said, I have a hunch that your charger is not responding to the new start/stop commands, but rather use the old. So I have prepared something you can try out: You have to install the master version of the zaptec component to get the new commands I have added for this test.
When the new version is installed, go to Developer tools -> Services. In the service input select zaptec.send_command. Use the UI to select the device for the charger device (not the installation or circuit). Then go to YAML mode and enter command: StopCharging (see below). Press "Call service".
Connect the car and let it start the charge process.
service: zaptec.send_command
data:
device_id: <your numbers>
command: StopCharging
Does this command work or does it give an error?
Does this work to have it start charging again?
service: zaptec.send_command
data:
device_id: <your numbers>
command: StartCharging
Thank you, very much!! Yes, as soon as the Audi is plugged in and the battery is below the level that is set in the car, it starts to charge. You might be right as it looks to me the charger does not respond to the commands. I installed the master, below is the error code that I get when I send the commands. I am going to retry tonight, because the car is not home. I assume it does not make any difference though.
STOP:
Fehler beim Aufrufen des Diensts zaptec.send_command. Command 'StopCharging' failed: POST request to https://api.zaptec.com/api/chargers/42eb23a0-5432-4529-84cd-7da6177ab27d/SendCommand/502 failed with status 500: <ClientResponse(https://api.zaptec.com/api/chargers/42eb23a0-5432-4529-84cd-7da6177ab27d/SendCommand/502) [500 Internal Server Error]> <CIMultiDictProxy('Date': 'Tue, 02 Jan 2024 11:59:13 GMT', 'Content-Type': 'application/json', 'Transfer-Encoding': 'chunked', 'Connection': 'keep-alive', 'Cache-Control': 'no-cache, no-store, must-revalidate, max-age=0', 'Expires': 'Tue, 26 Dec 2023 10:58:35 GMT', 'Vary': 'Origin', 'Request-Context': 'appId=cid-v1:13ae8764-9e17-4375-8db5-90bfd2569e15', 'X-Rate-Limit-Limit': '30m', 'X-Rate-Limit-Remaining': '29999', 'X-Rate-Limit-Reset': '2024-01-02T12:00:00.0000000Z', 'Strict-Transport-Security': 'max-age=15724800; includeSubDomains')>
Start:
Fehler beim Aufrufen des Diensts zaptec.send_command. Command 'StartCharging' failed: POST request to https://api.zaptec.com/api/chargers/42eb23a0-5432-4529-84cd-7da6177ab27d/SendCommand/501 failed with status 500: <ClientResponse(https://api.zaptec.com/api/chargers/42eb23a0-5432-4529-84cd-7da6177ab27d/SendCommand/501) [500 Internal Server Error]> <CIMultiDictProxy('Date': 'Tue, 02 Jan 2024 12:06:14 GMT', 'Content-Type': 'application/json', 'Transfer-Encoding': 'chunked', 'Connection': 'keep-alive', 'Cache-Control': 'no-cache, no-store, must-revalidate, max-age=0', 'Expires': 'Tue, 26 Dec 2023 10:58:24 GMT', 'Vary': 'Origin', 'Request-Context': 'appId=cid-v1:13ae8764-9e17-4375-8db5-90bfd2569e15', 'X-Rate-Limit-Limit': '30m', 'X-Rate-Limit-Remaining': '29998', 'X-Rate-Limit-Reset': '2024-01-02T12:30:00.0000000Z', 'Strict-Transport-Security': 'max-age=15724800; includeSubDomains')>
Thank you. We have now confirmed that the charger does not respond to the old start and stop commands. Good. So the initial question remains: Why doesn't your charger accept the ordinary start and stop commands. It's really odd.
Do you get the same error if you use the command StopChargingFinal and ResumeCharging ?
Yes same error.
I'm wondering, does the user you use have the rights to start and stop charging? The installation entity "
Mine says the same, like yours.
Do i need do change something in the Zaptec Portal? Authentication types is now set to nativ authentication.
Have you changed it to native authentication recently? If you have changed anything, then I'd try again. If not, I'm running out of options on why happens, and I'm increasingly getting convinced that it's not the zaptec integration that's the cause. Given the error that is received when issuing these commands, it is apparent that the zaptec portal/cloud is rejecting the commands. Perhaps you need to reach out to Zaptec support. I'm sorry that I'm not able to help you more in this.
No, i did not change anything. It is still like the way the electrician installed it. I reach out to Zaptec. Thank you, you helped me a lot!!
Problem solved. The charger was set to stand alone, if so it does not work with the ZapCloud. Changed the setting, it is working fine now! Thank you for your help though!!