[SmartThings Edge] Issue with the Refresh capability using a custom presentation

I am using a custom device presentation for some of my devices. I have narrowed down a behavior in which the “pull to refresh” in the detail view does not work when using a custom presentation. It is working fine when I switch that device back to a stock presentation.

I tried adding the refresh to the detailView just in case, with no effect:

{
            "component": "main",
            "capability": "refresh",
            "version": 1,
            "values": [],
            "patch": []
        }

Hi, @blueyetisoftware!
Can you share the VID that causes the error, please?

Scratch that. Adding refresh to the presentation did work! I had to recompile the presentation json. It is worth noting that the pull to refresh animation does show up in the app, even if it isn’t in the custom presentation. The only change I would suggest to the team is to keep that animation disabled if that capability is not in both the device profile and the presentation.

@nayelyz @blueyetisoftware
My device supports mainly switch capability. I have added refresh capability to my device profile. But state refresh is not working for me on page reload.

Is there something wrong with the way I am handling state refresh. if yes, how should this be modified such that my integration also supports refresh capability?
response.addDevice( externalDeviceId,
[
{
component: “main”,
capability: “st.switch”,
attribute: “switch”,
value: “on”
}
]
)

If you make a custom presentation, you need to add the refresh capability to it as well. Refresh has a UI that needs to be supported. Add it the same way you did with the switch.