You made a VCALENDAR generator with a web-accessible endpoint. It fills in the VCALENDAR with info passed in via URL parameters. And rather than returning a webpage, it just returns the VCALENDAR file.
So you send your friends the link, they click it, rather then returning text/html content, it returns a downloadable response consisting of a pre-filled VCALENDAR file with the correct MIME type, and .ics extension.
Do I have that right?
> Now I can finally send my friends a link to a calendar event for our next pub crawl.
I suggest you update the tagline to say "link" as there is no "terminal" involved. That is, you don't use cURL and you don't send a normal calendar invitation email, but instead you send a message with a link that gives them the ical file when they click it.
At least on the Chrome viewport emulator it looks fine to me...
https://github.com/mre/endler.dev/commit/bc1187d290d153455b0...
> There is no state on the server, it just generates a calendar event on the fly and returns it.
Didn't see that coming. I suppose it's handy that you can call it anywhere curl is installed (or even use the browser address bar as your command line) instead of having to install and run the Rust program locally.
Can you tell me why the above wouldn't work and why this is better?
I think the more difficult part is sending an email that looks and works right with the invite attached in a way compatible with the receiving systems.
Invitations from Microsoft systems are especially horrible as they look like normal, plain text messages (without an invite) in standards-compliant systems. Depending how the sender expresses themselves, the receiver might have no clue they were invited let alone the time and place.