Emailed Daily Agenda from Apple Calendar

Besides linking Apple Calendar to Google calendar (I've tried and failed to do), does anyone have a way to get a daily agenda from Apple calendar into an email delivered daily?

Printing from a day view surfaces a dialogue set to today's view, which, continued, gives a standard print dialogue. Then, there's an option in the PDF dropdown to Send in Email, which attaches the day's view into an unaddressed email.

Looking at the Calendar dictionary, the only part missing seems to be the select Send in Email from within the PDF dropdown menu.

While UI scripting looks doable tho fragile, a script triggered to run daily would be ideal.

To see a google calendar in your Mac, you need to add it in OSX System Preferences>Internet Accounts,
there add a Google Account:

Did it and no result. My system tends toward the wonky side, with some common things not working. So when I get my next Mac, I'll add back the iCloud documents and manually re-add EVERYthing else to not bring any issues forward.

Thank you for offering!

hm, tried to see if there's a way to add a Google Calendar from its link, but seems like Apple Calendar doesn't have that ability

Hey Bern,

You'll have to roll your own.

Take a look at icalBuddy.

icalBuddy Doesn't Work Within Keyboard Maestro. Mojave Calendar Permissions?

Most basic syntax:

icalBuddy eventsToday

-Chris

Hi @BernSh there is a simple solution to this (that I use) that doesn't require Keyboard Maestro or any other software or scripting.

You just need to think of the problem the other way around... and lever Google Calendar's inbuilt function to send the daily emails of Calendars. In other words use Google Calendar to send the Daily email of your iCloud Apple Calendar.

Open Apple Calendar on the Mac and select the Apple Calendar you want to have a daily schedule email from.

Still in Apple Calendar App, right-click this specific Calendar, choose Sharing Settings, check the "public" checkbox and a URL will be displayed. Copy this URL to the clipboard.

Now go to your Google Calendar on the Web. Look down the list on the left for "Other Calendars" and click the + sign. Choose "From URL" and paste in the URL of your iCal Calendar you copied to the clipboard.

The Mac Calendar will be read-only in Google Calendar, but it allows you to set up a daily email notification from your iCal Calendar as you wanted to do (by going to the Calendar's settings in Google Calendar and choosing to email a Daily Agenda). The email will arrive in your Mail App (it will be sent to the Gmail Account linked with the Google Calendar).

Thanks @Zabobon & @ccstone! I went down the yellow brick Google road multiple times and never made it to Oz. Google (The Wiz) just doesn't read the URL.
Untitled
I even found the seemingly obscure Calendar Sync Settings page (https://calendar.google.com/calendar/u/0/syncselect?pli=1) where my new calendar wasn't ticked off and I excitedly checked the checkbox for my new calendar annnndddd, still nothing. Sigh...

Took calendar out, put it back, restarted, signed in and out of Google and iCloud, Bupkis!

Again, I think it's my wonky system that I've beat up with lots of app downloads during my intensely app promiscuous years.

@ccstone - icalBuddy didn't work for me and has a hideous terminal/terminator look and feel so I'll mess with some UI hacking for now.

Thank you both again! :smiley:

1 Like

Before you resort to UI hacking, one other option you might want to try is Apple Shortcuts, perhaps along these lines:

Since Shortcuts also has support for timed daily automations now, this seems like it might be worth pursuing.

2 Likes

Very strange though as this is all being set up on the internet rather than your local computer. All Apple Calendar has to do is generate a URL for your shared calendar. So, I suppose if it is something to do with your system it could be that your Mac is not actually sharing the Calendar.

Anyways, looks like @gglick has a good route to a solution with Apple Shortcuts. I’m going to look into that for myself too.

2 Likes

Brillant! There's no place like Hom... Er, the KM Forum! :man_cartwheeling:

This will work as-is and any ideas how to add the time of the events preceding the titles?

This:

Outputs:

Glad the suggestion proved useful. I'm still waiting for Shortcuts to come to macOS with Monterey before I start trying to learn them seriously, as I can't stand the touch-based method of arranging and editing actions on iOS, so I don't know if this method I came up with for putting the event time before the titles is the preferred or optimal way to do so among Shortcuts aficionados, but in my testing it seemed to work:

Today’s Events.shortcut.zip (12.9 KB)


Essentially, this looks at the calendar events specified, ignores all-day ones since they didn't seem to make sense for a daily agenda list and threw off the formatting, then extracts the start and end times for events into separate (unnamed) variables, and finally assembles those times plus the event's title into the equivalent of an "Append to Variable" action in KM so that they're listed as:

[START TIME]-[END TIME]: [TITLE]

In my test calendar, this resulted in

7:45 AM-8:45 AM: Meeting
10:00 AM-11:00 AM: Appointment

The last action outputs to Drafts rather than email for testing purposes, but you can just replace that action with the "Send Email" one you were using and it should still work.

1 Like

I copied (with much effort tho it was a learning experience) your example and the last step produced weird lengthy outputs. Then I closing the shortcut and all the actions vanished. Damn!

I downloaded the zip file and found that Shortcuts would not open the expanded .shortcuts file nor was there an option to import it. Any ideas?

Ah, I guess the shortcuts file format doesn't work with anything pre-iOS 15. Try this link and see if that does the job:

https://www.icloud.com/shortcuts/56f1a308c8204433b732808ae8fb22cd

1 Like

Great, it works! Thank you!!!

Found out that you can add a "Run Shortcut" action to add an existing shortcut to the Automations section. Also needed to use (Send "If Result" to (my email address)) to get the correct output into an email.

I'd gladly send you a cup of coffee (if you like coffee) if you had a link. Might be a nice practice/option to have in the forum...

1 Like

Heh. I might take you up on that if there was a safe and practical way to tip one another beverages here, but in lieu of that, I'll settle for the satisfaction of helping and learning something new :slightly_smiling_face:

1 Like

I poked around and found https://www.buymeacoffee.com (requires setting up an account there and sharing a link), so not 'here.' Also found an app https://getnack.com (requires installing an app on phone or tablet and adding friends) which looks about as simple as is currently available and also not 'here'.

I went to the Meta Discourse site where it was suggested to pay someone to develop that service for a Discourse instance. Giving Beverage Tip - #2 by IAmGav - feature - Discourse Meta.

From the idea that this and other forums are basically opportunities for contributions, it's interesting that an opportunity to give back isn't baked in. :thinking:

While outside your conditions, I'd be glad to set up a Nack account and try it out with you if you're willing. The biggest unknown is that redeeming a coffee is dependent on where you are and if there are coffee shops in your area that work with it.

It also requires putting in a credit card, and there isn't much out there to vouch for the company's security record.

Hi,

I needed something similar and your post was helpful. Even so, it was way too hard to figure out!

But I did. And now I will share. :slightly_smiling_face:

The problem I was having with the shortcut above is is that the text would get added within the loop so I'd see:

Item A
Item A
Item B
Item A
Item B
Item C
Item A
Item B
Item C
Item D
Item A
Item B
Item C
Item D
Item E

...and so on. So, after lots of trial and error, I rewrote it so the text got added outside the IF statement and that worked.

I also needed it to come from a specific calendar so I changed the Get Calendar Action at the top.

Anyway... this should help someone save the headaches I had!

Screenshot 2022-10-27 at 2.44.18 PM

I then access this in Keyboard Maestro...