Pay3 Javascript SDK

Initialize

4min

initPay3()

Pay3 Wallet works in two modes

  1. EasySign and Payments mode
  2. Payments Only mode

The init function creates an instance of Pay3 client if not yet created and returns the client reference. In Payments Only mode the initPay3 function expects isPaymentMode as true as an additional parameter.

Pay3 team will share hostname and clientId during onboarding. Following parameters can be used for creating new instance of Pay3.

Parameters

  1. hostname: Pay3 Web Wallet will be opened in a new window using this hostname prefix. The host name is environment dependent.
  2. clientId: A unique client id is created for each client application. The client id is environment dependent.
  3. isPaymentMode (Type boolean, Optional): Pass true for payments only mode.

Easy Sign & Payments Integration

In this mode, the user uses Pay3's integrated wallet with Web2 & Web3 connect options. The dApp does not need to integrate with any other wallet provider. Easy Sign & Payment Illustration

index.js


Payments Only Integration

Payments only integration is useful when the dApp has an existing wallet integration and wants only transaction services from Pay3. For payments only integration pass isPaymentMode: true to initPay3. Payment Mode Illustration

index.js