How to Integrate Aadhaar Verification APIs?
Hypersign's Compliant Aadhaar Verification APIs enable organizations to securely verify an individual's Aadhaar identity while supporting modern privacy and compliance requirements.
The platform provides multiple verification methods that can be used independently or combined to achieve the desired level of identity assurance:
Aadhaar OTP Verification β Verify an individual's Aadhaar using the OTP sent to their Aadhaar-linked mobile number.
Aadhaar Secure QR Verification β Verify the authenticity of an Aadhaar card by validating the UIDAI-issued digital signature embedded in the Secure QR Code and extract the verified Aadhaar details.
Aadhaar Face Match β Perform biometric verification by comparing a live selfie with the Aadhaar photograph to confirm that the person presenting the Aadhaar is its legitimate holder.
Selective Disclosure β Request only the Aadhaar attributes required for your business purpose, reducing unnecessary personal data processing while receiving cryptographically verifiable proof of the disclosed information.
These APIs can be combined to support different onboarding and verification journeys based on your application's security, compliance, and user experience requirements.
Whether you are building a banking application, digital onboarding platform, employee verification system, or customer KYC workflow, Hypersign enables you to implement Aadhaar verification with Privacy by Design, data minimization, and cryptographic verifiability from day one.
Supported Verification Flows

Base URL
Authentication
All Aadhaar Verification APIs require an Access Token for authentication.
Authentication is a two-step process:
Generate a KYC API Secret from the Hypersign Dashboard.
Exchange the API Secret for a short-lived Access Token.
The generated Access Token must be included in the Authorization header of every API request. Please also read Detailed Steps To Generate Access Tokensection.
Generate Aadhaar OTP
Generates an OTP on the mobile number linked with the Aadhaar number.
POST /api/v1/aadhaar/otp/generate
Request Body
aadhaar_number
string
Yes
12-digit Aadhaar number of the user. For development/sandbox mode, use 111122223333.
reason
string
Yes
Purpose for generating the OTP (for example: "For KYC"). This may be used for audit and compliance purposes.
Successful Response
success
string
Indicates whether the request was processed successfully.
message
string
Overall status of the API response.
data.ref_id
string
Reference ID for this OTP generation request. This value must be passed to the OTP Verify API along with the OTP entered by the user.
data.message
string
Additional message describing the result of the operation.
Error Response
Verify Aadhaar OTP
Verifies the OTP entered by the user and returns the verified Aadhaar details obtained from UIDAI.
When to use: Invoke this API after successfully generating an OTP using the Generate Aadhaar OTP API.
POST /api/v1/aadhaar/otp/verify
Request Body
ref_id
string
Yes
Reference ID returned by the Generate Aadhaar OTP API.
otp
string
Yes
6-digit OTP received on the Aadhaar-linked mobile number. For sandbox/development mode, use 111111.
Successful Response
Example
success
string
Indicates whether the request was processed successfully.
message
string
Overall status of the API response.
data.verified
boolean
Indicates whether the Aadhaar data and digital signature were successfully verified.
data.aadhaarData
object
Verified Aadhaar details returned after successful verification.
The response contains verified Aadhaar information returned by UIDAI. The photo field can be directly used with the Face Match API.
Verify Aadhaar Secure QR
Verifies the authenticity of an Aadhaar Secure QR Code by validating its digital signature and extracting the Aadhaar details embedded within it.
Unlike a standard QR code scanner, this API performs cryptographic signature verification to ensure that the QR code was issued by UIDAI and has not been tampered with.
When to use: Use this API when the user presents a physical or digital Aadhaar card containing a Secure QR Code. This API provides an offline Aadhaar verification mechanism without requiring OTP authentication.
POST /api/v1/aadhaar/qr/verify
Request Body
qrString
string
Yes
The Aadhaar Secure QR Code content extracted by the client application after scanning the Aadhaar card. The complete QR string should be passed without modification.
What Happens Internally?
Hypersign
verifies UIDAI digital signature
validates QR authenticity
extracts Aadhaar information
extracts Aadhaar photograph
returns verified data
Successful Response
The extracted photo can be used with the Face Match API.
success
string
Indicates whether the request was processed successfully.
message
string
Overall status of the API response.
data.verified
boolean
Indicates whether the Aadhaar Secure QR Code's digital signature was successfully verified.
data.aadhaarData
object
Verified Aadhaar details extracted from the Secure QR Code.
Note: The fields within
aadhaarDataare identical to those returned by the Verify Aadhaar OTP API. Refer to the Aadhaar Data section in the previous API for a complete description of each field.
Aadhaar Face Match
Compares a live selfie captured by the user with the photograph obtained from the Aadhaar verification process and returns a biometric similarity score.
The Aadhaar photograph can be obtained from either:
Verify Aadhaar OTP API (
POST /api/v1/aadhaar/otp/verify)Verify Aadhaar Secure QR API (
POST /api/v1/aadhaar/qr/verify)
When to use: Use this API when biometric verification is required in addition to Aadhaar verification. This API helps confirm that the person presenting the Aadhaar document is the legitimate Aadhaar holder.
POST /api/v1/aadhaar/face/match
Request Body
face1
string
Yes
Base64-encoded Aadhaar photograph returned by either the Verify Aadhaar OTP API or the Verify Aadhaar Secure QR API. The image must include the appropriate Data URI prefix (for example, data:image/jpeg;base64,).
face2
string
Yes
Base64-encoded live selfie captured by the client application. The image must include the appropriate Data URI prefix (for example, data:image/jpeg;base64,).
Successful Response
success
string
Indicates whether the request was processed successfully.
message
string
Overall status of the API response.
data.userImageScore
number
Similarity score between the Aadhaar photograph and the live selfie. Higher values indicate a stronger facial match.
data.verified
boolean
Indicates whether the similarity score meets the configured verification threshold.
Aadhaar Data Returned Through API
referenceId
string
Masked Aadhaar reference identifier.
name
string
Full name of the Aadhaar holder.
dob
string
Date of birth.
gender
string
Gender (M, F, or O).
careOf
string
Parent, spouse, or guardian name.
house
string
House or building name/number.
street
string
Street or road name.
landmark
string
Nearby landmark.
villageTownCity
string
Village, town, or city.
postOffice
string
Post office name.
subDistrict
string
Sub-district or Taluk.
district
string
District name.
state
string
State or Union Territory.
pincode
string
Postal PIN code.
mobileHash
string
Masked representation of the Aadhaar-linked mobile number.
jpegImage
string
Base64-encoded photograph of the Aadhaar holder. This image can be passed directly to the Face Match API for biometric verification.
Complete Integration Examples
OTP + Face Match
QR + Face Match
OTP Only
Choosing the Right Verification Flow
The choice of verification flow depends on the level of identity assurance your application requires.
Verifies Aadhaar Information
β
β
Verifies the Person is the Aadhaar Holder
β
β
Biometric Face Verification
β
β
Helps Prevent Identity Fraud
β
β
Higher Identity Assurance
β
β οΈ Limited
Recommended For
Banking, Financial Services, Insurance, High-value Transactions, Digital Onboarding
Low-risk onboarding, Basic KYC, Mobile Number Verification
Why add Face Match?
OTP verification confirms that the user has access to the mobile number linked to the Aadhaar. However, it does not confirm that the person entering the OTP is the actual Aadhaar holder.
Face Match adds a biometric verification step by comparing the Aadhaar photograph with a live selfie, providing a much higher level of confidence that the individual being onboarded is the legitimate Aadhaar holder.
Recommended Verification Flow by Use Case
Banking & Financial Services
Aadhaar Verification + Face Match
NBFC Loan Onboarding
Aadhaar Verification + Face Match
Insurance KYC
Aadhaar Verification + Face Match
Securities & Investment Account Opening
Aadhaar Verification + Face Match
Digital Customer Onboarding
Aadhaar Verification + Face Match
High-value Transactions
Aadhaar Verification + Face Match
Employee Verification
Aadhaar Verification + Face Match
Telecom SIM Verification
Aadhaar Verification Only*
Low-risk Customer Onboarding
Aadhaar Verification Only
Basic Identity Verification
Aadhaar Verification Only
Mobile Number Verification
Aadhaar Verification Only
Note: If stronger identity assurance or fraud prevention is required, Face Match can be added to the Aadhaar verification flow.
Privacy by Design with Selective Disclosure
Why Request Only the Data You Need?
Many applications do not require the complete Aadhaar record to perform their business function.
For example:
An age-gated service may only need the user's date of birth.
A customer onboarding flow may only require the name and reference ID.
A logistics application may only need the name and address.
An employee verification portal may only require the name and photograph.
Requesting the complete Aadhaar dataset when only a few attributes are required increases the amount of personal data processed by your application.
Modern privacy regulations, including India's Digital Personal Data Protection (DPDP) Act, encourage organizations to collect and process only the personal data necessary for a specific purpose. Reducing the amount of personal data handled by your application lowers privacy risk, simplifies compliance, and limits unnecessary exposure of sensitive information.
Hypersign helps you implement this Privacy by Design approach from day one through Selective Disclosure.
What is Selective Disclosure?
Selective Disclosure is a privacy-preserving mechanism that allows a verifier to request only the Aadhaar > attributes required for a specific business purpose, instead of receiving the complete Aadhaar record. Instead > of disclosing all available Aadhaar information, the API returns only the fields requested by your application. For example, if your application only requires:
Name
Date of Birth
Reference ID the response will contain only those attributes.
How does Selective Disclosure helps your organizations?
Reduce personal data processing
Follow the principle of data minimization
Lower compliance and privacy risks
Build privacy-first applications
Using Selective Disclosure
Selective Disclosure is supported by both Aadhaar verification APIs:
POST /api/v1/aadhaar/otp/verifyPOST /api/v1/aadhaar/qr/verify
To request only specific Aadhaar attributes, include an additional QueryRequest object in the request body.
Request Format
The requested Aadhaar attributes are specified inside the credentialSubject object. To request an attribute, include its field name with an empty object ({}).
For example:
The API will return only:
namedobreferenceId
You can choose fields from Aadhaar Data Returned Through API
Response Format
When Selective Disclosure is used, the response format differs from the standard Aadhaar verification response.
Instead of returning the complete aadhaarData object, the API returns a W3C Verifiable Presentation (VP) containing only the attributes requested in the QueryRequest.
Example Response
The presentation contains:
A Verifiable Presentation
One or more Verifiable Credentials
Only the Aadhaar attributes requested in the
credentialSubjectframeCryptographic proofs proving the authenticity and integrity of the disclosed information
The returned presentation follows the W3C Verifiable Credentials specification and contains:
holder
DID of the Aadhaar holder presenting the credential.
verifiableCredential
Contains the selectively disclosed Aadhaar attributes.
credentialSubject
Contains only the requested Aadhaar fields.
proof
Cryptographic proof demonstrating that the disclosed attributes originate from a valid Aadhaar credential and have not been tampered with.
Sample Response where the verifier only requested name and dob:
Detailed Steps To Generate Access Token
Step 1: Generate a KYC API Secret
Log in to the Hypersign Dashboard and navigate to: Developer Hub β API Keys
Generate a new KYC API Secret and securely store it in your application's environment variables.
Example:
Important: Never expose your
KYC_API_SECRETin client-side applications (Web, Android, or iOS). It should only be used from your trusted backend or server environment.
Step 2: Generate an Access Token
Exchange the KYC_API_SECRET for an Access Token by calling the following endpoint.
Request
Request Headers
X-Api-Secret-Key
<KYC_API_SECRET>
Accept
application/json
Successful Response
The returned Access Token is valid until the time specified by the expiresIn field.
Do not generate a new Access Token before every API call.
Instead:
Cache the Access Token locally.
Reuse the cached token for subsequent API requests.
Automatically generate a new Access Token only after the current token expires.
Step 3: Authenticate API Requests
Include the generated Access Token in the Authorization header of every Aadhaar Verification API request.
Required Headers
Authorization
Bearer <ACCESS_TOKEN>
Content-Type
application/json
All APIs require authentication. Include the following headers with every request.
Need Help?
For complete request/response schemas, SDKs, and API playground, refer to the Hypersign OpenAPI documentation.
Last updated