How to upload a file on nextcloud?

Nextcloud : 15.0.7
I am developing nextcloud on my local server, and I can’t find the function that uploads the file. Can you help me where the function to upload is located?

The answer depends on what gui you are using. Assuming that you’re using the web gui, you will find a plus sign right to the home button in the files app.


Yes, thank you. But that’s not my problem. I’m looking for the function that makes this upload in the source code.

Hello, did you found a solution to your question @Guinou ? I’m looking for a way in that a administrator of a server could upload files on users cloud boxes. Via a API ? I can’t find anywhere a clue to that question.

I think it would be a better idea to use group folders or a shared folder. Nobody want that a admin uploads data directly in the own storage.

Thanks for your quick answer. No body in regular scenario but in my case i need it. GroupFolders can’t be a supportable solution. So i’ll need to code on the nextcloud projet or find another base project. (if you have a idea).

You can use “curl” see other post or other webdav-stuff .

Also you can use ftp, sftp, smb, … and then re-scan (cron?)

occ files:scan --all (or user)

Nice i’ll try that.

from ownCloud days, there is a implementation in python:

I move to the development sections.