Discord Oauth2 Plugin


(Makary Gołosz) #17

I’m wondering… Is there a way to limit ability to log in via Discord OAuth based on server (guild)?

(Jeff Wong) #19

I now pull avatars, for both new and existing accounts (if they don’t already have a custom avatar chosen).

(Thanks for the code tour btw, it’s very helpful :wink: )

Not as it stands right now, but that’s a nice idea, definitely.

(Rhukee) #20

This would be great.

(Makary Gołosz) #21

Would it be perhaps later possible to extend extend this to regular, geberuc OAuth? I mean replacing the avatars of course.

I’ll try to investigate this.

(Jeff Wong) #22

It’s definitely possible, I have an idea of how to do it, it’ll also involve grabbing the guild scope as well. Just need some time to see the best way forward.

I’m not sure what you mean by regular generic oauth though, there’s no standard field I know about for avatar paths in auth payloads. Do you mean to have a way to set an avatar url for the basic oauth plugin?

(Makary Gołosz) #23

Sorry, I had some comunication problem.
What i meant is:
If it is posible to pull avatars via Discord OAuth, could this function be imported into OAuth2 Basic Support plugin?

(Jeff Wong) #24

Yeah it’s possible, but not standard for their logins. See the response on that here-

(Jeff Wong) #25

I just updated the plugin to support automatic approval for a specified guild. Used in tandem with must approve users setting, this meets the desired result. See the first post for updated instructions.

(Dylan Hunt) #26

Is this still under active development (or working)?

(Jeff Wong) #27

Have you tried installing it or are you running into errors signing in?

(@SenpaiMass) #28

@featheredtoast its working really good, i am running it on my community.

(Dylan Hunt) #29

Just being weary of a year old plugin, trying not to repeat my mistake when the Steam oAuth plugin was borked~ seems like someone now confirmed this Discord plugin functionality, Woot!

(@SenpaiMass) #30

Can the discourse team officially adopt this plugin as it is actively maintained by one of the team members itself!

(Jeff Atwood) #31

Sure good idea let’s ask @featheredtoast

(Jeff Wong) #32

That definitely makes sense! The plugin was built before I joined the team, but here we are… :slight_smile:

I’ll go head and migrate the repo and give it a little more official pizzazz.

(Sam Saffron) #33

Be sure to have a chat with @david there are some new interfaces you should implement. Talking of which… we need a dev #howto to cover the new changes.

(Stephen) #34

Did this get moved? The repo is still under featheredtoast and not discourse.

Edit: Scratch that, the link goes to discourse, the text shows the old path. Confusing!

(Jeff Wong) #35

Yeah, that’s really strange, I definitely edited it to be under the discourse account, maybe the link didn’t get rebaked on edit somehow


Thanks for making this plugin.
Discourse and Discord fit well together, they should partner and make this plugin basic :slight_smile:
edit: just updated to latest git repo, you had me scared for a moment there, login wasn’t working :smiley:


Hello, This seems to be somewhat broken now. Getting the following warning after most recent update (v2.2.0.beta7 +5):

Deprecation notice: enabled_setting is deprecated. Please define authenticator.enabled? instead At /var/www/discourse/lib/plugin/instance.rb:514:in block (2 levels) in auth_provider

So the Discord button is also not showing up on the login screen, I assume as a result of the above warning.

Thank you for the awesome plugin :slight_smile: