DjMuffinTops / Google-Calendar-API-to-Discord-Webhook

Google Apps Script to send calendar events info to a discord webhook on time

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Google-Calendar-API-to-Discord-Webhook

Copy and paste this script into a Google Cloud Apps Script project at https://script.google.com

You will need to replace CHANNEL_POST_URL and CALENDAR_ID in the script with your Discord Webhook URL and your Google Calendar's Calendar ID respectively. You can also modify minInAdvance to change the amount of minutes ahead of time the events should show up. The default value should be 1 minute.

Then, you must enable Calendar API under Services on the left side of the Apps Script Page. Click the + button next to Services and look for Calendar API and enable it. v3 of the Calendar API should work fine.

You Will then need to setup a trigger to run the postEventsToChannel function every minute image

You should see any events that will start within the next minute posted into an embed into the discord channel your webhook was on

image

About

Google Apps Script to send calendar events info to a discord webhook on time

License:MIT License


Languages

Language:JavaScript 100.0%