Skip to main content
GET
/
verification
/
bgv
/
status
cURL
curl --request GET \
  --url https://bgv.konnectnxt.com/api/verification/bgv/status \
  --header 'Authorization: Bearer <token>'
{
"status": "success",
"code": 200,
"message": "string",
"data": {
"case_id": "string",
"aadhaar": {
"status": "verified",
"aadhaar_number": "********3434"
},
"pan": {
"status": "verified",
"pan_number": "CX892I8Q0W"
},
"passport": {
"status": "verified"
},
"employment_history": {
"status": "verified",
"uan_number": "783937927928"
},
"last_employment": {
"status": "string",
"mobile_number": "0987654321"
},
"criminal_check": {
"status": "In Progress",
"Description": "Candidate's consent is pending for the background verification process to start.",
"data": {
"email": "sumit@example.com",
"name": "Sumit"
}
},
"ref_status": {
"status": "In Progress",
"<reference_mail_id>": {
"status": "In Progress",
"candidate_details": {
"name": "Rahul",
"email": "rahul@example.com",
"salary": 5,
"start_date": "2023-09-16",
"end_date": "2023-10-15",
"designation": "Software Developer",
"employee_id": "EMP12345",
"employer_name": "TechCorp"
},
"reference_details": {
"name": "Eben",
"email": "eben@gmail.com",
"designation": "Senior Manager",
"contact_number": "0987654321",
"whatsapp_number": "0987654321"
}
}
}
}
}

API Response Explanation

The API provides a structured response, dynamically including only the data related to the cases you have initiated. If a case is not raised for a particular check, that section will not appear in the response. Below are the key details:

1. Dynamic Data Inclusion

  • The API response is tailored based on the checks initiated.
    • For example, if you have initiated a case for Aadhaar verification, you will receive the Aadhaar section in the response.
    • If no case is initiated for Criminal Check, the response will exclude the Criminal Check section.

2. Structure of the Response

The API response consists of the following top-level fields:
  • status: Indicates the overall success or failure of the API request.
  • code: The HTTP status code for the request.
  • message: A descriptive message about the request.
  • data: Contains the details for all initiated checks.

3. Example API Response

Here’s an example of a successful response with mixed statuses across different checks:
{
  "status": "success",
  "code": 200,
  "message": "Request processed successfully.",
  "data": {
    "case_id": "12345",
    "aadhaar": {
      "status": "verified",
      "aadhaar_number": "********3434"
    },
    "pan": {
      "status": "verified",
      "pan_number": "CX892I8Q0W"
    },
    "criminal_check": {
      "status": "In Progress",
      "description": "Candidate's consent is pending for the background verification process to start.",
      "data": {
        "email": "sumit@example.com",
        "name": "Sumit"
      }
    }
  }
}

4. Best Practices for Using the API

  • Initiate Required Cases:
    • Ensure you raise a case for the checks you need, as only those will be included in the response.
  • Handle Missing Sections:
    • Design your application to handle scenarios where a section might be absent if no case was raised for that check.
  • Monitor Pending Cases:
    • Track checks with the status In Progress and take necessary follow-up actions as needed.

Error Handling in the API Response

The API is designed to report errors in a structured and intuitive way. If any error occurs during the processing of a specific check, the error details will be encapsulated within that particular section. This ensures clarity and prevents errors from affecting unrelated sections of the response.

1. Error Format

  • Fields:
    • error: A descriptive message about the issue.
    • status_code: The HTTP status code representing the type of error.
  • Errors are included only in the section where they occur, leaving other sections unaffected.

2. Example of an Error in a Section

If an error occurs during Aadhaar verification, the response will include an error block as shown:
"aadhaar": {
  "error": "No Aadhaar Found",
  "status_code": 404
}
Other sections will continue to display their respective statuses and data without disruption.
For more Error Codes, Click here

3. Mixed Response Example

Here’s how a complete API response might look when an error is present in one section, while others are successful or in progress:
{
  "status": "success",
  "code": 200,
  "message": "string",
  "data": {
    "case_id": "string",
    "aadhaar": {
      "error": "No Aadhaar Found",
      "status_code": 404
    },
    "pan": {
      "status": "verified",
      "pan_number": "CX892I8Q0W"
    },
    "criminal_check": {
      "status": "In Progress",
      "description": "Candidate's consent is pending for the background verification process to start.",
      "data": {
        "email": "sumit@example.com",
        "name": "Sumit"
      }
    }
  }
}

4. Key Points About Error Handling

  1. Section-Specific Errors:
    • Errors are confined to the relevant section. For example, an Aadhaar error will not impact other sections such as PAN or Criminal Check.
  2. Consistent Response Structure:
    • Sections without errors continue to show valid data or processing statuses.
  3. Ease of Debugging:
    • Developers can easily identify issues by checking the error field in each section.
    • The status_code provides additional context for categorizing and resolving errors.

5. Best Practices for Handling Errors

  • Programmatic Checks:
    • Always check for the error field in each section before processing its data.
    • Use the status_code to determine the nature of the error (e.g., 404 for missing data, 500 for server-side errors).
  • Graceful Degradation:
    • Implement logic to handle missing or failed sections gracefully without impacting the overall process.
  • Logging and Notification:
    • Log errors for troubleshooting and debugging.
    • Notify users or administrators in case of critical issues, such as missing data for mandatory checks.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Query Parameters

case_id
string
required

Unique Id of the BGV Case

Response

Success

status
enum<string>
required

Overall status of the API

Available options:
success,
error
code
integer
required

HTTP status code

message
string
required

Description of the response or error

data
object
required