You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I was working on converting the existing !addCal command to a slash command, and in the process realized trying to shoehorn this in as a command just isn't going to work, especially with WIP features such as supporting other hosting providers.
Due to the fact that in order to authorize the bot to a 3rd party website, the user would have to leave the discord client anyway, so having this done through the discal website completely would be more optimal than going back and force between the discord client and one (or multiple) websites.
The process I believe would be best is as follows:
A user with elevated permissions runs the /addcal command, if the server can add a new calendar, it will send an ephemeral message to the user with a link to discal's site; something like https://www.discalbot.com/dashboard/$guild-id/calendar/new?type=external&step=0
On that page, it will prompt the user to login to the discal site through their discord account (to verify their permission status among other things). After logging in, they will be redirected back to the page, where it will show buttons for authorizing access to the different hosts (google/apple/outlook/etc). They will be sent to the respective oauth2 pages to authorize discal access, and will once again be redirected back to discal's site at https://www.discalbot.com/dashboard/$guild-id/calendar/new?type=external&step=1 where they will be presented with a selection for all of the calendars on the account that have correct permissions for discal to work with. They can select the calendar they wish to add, and the page will confirm the selection and once the backend does its checks, tell the user that the process is complete.
If there's an error, it will be shown to the user in an alert or similar fashion to tell them what may have gone wrong.
This solves the problem of trying to stick all this logic inside of a command system and how to handle displaying calendar choices in an understandable fashion while keeping things somewhat simple.
Opinions please? Thanks~
The text was updated successfully, but these errors were encountered:
This is locked to devs only for right now until I finish the full flow that is planned in #113
I also cleaned up some code in a few places while I was messing with some stuff
I was working on converting the existing
!addCal
command to a slash command, and in the process realized trying to shoehorn this in as a command just isn't going to work, especially with WIP features such as supporting other hosting providers.Due to the fact that in order to authorize the bot to a 3rd party website, the user would have to leave the discord client anyway, so having this done through the discal website completely would be more optimal than going back and force between the discord client and one (or multiple) websites.
The process I believe would be best is as follows:
A user with elevated permissions runs the
/addcal
command, if the server can add a new calendar, it will send an ephemeral message to the user with a link to discal's site; something likehttps://www.discalbot.com/dashboard/$guild-id/calendar/new?type=external&step=0
On that page, it will prompt the user to login to the discal site through their discord account (to verify their permission status among other things). After logging in, they will be redirected back to the page, where it will show buttons for authorizing access to the different hosts (google/apple/outlook/etc). They will be sent to the respective oauth2 pages to authorize discal access, and will once again be redirected back to discal's site at
https://www.discalbot.com/dashboard/$guild-id/calendar/new?type=external&step=1
where they will be presented with a selection for all of the calendars on the account that have correct permissions for discal to work with. They can select the calendar they wish to add, and the page will confirm the selection and once the backend does its checks, tell the user that the process is complete.If there's an error, it will be shown to the user in an alert or similar fashion to tell them what may have gone wrong.
This solves the problem of trying to stick all this logic inside of a command system and how to handle displaying calendar choices in an understandable fashion while keeping things somewhat simple.
Opinions please? Thanks~
The text was updated successfully, but these errors were encountered: