API
This section explains how to use the FuturePass Identity Provider (IDP) to authenticate users in your applications using the API directly without any of the Futureverse SDKs. It covers registering your experience, configuring authentication requests, handling responses, and decoding tokens.
This guide only covers custodial accounts, if non-custodial is a requirement we can add that.
Note: This demo's goal is simplicity, so do not depend on the helper functions used in the code to generate random strings, generate sha256, decode JWT, etc. Futureverse does not officially provide these and is here only for explanation purposes. You should use libraries that securely process data or extensively test your implementation for edge cases.
FuturePass IDP Barebones Demo App
All the examples from this document are also available in the FuturePass IDP Barebones Demo App.
Example Code:
Email, Google, Facebook, and IDP-F login example can be found at
./src/pages/login/login.ts
.MetaMask login example can be found at
./src/pages/login/metamask.ts
.Handling callback and decoding the ID token can be found at
./src/pages/callback/callback.ts
Handling signature callbacks for native clients(games) can be found at
./src/pages/signature-callback/signature-callback.ts
Last updated