NAV
shell

Introduction

Welcome to the Lendflow API! This document describes how clients can integrate with Lendflow, to create and monitor capital solutions offered by Lendflow.

We currently have language bindings in Shell! You can view code examples in the dark area to the right, and you can switch the programming language of the examples with the tabs in the top right. If you would like to request any additional bindings, then please contact the Technology Team at tech@lendflow.io and we will aim to add them in the near future.

Authentication

To authorize, use this code:

# With shell, you can just pass the correct header with each request
curl --header "Authorization: Bearer [YOUR_TOKEN]" https://app.lendflow.io/api/v1/

The following message will be returned, if the system is unable to authenticate you.

{
  "status":"Error",
  "code":500,
  "message":"Unauthenticated."
}

Make sure to replace [YOUR_TOKEN] with your API key.

Lendflow uses API Bearer Tokens to permit access to our API. You can register for a new Lendflow API key on our client portal in less than 60 seconds. The Bearer Token needs to be included in all API requests made to the API Service in the following form:

Authorization: Bearer [YOUR_TOKEN]

Capital Qualification

Pre-Qualification Endpoint

curl --header "Content-Type: application/json" \
  --header "Authorization: Bearer [YOUR_TOKEN]" \
  --header "Accept: application/json" \
  --request GET 
  --data '{
    "data": [
      {
          "statement_date": "2020-09-19T00:00:00Z",
          "statement_amount": 20000
      },
       {
          "statement_date": "2020-08-19T00:00:00Z",
          "statement_amount": 50000
      },
      {
          "statement_date": "2020-08-19T00:00:00Z",
          "statement_amount": 10000
      }

    ]
}' https://app.lendflow.io/api/v1/prequalification

The above command returns JSON structured like this:

{
    "code": 200,
    "data": {
        "issue_date": "2020-11-17T02:01:51Z",
        "prequalification_total": 13500
    }
}

This endpoint, allows registered users with historical financial data, to run a Pre-Qualification through the Lendflow system.

HTTP Request

GET https://app.lendflow.io/api/v1/prequalification

Query Parameters

Parameter Description Type
data.*.statement_date Date in ISO 8601 Date and Time Format. String
data.*.statement_amount The total aggregate amount of the month in question. String

Response

Parameter Description Type
issue_date The issue date of the prequalification computation. String
prequalification_total The amount the applicant is prequalified for. String

Capital Application

Apply for Capital

curl --header "Content-Type: application/json" \
  --header "Accept: application/json" \
  --header "Authorization: Bearer [YOUR_TOKEN]" \
  --request POST \
  --data '{
    "sandbox": "false",
    "uuid": "CUSTOM-IDENTIFIER-123456789",
    "dba_name": "Jonathan Parks Travel",
    "first_name": "Jonathan",
    "last_name": "Parks",
    "phone_number":4048788123,
    "email_address": "jparks@lendflow.io",
    "owner_date_of_birth": "01/12/1982",
    "owner_home_address": "12 South Jones Street",
    "owner_city": "Boise",
    "owner_state": "ID",
    "owner_zip": 83212,
    "owner_ssn": 871917734,
    "use_of_funds": "Own use",
    "amount_needed": 10000,
    "business_entity_type": "Travel Agency",
    "business_start_date": "12/31/2000",
    "business_address": "21 South Jones Street",
    "business_city": "Boise",
    "business_state": "ID",
    "business_zip": 83212,
    "employer_identification_number": "47-1850312",
    "number_of_owners": 1,
    "other_owners": [
        {
            "first_name": "Peter",
            "last_name": "Pan",
            "address": "12 South Jones Street",
            "city": "Boise",
            "state": "ID",
            "zip": 83212,
            "ssn": 871952434,
            "dob": "02/21/1981",
            "ownership": "50"
        }
    ]
  }' https://app.lendflow.io/api/v1/application

The above command returns JSON structured like this:

{
    "data": {
        "application_identifier": "7df9c924-4c85-4773-9b19-b2c8fa44f331"
    }
}

This endpoint, allows registered users, to submit a request for funding in the Lendflow system.

HTTP Request

POST https://app.lendflow.io/api/v1/application

Query Parameters

Parameter Required Description
sandbox false Perform a test run.
uuid false Custom identifier to attach to application.
dba_name true The business name of the company applying for funding.
first_name true The first name of the primary business holder.
last_name true The last name of the primary business holder.
phone_number true The phone number of the primary business owner.
email_address true The email address of the primary business owner.
owner_date_of_birth true The date of birth of the primary business owner.
owner_home_address true The first line of address of the primary business owner.
owner_city true The city of the primary business owner.
owner_state true The state of the primary business owner.
owner_zip true The zip or postal code of the primary business owner.
owner_ssn true The social security number of the primary business owner.
use_of_funds true The reason the business is applying for funding.
amount_needed true The requested amount to be funded.
business_entity_type true The type of business.
business_start_date true The date the business was started.
business_address true The first line of the business address.
business_city true The city that the business is regestered in.
business_state true The state that the business is regestered in.
business_zip true The zip or postal code that the business is regestered in.
employer_identification_number true The Employee Identification Number (EIN) of the business.
number_of_owners false The number of business owners.
other_owners.*.first_name false The first name of the additional business owner.
other_owners.*.last_name false The last name of the additional business owner.
other_owners.*.address false The first line of address of the additonal business owner.
other_owners.*.city false The city of the additional business owner.
other_owners.*.state false The state of the additonal business owner.
other_owners.*.zip false The zip or postal code of the additonal business owner.
other_owners.*.ssn false The social security number of the additonal business owner.
other_owners.*.dob false The date of birth of the additional business owner.
other_owners.*.ownership false The percentage of onwership of the additional business owner.

Retrieve Applications

curl --header "Content-Type: application/json" \
  --header "Authorization: Bearer [YOUR_TOKEN]" \
  --header "Accept: application/json" \
  --request GET https://app.lendflow.io/api/v1/deals

The above command returns JSON structured like this:

{
    "code": 200,
    "data": [
        {
            "uuid": "7df9c924-4c85-4773-9b19-b2c8fa44f331",
            "token": null,
            "business_name": "Jonathan Parks Travel",
            "first_name": "Jonathan",
            "last_name": "Parks",
            "state": "ID",
            "email": "jparks@lendflow.io",
            "status": "Application Started"
        }
    ]
}

This endpoint, allows registered users, to retrieve all applications that have been submitted through the integration widget and/or api.

HTTP Request

GET https://app.lendflow.io/api/v1/deals

Response

Parameter Description Type
data Array of applications belonging to the Bearer in question. Array
uuid The Unique Identifier associated to this account. String
token The unique customisable identifiable identifier, provided on application creation. String
business_name The business name of the applicant. String
first_name The First Name of the applicant. String
last_name The Last Name of the applicant. String
state The State that the applicant resides in. String
email The applicants email address. String
status The application status. String

Application Offers

Get all offers

curl --header "Content-Type: application/json" \
  --header "Authorization: Bearer [YOUR_TOKEN]" \
  --header "Accept: application/json" \
  --request GET https://app.lendflow.io/api/v1/offers

The above command returns JSON structured like this:

{
    "code": 200,
    "data": [
        {
            "businesslegalname": "Jonathan Parks Travel",
            "deal": "7df9c924-4c85-4773-9b19-b2c8fa44f331",
            "date_offer": null,
            "name": "Purchase Of Receivable",
            "offer_amount": "15000.00",
            "sell_factor_rate": "1.39",
            "term_length": 6
        }
    ]
}

This endpoint, allows registered users, to retrieve all offers.

HTTP Request

GET https://app.lendflow.io/api/v1/offers

Query Parameters

Parameter Description Type
complete Show all offers, regardless if seen before. Boolean

Response

Parameter Description Type
data Offers return data. Empty if no offers found. Array
businesslegalname Business Name of the deal for which the offer applies to. String
deal Lendflow Deal Identifier String
name The offer product type: Line Of Credit, Purchase Of Receivable, Term Loan, ARLOC String
credit_available Credit available. Only for Line of Credit and ARLOC String
discount_rate_10days 10 days discount rate after initial 30 days(%). Only for ARLOC String
discount_rate_month 30 day Discount Rate. Only for ARLOC String
term How many months of term. Only for ARLOC, TermLoan Integer
term_length Term length by number of months. Only for Line Of Credit and Purchase Of Receivable Integer
offer_amount Offer Amount. Only for Purchase Of Receivable and Term Loan String
sell_factor_rate Sell Factor Rate. Available to all product type except ARLOC String
credit_available Credit Available in facility. Only for Line Of Credit and ARLOC String

Commercial Applicant Data

Pull Application Commercial Data.

curl --header "Content-Type: application/json" \
  --header "Authorization: Bearer [YOUR_TOKEN]" \
  --header "Accept: application/json" \
  --request GET https://app.lendflow.io/api/v1/deal/{UUID}/commercial

The above command returns JSON structured like this:

{
    "code": 200,
    "data": {
        "uuid": "7df9c924-4c85-4773-9b19-b2c8fa44f331",
        "business_legal_name": "Jonathan Parks Travel",
        "commercial_data": {
            "plaid": null,
            "experian": [],
            "dnb": []
        }
    }
}

This endpoint, allows registered users, to pull commercial data on any given applicant.

HTTP Request

GET https://app.lendflow.io/api/v1/deal/{UUID}/commercial

Response

Parameter Description Type
uuid The UUID for the application.. String
business_legal_name The applicants business name. String
commercial_data.plaid Plaid data for the applicant. String
commercial_data.experian Experian Data for the applicant.. String
commercial_data.dnb D&B Data for the applicant. String

Errors

The Lendflow API uses the following error codes:

Error Code Meaning
200 Success -- Your request was processed.
400 Bad Request -- Your request is invalid.
401 Unauthorized -- Your API key is wrong.
403 Forbidden -- You do not have access to acces this API endpoint.
404 Not Found -- The specified application could not be found.
405 Method Not Allowed -- You tried to access an application with an invalid method.
406 Not Acceptable -- You requested a format that isn't json.
410 Gone -- The application requested has been removed from our servers.
418 I'm a teapot.
429 Too Many Requests -- You're requesting too many applications! Slow down!
500 Internal Server Error -- We had a problem with our server. Try again later.
503 Service Unavailable -- We're temporarily offline for maintenance. Please try again later.