remi-espie/yet-another-discord-webhook-planner
Yet Another Discord Webhook Planner is a simple discord webhook dropping a message with info of today's and tomorrow's events
๐ Yet Another Discord WebHook Planner
What is this โ
This is a simple Discord WebHook Planner ๐ , which allows you to fetch your events from a .ics online and display them in Discord through a webhook.
It displays 2 categories of events:
- courses, which are displayed as a list of events for the current day. It also displays the hour of the first and last event of this category.
- important, which are important events that are displayed as a list of events for the current day.
Moreover, it displays the events of today and tomorrow, but only if there are events for these days.
Besides, it displays a weather forecast for the day.
Else, it doesn't send a message.
It uses a .env file which contains your personal data, see .env.example:
๐ Getting started
Get a correct .ics !
This little script is made to work with specifics .ics file; it assumes that your relevant events:
- are in the
VEVENTsection of the file, and that theSUMMARYfield contains the name of the event. - have the property
CATEGORIESset toCoursif it is a course, orImportantif it is an important event.
I personally used Calendar.online as it is free, allow to fetch multiple data sources and can be edited by anyone from a link without login.
OpenMeteo
The script also fetch the weather for the day and the following day from OpenMeteo. As OpenMeteo is API-key free, it is not necessary to get one.
Get Go or see releases
First import the dependencies with go get -d ./....
Then update the .env file with your own data:
WEBHOOK_URL= # Your webhook URL
ICS_URL= # Your .ics URL
AVATAR_URL= # Your avatar URL
LONGITUDE= # The longitude of where you'd like to know the weather
LATITUDE= # The latitude of where you'd like to know the weather
Finally just run go run main.go and it will fetch the set ics and sent the data to your webhook.
You could also build it with go build main.go and run it with ./main.
The only release available was built with and for Linux x86_64.
๐ License
This project is under the MIT License - see the LICENSE file for details.
๐ป Dependencies for nerds
Developed with GO 19
And the following dependencies: