Yes, it could be possible using vfs_shadow_copy2
Guides:
Snapshots need to be supported so we need at least LVM.
The implementation could work like in Recycle Bin Samba NS8 - #31 by mrmarkuz
Interesting feature, I’m going to check…
For Windows there’s Robocopy | Microsoft Learn