1.5.1 • Published 1 year ago

enigmatic-breeze-auth v1.5.1

Weekly downloads
-
License
MIT
Repository
github
Last release
1 year ago

enigmatic-breeze-auth

A Node.js library for OAuth authentication.

Installation

You can install enigmatic-breeze-auth via npm:

npm install enigmatic-breeze-auth

Usage

const { initiateOAuth, completeOAuth } = require('enigmatic-breeze-auth');

// Initiating OAuth authentication process
const authorizationURL = initiateOAuth();
console.log('Authorization URL:', authorizationURL);

// Completing OAuth authentication process (sample usage)
const requestToken = 'your_request_token';
const requestTokenSecret = 'your_request_token_secret';
const verifier = 'verifier_code';

completeOAuth(requestToken, requestTokenSecret, verifier)
  .then(({ accessToken, accessTokenSecret }) => {
    console.log('Access Token:', accessToken);
    console.log('Access Token Secret:', accessTokenSecret);
  })
  .catch(err => {
    console.error('Error:', err);
  });

Replace 'your_consumer_key', 'your_consumer_secret', 'your_redirect_uri', and other placeholder values in the code with your actual OAuth configuration.

License

This project is licensed under the MIT License - see the LICENSE file for details.

1.5.1

1 year ago

1.5.0

1 year ago

1.0.0

1 year ago