# Discourse Salesforce

**URL:** https://meta.discourse.org/t/discourse-salesforce/218267
**Category:** Plugin
**Tags:** official, salesforce
**Created:** [8 במרץ,‏ 2022,‏ 2:28am UTC](https://meta.discourse.org/t/discourse-salesforce/218267 "2022-03-08T02:28:07Z")
**Posts on this page:** 1
**Showing post:** 1

<div class="post-metadata">

### Author: ![Discourse](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/discourse/32/148734_2.png) [@Discourse](https://meta.discourse.org/u/Discourse)
#### Post date: [8 במרץ,‏ 2022,‏ 2:28am UTC](https://meta.discourse.org/t/discourse-salesforce/218267/1 "2022-03-08T02:28:07Z")

</div>

| | | |
| --- | --- | --- |
| :discourse2: | **Summary** | **Discourse Salesforce** allows synchronization between Discourse Users and Salesforce leads/contacts, and enables Salesforce Social Login |
| 🛠 | **Repository Link** | [https://github.com/discourse/discourse-salesforce](https://github.com/discourse/discourse-salesforce) |
| 📖 | **Install Guide** | [How to install plugins in Discourse](https://meta.discourse.org/t/install-plugins-in-discourse/19157) |

> [@](#):
>
> :discourse2: As this is an #official plugin maintained by the Discourse team, #Support, #Contribute > Bug, #Contribute > UX, and #Contribute > Feature requests can be made in the respective categories here on Meta, and tagged with the appropriate plugin tag. Click on a link below to get one started. 👍
> 
> [❓&nbsp; **Support**](https://meta.discourse.org/new-topic?category_id=6&body=%3E%20Before%20asking,%20did%20you%20search%20first%3F%20Press%20%F0%9F%94%8D%20at%20the%20upper%20right%20to%20search.&tags=salesforce "Ask for support on configuring and using Discourse Salesforce") [🐛&nbsp; **Bug**](https://meta.discourse.org/new-topic?category_id=1&tags=salesforce "A bug report means something is broken, preventing normal/typical use of the plugin") [👀&nbsp; **UX**](https://meta.discourse.org/new-topic?category_id=9&tags=salesforce "Discussion about the user interface of Discourse Salesforce, and how features are presented (including language and UI elements)") [💡&nbsp; **Feature**](https://meta.discourse.org/new-topic?category_id=2&tags=salesforce "Discussion about how existing Discourse Salesforce features can be improved or enhanced, and how proposed new features could work")

### Sync between Salesforce leads/contacts & Discourse users

You can create a Salesforce Lead or Contact from any Discourse user using the post menu. To easily distinguish those users it will display a poster icon next to the username in posts. There will be linkbacks to these Discourse user profiles in corresponding Salesforce objects.

These created Leads and Contacts are automatically added into Discourse user groups.

 ![salesforce groups](https://global.discourse-cdn.com/meta/original/4X/f/a/5/fa581b8e8d30c77cbe02107f0e6864bbc8f69527.jpeg)

When Leads or Contacts create new topics, they will be added as a feed item in Chatter.

### Sync between Salesforce cases & Discourse topics

You can create a Salesforce Case for any Discourse topic from the topic admin menu. The topic author will automatically be created as a Salesforce Contact.

### Log in with Salesforce (OAuth)

This plugin will also allows Login with Salesforce, making it easier for your Salesforce users to sign up on Discourse.

### Configuration

Steps 1 to 3 cover setup on your Salesforce Console using the new ([2025](https://help.salesforce.com/s/articleView?id=release-notes.rn_security.htm&release=250&type=5)) External Client App Manager. Steps 4 and 5 cover setup on our Discourse Salesforce Plugin.

#### Step 1: Get to the External Client App Manager

Hit **Setup** in the cog at the top right. Search for “ **External Client App Manager”**.

> **📸**
>
> ![Screenshot 2025-10-03 at 1.38.01 AM](https://global.discourse-cdn.com/meta/original/4X/e/0/1/e014f505350a80ba6440fe7c2f1382f0c3274b6c.jpeg)  
> ![Screenshot 2025-10-03 at 1.38.22 AM](https://global.discourse-cdn.com/meta/original/4X/c/b/b/cbb334b82d91d0dc90d0116f8ea48815043c5ac9.jpeg)

#### Step 2: Create New External Client App

Fill in “Basic Information”, then enable OAuth Settings.

The callback URL should be

- https://\<your-discourse-site\>
- https://\<your-discourse-site\>/auth/salesforce/callback

Add these Available OAuth Scopes

- Access the identity URL service (id, profile, email, address, phone)
- Manage user data via APIs (api)
- Perform requests at any time (refresh\_token, offline\_access)

In Flow Enablement

- Enable Client Credentials Flow
- Enable JWT Bearer Flow (This is for creating leads and contacts)
  - [Generate a certificate](https://developer.salesforce.com/docs/atlas.en-us.sfdx_dev.meta/sfdx_dev/sfdx_dev_auth_key_and_cert.htm)
  - upload the `server.crt` file (this walkthrough assumes you would generate a `server.crt` and `server.key` file)
  - Keep the `server.key` file for your site

Save.

> **📸**
>
> ![Screenshot 2025-10-03 at 2.43.42 AM](https://global.discourse-cdn.com/meta/original/4X/4/1/1/411f124c5d06f3abe374363f8564d0c9364cbc3f.jpeg)  
> ![Screenshot 2025-10-03 at 1.47.53 AM](https://global.discourse-cdn.com/meta/original/4X/a/5/0/a50963f9bca515c220c02763625d4da7949276cb.jpeg)  
> ![Screenshot 2025-10-03 at 1.56.00 AM](https://global.discourse-cdn.com/meta/original/4X/c/c/a/cca0f63b1e21d57f4dbbcf0fe7fbf9eb89e70ef1.jpeg)

#### Step 3: Get the new External Client App’s Consumer secrets

On the newly created External Client App, go to the Settings tab then scroll down to expand OAuth Settings.

Click on “Consumer Key and Secret”, fill in login credentials again and then move on to the next step.

> **📸**
>
> ![Screenshot 2025-10-03 at 1.56.44 AM](https://global.discourse-cdn.com/meta/original/4X/3/b/6/3b6b7f038cd202bdfa7ec5682acc7ff49e09b46d.jpeg)

#### Step 4: Fill up details in Discourse Salesforce plugin settings

Head to `https://<your-discourse-site>/admin/plugins/discourse-salesforce/settings`

There are six + one settings to update

- Check “salesforce enabled”
- Check “salesforce login enabled”
- Fill in “salesforce client id” using the Consumer Key from previous step
- Fill in “salesforce client secret” using the Consumer Secret from previous step
- Fill in “salesforce rsa private key” with the `server.key` file that you generated above
- Fill in “salesforce username” with an admin email in your Salesforce org. This must be a System Administrator in [Salesforce](https://discourse-dev-ed.lightning.force.com/lightning/setup/ManageUsers/home).
- If you have a custom salesforce domain: salesforce authorization server url

#### Step 5: Authorize your Discourse app for Salesforce

Go to `https://<your-discourse-site>/salesforce/admin/authorize`

You will be prompted to authorize the app.

> **📸**
>
> ![Screenshot 2025-10-03 at 2.11.17 AM](https://global.discourse-cdn.com/meta/original/4X/1/1/1/1117d3c4bccfc5a747fdf309e7c2e3fc81faa1c5.jpeg)

> :discourse2: Hosted by us? This plugin is available on our Enterprise plans.

> Last edited by @nat 2025-10-10T18:11:41Z
> 
> > **Check document**
> >
> > Perform check on document:

---

_[View the full topic](https://meta.discourse.org/t/discourse-salesforce/218267)._
