Skip to main content

Fetch Document Details for Loan Id

GET Documents for Loan Id

This API is used to retrieve all the customer's documentation, which includes their profile photo, ID proof, and collateral, for the specified loan ID.

Screenshot 2023-04-20 at 2.30.30 AM.png

URL: {{base_url}}/loan-management/v1/getDocuments

Run in Postman: GET Documents

Request: 

Request Type: GET
Authorization: Bearer Token
Query Parameter:
Key Data Type Description Validations Default Value Required
loanId Integer Unique identity constraint  N/A - Yes

Response:

Success: 200 OK
Schema
Attribute
Type Description Mandatory

response

Boolean Internal status code that denotes the status of the request

data




Array of Object Response Array of Object for the given inputs
document_type String Document that is submitted
document_state String

receiving_date Date Date the document is received
is_verified Boolean Is the document verified for the customer
document_url String Location where the Document is stored
document_status String

description String

document_value String

applicant_type String Type of applicant
customer_name String Full name of the customer
other_document_name String

document_id Integer Unique Identity for the document
document_owner String Documents belonging to whom
document_stage String

document_department String

disbursal_stage String

error

String Internal error object for the given inputs
Body
{
   "response": true,
   "data": [
      {
         "document_type": "string",
         "document_state": null,
         "receiving_date": null,
         "is_verified": true,
         "document_url": "string",
         "document_status": null,
         "description": null,
         "document_value": null,
         "applicant_type": "string",
         "customer_name": "string",
         "other_document_name": null,
         "document_id": 0,
         "document_owner": "string",
         "document_stage": null,
         "document_department": null,
         "disbursal_stage": null
      }
   ],
   "error": null
}

 

Success (Error): 200 OK

Note: If the API is unable to retrieve data for specific fields against the relevant Loan Id, then this error will occur.

Schema
Attribute

Type Description Mandatory
response
String Internal status code that denotes the status of request Yes
data
Object Response Object for the given inputs No
error Object Data Object Internal error object for the given inputs Yes

code integer Internal error code for API Yes
text String Error message for the API No
detail String Reason / Detail for the cause of error No
Body
Expected messages as per Status API :
Error Code Description
107001 An Exception occurred in saving data
{
    "response": false,
    "data": null,
    "error": {
        "code": 0,
        "text": "string",
        "detail": "string"
    }
}

Unauthorized: 401

Note: If the API is not authorized with the Token or if the authorization token has expired, this error is going to show up.

Body
{
    "code": 401,
    "message": "auth fail, you can retry!"
}