Indian ID Classification
Introduction
You need to upload an image of Indian ID card to classify. You may put direct URLs to ID cards, in case you have them. For best results, please make sure the image you use fits tightly in camera view and is horizontally-aligned. This API also accepts direct URL to an image. Each image/pdf should be less than 2MB.
There are two important properties to note:
- task- indianIdCard (only Indian ID cards are supported currently). More to be coming up soon.
- essentials- This is the property which holds data for processing.
- files- array of images to be processed (batch processing coming soon, currently only one image at a time is allowed).
How to call the API
Before making API requests, you need to perform a login authentication and obtain an access token. The access token should be included in the authorization header of subsequent API requests. The API endpoints and environments for different operations are provided below.
API Input Guidelines
Endpoint Details
POST https://signzy.tech/api/v2/patrons/..patron-id.../idclassificationsPOST https://preproduction.signzy.tech/api/v2/patrons/..patron-id.../idclassificationsRequest Body Parameters
Parameter | Data Type | Description | Required |
|---|---|---|---|
task | String | Specifies the type of task to be performed (e.g., "indianIdCard"). | Yes |
essentials.files | String Array | Specifies the list of URLs of the images | Yes |
{
"task": "indianIdCard",
"essentials": {
"files": [
"..url..to..the..image.."
]
}
}Request Body Headers
Header Name | Required/Optional | DESCRIPTION |
|---|---|---|
Authorization | Required | access token returned as id field of login request |
Content-Type | Required | application/json |
Code Samples
const axios = require('axios');
let data = JSON.stringify({
"task": "indianIdCard",
"essentials": {
"files": [
"...url of the images..."
]
}
});
let config = {
method: 'post',
maxBodyLength: Infinity,
url: 'https://signzy.tech/api/v2/patrons/...patronID.../idclassifications',
headers: {
'Accept': '*/*',
'Accept-Language': 'en-US,en;q=0.8',
'Authorization': '<Access-Token>',
'content-type': 'application/json'
},
data : data
};
axios.request(config)
.then((response) => {
console.log(JSON.stringify(response.data));
})
.catch((error) => {
console.log(error);
});
Sample Response
{
"essentials": {
"files": ["..url..to..the..image.."]
},
"id": "5babXXXXX0c6",
"patronId": "5a905XXXXX19d8",
"task": "indianIdCard",
"result": [{
"status": "success",
"classification": {
"status": "success",
"idType": "aadhaar/individualPan/businessPan/unknownPan/passport/dl/voterId/cheque/unknown",
"message": "Successfully completed."
}
}]
}Sample Error
{
"error": {
"status": "422",
"msg": "Invalid request parameters: The image has expired",
"responseCode": "fail"
}
}Status Codes
Status Code | Description |
|---|---|
200 | OK |
400 | Bad Request |
401 | Authorization token is invalid |
422 | Unprocessable Entity |
Getting help
Please feel free to contact us if you have any questions, require clarification, or have ideas for how to make the documents or any of our services better.
You can reach out to us at [email protected].