They were onenote's files, research notes. Had problems with sync and lost files.
How can I recover the files in the safest way? It happened today. I already stopped using the phone.
(asking for a friend)
I'd try photorec (testdisk package) in Linux. Or the Piraform file recovery program in Windows. Get it connected to a PC sooner rather than later as you don't want the area it was stored to be overwritten.
Was the Onenote not syncing with a Microsoft account?
data-recovery
tag to your question. You might be interested in checking its tag-wiki which will give you some useful links on the topic.