Skip to main content
GET
/
digilocker
/
document
/
{document_type}
Get Document
curl --request GET \
  --url https://sandbox.cashfree.com/verification/digilocker/document/{document_type} \
  --header 'x-client-id: <api-key>' \
  --header 'x-client-secret: <api-key>'
{
"reference_id": 408,
"verification_id": "test001",
"status": "SUCCESS",
"uid": "xxxxxxxx5647",
"care_of": "S/O: Fakkirappa Dollin",
"dob": "02-02-1995",
"gender": "M",
"name": "Mallesh Fakkirappa Dollin",
"photo_link": "/9j/4AAQSkZJRgABAgAAAQABAAD/2wBDAAgGBgcGBQgHB",
"split_address": {
"country": "India",
"dist": "Haveri",
"house": "Shri Kanaka Nilaya",
"landmark": "",
"pincode": "581115",
"po": "Ranebennur",
"state": "Karnataka",
"street": "Umashankar Nagar 1st Main 5th Cross",
"subdist": "Ranibennur",
"vtc": "Ranibennur"
},
"year_of_birth": 2000,
"xml_file": "<xml file link with 48hrs expiry>",
"message": "Aadhaar Card Exists"
}
Currently we do not support downloading of full documents through Digilocker API. This feature will be added in the future enhancements.

Authorizations

x-client-id
string
header
required

Your unique client identifier issued by Cashfree. You can find this in your Merchant Dashboard.

x-client-secret
string
header
required

The secret key associated with your client ID. Use this to authenticate your API requests. You can find this in your Merchant Dashboard.

Headers

x-cf-signature
string

Send the signature if two-factor authentication is selected as Public Key. More details

Path Parameters

document_type
enum<string>
required

It is the type of document to be verified.

Available options:
AADHAAR,
PAN,
DRIVING_LICENSE

Query Parameters

reference_id
integer

It is the unique ID created by Cashfree Payments that you receive in the response of Create DigiLocker URL API. format: int64

verification_id
string

It is the unique ID you created to identify the Create DigiLocker URL API request.

Response

Success response for retrieving the document from DigiLocker

  • Option 1
  • Option 2
  • Option 3
care_of
string

It displays the name of the parent or guardian.

Example:

"John Snow"

dob
string

It displays the date of birth of the individual.

Example:

"02-02-1995"

gender
string

It displays the gender of the individual.

Example:

"M"

name
string

It displays the name of the individual.

Example:

"John Doe"

year_of_birth
integer

It displays the year of birth of the individual.

Example:

2000

It displays the Base64-encoded image of the individual whose document is to be retrieved.

Example:

"PHOTO_LINK"

message
string

It displays details about the success or failure of the API request.

Example:

"Aadhaar Card Exists"

reference_id
integer

It displays the unique ID created by Cashfree Payments for reference purposes. format: int64

Example:

1234

status
string

It displays the status of the aadhaar document fetch. Possible values are:

  • SUCCESS: Aadhaar successfully fetched
  • AADHAAR_NOT_LINKED: Aadhaar not linked
Example:

"SUCCESS"

split_address
object

It contains the address information in individual components.

Example:
{
"country": "India",
"dist": "Haveri",
"house": "House",
"landmark": "Landmark",
"pincode": "581112",
"po": "Post Office",
"state": "State",
"street": "Street",
"subdist": "SubDist",
"vtc": "Vtc"
}
uid
string

It displays the unique number assigned to the individual when applying for the aadhaar card.]

Example:

"xxxxxxxx5678"

verification_id
string

It displays the unique ID you created to identify the verification request.

Example:

"ABC00123"

xml_file
string

It is the link which points to the zip file containing the XML file and has 48 hrs expiry

Example:

"https://abc.xyz"