[SOLVED] How get calendar (ics)

With Google calendar I can download the ics file through wget:
wget -O diario.ics https://calendar.google.com/calendar/ical/[some remote path]/basic.ics

It is possible to do the same thing with nextcloud? What is, in that case, the address to use?
Thanks!
Merry Christmas!

For the path of /e/ calendar have a look to this ical config HOWTO hope it can help you…

Why don’t use the easy way via web browser ?

I have my reasons :slight_smile: I use an ics file to convert it in an md file on my PC (even offline).

Nothing to do: I get always an xml file (with no calendar content), or authentication problems…

Sorry, but I don’t understand. If you are going in browser to "Settings’ on bottom of left side and than on the 3dots, you can download your contacts via vcf file. That’s what you ask for :thinking:

Or your an use your phone to save your contacts as vcf.

So, sorry, I see no problem to do it

EDIT: Sorry, just seen, you want have an ics and not an vcf. So forgive me

The URL is :
https://ecloud.global/remote.php/dav/calendars/your-/e/-email@e.email/personal/?export

You will be prompt for user/password in a browser.

Then you can add at the end these parameters to previous command line :
… --user=username --password=password

Everything found following this Link :wink:

Have fun.

1 Like

nice, but I still don’t get it, why not using the browser. One click and everything is fine.

Scriptable by bash, i hope would be an answer…

Sorry, just seen that I was confused. I’m always talked about contacts :frowning:

But calendar export to ics is the same easy way

Thank you very much, in particular @e-media: your solution (with some corrections) is the right! very well!

1 Like

Great, that you have found a solution. Could you pls edit the head line of you first post to [SOLVED]

THX

Ehm, sorry, but there is still a problem: the ics file I managed to download is both a calendar and a task file (with “VEVENT” and “VTODO” items), and this make impossible for python to transform in a suitable md file…
This is the code:

wget -O diario.ics https://ecloud.global/remote.php/dav/calendars/[myuser]/personal/?export --user=[myuser]--password=[mypassword]

I will see if this last problem can be fixed.

EDIT

I have deleted all todos from that calendar, but yet remain “alarms” (“VALARM”) and this is an obstacle for python.

EDIT

Done! I managed to delete all alarms in that calendar. Now the script works! :grinning:

1 Like

Hello I am interested as well! I need an output to parse using PHP.
I tried writing “https://ecloud.global/remote.php/dav/calendars/[myuser]/personal/?export
–user=[myuser]–password=[mypassword]” in the browser but all I get is “This is the WebDAV interface. It can only be accessed by WebDAV clients such as the Nextcloud desktop sync client.”

[myuser] is the email user@e.email ?

Try this in a bash command line on linux :

$wget -O ~/diario.ics https://ecloud.global/remote.php/dav/calendars/[myuser]/personal/?export --user=[myuser] --password=[mypassword]

You will get in your home path a file named diaro.ics with your calendar in ics format.

If not in a browser URL type :
https://ecloud.global/remote.php/dav/calendars/[myuser]/personal/?export

And you’ll be prompt for user and password then ask for path to download your ics calendar.

Note : You have to change myuser by your/e/mail@e.email. and mypassword by your password :wink:

Yes it works, just correct:
"You have to change [myuser] by your/e/mail@e.email. and [mypassword] by your password.

How to specify a different calendar within the [myuser] account?

If your new calendar is named testcal then the URL might be :
https://ecloud.global/remote.php/dav/calendars/[myuser]/testcal/?export

1 Like