Our small web app need a function to create .ics calendar file/s and send the created .ics file as attachment in email.
You need to to create ics file and write the binary to the datastore, then send email with the .ics file as attachment.
For your reference -- you can choose to use vobject lib to create the .ics file.