I have a sharepoint file structure that looks like this:
MainFolder -> SubFolder -> FileFolder -> myfile.txt
I am able to retrieve the MainFolder metadata using the api endpoint:
https://{siteRoot}/{site}/_api/web/lists/getByTitle('MainFolder')/rootfolder
But I cannot for the life of me work out which endpoint to use to retrieve myfile.txt. Any help would be appreciated.