Add events that automatically take a free slot on your calendar based on how you want it. You can change the following settings for each new event:
Event-Duration
Shrinking: An event can try to shrink down to a specified minimum duration in case there is no fitting slot for the full duration.
Deadline: Events will get planned only before the defined deadline. If there is no fitting slot before the deadline, Calendar Agent will warn you.
Priority: Important events can claim slots of other, less important events if necessary.
Pre/Post Timeblock: Block time before your event starts or after it ends.
Allowed Days: The event will only be scheduled on the selected days.
Assigned Categories: see below under "Settings"
Calendar: The calendar in which to schedule the event.
Tasks
A Task adds daily Rearrange Events (work sessions) over a specified period of time and is perfect for longer projects. There are the following settings:
Task Duration: The total duration you need for your task.
Task Deadline: Work sessions will get planned only before the defined deadline. If there is no fitting slot before the deadline, Calendar Agent will warn you.
Task Priority: Important work sessions can claim slots of other, less important events if necessary.
Session Duration: Minimum and maximum duration for each work session. If you set a task duration as well as a task deadline, the necessary duration for each work session will be suggested/calculated based on those two settings and the selected days.
Session Pre/Post Timeblock: Block time before your work session starts or after it ends.
Session Rearrange Limit: By default, if a daily work session collides with other events, it will get rearranged to the next best slot. This slot could be on any day within the Operation Days. Optionally you can limit the rearranging of work sessions only to the scheduled day of the work session.
Allowed Days: Work sessions will only be scheduled on the selected days.
Assigned Categories: see below under "Settings"
Calendar: The calendar in which to schedule the work sessions.
Fixed Event
Create a regular, fixed Calendar Event that won't get rearranged.
Habits
Habits are reocurring events (like meals, workouts, time for meditating, naps, etc.). You can set up the following options:
Preferred Time: When should the habit take place ideally.
Duration: How much time do you need for the habit.
Pre/Post Timeblock: Block time before your habit starts or after it ends.
Protected: By default, habits get deleted if there is not enough time left on the day in question. A protected habit will defend its place.
Allowed Days: The habit will only be scheduled on the selected days.
Assigned Categories: see below under "Settings"
Calendar: The calendar in which to schedule the habit.
Edit Tasks
Edit your existing tasks, for example in case you need more time for a project.
Exclude Slot
Exclude a Timeslot so that no events will get scheduled within that timeslot.
Settings
Operation Days: The amount of days Calendar Agent will plan ahead.
Active Calendars: The calendars used for creating events, tasks and habits.
Collision Calendars: The calendars used for calculating free timeslots and collisions.
Categories: Categories are defined timeslots on a day (for example the category "Morning" could be set to 09:00 to 12:00). Each event, task or habit gets assigned to one or more categories. Events of a category are only scheduled within those timeslots.
Preset for new events, tasks and habits: Set up a preset for the selected days and categories to create events even faster.
Rearrange Mode: By default, everytime you close your calendar app, Calendar Agent checks and resolves new collisions. You can change this for each device. Calendar Agent could alternatively ask you if you changed something (this reduces battery drain), or you could disable it entirely.
Step 1
Calendar Agent requires iOS 16 (and above) or macOS 13 (and above). Make sure that your operation systems are compatible.
On all devices where you plan to use Calendar Agent, make sure the app Shortcuts is allowed to run shortcuts that share large amounts of data and delete without confirmation.
On macOS, open the Shortcuts app and open the settings. You can find the mentioned options under "Advanced". On iOS, you can find the options in the Settings app of your iPhone under "Shortcuts" -> "Advanced".
Step 2
Download the installer for the latest version:
Run it in your Shortcuts app and let it guide you through the installation process. If you have iCloud Sync enabled for Shortcuts (recommended), only run the installer on one device (preferably on macOS if possible, as the installation process on macOS is a lot faster and easier).
Step 3
After finishing the installation, run the shortcut "Calendar Agent" to start the initial setup of Calendar Agent. This process works the same on any device.
Step 4
Choose and set up the way you want to open the main menu (The shortcut named "Calendar Agent"). Here are a few options for you to consider:
You can add the shortcuts widget to your homescreen.
However, it might be cleaner to add the shortcut directly to your homescreen. You can place it next to your calendar app for fast access.
Another option is to use the double or triple tap function. You can find it within "Accessibility" in the Settings app of your iPhone.
You can add the shortcut "Calendar Agent" to your dock. Right-click the shortcut and choose the option. You can place it next to the calendar app.
Also, you can add a keyboard shortcut that executes the "Calendar Agent" shortcut. You can add it in different ways: For example within the shortcuts app in the settings of given shortcut, in the settings of macOS under the Keyboard options or you could use the third party app Shortery that plays a part later in this installation.
Step 5
Now we need to create automations for the shortcut "CA - Closing App Automation". This shortcut should get executed on any device you are using Calendar Agent with each time the calendar app gets closed/quit.
Go to your Shortcuts app and add a new personal automation. Select "App" and then choose the Calendar.Select only the "when closed" option. Then add the action to execute a shortcut. Select the shortcut "CA - Closing App Automation". Disable "Confirm before running" and then add the automation.
You can use the free version of the third-party app Shortery.
Add a new Shortcut Trigger, select "Application" as trigger type and choose a name for the trigger. Select the shortcut named "CA - Closing App Automation". Select the application "Calendar" and choose "App is Quit". Save your trigger.
Step 6
For the "CA - Cronjob Automation" shortcut, adding an automation on just one device (peferably an iPhone) is sufficient.
Add another personal automation in the Shortcuts app. This time, we need to create a time-based automation that should get executed once a day. The exact time on the day does not matter (as in the beginning there will be a few privacy prompts you need to allow, you could add it somewhere in the morning.). Then add the action to execute a shortcut and select "CA - Cronjob Automation". Disable "Confirm before running" and then add the automation.
If you only have a Mac and no iPhone, you have two options to add the time-based automation on macOS.
Option 1: You could use the paid version of Shortery: Select "Time" as trigger type and choose a name. Select the shortcut "CA - Cronjob Automation", then select "Every Day" and choose a time. Leave the option "Don't skip" checked.
Download the AppleScript to run "CA - Cronjob Automation":
Save it somewhere on your computer and copy the filepath to it. Then open the Terminal and type: crontab -e Enter i
Then add the following line: 0 10 * * * osascript ""
Change the 0 to the minute and the 10 to the hour you want to execute the shortcut. Paste your filepath between the "".
Type: esc :wq Enter
Accept and you are done. You can verify your crontabs with crontab -l. Remove a crontab using the same procedure again and removing the line.
Now everything is set up.
Run the shortcut "Calendar Agent" to begin setting up your tasks and habits. Take some time to try out every function. Due to the Shortcuts app's privacy design, there will be many prompts at the beginning asking for your permission to do certain things. But if you click "Always allow" on these, they will quickly decrease and eventually disappear completely, leaving the Calendar Agent working in the background without bothering you any further.
I wish you productive planning!
A lot of time, effort, work and thought went into this project - so if you enjoy Calendar Agent, a small donation would be greatly appreciated. With your help I can continue working on this project and the next version. Thanks!
In the near future you will find tutorials on how to use all functions of Calendar Agent here.