User Sign-in and registration
First, follow steps from the SDK setup and initialization section to setup your Singularity account and initialize the Singularity SDK inside your app.
Now, before calling any of the Payments APIs, you must first 'register' the user with Singularity SDK, using either of the following methods, depending on which wallet the user is using:
Option A: If using Singularity Wallet, sign-in the user using one the methods listed in the Singularity Wallet User Sign-in and Registration section.
Option B: If you are using an external wallet (e.g. Metamask or any external wallet via Wallet Connect), then you must pass the wallet provider connection to the Singularity drawer before initiating any payments calls. See below for details:
Option C: If you are a wallet app on your own, then you must establish a Wallet Connect connection with Singularity in order to proceed with Payment APIs. More details below:
You can now subscribe to the following callback events to know when the user has been signed-in to Singularity:
Last updated