This guide demonstrates how to implement user verification end-to-end using a simply Node.js Express server.
User verification ensures that only authorized users can access your private roadmaps or widgets. Because this process involves sensitive credentials (your Shared Secret), the authentication token must be generated on your server, never in the browser.
This guide provides a complete, minimal working example using Node.js. You can use this to understand the flow before integrating it into your main application.
Prerequisites
Before running the example, ensure you have the following:
Node.js installed (v18 or newer recommended).
Your Released credentials (found in Settings → User Verification):
Create a file named server.js and paste in the code below.
Security Warning
This example includes your SHARED_SECRET for demonstration purposes. In a production environment, use Environment Variables (e.g., .env files) to keep secrets out of your source code.
3. Run the server
Start the application in your terminal:
Bash
4. Tunneling (Required for HTTPS)
Most browsers restrict embedded widgets or cookies when running on localhost. To test this properly, you need a public https URL. We recommend using a tool like ngrok.
Install ngrok (if you haven't already).
Run the tunnel in a new terminal window:
Bash
Copy the Forwarding URL provided by ngrok (e.g., https://a1b2-c3d4.ngrok-free.dev).
Important: Add this URL to your Allowed Domains in the Released dashboard if you have domain restrictions enabled.
Open the URL in your browser to see your authenticated roadmap.