API Request & Response
The Philippines NBI Clearance verification service is the activity of checking the validity of inputted NBI Clearance number compared to authoritative datasource.
Endpoint
| Method | Base URL | Path |
|---|---|---|
| POST | https://api.verihubs.com | /philippines/nbi/verify |
Request
Header
| Key | Type | Notes | Description |
|---|---|---|---|
| App-ID | string | Required | Application ID generated from Verihubs Dashboard. |
| API-Key | string | Required | API-Key linked to the App ID. |
Body
| Key/Parameter | Type | Example | Description |
|---|---|---|---|
| clearence_number* | string | U000KATL67-RP1089164 | Exact 20 digits of clearance number as stated on the document with 10-9 digit format. |
| reference_id | string | Reference in string format. | This reference_id can be used to indicate your company’s transaction (must be unique) Note: If the reference_id is empty or did not include to the request, Verihubs will generate the unique reference_id |
Response
HTTP Code
| No | Code | Description | Examples |
|---|---|---|---|
| 1 | 200 | Successful Transaction; Transaction that is considered successful and has been successfully verified by the data source. | { "message": "NBI Clearance verification successfully completed", "id": "fdb47ebd-a54f-4355-847b-984ce9576903", "reference_id": "e40a3e32-5419-4ac8-a9b5-b2a787dc7495", "verification_status": "VERIFIED", "verification_result": { "clearance_number": "U000KATL67-RP1089164", "full_name": "JOHN JACK DOE", "last_name": "JOHN", "middle_name": "JACK", "first_name": "DOE", "clearance_expiry": "July 25, 2023", "occupation": "-", "is_valid": true } } |
| 2 | 400 | Invalid Payload; Transaction that is considered failed due to validation errors, an error_field will appear explaining the error. | { "message": "Invalid payload", "error_code": "INVALID_PAYLOAD", "error_fields": [ { "field": "clearance_number", "message": "clearance_number length should consist of 20 digit(s)" } ] } |
| 3 | 401 | Authorization Failed (the transaction cannot proceed because it is unauthorized). Please check the validity of your Application ID and API-Key and ensure it is in the right environment. | { "message": "Authorization Failed", "error_code": "UNAUTHORIZED", "error_fields": [] } |
| 4 | 403 | Quota Insufficient (the transaction failed due to insufficient quota, please contact CS Verihubs) | { "message": "Insufficient testing quota", "error_code": "FORBIDDEN", "error_fields": [] } |
| 5 | 429 | Too Many Request; Spam Error as the transaction is read as spam, please wait 10 seconds before re-performing the hit process with the same identity. | { "message": "Too many request in the allowed time frame", "error_code": "TOO_MANY_REQUEST", "error_fields": [] } |
| 6 | 500 | Internal Server Error; The transaction failed due untraced server error that could be caused by data source constraints, timeout, internal error. | { "message": "Internal Server Error", "error_code": "INTERNAL_SERVER_ERROR", } |
Response Parameter
| No | Type | Description | Example |
| message | string | Message of response | NBI Clearance verification successfully completed |
| id | string | Verihubs Transaction ID, string that can be used for reconciliation purpose (unique for every transactions) | e3c0326e-23f7-49d0-8876-71528a860a0c |
| reference_id | string | The reference_id inputted prior to the API transaction. | e40a3e32-5419-4ac8-a9b5-b2a787dc7495 |
| verification_status | string | The ID inputted by the user on request. | VERIFIED/REJECTED |
| verification_result | array | Array containing detailed information. | [] |
| clearance_number | string | The inputted clearence_number if the data found. | U000KATL67-RP1089164 |
| full_name | string | Full name of the person owning the NBI Clearance. | JOHN JACK DOE |
| last_name | string | Last name of the person. | DOE |
| middle_name | string | Middle name of the person. | JACK |
| first_name | string | First name of the person. | JOHN |
| photo | string | Face photo URL. | URL |
| clearance_expiry | string | Clearance expiry date in Month Date, Year format. | July 25, 2023 |
| occupation | string | Occupation of the person. May sometimes be empty since this field is not always asked by the Authority. | Sales |
| is_valid | bool | Is the inputted number valid or not. | true |
Response Example
| Case | Request Example | Response Example |
|---|---|---|
| Number inputted match with authoritative data | { "card_no":"U000KATL67-RP1089164", "reference_id":”Docs-NBI-1” } | { "message": "NBI Clearance verification successfully completed", "id": "fdb47ebd-a54f-4355-847b-984ce9576903", "reference_id": "e40a3e32-5419-4ac8-a9b5-b2a787dc7495", "verification_status": "VERIFIED", "verification_result": { "clearance_number": "U000KATL67-RP1089164", "full_name": "JOHN JACK DOE", "last_name": "JOHN", "middle_name": "JACK", "first_name": "DOE", "clearance_expiry": "July 25, 2023", "occupation": "-", "is_valid”: “true” } } |
| Number inputted did not match with authoritative data | { "card_no":"U000KATL67-RP3423123", "reference_id":”Docs-NBI-2” } | { "message": "NBI Clearance verification successfully completed", "id": "fdb47ebd-a54f-4355-847b-984ce9576903", "reference_id": "e40a3e32-5419-4ac8-a9b5-b2a787dc7495", "verification_status": "NOT VERIFIED", "verification_result": {} } |
Updated 9 days ago
