📃
Ninja Lender Api (en)
  • About
  • Life cycle
  • Hierarchy
  • Segments
  • Loan types
  • Loan templates
  • Import
    • Import
    • Mortage template
    • Customer loan template
  • API methods
    • Authorization
    • Get template body
    • Create application
    • Application loading
    • Applications list
    • Bet
    • Widthraw bet
    • Application purchase
    • Issuance
    • Resending
  • Handbooks
    • Refuse reason
    • Loan purpose
    • Organization types
    • Requisites
Powered by GitBook
On this page

Was this helpful?

  1. API methods

Authorization

method: POST

url: https://ninjalender.online/client/auth

Headers:

header key

header content

Content-Type:

application/json;

Request body:

Key

Type

Required

Description

login

text

+

User login

password

text

+

User password

segment

int

-

id of segment

Depending on the specified segment, when authorizing via the API, you will have access only to that part of the trading space of which this segment corresponds. BUT! When a application is loaded into the system, the selected segment does not matter as the reconciliation of the segment of the loaded loan comes from the loan type. Which in turn is attached to the template.

If the segment is not explicitly specified, the system will select the first segment from the list of segments.

response:

Key

Type

Description

code

int

Response code

message

string

Message

data

JSON.object

Response data

data.access_token

string

Token

The resulting token should be added to the headers in all subsequent requests.

Request example:

{
  "login": "test",
  "password": "25d55ad282aa400af464c76d713c07ad",
  "segment": "1"
}

Response example:

[
  {
    "code": 0,
    "message": "ok",
    "data": {
      "access_token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.e12pYXQiOjE1MzA5NTM3OTYsImp0aSI6IjVjOTkyMGU2N2Y0MzVmYTNjYTI4ZTg4ZDBkYTQ4ZWExIiwiaXNzIjoiZGV2My5uaW5qYWxlbmRlci5vbmxpbmUiLCJuYmYiOjE1MzA5NTM3OTYsImV4cCI6MTUzMTA0MDE5NiwiZGF0YSI6eyJhcHBsaWNhdGlvbl9pZCI6IjIiLCJ1c2VyX2lkIjoiMjUiLCJvcmdhbml6YXRpb25faWQiOiIxOSIsImFwcGxpY2F0aW9uX3R5cGUiOjB9fQ.ZUuAJFXP1Xmb4XNIV6E0CgOOxYE75V1pJbkc2hE2yy0"
    }
  }
]

List of errors:

Key

Message

-99

System error! Try again later or contact us

-2010103

login must not be blank

-2010104

Incorrect password

-2010105

segment not found

-2010108

Incorrect login

-2010109

Inactive user

-2010110

Password does not match

PreviousCustomer loan templateNextGet template body

Last updated 5 years ago

Was this helpful?