Feel free to reach techsupport@surepass.io for any technical support or guidance.
Authorization
header as Bearer TOKEN
.https://sandbox.surepass.io
https://kyc-api.surepass.io
Header | Required | Description |
---|---|---|
Authorization | Yes | Bearer token authentication using JWT token |
Content-Type | Yes | application/json |
Parameter | Type | Required | Description |
---|---|---|---|
client_id | String | Yes | The DigiLocker Client ID obtained from previous API calls |
file_id | String | Yes | The File ID of the document to be downloaded, obtained from previous API calls |
Parameter | Type | Description |
---|---|---|
data | Object | Container for the response data |
data.download_url | String | Temporary URL to download the document (valid for a limited time) |
data.mime_type | String | MIME type of the document (e.g., application/pdf) |
status_code | Integer | HTTP status code of the response |
success | Boolean | Indicates whether the request was successful |
message | String | Human-readable message describing the result |
message_code | String | Machine-readable code representing the result |
{
"data": {
"download_url": "https://aadhaar-kyc-docs.s3.amazonaws.com/test/digilocker/digilocker_puWsFhgqyuEpEdEWkxzm/PANCR_1710510006206872.pdf?response-content-type=application%2Fpdf&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAY5K3QRM5FYWPQJEB%2F20240315%2Fap-south-1%2Fs3%2Faws4_request&X-Amz-Date=20240315T134006Z&X-Amz-Expires=600&X-Amz-SignedHeaders=host&X-Amz-Signature=b65ab9a797debce8b30af82561f6df8e81327c52b0a2513c77964ac84040ded7",
"mime_type": "application/pdf"
},
"status_code": 200,
"success": true,
"message": "Success",
"message_code": "success"
}
{
"data": null,
"status_code": 404,
"success": false,
"message": "DigiLocker client not found",
"message_code": "digilocker_client_not_found"
}
curl --location --request GET 'https://kyc-api.surepass.app/api/v1/digilocker/download-document//'
{
"data": {
"download_url": "https://aadhaar-kyc-docs.s3.amazonaws.com/test/digilocker/digilocker_puWsFhgqyuEpEdEWkxzm/PANCR_1710510006206872.pdf?response-content-type=application%2Fpdf&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAY5K3QRM5FYWPQJEB%2F20240315%2Fap-south-1%2Fs3%2Faws4_request&X-Amz-Date=20240315T134006Z&X-Amz-Expires=600&X-Amz-SignedHeaders=host&X-Amz-Signature=b65ab9a797debce8b30af82561f6df8e81327c52b0a2513c77964ac84040ded7",
"mime_type": "application/pdf"
},
"status_code": 200,
"success": true,
"message": "Success",
"message_code": "success"
}