This is an example of how to use Evervault's 3D-Secure (3DS) API. It contains a simple form that allows you to create a 3DS session and mount the 3DS UI. The backend is implemented in Vercel's Edge Functions. All 3DS response data received by the backend is logged in the browser console for demo purposes.
- Clone the repository
git clone https://github.com/evervault/3ds-example.git
- Install dependencies with
pnpm install
Important
Make sure to use pnpm
instead of npm
or yarn
as this project uses pnpm
workspaces.
- Create a
.env
file with the following variables:
Important
Make sure the API key has permissions to create 3DS sessions.
EVERVAULT_API_KEY=
VITE_EVERVAULT_APP_ID=
VITE_EVERVAULT_TEAM_ID=
- Run the application using
vercel dev
Note
Using the vercel dev
command is required to enable the API routes.