Good evening,
This is the first thing in my Home Assistant where I’m really lost and even after reading a lot of topic in the community, watched different youtube guides and checked a few other sites I still do not get this up and running.
The value which I’d like to scrape is generated via javascript and I have tried several select values in my scape platform section but either the value of the data is unknown or the data returns empty.
The website from which I want to scrape the data is:
´https://www.fitnesspark.ch/standorte/zuerich/sihlcity
The value is “Aktuelle Gäste” or (optional) “Freie Plätze”
My current section in my sensors.yaml looks as follows:
- platform: scrape
resource: https://www.fitnesspark.ch/standorte/zuerich/sihlcity
select: “span.currentVisitors”
name: fitnessparkvisitors
headers:
User-Agent: Mozilla/5.0
I also tried “.currentVisitors” for the select parameter and also the full selector (which I get via Chrome via inspection mode):
body > div.rf-content > div:nth-child(4) > div.row > div > div > div > div:nth-child(2) > span.currentVisitors
Any hints what I’m doing wrong or what my error in reasoning is?
Thanks.
P4SQL