Fetch Aadhaar XML from DigiLocker

Fetches the user's Aadhaar XML document from DigiLocker and returns it as a file.

HTTP StatusCodeReasonMessageMerchant Action
2001004DOC_RETRIEVEDAadhaar retrieved successfully.Proceed with verification.
4042007DOC_NOT_FOUNDAadhaar is not linked in this user's DigiLocker account.Offer alternate KYC document.
4032005CONSENT_NOT_PROVIDEDUser did not consent to share Aadhaar, or the Aadhaar document is not present in DigiLocker.Retry/alternate doc.
5002009DOC_UNAVAILABLEWe could not fetch the Aadhaar document from DigiLocker right now. Retry the request or offer an alternate KYC document.Retry later.
410-REFERENCE_KEY_EXPIREDReference key expired.Restart flow.
Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…
Body Params
string
required
^[0-9a-zA-Z_\-]+$

Reference key obtained from /digilocker/get_reference.

Headers
string
enum
Defaults to application/json

Generated from available response content types

Allowed:
Responses

400

Invalid request or missing/invalid reference_key

401

Unauthorized - missing/invalid API key or client id

Language
Credentials
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/xml
application/json