Name: auth-routes
Owner: Probot
Description: null
Created: 2018-04-04 18:29:24.0
Updated: 2018-04-05 21:38:49.0
Pushed: 2018-04-05 02:05:35.0
Homepage: null
Size: 3
Language: JavaScript
GitHub Committers
User | Most Recent Commit | # Commits |
---|
Other Committers
User | Most Recent Commit | # Commits |
---|
Helpful authentication routes for Probot Apps
t authRoutes = require('probot-auth')
le.exports = robot => {
nst app = robot.route()
thRoutes(app)
Or pass some options:
thRoutes(app, {
loginURL: '/log-me-in',
callbackURL: '/call-me-back'
You will need to set your app's CLIENT_ID
and CLIENT_SECRET
environment variables, or you can pass them manually in the options.
| Name | Description | Default |
| ——- | ———– | ——- |
| loginURL
| Login path | '/login'
|
| callbackURL
| Authorization callback URL, for your GitHub App | '/login/cb'
|
| afterLogin
| Where users are redirected to after they've logged in | '/'
|
| client_id
| GitHub App's Client ID | process.env.CLIENT_ID
|
| client_secret
| GitHub App's Client Secret | process.env.CLIENT_SECRET
|