K
K
KirylLapouski2018-05-19 09:40:31
JavaScript
KirylLapouski, 2018-05-19 09:40:31

How to use users' cloud resources to host application files there?

There was a need to store the data that the user placed not on the server, but on the client.
There is an idea to register users through Yandex, and ask for the right to use their Yandex disk.
Google has the same integration, in its classroom, only google drive is used instead of Yandex drive. But there is a problem: the data posted by the user must be available to everyone, that is, you need to create a public link to this resource. But the public link does not point directly to the file. The public link points to a page where you can already download the file. Any ideas? There is no binding to Yandex disk, you can offer other services.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
S
Sergey Sokolov, 2018-05-19
@sergiks

I recommend Google Drive. For a standalone application, see the Google Drive REST API . JavaScript examples .
Another good serverless option is Google Apps Script ( GAS ) inside, for example, Google SpreadSheet - this can be done, in particular, by a telegram bot into which you can upload pictures that will be in Google Drive, and the bot will receive a link to the downloaded image, available everyone. Recently did such mechanics.
The GAS Drive API allows you to upload a file, make it available to "everyone" and get a link to it.

E
Ezhyg, 2018-05-19
@Ezhyg

The task of "clouds" is just the opposite. Why think about them at all and repeat like a mantra?
To do this, each client computer must also become a server, albeit for one specific task.
Either a "shared cloud" (or editing access is not shared), or a "shared folder" of a corporate network (local, work, etc.).

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question