I'm trying to download a .txt file from the web in flutter is there any way? it would be helpful if it works also for Google drive. thanks.
Asked
Active
Viewed 299 times
1 Answers
1
you can use dio flutter to download files
response = await dio.download("url", "storagePath");
downloading from google drive your url would look something like this
GET https://www.googleapis.com/drive/v3/files/[FILEID]?alt=media&key=[YOUR_API_KEY]
here is a link to SO answer with more details on using dio to download files

griffins
- 7,079
- 4
- 29
- 54