multipassify

Shopify Multipass module for Node.js

Showing:

Popularity

Downloads/wk

6.5K

GitHub Stars

59

Maintenance

Last Commit

5yrs ago

Contributors

1

Package

Dependencies

1

Size (min+gzip)

0.6KB

License

Type Definitions

Tree-Shakeable

No?

Categories

Readme

multipassify

Shopify Multipass module for Node.js

Shopify provides a mechanism for single sign-on known as Multipass. Multipass uses an AES encrypted JSON hash and multipassify provides functions for generating tokens

More details on Multipass with Shopify can be found here.

Installation

    npm install multipassify

Usage

To use Multipass an Enterprise / Plus plan is required. The Multipass secret can be found in your shop Admin (Settings > Checkout > Customer Accounts). Make sure "Accounts are required" or "Accounts are optional" is selected and Multipass is enabled.

  var Multipassify = require('multipassify');

  // Construct the Multipassify encoder
  var multipassify = new Multipassify("SHOPIFY MULTIPASS SECRET");

  // Create your customer data hash
  var customerData = { email: 'test@example.com', remote_ip:'USERS IP ADDRESS', return_to:"http://some.url"};

  // Encode a Multipass token
  var token = multipassify.encode(customerData);

  // Generate a Shopify multipass URL to your shop
  var url = multipassify.generateUrl(customerData, "yourstorename.myshopify.com");

  // Generates a URL like:  https://yourstorename.myshopify.com/account/login/multipass/<MULTIPASS-TOKEN>

Rate & Review

Great Documentation0
Easy to Use0
Performant0
Highly Customizable0
Bleeding Edge0
Responsive Maintainers0
Poor Documentation0
Hard to Use0
Slow0
Buggy0
Abandoned0
Unwelcoming Community0
100
No reviews found
Be the first to rate

Alternatives

No alternatives found

Tutorials

No tutorials found
Add a tutorial