# Installment Loan Calculator ⚠️(Deprecated)

Before [requesting an order](create-order.md), a customer must choose the installment loan duration and the discount method. Thus before calling the [Order Request](create-order.md) service, you should use a calculation method which based on the cost of the product will return a list containing the combination of all allowed loan duration (in months) with type and monthly payment amounts. You should pass the terms selected by a customer from the ones available in the returned list. You also may use our [JS SDK](modal.md) to retrieve this list.

:::note
Discount type and loan duration is assigned to each Merchant individually. Thus different Merchants might receive different values in the list.
:::

### Header

- `Content-Type` — application/json, required

- `Authorization` — Bearer <jwt_token>, required

  `Bearer <jwt_token>`, where the jwt_token is a value returned in an access_token parameter from the Authentication Method Response

### Body

- `amount` — object, required

  A total amount of the installment loan

- `client_id` — string, required

  A Merchant’s unique identifier is provided to a Company once it has been successfully registered

**http**

```api
GET /v1/services/installment/calculate HTTP/1.1
```

```properties
amount=1000.00
client_id=1006
```

### Response

- `discounts` — array

  A list of all allowed conditions within the given installment loan which contains the following attributes:

  - `month` — number

    An installment loan duration in months

  - `amount` — string

    An installment loan  monthly payment amount

  - `discounts` — string

    An installment loan discount code

**response**

```json
[
    {
        "month": 3,
        "amount": "333.33",
        "discount_code": "ZERO"
    },
    {
        "month": 4,
        "amount": "250.0",
        "discount_code": "ZERO"
    },
    {
        "month": 6,
        "amount": "175.72",
        "discount_code": "STANDARD"
    },
    {
        "month": 12,
        "amount": "93.50",
        "discount_code": "STANDARD"
    },
    {
        "month": 24,
        "amount": "52.73",
        "discount_code": "STANDARD"
    },
    {
        "month": 36,
        "amount": "39.44",
        "discount_code": "STANDARD"
    },
    {
        "month": 48,
        "amount": "33",
        "discount_code": "STANDARD"
    }
]
```
