Skip to main content

Create Profile

The following documentation details the process for integrating with the Add Candidate API, which is used to add candidates as per the form created on the portal.

Try it out

API Endpoint

Endpoint URL: POST https://api.trential.dev/verification/api/1.0/ekyc-forms/:formId/diy-candidate

Request

To add a candidate, send a POST request with the following JSON payload:

{
"name": "Candidate Name",
"gender": "Male",
"dob": "05-01-1990",
"mobile": "+91-9119216041",
"profession": "Other",
"fatherName": "father name",
}

Parameters

  • name (string): The candidate's full name.(Required)
  • gender (string): The candidate's gender. Accepted values are Male, Female, Other.(Required)
  • dob (string): The candidate's date of birth in DD-MM-YYYY format.(Required)
  • profession (string): The candidate's profession.(optional)
  • fatherName (string): The candidate's father's name.(optional)
  • mobile (string): The candidate's mobile phone number, including country code.(optional)
  • email (string): The candidate's email.(optional)

Response

If the candidate is valid, the response will be as follows:

{
"code": 0,
"message": "Success",
"data": {
"transactionId": "6647408598332f345e0747ae"
}
}
Success Response
  • code (integer): Status code indicating the result of the request. 0 indicates success.
  • message (string): Description of the result. Success indicates the candidate was successfully added.
  • data (object): Contains additional data related to the request.
    • transactionId (string): A unique identifier for the transaction.

If the candidate is invalid, the response will be as follows:

{
"message": "name must be a string/dob must be a string/gender must be one of the following values: Male, Female, Other",
"code": -1
}
Error Response
  • message (string): Description of the error(s) encountered. This field provides detailed information about the specific validation issues.
  • code (integer): Status code indicating the result of the request. -1 indicates a failure due to invalid candidate data.