Problems with AirqualityWorld and Purpleair Blocks

Post Reply
meteobescano
Newbie
Newbie
Posts: 4
Joined: Mon Oct 05, 2020 6:34 pm
Station model: Davis Pro 2 plus
Software: Weatherlink IP

Problems with AirqualityWorld and Purpleair Blocks

Post by meteobescano » Sat Sep 30, 2023 2:38 pm

Hello,
I recently purchased two Air Quality sensors.
I installed the Purpleair 1.0 block and tried to put the sensor ID number in the block and it didn't work. I got the ID from the Purpleair email and I think it is 6 numbers but I can't get it to work.
I tried to configure the other sensor in the Air Quality World block. I enter my address:
https://aqicn.org/station/spain-bescan% ... eobescano/
It doesn't work either.
Can someone help me configure these two sensors on the page?

Thank you so much

FSC830
Forecaster
Forecaster
Posts: 139
Joined: Thu Aug 02, 2018 11:40 am
Station model: Davis Vantage Pro2
Software: Meteobridge

Re: Problems with AirqualityWorld and Purpleair Blocks

Post by FSC830 » Sat Sep 30, 2023 8:35 pm

Did not use this sensors, but took a look in block and to purpleair.com.
Seems, that the API call was modified by purpleair, the URL for the API request is totally different then in block.
So my guess, its not so easy to modify the block quickly.
As far as I can see at purpleair.com you need not only your sensor ID, but an API key too (and may be a read key).

Did you get all of these (sensor ID, API key, read key) in confirmation mail when registering the sensors?

Regards
Image

meteobescano
Newbie
Newbie
Posts: 4
Joined: Mon Oct 05, 2020 6:34 pm
Station model: Davis Pro 2 plus
Software: Weatherlink IP

Re: Problems with AirqualityWorld and Purpleair Blocks

Post by meteobescano » Mon Oct 02, 2023 2:32 pm

Thanks for your answer...
In the Purpleair email after registering the sensor I received different urls:
• Sensor summary JSON is here: https://www.purpleair.com/data.json?sho ... ey=xxxxxxx

• Sensor details JSON is here: https://www.purpleair.com/json?show=185 ... =xxxxxxxxx

I thought that the number 185613 was the JSON number that the block asks for in the configuration.
It seems that it is not correct.
In reference to the API, I think that now it has an economic cost and therefore you have to request it.

Regarding the airqualityWorld Block, can you know why it doesn't interpret the URL of my sensor?

Thank you very much and sorry for my questions

FSC830
Forecaster
Forecaster
Posts: 139
Joined: Thu Aug 02, 2018 11:40 am
Station model: Davis Vantage Pro2
Software: Meteobridge

Re: Problems with AirqualityWorld and Purpleair Blocks

Post by FSC830 » Tue Oct 03, 2023 5:43 am

As said, the API was modified and it seems, that the URL in block for calling the data is not correct any longer.
My guess, you did register you sensors as "private sensors"?
Referring to the purplecair webpage you need 3 different variables for a private sensor: the sensor ID, the API key and a read key.

But if private data or not, referring the API reference the URL always starts with https://api.purpleair.com/v1/..., so it seems, that the URL you use is not correct any more.

Regards
Image

davidefa
Expert
Expert
Posts: 862
Joined: Tue Jan 12, 2021 8:03 am
Location: Italy
Station model: WH2650
Software: WH2650 (direct upload)
Contact:

Re: Problems with AirqualityWorld and Purpleair Blocks

Post by davidefa » Sun Oct 08, 2023 9:21 pm

@meteobescano

The block airQualitySensor supports the purpleair sensor.
If you prefer the look of purpleair block I can take a look and update it ( not sure if I still have a valid purple air token/key )

For the airQualityWorld I think only the urls that begin with: https://aqicn.org/city can be used.
Those with https://aqicn.org/station ( as your in bescano ) can not.
Image

Post Reply