# Help implementing SSO

**URL:** <https://meta.discourse.org/t/help-implementing-sso/64540>\
**Category:** Product Support\
**Created:** [June 15, 2017, 10:32am UTC](https://meta.discourse.org/t/help-implementing-sso/64540 "2017-06-15T10:32:46Z")\
**Posts on this page:** 19\
**Page:** 1

<div class="post-metadata">

**Author:** ![Kwame\_Iwegbue](https://avatars.discourse-cdn.com/v4/letter/k/bbce88/32.png) [@Kwame\_Iwegbue](https://meta.discourse.org/u/Kwame_Iwegbue)\
**Post date:** [June 15, 2017, 10:32am UTC](https://meta.discourse.org/t/help-implementing-sso/64540/1 "2017-06-15T10:32:46Z")

</div>

Are you able to provide some assistance with adding Single Sign On to my Discourse instance? I have a website with existing clients, and I would like to add a button to my discourse community that allows them log in/register with their existing credentials. Thanks.

---

<div class="post-metadata">

**Author:** ![codinghorror](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/codinghorror/32/110067_2.png) [@codinghorror](https://meta.discourse.org/u/codinghorror)\
**Post date:** [June 15, 2017, 11:25am UTC](https://meta.discourse.org/t/help-implementing-sso/64540/2 "2017-06-15T11:25:20Z")

</div>

Follow the official sso topic in the #howto category.

---

<div class="post-metadata">

**Author:** ![Kwame\_Iwegbue1](https://avatars.discourse-cdn.com/v4/letter/k/ea5d25/32.png) [@Kwame\_Iwegbue1](https://meta.discourse.org/u/Kwame_Iwegbue1)\
**Post date:** [June 15, 2017, 12:31pm UTC](https://meta.discourse.org/t/help-implementing-sso/64540/3 "2017-06-15T12:31:59Z")

</div>

Thanks Jeff. I think I may have asked the wrong question. I do not want to replace the existing auth options ie Google, Facebook, Email form, etc. I want to add another button which allows the user also use their existing credentials on my site. Your official SSO topic suggests using OmniAuth:  
[https://github.com/omniauth/omniauth](https://github.com/omniauth/omniauth)

My Discourse instance is hosted by you guys, so how would I implement this?

Thanks

---

<div class="post-metadata">

**Author:** ![blake](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/blake/32/157322_2.png) [@blake](https://meta.discourse.org/u/blake)\
**Post date:** [June 15, 2017, 2:33pm UTC](https://meta.discourse.org/t/help-implementing-sso/64540/4 "2017-06-15T14:33:08Z")

</div>

Sounds like you will need to use the [oauth2 plugin](https://meta.discourse.org/t/oauth2-basic-support/33879) this is only available on the business/enterprise plans. If you are on the standard plan just lets us know and we can upgrade you to business.

---

<div class="post-metadata">

**Author:** ![Kwame\_Iwegbue1](https://avatars.discourse-cdn.com/v4/letter/k/ea5d25/32.png) [@Kwame\_Iwegbue1](https://meta.discourse.org/u/Kwame_Iwegbue1)\
**Post date:** [June 15, 2017, 2:59pm UTC](https://meta.discourse.org/t/help-implementing-sso/64540/5 "2017-06-15T14:59:35Z")

</div>

Ok, please upgrade to the business plan.

---

<div class="post-metadata">

**Author:** ![blake](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/blake/32/157322_2.png) [@blake](https://meta.discourse.org/u/blake)\
**Post date:** [June 15, 2017, 3:03pm UTC](https://meta.discourse.org/t/help-implementing-sso/64540/6 "2017-06-15T15:03:06Z")

</div>

Unlisted on June 15, 2017, 3:03pm UTC



---

<div class="post-metadata">

**Author:** ![blake](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/blake/32/157322_2.png) [@blake](https://meta.discourse.org/u/blake)\
**Post date:** [June 15, 2017, 3:03pm UTC](https://meta.discourse.org/t/help-implementing-sso/64540/7 "2017-06-15T15:03:37Z")

</div>

What is the name of your site? I can’t seem to find it by your name or email in our system?

---

<div class="post-metadata">

**Author:** ![Kwame\_Iwegbue1](https://avatars.discourse-cdn.com/v4/letter/k/ea5d25/32.png) [@Kwame\_Iwegbue1](https://meta.discourse.org/u/Kwame_Iwegbue1)\
**Post date:** [June 15, 2017, 3:33pm UTC](https://meta.discourse.org/t/help-implementing-sso/64540/8 "2017-06-15T15:33:54Z")

</div>

The site is [https://community.gene.chat](https://community.gene.chat)

---

<div class="post-metadata">

**Author:** ![blake](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/blake/32/157322_2.png) [@blake](https://meta.discourse.org/u/blake)\
**Post date:** [June 15, 2017, 4:07pm UTC](https://meta.discourse.org/t/help-implementing-sso/64540/9 "2017-06-15T16:07:08Z")

</div>

Okay you are now on the business plan!

 ![](https://global.discourse-cdn.com/meta/original/3X/8/2/8218ba5967b581d16e9a277c996e5445cbf29aa7.png)

---

<div class="post-metadata">

**Author:** ![Kwame\_Iwegbue1](https://avatars.discourse-cdn.com/v4/letter/k/ea5d25/32.png) [@Kwame\_Iwegbue1](https://meta.discourse.org/u/Kwame_Iwegbue1)\
**Post date:** [June 15, 2017, 4:24pm UTC](https://meta.discourse.org/t/help-implementing-sso/64540/10 "2017-06-15T16:24:26Z")

</div>

Cool. So how do we implement the oath2 plugin?

Kwame

---

<div class="post-metadata">

**Author:** ![blake](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/blake/32/157322_2.png) [@blake](https://meta.discourse.org/u/blake)\
**Post date:** [June 15, 2017, 4:51pm UTC](https://meta.discourse.org/t/help-implementing-sso/64540/11 "2017-06-15T16:51:50Z")

</div>

Take a look at this guide:

> [@Discourse OAuth2 Basic](https://meta.discourse.org/t/oauth2-basic-support/33879):
>
> discourse2Summary Discourse OAuth2 Basic supports basic OAuth2 providers, assuming they have a JSON API endpoint where user details can be retrieved by token.open_bookInstall Guide This plugin is bundled with Discourse core. There is no need to install the plugin separately. Features This plugin allows you to use a basic OAuth2 provider as authentication for Discourse. It should work with many providers, with the caveat that they must provide a JSON endpoint for retri…

The plugin has been installed and you can change the settings for it in your admin site settings. You will need to update it with values from your OAuth2 provider.

---

<div class="post-metadata">

**Author:** ![Kwame\_Iwegbue](https://avatars.discourse-cdn.com/v4/letter/k/bbce88/32.png) [@Kwame\_Iwegbue](https://meta.discourse.org/u/Kwame_Iwegbue)\
**Post date:** [June 15, 2017, 5:28pm UTC](https://meta.discourse.org/t/help-implementing-sso/64540/12 "2017-06-15T17:28:42Z")

</div>

I still have no idea how to do this. Like I said in my earlier email, the website that I am trying to authenticate with is my existing website (app engine site). It does not have OAath endpoints so how will I implement this. Do I need to build my own OAuth implementation from scratch and add it to my web site!

---

<div class="post-metadata">

**Author:** ![blake](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/blake/32/157322_2.png) [@blake](https://meta.discourse.org/u/blake)\
**Post date:** [June 15, 2017, 6:00pm UTC](https://meta.discourse.org/t/help-implementing-sso/64540/13 "2017-06-15T18:00:36Z")

</div>

Yes, your existing app will have to implement OAuth.

---

<div class="post-metadata">

**Author:** ![Kwame\_Iwegbue1](https://avatars.discourse-cdn.com/v4/letter/k/ea5d25/32.png) [@Kwame\_Iwegbue1](https://meta.discourse.org/u/Kwame_Iwegbue1)\
**Post date:** [June 15, 2017, 7:32pm UTC](https://meta.discourse.org/t/help-implementing-sso/64540/14 "2017-06-15T19:32:09Z")

</div>

So my app uses app engine, Python. Do you have any sample code I might use to get started?

---

<div class="post-metadata">

**Author:** ![mpalmer](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/mpalmer/32/45740_2.png) [@mpalmer](https://meta.discourse.org/u/mpalmer)\
**Post date:** [June 16, 2017, 1:28am UTC](https://meta.discourse.org/t/help-implementing-sso/64540/15 "2017-06-16T01:28:57Z")

</div>

Sorry, we’re all ruby developers. DuckDuckGo suggests this might be a good place to start:

[https://github.com/joestump/python-oauth2](https://github.com/joestump/python-oauth2)

---

<div class="post-metadata">

**Author:** ![robbyoconnor](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/robbyoconnor/32/120330_2.png) [@robbyoconnor](https://meta.discourse.org/u/robbyoconnor)\
**Post date:** [June 16, 2017, 2:08am UTC](https://meta.discourse.org/t/help-implementing-sso/64540/16 "2017-06-16T02:08:54Z")

</div>

Uses the [discourse-sso](https://www.npmjs.com/package/discourse-sso) Node.js library:

> <https://github.com/openmrs-archive/openmrs-contrib-id-sso/blob/master/lib/discourse.js>

You don’t need OAuth per se.

---

<div class="post-metadata">

**Author:** ![blake](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/blake/32/157322_2.png) [@blake](https://meta.discourse.org/u/blake)\
**Post date:** [June 16, 2017, 12:23pm UTC](https://meta.discourse.org/t/help-implementing-sso/64540/17 "2017-06-16T12:23:07Z")

</div>

Yes sso would be easier to setup than oauth2, but also depends what you are trying to accomplish:

> [@Setup DiscourseConnect - Official Single-Sign-On for Discourse (sso)](https://meta.discourse.org/t/setup-discourseconnect-official-single-sign-on-for-discourse-sso/13045/1):
>
> The intention around SSO is to replace Discourse authentication

If you have sso set up you will lose your other sign in methods via google, twitter, etc.

---

<div class="post-metadata">

**Author:** ![blake](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/blake/32/157322_2.png) [@blake](https://meta.discourse.org/u/blake)\
**Post date:** [June 16, 2017, 12:30pm UTC](https://meta.discourse.org/t/help-implementing-sso/64540/19 "2017-06-16T12:30:22Z")

</div>

Also @Kwame_Iwegbue just want to make sure you knew that the business plan is $200/month since I didn’t state that earlier you can see more info on [http://discourse.org/buy](http://discourse.org/buy) if the oauth2 plugin doesn’t end up working out just let us know and we can downgrade you back to the $100/month standard plan.

---

<div class="post-metadata">

**Author:** ![Falco](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/falco/32/179432_2.png) [@Falco](https://meta.discourse.org/u/Falco)\
**Post date:** [June 16, 2017, 1:52pm UTC](https://meta.discourse.org/t/help-implementing-sso/64540/20 "2017-06-16T13:52:31Z")

</div>

> [@robbyoconnor](#):
>
> You don’t need OAuth per se.

SSO won’t allow multiple concurrent login methods, that’s the **Single** in Single Sign On.

> [@Kwame\_Iwegbue1](#):
>
> I do not want to replace the existing auth options ie Google, Facebook, Email form, etc. I want to add another button which allows the user also use their existing credentials on my site.
