{"id":13840743,"url":"https://github.com/KrishGarg/OAuth2-Discord-ExpressJs","last_synced_at":"2025-07-11T09:33:02.397Z","repository":{"id":59256095,"uuid":"410024140","full_name":"KrishGarg/OAuth2-Discord-ExpressJs","owner":"KrishGarg","description":"An example express js app to handle OAuth2 with discord without passportjs.","archived":false,"fork":false,"pushed_at":"2022-09-18T19:18:24.000Z","size":56,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2024-08-05T17:25:39.261Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/KrishGarg.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-09-24T16:02:41.000Z","updated_at":"2022-09-16T20:38:23.000Z","dependencies_parsed_at":"2023-01-18T13:46:03.894Z","dependency_job_id":null,"html_url":"https://github.com/KrishGarg/OAuth2-Discord-ExpressJs","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/KrishGarg%2FOAuth2-Discord-ExpressJs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/KrishGarg%2FOAuth2-Discord-ExpressJs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/KrishGarg%2FOAuth2-Discord-ExpressJs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/KrishGarg%2FOAuth2-Discord-ExpressJs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/KrishGarg","download_url":"https://codeload.github.com/KrishGarg/OAuth2-Discord-ExpressJs/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":225712693,"owners_count":17512460,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-04T17:00:54.812Z","updated_at":"2024-11-21T10:30:43.233Z","avatar_url":"https://github.com/KrishGarg.png","language":"JavaScript","funding_links":[],"categories":["Web Development"],"sub_categories":[],"readme":"# Discord OAuth2 with ExpressJs and Axios\n\nThis is a sample app on how you can implement discord oauth2 on the backend.\n\n# Clean Version\n\nThere is a [clean version](https://github.com/KrishGarg/OAuth2-Discord-ExpressJs/tree/clean) of this code in which all the comments from index.js has been removed which you can clone if you want to work with the code and not want to clean up the comments manually.\n\nTo clone just that branch, you can use [degit](https://github.com/Rich-Harris/degit). By using degit, it won't clone the git history and the other branches, so it will be much cleaner and quicker.\n\n```\nnpx degit KrishGarg/OAuth2-Discord-ExpressJs#clean\n```\n\n## Environment Variables:\n\n|   Variable    | Default | Description                                        | Required? |\n| :-----------: | ------- | -------------------------------------------------- | --------- |\n|   CLIENT_ID   | None    | Client ID of the application.                      | Yes       |\n| CLIENT_SECRET | None    | Client Secret of the application.                  | Yes       |\n|  OAUTH2_URL   | None    | OAuth2 URL of the application.                     | Yes       |\n| REDIRECT_URL  | None    | {api_host}/api/discord/callback                    | Yes       |\n|     SCOPE     | None    | Scoped you want to use. Example: guilds%20identify | Yes       |\n|     PORT      | 3000    | The port on which the app would listen to.         | No        |\n\nYou can get all the above constants from [discord developer portal](https://discord.com/developers/applications). For detailed information on the available scopes, you can checkout the [discord documentation](https://discord.com/developers/docs/topics/oauth2#shared-resources-oauth2-scopes).\n\nThe [index.js](https://github.com/KrishGarg/OAuth2-Discord-ExpressJs/blob/master/index.js) file is well commented/documented.\n\n---\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FKrishGarg%2FOAuth2-Discord-ExpressJs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FKrishGarg%2FOAuth2-Discord-ExpressJs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FKrishGarg%2FOAuth2-Discord-ExpressJs/lists"}