This was my question a few days ago, but I also have an answer which I’d like to share.
One of the neat things that AWS S3 offers is versioning. Every time a file is updated (or deleted), the old version of that file is kept around.
While that does increase storage costs, it also allows for files to be undeleted in case of accidental deletion.
The process is somewhat complicated, so I wrote up an entire blog post covering the topic:
Enjoy! Feel free to let me know in the replies how it works out.
– Doug