Unable to retrieve data from Thingspeak API (PurpleAir)
12 ビュー (過去 30 日間)
I am having trouble accessing the Thingspeak API with PurpleAir.
Currently my code contains this,
temp_df = pd.read_csv(StringIO(requests.get("https://api.thingspeak.com/channels/"+repr(id)+"/feeds.csv?resutls=8000&api_key="+api+"&end="+end_time).text))
where api_key is retrived from api.purpleair and end_time is for my time period.
Now it just returns -1.
This code worked before for several years however it stopped working today. I assume it blocked me out from accessing the data. How can I fix this?
回答 (2 件)
Christopher Stapels 2022 年 5 月 19 日
Thank you for noting that the issue you had is resolved. If you are reading multiple channels, please be sure to use a short delay between each read attempt, so as not to create undue burden on the server.