sheetCalendarSync
Google App Script for synchronizing Excel
AI Summary
Sheet Calendar Sync Library
Two-way sync between Google Calendar and Sheets
Target Users
Due to limited info, beginner–intermediate devs building internal tools to automate Calendar–Sheets sync
Problems Solved
Manual updates between Calendar and Sheets are error-prone and time-consuming
Tags
Main Features
1
Structured sheet
Creates required columns and sample data to standardize event tables
2
Fetch events
Imports events from Google Calendar into an empty sheet for editing
3
Delta sync control
Only rows with Update (Y/N)=Y are processed; threshold minutes limit excessive API calls
4
All-day and timed
Supports all-day and timed events with appropriate date/time formats
5
Two-way workflow
Fetch, edit, and sync to keep Sheets and Calendar aligned
Usage Examples
The following example from the README shows the basic flow: create sheet → fetch events → sync changes.
```javascript
const sheetName = "GCal Event Sync"; // Sheet name for event management
const calendarId = "your-calendar-id@group.calendar.google.com"; // Target Calendar ID
const syncThresholdMinutes = 5; // Minimum minutes between syncs
function createSheet() {
// Create a sheet with required columns and a sample row
SheetCalendarSync.createSheetWithColumns(sheetName);
}
function syncWithCalendar() {
// Push changes for rows where Update (Y/N)=Y; throttled by threshold minutes
SheetCalendarSync.syncWithCalendar(sheetName, calendarId, syncThresholdMinutes);
}
function fetchEvents() {
// Import events from Calendar into an empty sheet (defaults: last 90 days to today)
SheetCalendarSync.fetchEventsToTable(sheetName, calendarId);
}