jwcooper wrote:The feed itself doesn't 404, does it? I assume calling
- Code: Select all | TOGGLE FULL SIZE
/api/v2/{username}/feeds/{feed_key}
would return all of the metadata for that feed.
Correct, using curl and the API url, the feed itself does indeed return metadata. Until you mentioned that, I'm not sure I would have taken the time to try it because I've only seen this issue using the CircuitPython
http client object. For instance (pseudo-code):
- Code: Select all | TOGGLE FULL SIZE
from adafruit_io.adafruit_io import IO_HTTP
io = IO_HTTP(ADAFRUIT_IO_USER, ADAFRUIT_IO_KEY, wifi)
apod_delay_feed = io.get_feed('pyportal-01.apod-delay')
io.receive_data(apod_delay_feed['key'])
The
io.receive_data call returns the 404 error as shown in the PyPortal image in one of my previous posts (see below).

Granted, catching the AdafruitIO_RequestError (which I wasn't doing) could have helped here. But, a 404 on a request for data, from a valid feed, with a known last value kinda seems weird, no?
jwcooper wrote:We'll file an issue internally and sort out if we should return the last_value always (even if there is no data), or if we should update that UI to show 'no data' once the data records have expired.
I expect what you ultimately do will warrant internal dev discussions, but my 2¢ is that if "last_value" is available but historical data has been purged, the CircuitPython case (at least) shouldn't return a 404 error, it should just offer up the last known value.