Search code examples
phpdownloadgoogle-calendar-apiicalendar

What kind of link does google calendar accept for import link?


I'm trying to generate a link for an ics file which Google Calendar accepts. Right now I have my website which generates a download link. So if you copy the link into your webbrowser, it downloads the calendar file. I'm trying to avoid that I need to download the file and upload it on Google Calender, but rather just copy the link direct into "From url". Any suggestions?

Edit: What I've found out is that if I upload the file to dropbox, make a shared link and edit it from ?dl=0 to ?dl=1 it works on google calendar. My ical file is created with header-content to create a download when user is clicking a button. Does this mean I have to find another way to create the download on? The file is not stored on any server. It's just created with methods and header-content when the user is clicking "download" or copy paste the link into web browser

Regards, Bojar


Solution

  • Seems to be an Authentication issue from where I'm getting my calendar. The link does not give Google access to the necessary data. Thanks for all your inputs