npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

deepvue-aadhaar-ekyc-digilocker-switch

v1.0.3

Published

A SDK powered by DeepVue.Tech for Aadhaar eKYC and DigiLocker authentication flows

Readme

deepvue-aadhaar-ekyc-digilocker-switch

A React component library that provides a seamless integration for Aadhaar eKYC and DigiLocker authentication flows. This package allows users to choose between Aadhaar-based verification or DigiLocker-based document verification in your React applications.

Installation

npm install deepvue-aadhaar-ekyc-digilocker-switch
# or
yarn add deepvue-aadhaar-ekyc-digilocker-switch

Peer Dependencies

This package requires the following peer dependencies:

{
  "react": "^18.0.0 || ^19.0.0",
  "react-dom": "^18.0.0 || ^19.0.0",
  "@mui/material": "^7.0.0",
  "@emotion/react": "^11.0.0",
  "@emotion/styled": "^11.0.0"
}

Usage

import {
  FlowSelector,
  AadhaarFlow,
  DigiLockerFlow,
} from "deepvue-aadhaar-ekyc-digilocker-switch";
import { useState } from "react";

function App() {
  const [flow, setFlow] = useState<"aadhaar" | "digilocker" | null>(null);

  // Your DeepVue credentials
  const apiKey = "your_api_key";
  const clientId = "your_client_id";
  const userCallback = "https://your-callback-url.com";

  const handleBackToSelection = () => {
    setFlow(null);
  };

  return (
    <div>
      {!flow ? (
        <FlowSelector
          apiKey={apiKey}
          clientId={clientId}
          onSelectAadhaar={() => setFlow("aadhaar")}
          onSelectDigiLocker={() => setFlow("digilocker")}
          onAutoSelectDigiLocker={() => setFlow("digilocker")}
        />
      ) : flow === "aadhaar" ? (
        <AadhaarFlow
          apiKey={apiKey}
          clientId={clientId}
          generatePdf={false}
          redirectUrl={userCallback}
          onBack={handleBackToSelection}
          companyName="Your Company"
          purpose="ForKYC"
        />
      ) : (
        <DigiLockerFlow
          apiKey={apiKey}
          clientId={clientId}
          redirectUrl={userCallback}
        />
      )}
    </div>
  );
}

Components

FlowSelector

The main component that allows users to choose between Aadhaar and DigiLocker flows.

Props:

  • apiKey (string, required): Your DeepVue API key
  • clientId (string, required): Your DeepVue client ID
  • onSelectAadhaar (function, required): Callback when Aadhaar flow is selected
  • onSelectDigiLocker (function, required): Callback when DigiLocker flow is selected
  • onAutoSelectDigiLocker (function, required): Callback for auto-selecting DigiLocker flow
  • autoDetectCallback (boolean, optional): Enable auto-detection of DigiLocker callback

AadhaarFlow

Component for handling Aadhaar eKYC verification flow.

Props:

  • apiKey (string, required): Your DeepVue API key
  • clientId (string, required): Your DeepVue client ID
  • generatePdf (boolean, optional): Whether to generate PDF after verification
  • redirectUrl (string, required): URL to redirect after successful verification
  • onBack (function, required): Callback when user wants to go back
  • companyName (string, required): Your company name
  • purpose (string, required): Purpose of verification

DigiLockerFlow

Component for handling DigiLocker document verification flow.

Props:

  • apiKey (string, required): Your DeepVue API key
  • clientId (string, required): Your DeepVue client ID
  • redirectUrl (string, required): URL to redirect after successful verification

Features

  • Dual Authentication Flow

    • Aadhaar eKYC verification
    • DigiLocker document verification
    • Easy switching between authentication methods
    • OTP-based verification
    • PDF generation support for Aadhaar flow

Configuration

Before using the components, you need to:

  1. Sign up for a DeepVue account to get your API credentials
  2. Configure your callback URLs in the DeepVue dashboard
  3. Add your API key and client ID to your application

License

MIT © DeepVue