Loan Issuing

The Loan Issuing process in Prime API represents the final step in converting an approved Application into an active loan. This process triggers the creation of loan records, sets up payment schedules, and initiates the fund disbursement process.

To issue a loan, an Application must be in an approved state with all required documents signed, bank accounts verified, and loan terms selected. The Prime system will validate these requirements before proceeding with loan creation and will return detailed error messages if any prerequisites are not met.

After successful loan creation, the system returns the loan terms including the loan ID, status, amounts, and payment schedule. This information should be stored on the Partner side for future reference. Prime executes loan originating with its lending bank partner, Lead, and processes the fund disbursement automatically. This disbursement typically happens the same or next business day. When the loan is issued, the Borrower receives a confirmation notification by email, with attachments that include all their signed agreements from both parties (Borrower and Prime).


Code sample

import requests

def create_loan(auth_token, application_id):
    headers = {
        "Authorization": f"Bearer {auth_token}",
        "Content-Type": "application/json"
    }
    
    payload = {
        "application_id": application_id
    }

    response = requests.post(
        "https://api.primeft.com/v2/loans",
        headers=headers,
        json=payload
    )
    
    if response.status_code == 201:
        result = response.json()
        return {
            "loan_id": result["loan"]["id"],
        }
    
    raise Exception(f"Failed to create loan: {response.text}")