EskomSePush: API available

Thanks! It worked. Updated my code to work with the integration and seems to have gone flawlessly. Now to do the cards… probably tonight.

I’ve created a python script that exposes next loadshedding date and time as well various switches via MQTT in the Homie standard.

Details in the README at above location.

2 Likes

Is anyone having an issue with the loadshedding integration? Mine is updating only the “API Quota” and Stages for Eskom and CoCT, but not the loadshedding forecast. Before I dive into it, just want to check if it is a general issue with their API.

On the Integration itself, I’m just seeing this:

The Stages ones work, and was updated today. Difficult to post screenshot because it is so long, but here’s the bottom of the attributed page:

Mine is working fine as far as I can see.

Hmmm okay, I’ll try and figure out where mine is going wrong. Just checking: Are you also using the integration, or did you build it manually? My first step will be to disable the integration and uncomment my old code.

I’m only using the integration… None of my own code.

Hmmm well it seems a restart of the HA did the trick. Not sure what caused it to get stuck… oh well. Let’s not investigate this further.

1 Like

I’ve had that before, think the rest sensors can get into a bad state for some reason

5 posts were split to a new topic: Sonoff NSPanel

Is there any way to identify areas listed as Cape Town or National with the eskom see push API. A list of the areas under Cape Town would do as well or the area_ids for areas in Cape Town would help as well

This morning I noticed an interesting bug with the loadshedding integration. See picture below:

As you can see the integration (and likely ESP) split up the 02:00 to 05:00 slot into one slot and the 05:00 to 06:30 into another.

Technically the total duration of the next loadshedding is 4.5h and not 3h but my min SoC automation will use 3h and not add the 1.5h, since it considers the durarion of the next event.

It seems the solution is fairly easy: next loadshedding duration is 3h plus 1.5h (if next loadshedding slot end time = after next loadshedding slot start) but I’m not well versed in YAML so was hoping anyone have amended their code to adjust for this event already… :pray:

Go to the integration settings, there is a setting to combine different stages. That will fix the calendar.

That said, I see you are using the template sensor in your image. I sort-off fixed it a bit. I still get annoyed when the first of those differing slots ends, but your initial automation should work correct, because Its combined up until 5 at least.

See: home-assistant-config/eskomsepush.yaml at b785b1fe1e32cb37b87f1ae7e8b0c77459fe06e5 · tinuva/home-assistant-config · GitHub

Also look at the next_loadshedding_duration sensor in that link further down, should give the duration for slots combined.

1 Like

This still working for everyone? I see that I’m no longer getting the forecast or duration.

Yes.

Though there is a bug. if your HA haven’t restarted for a while, then you need to reload the integration.

Do you have YAML for an automation that would reload the integration periodically? Currently I’m doing it manually…

alias: Reload "Load Shedding"
description: ""
trigger:
  - platform: time
    at: "00:00:00"
condition: []
action:
  - service: homeassistant.reload_config_entry
    data: {}
    target:
      device_id: 
mode: single

You just have to figure out the device id.

2 Likes

Thanks! This was definitely the least painful piece of YAML I ever had to implement.

Actually seems like a value template issue with HA 2023.5 and above. Will scratch and fix.

being dumb this side… got this working on my HA… trying to help a friend and running into the below…

sow how i got here…
installed HACS
then went integrations and installed/downloaded “Load Shedding”
then settings/Devices and Services, click add Integration, select Load Shedding which then results in below.
anyone tell me where I’m messing up.

Please

G

Config flow could not be loaded: ha.mullerhomeza.com | 524: A timeout occurred

A timeout occurred Error code 524

Visit cloudflare.com for more information.
2023-07-08 08:42:35 UTC
You

Browser

Working
Cape Town

Cloudflare

Working
ha.mullerhomeza.com

Host

Error

What happened?

The origin web server timed out responding to this request.

What can I do?

If you’re a visitor of this website:

Please try again in a few minutes.

If you’re the owner of this website:

The connection to the origin web server was made, but the origin web server timed out before responding. The likely cause is an overloaded background task, database or application, stressing the resources on your web server. To resolve, please work with your hosting provider or web development team to free up resources for your database or overloaded application. Additional troubleshooting information here.

Cloudflare Ray ID: 7e370674bb594931 Your IP: Click to reveal 160.119.238.17 Performance & security by Cloudflare

so got app installed and all… eventually. just allot of redo’s and restarts.
trying to get it configured, trying to determine which area i need to specify and like 3 times i I get message complaining/suggesting I’m abusing the free account… eish.
is there a test server or can someone send me all the areas that fall under jeffreysbay.

G