Generate download statistics

We use NextClud to provide informational handouts to the patients of our clinic group. We would like to analyze the download numburs in accordance with clinic name and department (eg. “Klinik Bellevue”/Department physio therapy).

Until now we note down all downloads manually into an excel sheet. Because of the amount of downloads each day this process is very time consuming. Is there any possibility to generate an automatical report about the download numbers?

Technical support said “no” and reccommended to ask the community - SO HERE I AM :slight_smile:

I’m really looking forward to your replies!

Best, Cindy


hey cindy

welcome to the nc-forum and thanks for your posting here.

i moved your question to the german subforum since the thread title is in german, only and you put your question in german first.

if you’d add an english translation to your title and add something like “>>> english version below <<<” you could move it back to the desired category of our forums.

or you would get rid of the german part at all… :wink:

i mean you definitly would reach more ppl by posting in english, that’s for sure.


ps: ich verstehe, dass postings auf deutsch einfacher fallen… :wink:

Hi Jimmy,

thanks for your reply.

I already added an English Version below the German but I can also remove the German text at all.

Best, Cindy

1 Like

well done! moved to support now… hope you feel ok with it ^^

1 Like

You can do a manual sql query on the activity table and get public shared download. I don’t know if you can get the same via the API. But if you have access to the database you can sort it out with the right query.

I guess one could write a simple app to pull the same for an admin.

1 Like

The short answer is: Yes, this can be done by analysing the logs generated by Nextcloud with a product such as Splunk (Splunk is a commercial product but does have a free version with some limitations which may or may not be an issue in your case).

Slightly longer answer: There is a Splunk app which can already provide a lot of analysis of the Nextcloud log files. The app has some dashboards that almost meet your requirements. See this post for a description and screenshots of the available dashboards:

I wrote that the currently available dashboards possibly don’t quite do what I think you are after, but a dashboard could no doubt be created which does do what you are after, but for that I’d need to better understand your requirement. So:
Are the downloads done by named users or are they done from public shares?
If the downloads are done by named users, is it a count of how many and which files have been downloaded you are after?
Or is the above “Klinik Bellevue/Department physio therapy" a file path? If so, should the count be of individual files accessed?

1 Like

Thanks a lot for your reply! :slightly_smiling_face:

“Klinik Bellevue/Department physio therapy” is one of many file paths and it should be count how many documents of one specific file are downloaded. Downloads are done from puclic Shares without any names.

Then the easiest way is a simple php script that runs an sql query that builds a csv file to use in a spreadsheet. You also need to add an app for it to work correctly so that activity is generated on public shares.

Do you know how to build it or do you need assistance feel free to send a pm?

Thank you a lot!
I will discuss this with a colleague and if we need any advice I would really appreciate your help!