1.0.3 • Published 3 years ago
@hgc-ab/oauth-service v1.0.3
@hgc-ab/oauth-service
Oauth2 Library for Node.js
Usage
Install
npm i @hgc-ab/oauth-service
Config
This library used @hgc-ab/debug-service package for debug statements and if you want enabled it use .env files to set environment variables as below.
# Set any value to enforce debugging
DEBUG="@hgc-ab/oauth-service:*"
Note: .env files requires that you load them as early in your code as possible, see example below.
// Load env variables early
require('dotenv').config()
const Server = require('@hgc-ab/oauth-service')
const { Request, Response } = Server
// Your data model API
const model = {}
// Your new created Oauth 2 Server instance
const oAuth2Server = new Server(model)
Features
The @hgc-ab/oauth-service utilizes authorization server endpoints:
- Authorization endpoint, used by the client to obtain authorization grant from the resource owner.
- Token endpoint, used by the client to exchange an authorization grant for an access token, typically together with client authentication.
- Redirection endpoint - used by the authorization server to return responses containing authorization grant to the client via the resource owner user-agent.
For more information;
License
MIT
1.0.3
3 years ago
1.0.2
3 years ago
1.0.1
3 years ago
1.0.0
3 years ago
0.0.22
3 years ago
0.0.21
3 years ago
0.0.20
3 years ago
0.0.19
4 years ago
0.0.17
4 years ago
0.0.18
4 years ago
0.0.16
4 years ago
0.0.15
4 years ago
0.0.14
4 years ago
0.0.13
4 years ago
0.0.12
4 years ago
0.0.11
4 years ago
0.0.10
4 years ago
0.0.9
4 years ago
0.0.8
4 years ago
0.0.7
4 years ago
0.0.6
4 years ago
0.0.5
4 years ago
0.0.4
4 years ago
0.0.3
4 years ago
0.0.2
4 years ago