You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/02-Onboarding.md
+27-13Lines changed: 27 additions & 13 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -68,26 +68,40 @@ _`DISCORD_CLIENT_SECRET` is not required unless you need to test the discord log
68
68
69
69
You can create your own `DISCORD_CLIENT_ID` and `DISCORD_CLIENT_SECRET` by going to [Discord Developer Portal](https://discord.com/developers/docs/intro).
70
70
71
-
Under **OAuth2**
71
+
Under **[OAuth2](https://discord.com/developers/docs/topics/oauth2)**
72
+
73
+
- Set up Client Id and Client Secret [here](https://discord.com/developers/applications).
74
+
- Click on New Application in the top-right corner.
75
+
76
+
<p><imgsrc="images/discord-oauth-new-application-button.JPG"alt="screenshot of discord new application button"width="100"></p>
77
+
78
+
- After naming your app ("Together local", for example) navigate to 0Auth2 in the menu on the left.
79
+
- Click "Add Redirect" and set to `http://localhost:2121/api/auth/discord/callback`.
80
+
81
+
<p><imgsrc="images/discord-redirect-button.jpg"alt="screenshot of add discord add redirect button"width="500"></p>
82
+
83
+
- Locate Client ID right above. Click "Reset Secret" button and enter your discord password to get secret. Make sure to copy both the `client id` and the `client secret`.
84
+
85
+
<p><imgsrc="images/discord-client-secret.JPG"alt="screenshot of discord client secret section"width="500"></p>
72
86
73
-
- Set up Client Id and Client Secret
74
-
- Set the Redirects to `http://localhost:2121/api/auth/discord/callback`.
75
87
- Update .env to:
76
88
77
-
```
78
-
PORT=2121
79
-
DB_STRING=mongodb://127.0.0.1:27017/
80
-
DISCORD_CLIENT_ID=YOUR ID
81
-
DISCORD_CLIENT_SECRET=YOUR SECRET
82
-
OAUTH_REDIRECT_URL=http://localhost:3000/
83
-
MOCK_USER=false
84
-
NODE_ENV=development
85
-
```
89
+
```
90
+
PORT=2121
91
+
DB_STRING=mongodb://127.0.0.1:27017/
92
+
DISCORD_CLIENT_ID=YOUR ID
93
+
DISCORD_CLIENT_SECRET=YOUR SECRET
94
+
OAUTH_REDIRECT_URL=http://localhost:3000/
95
+
MOCK_USER=false
96
+
NODE_ENV=development
97
+
```
86
98
87
-
**To start the Test Event API, execute this command:**
99
+
To start the Test Event API, execute this command:
88
100
89
101
-`npm run dev`
90
102
103
+
Then open [localhost:3000](http://localhost:3000) and try to log in through Discord!
0 commit comments