MotionEye Snapshot URL Refresh problem

I am attempting to provide the snapshot URL from my motioneye server to a SharpTools tile. I created the resource and set it to refresh every 10 seconds. It works when first loading the page, but when it automatically refreshes, it adds &st_uuid=XXXXXX to the end of the URL and breaks the image. A manual refresh of the page fixes it until it auto refreshes the resource again.

The auto-refresh feature appends this to the end of the image URL as a cache busting feature.

It sounds like MotionEye could be getting tripped up with the addition of the cache busting parameter. Have you reached out to the MotionEye team to see if it is an issue to have additional parameters added to the URL and if so, could the server can be configured to ignore additional parameters?

Edit: It would also be helpful to see the full URL.

The URL contains a signature for authentication at the end, which explains the trouble with additional parameters being added on. Would there be any way around this?

Here’s a censored version of the URL I am attempting to use: http://sub.domain.com:8765/picture/1/current/?_username=admin&_signature=XXXXXXXXXXXXXXXXXX

Without more details, it’s hard to provide additional guidance.

Edit: Just to clarify that point… as mentioned above, SharpTools adds the st_uuid parameter as a cache buster - most servers have no problems with additional arbitrary parameters that are added, provided the parameter doesn’t conflict with a system parameter. This is a common cache busting technique. You mentioned that the signature explains the trouble, but I didn’t see an explanation as to why. If the signature is somehow hashing the full URL along with a secret of some sort, then the signature would need to be dynamically computed after the st_uuid is added if you want to use auto refreshed snapshots.

Alternatives include disabling the auto refresh in SharpTools (maybe using an MJPEG URL instead), using a proxy service in front of the requests (nginx seems to be recommended by the MotionEye developer), pointing the Media Tile toward an endpoint that dynamically computes the signature and redirects you accordingly (or if MotionEye sets the right cache headers, just do a static redirect), or even using a different middleware that can translate your source media into a supported format (eg. Blue Iris, TinyCam, VLC, etc).