Get credentials
1
Register an OAuth App
Go to github.com/settings/applications/new (personal account) or Organization Settings > Developer Settings > OAuth Apps for an org app.- Application name: your app name
- Homepage URL:
https://example.com - Authorization callback URL:
https://auth.example.com/auth/oauth/callback/github
GitHub also supports GitHub Apps, which have more granular permissions and work across organizations. OAuth Apps are simpler for sign-in use cases.
Configuration
- Basic
- With extra scopes
lib/theauth.ts
Scopes
Default scope:user:email
User data returned
Related
OAuth overview
Generic OAuth 2.0 setup and account linking behavior.
GitLab
OAuth 2.0 for GitLab, including self-hosted instances.
Sign in with Google using OIDC.
Authentication overview
All sign-in methods available in theAuth.