# Creating a Custom Social Connection for Reddit with Auth0

**URL:** <https://community.auth0.com/t/creating-a-custom-social-connection-for-reddit-with-auth0/105859>\
**Category:** Get Help\
**Tags:** custom-social-connections-branding, connections\
**Created:** [May 1, 2023, 2:55am UTC](https://community.auth0.com/t/creating-a-custom-social-connection-for-reddit-with-auth0/105859 "2023-05-01T02:55:02Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![maxhager28](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/maxhager28/32/46253_2.png) [@maxhager28](https://community.auth0.com/u/maxhager28)\
**Post date:** [May 1, 2023, 2:55am UTC](https://community.auth0.com/t/creating-a-custom-social-connection-for-reddit-with-auth0/105859/1 "2023-05-01T02:55:02Z")

</div>

I’m trying to create a custom social connection for Reddit using Auth0. Here’s what I have set up so far:

- Authorization URL: `https://www.reddit.com/api/v1/authorize`
- Token URL: `https://www.reddit.com/api/v1/access_token`
- Scope: `identity,read,submit`
- Client ID & secret taken from the Reddit app I created

I’ve also implemented the following Fetch User Profile Script:

```js
function(accessToken, ctx, cb) {
  request.get('https://oauth.reddit.com/api/v1/me', {
    headers: {
      'Authorization': 'Bearer ' + accessToken,
      'User-Agent': 'Auth0/1.0'
    }
  }, function(e, r, b) {
    if (e) return cb(e);
    if (r.statusCode !== 200) return cb(new Error('StatusCode: ' + r.statusCode));
    var profile = JSON.parse(b);
    cb(null, {
      user_id: profile.id,
      username: profile.name,
      email: profile.email || ''
    });
  });
}

```

However, when I try the connection, I get the following error:

```json
{
  "error": "invalid_request",
  "error_description": "the connection is not enabled"
}

```

I’m not sure what I need to insert into the custom header. I found [this post](https://community.auth0.com/t/how-to-create-a-custom-social-connection-for-reddit-oauth-login/8281) but I’m still having trouble defining the user profile script and the custom header. Any help would be appreciated.

---

<div class="post-metadata">

**Author:** ![dan.woda](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/dan.woda/32/18340_2.png) [@dan.woda](https://community.auth0.com/u/dan.woda)\
**Post date:** [May 3, 2023, 2:52pm UTC](https://community.auth0.com/t/creating-a-custom-social-connection-for-reddit-with-auth0/105859/3 "2023-05-03T14:52:51Z")

</div>

Hi @maxhager28,

Welcome to the Auth0 Community!

This error indicates that you have not enabled the connection for any applications. To use the “Try” function, you need to enable an application for the connection. Here’s an example of a connection’s settings with an application enabled.

 ![image](https://global.discourse-cdn.com/auth0/original/3X/3/b/3be17a58548959924e6996ad7b0aaaf6656029e5.png)

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/auth0/original/3X/b/5/b560f266932fcce5d57f09a6595bd50518cae3f3.jpeg) [@system](https://community.auth0.com/u/system)\
**Post date:** [May 17, 2023, 2:53pm UTC](https://community.auth0.com/t/creating-a-custom-social-connection-for-reddit-with-auth0/105859/4 "2023-05-17T14:53:41Z")

</div>

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.
