add
Overview
- API URL:
/api/v1/zoloz/idnetwork/add
- API Description: Provides the capability to add a new record i.e. add a record to the database.
Structure
Request parameters
Parameter | Data type | Max length | Description | Example |
bizId | String | 32 | Required. A unique business ID for tracing purposes. For example, the sequence ID from the merchant's business-related database. Note: The ZOLOZ server does not perform uniqueness checks on the value of this field. For better tracking, it is strongly recommended to enable the merchant server to guarantee the uniqueness of the business ID. | "1658894076638" |
userId | String | 64 | Optional. Merchant user ID, or other identifiers that can be used to identify a specific user. | "e9830710-0d70" |
riskDetection | RiskDetection | - | Optional. Risk detection. For more details, please see RiskDetection. Note: When data is being stored, in order to improve efficiency, this field can be skipped so that data is stored first without risk detection. Once data has been stored, risks can be detected using the risk query interface instead. | { "riskTypes":[ "IDFAKE", "DUPLICATE", "BATCH_REGISTER" ], "timeWindow":{ "startTime":1651882535687, "endTime":1658902665000 } } |
checkAllianceRisk | String | – | Optional. Specifies whether to check the affiliate risk. The default value is N.
| “N” |
imageInfo | ImageInfo | – | Required. Specifies the image information to be passed in. For more details, see ImageInfo.
| { "docImage":"eA3AW/6dxn6QAAAABJRU5ErkJggg==...", "faceImage":"p+AY/b2OF/F1CxAAAAAElFTkSuQmCC..." } |
basicInfo | BasicInfo | – | Optional. Basic information about the user. For more details, see BasicInfo. Note:The values of the incoming basicInfo field should be as detailed as possible. In the risk detection phase, the incoming basic information will be compared. | { "idType":"00000001003", "idNumber":"46082119870811896X", "certName":"Tom", "dateOfBirth":"19870811" } |
referenceId | String | 64 | Optional. Specifies the reference ID value returned by other businesses. This field is only used for recording and the system will not verify it. | "8365364ceddd411da027cdb15fea92ed" |
RiskDetection
Field | Data type | Max length | Description | Example |
riskTypes | List<String> | - | Optional. Specifies the type of risk to be queried. The following three major risk types are supported, and the system will automatically query the sub-risks they contain.
| [ "IDFAKE", "DUPLICATE", “BATCH_REGISTER” ] |
timeWindow | TimeWindow | - | Optional. The risk query time window. For more details, see TimeWindow. | { "startTime":1651882535687, "endTime":1658902665000 } |
TimeWindow
Field | Data type | Max length | Description | Example |
startTime | Long | - | Optional. Risk query start time, using a 14-digit timestamp. | 1651882535687 |
endTime | Long | - | Optional. Risk query end time, using a 14-digit timestamp. | 1658902665000 |
ImageInfo
Note:
- Currently, only faceImage fields are supported. docImage fields are not supported by the system at the moment.
- Image size should not exceed 5MB
- The picture format should be base64.
Field | Data type | Max length | Description | Example |
docImage | String | - | Optional. The ID image to be passed in (this field is not supported at the moment). | "eA3AW/6dxn6QAAAABJRU5ErkJggg==..." |
faceImage | String | - | Optional. The face image to be passed in. | "p+AY/b2OF/F1CxAAAAAElFTkSuQmCC..." |
BasicInfo
Field | Data type | Max length | Description | Example |
idType | String | 32 | Optional. Specifies the document type. For supported document types, see Document types supported and OCR results returned. | "00000001003" |
certName | String | 32 | Optional. Name. | "Tom" |
idNumber | String | 32 | Optional. ID number. | "46082119870811896X" |
dateOfBirth | String | - | Optional. The date of birth in | "19870811" |
Response parameters
Parameters | Data type | Description | Example |
result | Result | Required. The API request result, which contains information about the result of the API request, such as status and error codes. | { "resultStatus":"S", "resultCode":"SUCCESS", "resultMessage":"Success" } |
transactionId | String | Optional. A unique business ID generated by the IDN. | "G00000000817636816" |
itemId | String | The record ID of the item. Note: Please save the record ID as it is required for subsequent record inquiries, risk inquiries as well as record deletion. | "AIN20220727890204890950" |
hasRisk | Boolean | Specifies whether risk exists.
| true |
riskDetails | List<RiskDetail> | Risk details. For more information, see RiskDetail. | [ { "type":"IDFAKE", "subType":"SameFaceDifferentIdNumber", "riskData":[ "AIN20220727890199220364" ] } |
allianceRiskDetails | List<RiskDetail> | Alliance risk details. For more information, see RiskDetail. | [ { "type":"IDFAKE", "subType":"SameFaceDifferentIdNumber", "riskData":[ "AIN20220727890976220364" ] } |
RiskDetail
Field | Data type | Description | Example |
type | String | Risk type. | "IDFAKE" |
subType | String | Sub-risk type. | "SameFaceDifferentIdNumber" |
riskData | List<String> | Risk data with an itemId array. | ["AIN20220727890199220364"] |
Sample
Request sample
POST /api/v1/zoloz/idnetwork/add HTTP/1.1
Content-Type: application/json; charset=UTF-8
Client-Id: 5X67656YXXXXXX
Request-Time: 2023-05-05T15:08:56+05:30
Signature: algorithm=RSA256, signature=xxxxxxxxxxxx
{
"bizId":"1658894076638",
"riskDetection":{
"riskTypes":[
"IDFAKE",
"DUPLICATE",
"BATCH_REGISTER"
],
"timeWindow":{
"startTime":1651882535687,
"endTime":1658902665000
}
},
"imageInfo":{
"docImage":"eA3AW/6dxn6QAAAABJRU5ErkJggg==...",
"faceImage":"p+AY/b2OF/F1CxAAAAAElFTkSuQmCC..."
},
"basicInfo":{
"idType":"00000001003",
"idNumber":"46082119870811896X",
"certName":"Tom",
"dateOfBirth":"19870811"
},
"userId":"e9830710-0d70",
"referenceId":"8365364ceddd411da027cdb15fea92ed"
}
Response sample
HTTP/1.1 200 OK
Content-Type: application/json; charset=UTF-8
Response-Time: 2023-05-05T15:08:56+05:30
Signature: algorithm=RSA256, signature=xxxxxxxxxxxxxxxxxx
{
"result":{
"resultStatus":"S",
"resultCode":"SUCCESS",
"resultMessage":"Success"
},
"itemId":"AIN20220727890204890950",
"transactionId":"G00000000xxxxxxx",
"hasRisk":true,
"riskDetails":[
{
"type":"IDFAKE",
"subType":"SameFaceDifferentIdNumber",
"riskData":[
"AIN20220727890199220364"
]
},
{
"type":"IDFAKE",
"subType":"SameIdDifferentFace",
"riskData":[
"AIN20220727890199220387",
"AIN20220727890222174163"
]
},
{
"type":"BATCH_REGISTER",
"subType":"SameFaceBackgroundDifferentFace",
"riskData":[
"AIN20220727890862716253",
"AIN20220727899872658271"
]
}
],
"allianceRiskDetails":[
{
"type":"IDFAKE",
"subType":"SameFaceDifferentIdNumber",
"riskData":[
"AIN20220727890976220364"
]
},
{
"type":"IDFAKE",
"subType":"SameIdDifferentFace",
"riskData":[
"AIN20220727890199220387",
"AIN20220727890222174163"
]
},
{
"type":"BATCH_REGISTER",
"subType":"SameFaceBackgroundDifferentFace",
"riskData":[
"AIN20220727890862716253",
"AIN20220727899872658271"
]
}
]
}