-
Notifications
You must be signed in to change notification settings - Fork 20
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adding support for discord oauth verification #2710
Adding support for discord oauth verification #2710
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I left small comments but overall it looks great 👍🏼
tee-worker/client-api/parachain-api/prepare-build/interfaces/identity/definitions.ts
Show resolved
Hide resolved
tee-worker/ts-tests/integration-tests/common/utils/identity-helper.ts
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.
Is there anything setup from our Discord server?
We need to setup OAuth2 on the app we use or create a new app in the account and set it up to get the client id and client secret. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, only have some small naming questions, otherwise it looks good
This PR introduces a new option to verify discord accounts using OAuth2.0
The discord oauth 2.0 mechanism works a little differently than Twitter's, there is no need to generate a code challenge from our side so clients only need one interaction with the worker to link identities.
Just like with twitter, we need to register the redirect uri clients will use in the discord developer account.
As Kai suggested here #2641 (review), in the future, we could register these oauth clients in the parachain.
Important
DISCORD_CLIENT_ID
andDISCORD_CLIENT_SECRET
.https://discord.com/oauth2/authorize?client_id={DISCORD_CLIENT_ID}&response_type=code&redirect_uri={CLIENTS-REDIRECT-URI}&scope=identify
.