The Automated Time Blocking Tool allows users to automatically block time in their Google Calendar for additional tasks after existing events. By leveraging the Google Calendar API, this tool ensures that your calendar is always updated and optimized for productivity.
- Google Calendar Integration: Connects directly to your Google Calendar for event management.
- Automatic Time Blocking: Automatically creates a focused work block after existing calendar events.
- OAuth 2.0 Authentication: Simplifies login using a saved
token.json
file. - Dynamic Scheduling: Adjusts new blocks based on the current schedule to avoid conflicts.
- Python 2.7: Ensure Python 2.7 is installed on your system.
- Google Calendar API Credentials: Download
credentials.json
from the Google Developer Console.
- Install the required Python libraries:
pip install --upgrade google-api-python-client oauth2client httplib2
- Place
credentials.json
in the same directory as the script.
- Execute the script:
python time_blocker.py
- On the first run, the tool will prompt you to log in to your Google account and authorize access to your calendar.
- A
token.json
file will be created for future use.
Upon running the tool, you might see the following output:
============================================
Automated Time Blocking Tool (Python 2.7)
============================================
Fetching upcoming events...
Existing event: Team Meeting
Start: 2024-12-24T10:00:00Z, End: 2024-12-24T11:00:00Z
Created event: Work Block - Focused Time