How can I download a password protected file inside python?
The file is shared via Owncloud and the access is protected with a password by Owncloud.
I know it works with curl by using:
curl -u "FileId:FilePw" -H 'X-Requested-With: XMLHttpRequest' "https://exampledomain.com/public.php/webdav/" >output_file
The field file id FileId is extracted from the shared link.
There are web pages which can convert
curlcommand to many different languages and modules - even toPythonandrequests- ie. Curl ConverterAnd this needs only to save response in binary mode