How to create your own Front-Office

TurnKey Lender offers the full stack of API methods which can be used by clients to create their own Front-Offices. This can be a website or a mobile application where your borrowers register, apply for loans, track their loan application statuses, sign contracts, pay with a single click, and more.

Let's go through the TurnKey Lender's Front-Office and clarify which API endpoints need to be used to build this functionality.

API key & Permissions

To send an API request to TurnKey Lender, an API key is required. You can generate as many keys as you need with different access permissions in your Back-Office. For details, read the article How to get access to TurnKey Lender Public API

Base URL

The full path to every API endpoint is created as follows: https://{site_domain_name}/PublicApi/{version}/{endpoint_path}.

To simplify reading this article, the base URL (https://{site_domain_name}/PublicApi/{version}) is omitted everywhere below. For example, the endpoint POST https://trial-us.turnkey-lender.com/PublicApi/v7-8/User/Login is called POST /User/Login.

User token

Once a customer creates their personal account or authorizes on the platform, their unique AuthToken  is generated. This token is required as tkLender_UserAuthToken almost for all endpoints below.  

Welcome page

To create this web page, the following methods are used:

Once a customer submits selected loan terms, these data should be saved in some way while these data points are needed on the next step to create a loan application.  On TurnKey Lender Front-Office, for example, the next page (Create an account) opens, and all specified parameters are sent in the URL (for details, see Front site integration).

Create an account page

Once a customer submits their login and password, the following methods are used:

We recommend you add a captcha to your web page(s) where customers create new accounts and loans.

Application form

To save the provided customer's details, the next method should be used:

If a customer wants to upload their Photo (as an avatar), the following methods should be used:

Personal & Loan Documents

To support Personal & Loan documents management, the following endpoints need to be done:

Verify bank account

This step is available if the 'Bank account verification' integration (Paid, Flinks, etc.) is enabled on the Back-Office and all credentials are correctly set there. 

At the same time, integration with the selected service should be implemented on the side of the custom Front-Office.

The diagram below shows how to use the API methods and this algorithm works for any built-in provider (see Integrations By Country):

Login page

Only one endpoint is needed to authorize a customer: 

Restore password page

If a customer forgot their password, they have to provide their email  (the following method should be sent to the server): 

Customer's Dashboard

Personal details

To display and manage customer details, two methods can be used:

The following endpoints are needed to manage customer's Personal documents:

The authorized customer can change their password with the next method:

Bank Details

The following methods are designed for managing customer's payment options: 

Active loans 

The list of all customer's loans, which are not sent to the Archive, can be retrieved with the next method: 

Customers can pay directly from their dashboard if the following methods are used:

New loan

Creating a repeated loan (another loan taken out by the same customer) is much easier than creating the first one. Here are the required steps: