albis.getRates - ALBIS-GROUP/LeaseKitSDK-JS GitHub Wiki

albis.getRates(values, albisToken) ⇒ ResponseGetRates

getRates(values, albisToken) retrieves proposed rates. Returned object is needed for proceed getApplication(albisToken)

Kind: instance method of Albis
Returns: ResponseGetRates - response object

Param Type Description
values Object An object with data for providing rate offers
values.purchasePrice number Total net value of the cart [EUR]
values.productGroup number Product group of chosen products
[values.downPayment] number Net value of down payment [EUR]. Default 0 (optional)
values.contractType number Contract type
values.paymentMethod number Payment options
albisToken Object object with Albis token, which lets to communicate with Albis API

Example

Albis.getRates({ purchasePrice: 5000, productGroup: 1, downPayment: 500, contractType: 1, paymentMethod: 1 }, { token: '12345' })

ResponseGetRates : Object

Kind: global typedef
Properties

Name Type Description
response.id string json rpc lib id
response.jsonrpc string json rpc version number ("2.0")
response.result Array.<Object> array of objects i.e. { leaseTerm: 18, rate: 188.8, rateWithInsurance: 195.7, total: 3522.6 }
⚠️ **GitHub.com Fallback** ⚠️