Skip to content

Create a new lead

POST

Creating a new customer from a lead

When creating a Client from a Lead, the core itself can determine that this is a Lead from an existing client. The kernel thinks that if the fields [Surname, First name, Patronymic, passport series, passport number] match, then this is a Lead from an existing client and the kernel will add an application to this client. Otherwise, new clients will be created.

If, when creating a lead, the parameters: ** firstName, lastName, patronymic, passport.seria, passport.no ** coincide with an existing client, then this lead will be linked to the client. There is validation within the legal framework. persons (included separately, there is no validation by default). Linking a lead to one or another legal entity. face occurs by the parameter ** managerId **.

When creating a new lead, you can send a completely filled address structure, or you can specify only three fields - country identifier ([countryId] (/documentation/page/73)), FIAS identifier (fiasId) and string addresses (fullAddressText) (including the apartment number) and all other fields will be filled in automatically. The trigger for sending a separate request to clarify the address is the filled FIAS identifier (fiasId) and address string (fullAddressText) fields. The fiasId field must correspond to the FIAS address line (fullAddressText). Correct values ​​are obtained by the method "[Retrieving FIAS address and ID by string] (/documentation/page/533)". For correct display of the address in the interface, three fields must be passed - the country identifier ([countryId] (/documentation/page/73)), the FIAS identifier (fiasId) and the address string (fullAddressText) (including the number apartments). More details with examples are described below in the addressData, registrationAddressData and addresses parameters.

The minimum information required to create a lead in the system is the "firstName", "mobilePhone" fields.

In order to determine which fields are required and must be passed in the request body (the JSON object passed in the request body), you need to look in the admin panel in the "Model Editor" category. ** It is important ** to understand that a client, an application is created from a lead and a contract can be created. Consequently, the minimum set of fields transmitted in the request body consists of the required fields of the client (individual or legal entity), application and contract. The system contains both system-required fields and mandatory fields, which can be disabled through the "Model Editor" functionality.

The minimum working example of a created lead and possibly created client objects and applications are described in the articles "[Elementary script for creating a lead] (/documentation/article/336)", "[Creating a client (physical .face) and requests from the lead automatically] (/documentation/article/337) ". A general description of working with API methods is described in the article "[Nuances ofand working with API] (/documentation/article/338) "

Request Body

application/json
object

Amount of current debt

Format"double"

Number of active loans

Format"int32"

Amount of current overdue payments

Format"double"
object

Apartment number

object

Building number

Building number

Format"int64"
object

The FIAS address chain. This parameter is optional. When creating a client, you can choose not to transfer

JSON URL string

Address chain

FIAS address string

House number

Housing type

Residence Address ID

Format"int64"

District

Nearest metro station

An outdated address, for example, an old street name in a passport. Used for informational purposes only!

Postal Code

Registration date in YYYY-MM-DD format

Format"date"

Scope

Locality, street, house

Landline telephone in digital form of international format (e.g. 74951001112, 37369123456)

object[]

Apartment number

object

Building number

Building number

Country identifier

Format"int64"
object

FIAS address chain

JSON URL string

FIAS code (street level)

FIAS address string

House number

Housing type

Additional address identifier

Format"int64"

Name of the settlement

Nearest metro station

The string of the address entered manually (not the actual address as in the passport)

Index of the position of the address in the collection of additional addresses

Format"byte"

Postal Code

Address assignment (registration, place of work, etc.)

Format"int64"

Registration date in YYYY-MM-DD format

Format"date"

Scope

Street name

Landline telephone in digital form of international format (e.g. 74951001112, 37369123456)

Number of adult children

Format"int32"

Loan amount

Format"double"

Scorista approved

Average monthly expenses

Format"double"

Country of citizenship ID

Format"int64"

Date of birth (YYYY-MM-DD)

Format"date"

Place of Birth

CVC code, 3 digits

Card holder (To store card data, the client must have a PCI DSS certificate)

Bank card number, only numbers, no spaces or other signs

Channel for the lead

Channel list : - PRESCORE - GENERATOR - SITE - ECOMM - UNO_MOMENTO - LOAN_APPLICATION

Valid values"ECOMM""GENERATOR""LOAN_APPLICATION""PRESCORE""SITE""UNO_MOMENTO"

Amount of children

Format"int32"
Format"int64"

Number of closed loans

Format"int32"

Credit product identifier : - 101339 - Short loans for a salary. - 1013310 - Loan for a year (annuity). - 1013311 - Loan for a year (with distributed OS) (Pyatak). - 1013312 - Residual with concessional tranches -

Format"int64"

Number of past arrears

Format"int32"

Refusal reason ID

Format"int64"

The number of dependents

Format"int32"

Device Type Id

Format"int64"

Email

Employer's TIN

Employer name

object[]

Additional fields

Additional field identifier

Format"int64"

The name of the additional field.

If you want the variables from the lead to be taken from the lead to the client / application / contract during the operation of the decision making system (DSS),

then you need to transfer them as follows: - client.field_name - for placing a field in the client - loanApplication.field_name - for placing a field in an application - contract.field_name - for placing a field in a contract

Additional field value

Name

How to get a loan

Format"int64"
object[]

List of goods

Item Amount

Format"double"

Item number

Product description

Product ID

Format"int64"

Name of product

Quantity of goods

Format"int32"

How did you hear about us : - 102171 - Transport - 102172 - Television - 102173 - Newspaper - 102174 - Outdoor advertising - 102175 - Friends - 102176 - Internet

Format"int64"

Lead ID

Format"int64"

INN

IP address

Does the declared region in the registration address match the applicant's IP address?

Does the declared region in the actual address (residence address) match the applicant's IP address?

Surname

object[]

Current loans and borrowings

The presence of delays in an existing loan or loan

Bank of an active loan or loan

Number / Date of the current credit or loan agreement

The amount of the current loan or loan

Format"double"

Object identifier bank of active credit or loan

Format"int64"

The name of the current loan or loan

Current loan or loan identifier

Format"int64"

Interest rate of an active loan or loan

Format"double"

Date of the last actual payment on an active loan or loan in the format YYYY-MM-DD

Format"date"

Monthly payment of an existing loan or loan

Format"double"

Frequency of payments of an existing loan or loan

Remaining debt of the current loan or loan

Format"double"

Details of a valid loan or loan

MAC address

Loan Specialist ID

Format"int64"

Average monthly income

Format"double"

Only numbers are indicated in international format 79886542301

Phone verification flag

Monthly loan payments

Format"double"

Individual (yes / no), default is true

Order code

object

The passport

Format"int64"

Expiration date in YYYY-MM-DD format

Format"date"

Founder's document type identifier : - 102121 - Driver's license - 102122 - SNILS - 102123 - Foreign passport - 102126 - Passport - 102127 - Other document - 102128 - No Currently, although this parameter is present, it will have the null value in the passport,

because there is a complementaryDoc object that contains the complementaryDocTypeId parameter, which has a value (see the description of this parameter above)

Format"int64"

Additional number

Certificate ID

Format"int64"

Date of issue in YYYY-MM-DD format

Format"date"

Issued by

Certificate number

Certificate Series

Department code

middle name

Number of closed delinquencies

Format"int32"

Requested loan term

Format"int32"
Valid values"DAYS""MONTHS""WEEKS""YEARS"

Referral link [maxLength: 255]

object

Apartment number

object

Building number

Building number

Format"int64"
object

The FIAS address chain. This parameter is optional. When creating a client, you can choose not to transfer

JSON URL string

Address chain

FIAS address string

House number

Housing type

Residence Address ID

Format"int64"

District

Nearest metro station

An outdated address, for example, an old street name in a passport. Used for informational purposes only!

Postal Code

Registration date in YYYY-MM-DD format

Format"date"

Scope

Locality, street, house

Landline telephone in digital form of international format (e.g. 74951001112, 37369123456)

Registration number (OGRN) (for a lead legal entity)

object[]

List of relatives

Relative address

Relative's date of birth (YYYY-MM-DD)

Format"date"

Affinity identifier : - 102141 - Wife - 102142 - Husband - 102143 - Mom - 102144 - Dad - 102145 - Daughter - 102146 - Son - 102147 - Brother - 102148 - Sister - 102149 - Colleagues - 1021410 - Friends - 1021411 - Grandmother - 1021412 - Grandfather - 1021413 - Uncle - 1021414 - Aunt - 1021415 - Other

Format"int64"

Comments by relatives

Relative email

Relative name

Relative ID

Format"int64"

Relative surname

object

Relative's passport

Relative patronymic

Resident

TIN of a relative

Relative phone number

Verified

A relative's place of work

Rosfinmonitoring passed inspection

Gender: - 101251 - Male - 101252 - Female

Format"int64"
Format"int64"

SNILS

Store code

Shop category identifier

Format"int64"

Unit ID 101791 - Moscow - 101792 - Moscow - Internet - 101793 - Sevastopol-1 - 101794 - Krasnogorsk - 101795 - Sevastopol- 2 - 101798 - Seventh - 1017910 - At Posadskaya - 101796 - First - 101797 - Second 101799 - Cashier of a slice

Format"int64"

Organization name (For Legal entity)

Passed a check on the passport database of the FMS

Card validity month, format: MM

Card validity year, format: YY

Format"int64"

Number of written off delinquencies

Format"int32"

Responses

OK

*/*
object

The identifier of the created item of the "Invoices" lookup

Format"int64"

If the element is successfully added to the directory, the status "ok" is returned. Otherwise, an error is returned

Valid values"error""ok"

Returns the date + time (kernel) in unix timestamp format in milliseconds

Format"int64"