BrandKwikID Documentation
Video Flow

API Integrations

APIs

Integration API Documentation

API Curl

API_1

API_2

Base URL

https://<your-domain>.test.getkwikid.com

Authentication

All endpoints except token generation require JWT authentication.

Header:

auth: jwt_token

Endpoints

1. Generate Token

POST /agentapi/v1/agent/generate_token

Generates a JWT token for API authentication.

Request Body:

{
  "username": "<your_username>",
  "password": "<your_password>"
}

Required Fields:

FieldTypeCharacter LengthValidationDescription
usernamestring3-20alphanumericUsername for authentication
passwordstring8-32alphanumericPassword for authentication

200 Success:

{
  "Token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9..GFKV8h5mgGd4BRlMzPY6R92fO4IzWwMGxc6Y9YDoXXw",
  "status_code": 200,
  "success": true
}

Response Fields:

KeyTypeCharacter LengthDescription
TokenstringVariable (JWT)JWT token for authentication
status_codeinteger3HTTP status code indicating the result
successbooleanN/AIndicates whether the request was successful

401 Unauthorized:

{
  "msg": "username/password did not match",
  "status_code": 401,
  "success": true
}

Response Fields:

KeyTypeCharacter LengthDescription
msgstringVariableError message describing the issue
status_codeinteger3HTTP status code indicating the result
successbooleanN/AIndicates whether the request was successful

400 Bad Request:

{
  "msg": "please provide valid username and password",
  "status_code": 400,
  "success": true
}

Response Fields:

KeyTypeCharacter LengthDescription
msgstringVariableError message describing the issue
status_codeinteger3HTTP status code indicating the result
successbooleanN/AIndicates whether the request was successful

429 Rate limit:

{
  "status": 429,
  "message": "Rate limit exceeded"
}

Response Fields:

KeyTypeCharacter LengthDescription
statusinteger3HTTP status code for rate limiting
messagestringVariableMessage indicating the rate limit exceeded

POST /agentapi/v1/agent/sendLink/

Generates and sends a KYC link to the customer.

Headers:

auth: jwt_token
accept: application/json

Request Body:

{
  "user_id": "1234567890",
  "phone_number": "7710978566",
  "send_notification": 1,
  "link_type": "free",
  "extras": {
    "last_kyc_date": "1691154990",
    "link_expires_in": "900"
  }
}

Required Fields:

FieldTypeDescription
user_idstringUnique identifier for the user
phone_numberstringUser's phone number
send_notificationintegerWhether to send notification (0/1)
link_typestringType of link to generate (e.g., "free"), case-sensitive

200 Success:

{
    "link_expiry_time": "1745308158.1170702",
    "link_id": "3bKabcAF2AWK",
    "link_url": "https://<your-domain>.test.getkwikid.com/user/%3Fl%3D3bKabcAF2AWK%26d%3D1%26s%3D0",
    "phone_number": "1234567890",
    "session_id": "8b19b5c9-36de-47a2-9cb8-1025f36da034",
    "user_id": "1234567894",
    "validity_duration": 900
}

Response Fields:

KeyTypeCharacter LengthDescription
link_expiry_timestringVariableExpiry time of the link in epoch format
link_idstringVariableUnique identifier for the link
link_urlstringVariableURL for accessing the resource
phone_numberstring10User's phone number
session_idstringVariableUnique identifier for the session
user_idstringVariableUnique identifier for the user
validity_durationintegerVariableDuration in seconds for which the link is valid
messagestringVariableError message for unauthorized or bad requests
statusinteger3HTTP status code indicating the result
msgstringVariableError message for internal server errors

Error Responses:

401 Unauthorized

{
  "message": "Token is invalid"
}

Response Fields:

KeyTypeCharacter LengthDescription
messagestringVariableError message indicating token issue

400 Bad Request

<!doctype html>
<html lang=en>
  <title>400 Bad Request</title>
  <h1>Bad Request</h1>
  <p>The browser (or proxy) sent a request that this server could not understand.</p>
</html>

500 Internal Server Error

{
  "msg": "error message",
  "status": 500
}

Response Fields:

KeyTypeCharacter LengthDescription
msgstringVariableError message indicating server issue
statusinteger3HTTP status code for internal error

429 Rate limit

{
  "status": 429,
  "message": "Rate limit exceeded"
}

Response Fields:

KeyTypeCharacter LengthDescription
statusinteger3HTTP status code for rate limiting
messagestringVariableMessage indicating rate limit exceeded

3. Get Session Details

GET /agentapi/v1/session/get_details/{SESSION_ID}

Retrieves detailed information about a specific KYC session.

Headers:

auth: jwt_token
accept: application/json

Path Parameters:

ParameterTypeDescription
SESSION_IDstringUnique identifier for the session

Response Codes:

200 Success

{
  "session_data": {
    "IS_VIDO_UPLOADED": true/ false,
    "aadhaar_request_time": "timestamp",
    "aadhaar_url": "aadhaar_front_url",
    "aadhaarback_url": "aadhaar_back_url",
    "agent_assignment_time": "timestamp",
    "agent_id": "agent_identifier",
    "agent_region": "region_name",
    "agent_screen_url": "agent_screen_video_url",
    "agent_tl": null,
    "agent_video_url": "agent_video_url",
    "captured_images": ["selfie", "pan", "aadhaar", ... other doc list],
    "client_name": "client_name",
    "customer_IP": "ip_address",
    "end_time": "timestamp",
    "extras": {
      "applicant_name": "applicant_name",
      "current_address": "address",
      "current_employer_name": "employer_name",
      "institute_name": "institute_name",
      "loan_amt": "loan_amount",
      "pan_number": "pan_number",
      "session_status": "status",
      "session_type": "VKYC",
      "user_ip": "ip_address"
    },
    "feedback": "{\"type\":\"Approve\",\"comment\":\"All Successful\"}",
    "link_id": "link_identifier",
    "number_of_videos_uploaded": 2,
    "origin": "KWIKID_ID",
    "pan_request_time": "timestamp",
    "pan_url": "pan_url",
    "phone_number": "phone_number",
    "selfie_request_time": "timestamp",
    "selfie_url": "selfie_url",
    "session_id": "session_id",
    "session_status": "kyc_result_approved",
    "start_time": "timestamp",
    "summary_data": {
      "agent_id": "agent_id",
      "client_name": "client_name",
      "docs": [
        {
          "name": "Pan Card",
          "details": {},
          "front_url": "url"
        },
        {
          "name": "Aadhaar Card",
          "details": {},
          "facematch_score": {},
          "front_url": "url"
        },
        {
          "name": "Signature Match",
          "validator": {
            "success": false,
            "type": "isSignatureVerify"
          }
        },
        ... other doc list
      ],
      "overall_summary": [
        {"success": true, "title": "Selfie"},
        {"success": true, "title": "Pan Card"},
        {"success": true, "title": "Aadhaar Card"},
        null,
        {"success": true, "title": "Qna"}
      ],
      "qna": [
        {"q": "Question?", "a": "Answer"}
      ],
      "user_info": {
        "location": "location_address",
        "latitude": 0.0,
        "longitude": 0.0,
        "user_id": "user_id"
      }
    },
    "summary_json_url": "summary_url",
    "user_ack": 1,
    "user_id": "user_id",
    "user_video_url": "user_video_url",
    "vkyc_start_time": "timestamp",
    "zip_url": "zip_url"
  },
  "status": 200
}

Response Fields:

KeyTypeCharacter LengthDescription
session_dataobjectN/AContains all session-related data
IS_VIDO_UPLOADEDbooleanN/AIndicates if the video has been uploaded
aadhaar_request_timestringVariableTimestamp for Aadhaar request
aadhaar_urlstringVariableURL for Aadhaar front document
aadhaarback_urlstringVariableURL for Aadhaar back document
agent_assignment_timestringVariableTimestamp for agent assignment
agent_idstringVariableIdentifier for the agent
agent_regionstringVariableRegion of the agent
agent_screen_urlstringVariableURL for the agent's screen video
agent_tlnullN/ATeam leader identifier (if applicable)
agent_video_urlstringVariableURL for the agent's video
captured_imagesarrayVariableList of captured images
client_namestringVariableName of the client
customer_IPstringVariableIP address of the customer
end_timestringVariableTimestamp for the end of the session
extrasobjectN/AAdditional information about the session
feedbackstringVariableFeedback in JSON format
link_idstringVariableIdentifier for the link
number_of_videos_uploadedintegerN/ACount of videos uploaded
originstringVariableOrigin identifier
pan_request_timestringVariableTimestamp for PAN request
pan_urlstringVariableURL for PAN document
phone_numberstring10Phone number of the user
selfie_request_timestringVariableTimestamp for selfie request
selfie_urlstringVariableURL for the selfie document
session_idstringVariableIdentifier for the session
session_statusstringVariableStatus of the session
start_timestringVariableTimestamp for the start of the session
summary_dataobjectN/ASummary data of the session
summary_json_urlstringVariableURL for the summary JSON
user_ackintegerN/AUser acknowledgment status
user_idstringVariableIdentifier for the user
user_video_urlstringVariableURL for the user's video
vkyc_start_timestringVariableTimestamp for the start of VKYC
zip_urlstringVariableURL for the zip file
statusinteger3HTTP status code indicating the result

Session Status Values:

session_statusRemarks
waitinglink is sent
agent_allotedUser opens the link for preassigned call
kyc_request_acceptedAgent accepted the call
kyc_request_rejectedAgent rejects call
kyc_result_rejectedWhen KYC result is rejected at the end.
Auto reject if result is pending after expiry
kyc_result_approvedWhen agent approves the session at the end
session_expiredWhen scheduled call gets cancelled.
Link validity expires for that session
user_abandonedUser disconnected for a time longer than configured user_abandoned_timer
vkyc_requestedWhen user schedules a call
kyc_rejectedAgent has a pre-existing link attached.
If a new link is assigned, old gets rejected

401 Unauthorized

{
  "message": "Missing authorization header"
}

Response Fields:

KeyTypeCharacter LengthDescription
messagestringVariableError message indicating token issue

400 Bad Request

{
  "e": "list index out of range",
  "msg": "Invalid session id",
  "status": 400
}

Response Fields:

KeyTypeCharacter LengthDescription
estringVariableError message indicating session issue
msgstringVariableError message indicating session issue
statusinteger3HTTP status code for session issue

500 Internal Server Error

<!doctype html>
<html lang=en>
<title>500 Internal Server Error</title>
<h1>Internal Server Error</h1>
<p>The server encountered an internal error and was unable to complete your request.</p>

429 Rate limit

{
  "status": 429,
  "message": "Rate limit exceeded"
}

Response Fields:

KeyTypeCharacter LengthDescription
statusinteger3HTTP status code for rate limiting
messagestringVariableMessage indicating rate limit exceeded

4. Push User Data

POST /appapi/v1/dkyc/push_user_data

Pushes user data for digital KYC (DKYC) processing. It automates the KYC workflow by initiating a session, processing form data, and handling verification.

Headers:

HeaderValue
acceptapplication/json
authjwt_token
Content-Typeapplication/json

Request Body:

{
    "data": [
        {
            "step_info": {
                "doc_type": "forms",
                "label": "Personal Information Collection"
            },
            "user_form_data": {
                "BASIC_INFORMATION": { ... },
                "FAMILY_INFORMATION": { ... },
                "PERSONAL_INFORMATION": { ... }
            }
        },
        {
            "step_info": {
                "doc_type": "forms",
                "label": "Address Information"
            },
            "user_form_data": {
                "COMMUNICATION_ADDRESS": { ... },
                "PERMANENT_ADDRESS": { ... }
            }
        },
        {
            "step_info": {
                "doc_type": "forms",
                "label": "Verification Information"
            },
            "user_form_data": {
                "IDENTITY_VERIFICATION": { ... },
                "INPERSON_VERIFICATION": { ... }
            }
        },
        {
            "step_info": {
                "doc_type": "forms",
                "label": "FATCA Declaration"
            },
            "user_form_data": {
                "FATCA_DECLARATION": { ... }
            }
        },
        {
            "step_info": {
                "doc_type": "forms",
                "label": "Document Collection"
            },
            "user_form_data": {
                "DOCUMENT_COLLECTION": { ... }
            }
        }
    ],
    "extras": {
        "location": {
            "address": "Full address string",
            "latitude": 19.10817,
            "longitude": 72.903107
        }
    },
    "phone_number": "1212121212",
    "user_id": "dkyc-test-01"
}

Request Parameters:

NameTypeDescriptionMandatory
user_idstringUnique identifier for the userYes
phone_numberstringUser's phone numberYes
dataarrayArray of form data objects structured by stepYes
extrasobjectAdditional contextual informationNo

Form Data Fields:

BASIC_INFORMATION Fields

Field PathTypeDescriptionValid ValuesMandatory
BASIC_INFORMATION.uploadTypestringType of upload"03"Yes
BASIC_INFORMATION.panstringPAN numberFormat: AAAAA1234AYes
BASIC_INFORMATION.dobstringDate of birthFormat: DD-MON-YYYYYes
BASIC_INFORMATION.amcstringAMC codee.g., "TEST_AMC"Yes
BASIC_INFORMATION.ipvDatestringIPV dateFormat: DD-MON-YYYYYes
BASIC_INFORMATION.uidNostringUID/Aadhaar number12-digit numberYes
BASIC_INFORMATION.ekycTypestringeKYC type"I"Yes
BASIC_INFORMATION.kycTypestringKYC type"1", "2", "3", "4", "5"Yes

PERSONAL_INFORMATION Fields

Field PathTypeDescriptionValid ValuesMandatory
PERSONAL_INFORMATION.applicantTitlestringTitle of applicant"Mr", "Mrs", "Miss", "Dr"Yes
PERSONAL_INFORMATION.applicantFirstNamestringFirst name of applicant-Yes
PERSONAL_INFORMATION.applicantMiddleNamestringMiddle name of applicant-No
PERSONAL_INFORMATION.applicantLastNamestringLast name of applicant-Yes
PERSONAL_INFORMATION.genderstringGender"M", "F", "T"Yes
PERSONAL_INFORMATION.maritalStatusstringMarital status"01", "02", "03"Yes
PERSONAL_INFORMATION.occupationstringOccupation code"01" through "13", "99"Yes
PERSONAL_INFORMATION.applicantCitizenshipstringCitizenship code"01" (Indian), "02" (Other)Yes
PERSONAL_INFORMATION.applicantStatusstringApplicant status"R", "N", "P", "I"Yes

FAMILY_INFORMATION Fields

Field PathTypeDescriptionValid ValuesMandatory
FAMILY_INFORMATION.relationshipstringRelationship type"F" (Father), "S" (Spouse)Yes
FAMILY_INFORMATION.fatherTitlestringTitle of father"Mr", "Mrs"Yes
FAMILY_INFORMATION.fatherFirstNamestringFirst name of father-Yes
FAMILY_INFORMATION.fatherMiddleNamestringMiddle name of father-No
FAMILY_INFORMATION.fatherLastNamestringLast name of father-Yes
FAMILY_INFORMATION.motherTitlestringTitle of mother-No
FAMILY_INFORMATION.motherFirstNamestringFirst name of mother-No
FAMILY_INFORMATION.motherMiddleNamestringMiddle name of mother-No
FAMILY_INFORMATION.motherLastNamestringLast name of mother-No

COMMUNICATION_ADDRESS Fields

Field PathTypeDescriptionValid ValuesMandatory
COMMUNICATION_ADDRESS.commAddress1stringAddress line 1-Yes
COMMUNICATION_ADDRESS.commAddress2stringAddress line 2-No
COMMUNICATION_ADDRESS.commAddress3stringAddress line 3-No
COMMUNICATION_ADDRESS.commpincodestringPIN/Postal code-Yes
COMMUNICATION_ADDRESS.commCitystringCity-Yes
COMMUNICATION_ADDRESS.commDistrictstringDistrict-Yes
COMMUNICATION_ADDRESS.commStatestringState-Yes
COMMUNICATION_ADDRESS.commCountrystringCountry code-Yes
COMMUNICATION_ADDRESS.commMobileNoCodestringMobile country code"91"Yes
COMMUNICATION_ADDRESS.commMobileNostringMobile number-Yes
COMMUNICATION_ADDRESS.commEmailIdstringEmail address-Yes
COMMUNICATION_ADDRESS.comAddresstypestringAddress type"01" through "05"Yes
COMMUNICATION_ADDRESS.commAddressProofstringAddress proof type"01" through "33" (except "30")Yes
COMMUNICATION_ADDRESS.commIdentityNostringIdentity number for address proof-Yes

PERMANENT_ADDRESS Fields

Field PathTypeDescriptionValid ValuesMandatory
PERMANENT_ADDRESS.perAddress1stringAddress line 1-Yes
PERMANENT_ADDRESS.perAddress2stringAddress line 2-No
PERMANENT_ADDRESS.perAddress3stringAddress line 3-No
PERMANENT_ADDRESS.perPincodestringPIN/Postal code-Yes
PERMANENT_ADDRESS.perCitystringCity-Yes
PERMANENT_ADDRESS.perDistrictstringDistrict-Yes
PERMANENT_ADDRESS.perStatestringState-Yes
PERMANENT_ADDRESS.perCountrystringCountry code-Yes
PERMANENT_ADDRESS.perAddressProofstringAddress proof type-Yes
PERMANENT_ADDRESS.peridentityNostringIdentity number for address proof-Yes

IDENTITY_VERIFICATION Fields

Field PathTypeDescriptionValid ValuesMandatory
IDENTITY_VERIFICATION.idProofstringID proof type"01" through "15"Yes
IDENTITY_VERIFICATION.idProofIdentityNostringIdentity number-Yes
IDENTITY_VERIFICATION.aaplicantKycAccTypestringKYC account type"01"Yes

INPERSON_VERIFICATION Fields

Field PathTypeDescriptionValid ValuesMandatory
INPERSON_VERIFICATION.ipvDoneBystringName of person who did IPV-Yes
INPERSON_VERIFICATION.ipvEmployeeBranchstringEmployee branch-Yes
INPERSON_VERIFICATION.ipvEmployeeCodestringEmployee code-Yes
INPERSON_VERIFICATION.ipvEmployeeDesignationstringEmployee designation-Yes
INPERSON_VERIFICATION.ipvEmployeeNamestringEmployee name-Yes
INPERSON_VERIFICATION.ipvInstitutionCodestringInstitution code-Yes
INPERSON_VERIFICATION.ipvInstitutionNamestringInstitution name-Yes
INPERSON_VERIFICATION.kycDatestringKYC dateFormat: DD-MON-YYYYYes

FATCA_DECLARATION Fields

Field PathTypeDescriptionValid ValuesMandatory
FATCA_DECLARATION.fatcataxJurisdictionstringFATCA tax jurisdiction flag"Y", "N"Yes
FATCA_DECLARATION.fatcaRelPersonstringFATCA related person flag"N"Yes
FATCA_DECLARATION.dobDeclarationstringDate of birth declarationFormat: DD-MON-YYYYYes
FATCA_DECLARATION.placeDeclarationstringPlace of declaration-Yes
FATCA_DECLARATION.kraInfostringKRA info"eKYC-eIPV"Yes
FATCA_DECLARATION.panCopystringPAN copy flag"Y"Yes
FATCA_DECLARATION.exmtCatstringExemption category"N"Yes

DOCUMENT_COLLECTION Fields

Field PathTypeDescriptionValid ValuesMandatory
DOCUMENT_COLLECTION.docAddressProofstringAddress proof documentBase64 or URLYes
DOCUMENT_COLLECTION.docPhotostringPhoto documentBase64 or URLYes
DOCUMENT_COLLECTION.docSignstringSignature documentBase64 or URLYes
DOCUMENT_COLLECTION.docPerVerVideostringVerification videoBase64 or URLYes
DOCUMENT_COLLECTION.appDocAddrProofCorrespondencestringCorrespondence address proofBase64 or URLYes
DOCUMENT_COLLECTION.docEsignFormstringE-sign formBase64 or URLYes

Response:

Status CodeDescription
200Success, data processed successfully
400Invalid request parameters
500Internal server error

200 Success:

{
  "success": true,
  "session_id": "<session_id>",
  "track": {
    "user_id": "<user_id>",
    "session_id": "<session_id>"
  }
}
FieldTypeDescription
successbooleanOperation success status
session_idstringUnique session identifier
track.user_idstringUser ID from request
track.session_idstringSession ID created for this request

400 Bad Request:

{
  "msg": "Invalid request format",
  "status_code": 400,
  "success": false,
  "track": {
    "user_id": null,
    "session_id": null
  },
  "errors": {
    "missing_fields": ["field1", "field2"],
    "incorrect_formats": ["field3"]
  }
}
FieldTypeDescription
msgstringError message
status_codeintegerHTTP status code
successbooleanOperation success status (false)
trackobjectTracking information (may be null)
errorsobjectValidation error details

500 Internal Server Error:

{
  "msg": "An internal error occurred",
  "status_code": 500,
  "success": false,
  "track": {
    "user_id": "<user_id>",
    "session_id": "<session_id>"
  }
}
FieldTypeDescription
msgstringError message
status_codeintegerHTTP status code
successbooleanOperation success status (false)
trackobjectTracking information if available

429 Rate limit

{
  "status": 429,
  "message": "Rate limit exceeded"
}

Best Practices

1. Token Management

  • Store the JWT token securely
  • Refresh the token before it expires
  • Include the token in all authenticated requests

2. Error Handling

  • Implement proper error handling for all API responses
  • Log errors for debugging purposes
  • Implement retry logic for transient failures

3. Data Validation

  • Validate all input data before sending to the API
  • Ensure required fields are present
  • Format data according to API specifications

4. Rate Limiting

  • Implement rate limiting in your application
  • Handle 429 (Too Many Requests) responses appropriately