How to save audio file locally?

Hi,
I am saving audio file into the cloudDB.
Later, I want to copy the file in to my computer.
In order to do so, I want to first save the file locally to the phone.
I read the file from the cloud and can play it.
How do I save the file to my phone memory?
Tnx!

Where does the audio file come from in the first place ?

Use Taifun's File extension: App Inventor Extensions: File | Pura Vida Apps

From the appinventor recorder.

https://puravidaapps.com/snippets.php#2soundrecorder

The audio file should already be saved to your device, you need to get the filename and path when you create it.

The default path of the SoundRecorder is:
/storage/emulated/0/My Documents/Recordings/app_inventor_1587821487524.3gp

To set your own path, try e.g. this path:

This will not work since we are a group that record birds in the field. So the app will save files from different cell phones.
Later on, we want to move all the records to one computer.
So. we manage to save the files on the cloud.
We can retrieve and listen to the files, but I do not know how to save all the files again, locally.

Thank you for that useful additional information.

Are you running your own redis server?
If so, who ever controls this could use the redis cli program to download all the files to a computer.

If you are using the MIT provided default redis server for the cloudDB component, this is not the best place to store data/binary files for production purposes, the data may not always be there or be available.

Do you want every user to be able to download all the files to their device ?
Do you want to do it in a batch (download all files at once), or just one by one as they listen to a file ?

I am using the MIT default server.
We are many users who save files, and only one person, take the data at the end of a week to his own data base.

https://ai2.metricrat.co.uk/guides/howto-setup-redis-server-with-ssl-for-use-with-ai2

Establish a server is too complicated for me…

Is it possible to send the files to google or google drive somehow?

Yes…

HOWTO: Upload Any File To Google Drive

Thank you, but:
What do I do with the WEB APP SCRIPT? Is it part of the MIT app invertor?

No, it is part of the googlesphere.

What do you mean by what do you do with it?

In this case one would:
Open google drive
File > New > Google Apps Script (you may need to add this is not present)
Name the script
Add the code, change script to your folder ID
Publish and get the url
Test

Also for everytime with the script:

1 Open the script project
2 Go to Publish
3 Deploy as Web App
4 Project version: - select New from the dropdown
5 Execute the app as: your google account address (email)
6 Who has access to the app: Anyone, even anonymous
7 Press the Update button

You have to do this EVERY TIME you change your script

Tnx for the detailed response!
I managed to publish in the google drive.
I am trying to program the blocks in the App invertor, but I can’t find: “call KIOS_Base641 getmimetype”
As shown in https://ai2.metricrat.co.uk/guides/upload-any-file-to-google-drive-with-ai2
Can you support?
Tnx!

this is an extension, and my guess is, it is this one File to String. String to File. Base64 Extension (Version 2) by Juan Antonio
for the extensions directory see also here App Inventor Extensions | Pura Vida Apps
Taifun


Trying to push the limits! Snippets, Tutorials and Extensions from Pura Vida Apps by Taifun.