Contributor API development guide
This guide provides the technical specifications for developing and securely consuming the specified REST API endpoint securely and effectively.
1. Integration via Microservices and Daily Data Upload/Refresh
Database Information Upload/Update:
There should be one record per each loan for each borrower.
Contributors should extract a snapshot of their loan portfolio and upload to the database daily, ideally during the night.
Each daily upload should completely replace the previous one, ensuring only the latest data is available in the system.
The difference from month to month in the data will be:
(1) Update of the status of the loan and the payments for existing loans from previous day.
(2) Newly disbursed loans from the past day.
Note: Having the KYC (Know Your Customer) and Loan information in one table will result in duplicating the KYC columns for each loan of each borrower, but will also allow for easier extraction of a single CSV file and easier upload to the database.
2. Integration via Contributor API endpoint
Overview
This document explains how Contributors should return data when they get an API request from the LenderLink API. It covers the authentication methods and parameters needed to make the process easy and straightforward. This way, when a lender makes a request for a specific number to the LenderLink API, we will be able to obtain this information from the contributors.
API response layout
The structure of the Contributor Database table to be used as a layout for the API response.
The contributors should keep the data, which will be returned to LendeLink upon enquiry, up-to-date.
The response data should be generated in real-time or reflect data as of the most recent update (the same day or the day before).
Authentication Method
The API you are going to build must include some form of authentication. This could be either JWT (JSON Web Token) as a Bearer token, or a simple one-time generated token that you provide to LenderLink.
Additionally, IP whitelisting can be implemented, especially if using a one-time token.
Request for a Borrower Data
Contributors should build a REST API endpoint which accepts a request payload with recordId
and mobileNumber
, and returns a detailed response containing KYC and loan information.
Example API Endpoint
GET API URL (Endpoint)
Request Headers
Content-Type: application/json
Authorization: Token <token>
Query params:
requestId
String
Yes
Unique identifier
mobileNumber
String
Yes
Borrower's mobile number
Response of a borrower data request
Success Response
NB! In case there is information for more than one loan in the current response, the information is returned as each loan follows the structure described in the table, collected in an array (array of JSON object, each one following the example above).
For loanInfoStatusCode: "Rejected" , when you encounter a rejected borrower, you should return an object similar to the one below.
Fields Description
Please scroll to the right to see all the columns
Last updated