Can i get all sensors id's?

I would like to get the data of all the sensors registered on south america automatically in my app. Otherwise, i have to keep updating my code whenever i install a new sensor. Is there a way to do it?

1 Like

Is the app that you’re using written by yourself?

If you want to obtain a list of all sensor indexes in South America, you may be interested in an article we posted showing how to find large amounts of sensor indexes using geographic coordinates. You can set a bounding box for South America, and periodically resend the query to find new sensor indexes.

3 Likes

Yes, it is. “SelvaApp” on play store, and appselva.com.br on web. Thank you, it worked!

3 Likes

One more question. Can i get the data from private sensors if i have the login of the owner? How can i do that via API?

1 Like

You can get data for private sensors by using their sensor index, and including their read key in the “read_keys” parameter. This parameter accepts a comma delineated list of read keys.

You’ll need to view a private sensor on the PurpleAir map to obtain its read key.

2 Likes