This project acts as a simple web application for a fictional customer, Hooli, which uses Unum ID to issue reusable credentials to its users. Additional information on how to issue credentials can be found here.
The Hooli Web Demo is implemented using the Remix full stack web framework. Additional information about the Unum ID demo ecosystem can be found in our documentation.
While knowledge of the Remix framework is not fully required to observe and understand the simplicity of the implementation for issuing Unum ID digital ID cards it is worth noting that Remix has a notion of "middleware" that serves as a lightweight backend, which takes the form of an express server.
Because of this characteristic, even though this is a client side app, not all of the software in this repo is executed in the browser. The files with the naming convention .server.
denote that they are executed on the express server. This is an important distinction because your Unum ID API Key used to authenticate needs to be kept secret and can only be used in a secure backend environment. TL;DR, Please do not call the Unum ID API directly from client side code that is executed in the browser because the API key is sensitive.
The live web app can be found here.
The application's home page is a sample login page. In order to sign in, you may enter any combination of email address and password. Please note, if the email address is not valid email format, credentials will not successfully issue on subsequent screens.
Once passed the login screen the user is prompted to activate their Unum ID digital identity card or not. If agreed to, an EmailCredential is issued corresponding to the authenticated user. A number of 'dummy' credentials (e.g. FullNameCredential, SsnCredential) will also be issued for the user.
The critical api call to /credentials for issuing the credentials can be found in the coreAPI.server.ts file. By issuing credentials Hooli qualifies themselves for Unum ID's Free IDV offering.
Install necessary dependencies
npm install
Make a clone of the .env.example
file and save as .env
in the demo's root directory. There are a few items worth noting for setting up the .env
.
PORT
can be updated to whichever port you'd prefer the demo to run on locally.UNUM_API_KEY
needs to be populated with the API key you've been provided.CORE_SERVICE_URL
is defaulted to the Unum ID Core Service API in our sandbox environment.
Start the Remix development asset server and the Express server by running:
npm run dev
Note: The demo will launch on the specified PORT
in the .env
file.