npm-login-oauth
v1.0.0
Published
A package for Oauth link creation function
Downloads
2
Readme
npm-login-oauth
A package for oauth login url creation
Install
npm install npm-login-oauth
Usage
const loginOauth = require("npm-login-oauth");
let oauthbaseURL = "Oauth Base URL"; // Replae oauth base url
let oauthClientId = "Oauth Client Id"; // Replae oauth client id
let redirectURI = "Redirection URL"; // Replace redirection url after login
let loginOauthURLObj = loginOauth.loginOauth.loginLink(oauthbaseURL, oauthClientId, redirectURI);
if(loginOauthURLObj.status=='200'){
windows.location = loginOauthURLObj.url;
}else{
console.log(loginOauthURLObj.message); //loginOauthURLObj.message contains error message.
}