Image update button

Hi,

I am building an app for OSAIO (GNCC, WOLFANG) security cameras. On each event (motion or sound), the camera takes a snapshot and uploads it to Backblaze B2. The API for the cameras provides the URL to the snapshot on Backblaze B2. I can’t use the image.setUrl() function, because the URL expires after 30 minutes, so I used image.setStream() instead.

I see this refresh button here:

image

What capability is this? I can’t find it anywhere. I want my app to check for and download a new image whenever that button is pressed. Is that possible? Or is it only to refresh the image from a URL?

For now I solved it using a custom capability.

The app also auto-refreshes every 5 minutes via polling.

While it works just fine, I’d rather have it use the refresh button under the image for that since that’s easier to use, instead of constantly having to switch between buttons and camera view. Is there any way to use the small refresh button under the image instead?.

This icon?

It’s a Homey core function.

It triggers the image handler automatically. Also using the image flow tag triggers the image handler.

So your image.setStream( ) should be called every time a user

  • opens the image tab of the device
  • presses the refresh button
  • an image tag is used in a flow (to send a push meaasge including the image)

Ah okay, my app only streamed the image from the object storage URL there, my app didn’t fetch the new URLs so I never noticed that. Thanks for pointing it out!
.

OSAIO app is in testing here for anyone looking for the app: