Answer the question
In order to leave comments, you need to log in
How to set a file name when saving from YandexDisk?
Hello.
There are files on the disk by uuid.
I would like to give the user the ability to save these files in the "DATE_SOME" format (for example).
The procedure is as follows - https://example.com/disk/uuid.wav
When you click on the link, the request arrives in the application. The application determines where to give the file from: local http server or YD. Generates a 307 request and returns a new link that is already downloading.
When returning from local http, I pass the name parameter in the request arguments ?filename=123__234.wav.
For YD, a link is formed to receive the file and is also transmitted through a 307 request.
I did not find in the documentation for YD whether the replacement of filename is allowed in the received url.
If I change it myself - I get 403
I would not want to proxy files through myself (download, then give)
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question