Skip to content

srikanthlogic/aadhaar-validator

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

41 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

aadhaar-validator

Build Status codecov NPM Downloads

This library checks whether a given number is valid Aadhaar number or Aadhaar Virtual ID, following the structure which is given by Government of India.

This is not Aadhaar check. This library computes whether a given number confirms criteria specified by UIDAI. The aadhaar number validated by this library, may or may not have been issued to real person as theoritically 8000 Crore (80 Billion) UIDs are possible where as Indian population is little over 100 Crores(1 Billion).

References:

Installation

npm install aadhaar-validator

Use

var validator = require('aadhaar-validator')
validator.isValidNumber('123412341234')
//returns false
validator.isValidNumber('123412341235')
//returns false
validator.isValidNumber('234123412346')
//returns true

//VID Tests
validator.isValidVID('2345234523436129')
//returns true
validator.isValidVID('2345234523436123')
//returns false
validator.isValidVID('2345234523436')
//returns false

Test

npm test

About

Validates Aadhaar Number

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 100.0%