Loan Risk Levels Configuration
  • 03 May 2023
  • 2 Minutes To Read
  • Dark
    Light
  • PDF

Loan Risk Levels Configuration

  • Dark
    Light
  • PDF

Article Summary

Risk Levels are user-defined categories composed of an interval for number of days in arrears and a correspondent provision amount. Risk levels will be used to calculate the organization’s portfolio at risk (PAR), based on the number of loans in arrears that fall into each level. For more information, see Defining Risk Levels.

With Configuration as Code (CasC), you may batch configure your loan risk levels configuration via the API using YAML. For general information on CasC, see Configuration as Code Overview.

API Operations

CasC for loan risk levels supports two operations.

ActionEndpointDescription
GET/configuration/loanrisklevels.yamlGet current loan risk levels configuration.
PUT/configuration/loanrisklevels.yamlWrite a new loan risk levels configuration to Mambu.
Please Note

If you PUT a configuration to Mambu, any current configuration settings not included in the new YAML configuration will be deleted. PATCH requests are not currently supported.

Requests

For general information on CasC requests such as authentication and required headers, see Configuration as Code Overview.

The following section shows sample requests using curl and basic authentication. For all examples, replace TENANT_NAME with your actual tenant name.

GET configuration

curl -X GET 'https://TENANT_NAME.mambu.com/api/configuration/loanrisklevels.yaml' \
-H 'Accept: application/vnd.mambu.v2+yaml' \
-H 'Authorization: Basic {auth}'

{auth} is the base-64-encoded value of username:password. For more information, see Authentication in our API reference.

PUT configuration

curl -X PUT 'https://TENANT_NAME.mambu.com/api/configuration/loanrisklevels.yaml' \
-H 'Accept: application/vnd.mambu.v2+yaml' \
-H 'Content-Type: application/yaml' \
-H 'Authorization: Basic {auth}' \
--data-binary @loanrisklevels.yaml

{auth} is the base-64-encoded value of username:password. For more information, see Authentication in our API reference.

@loanrisklevels.yaml represents the absolute path of the file on your device.

Use “--data-raw” if you want to specify the YAML body inline.

Configuration body example

---
loanRiskLevels:
- id: "1"
  name: "Mild Risk"
  arrearsFrom: 10
  arrearsTo: 30
  provisioningPercent: 4.5
- id: "1153177013"
  name: "Healthy loans"
  arrearsFrom: 0
  arrearsTo: 0
  provisioningPercent: 3
- id: "2"
  name: "Moderate Risk"
  arrearsFrom: 30
  arrearsTo: 40
  provisioningPercent: 7

Attributes

NameTypeDescriptionRequired
idStringUser-defined ID, globally unique.
nameStringName of the loan risk level.
arrearsFromInteger(int32)Lower level of the band of number of days the account is at risk.
arrearsToInteger(int32)Upper level of the band of number of days the account is at risk.
provisioningPercentNumberHow much to provision at this level (as a percent).

Replies

If you do not receive a 200 OK status code then fix any validation errors and make another PUT request until you receive a 200 OK status code.

Please Note

If you PUT a valid YAML configuration to the API and you do not receive a 200 OK status code within 60 seconds, you may receive a 504 Gateway Timeout status code. We expect all responses to be below 60 seconds.

If you encounter this issue, please contact us through Mambu Support so we can investigate it.

Input Requirements

NameValidations
idMust not be blank, must not exceed 32 characters in length, must contain only letters and numbers, and must be unique in the configuration.
nameMust not be blank and must not exceed 256 characters in length.
arrearsFrom arrearsToMust be a whole number (positive or 0), cannot be null or empty, cannot be larger than 2,000,000,000.
provisioningPercentCan be any number, but cannot be null or empty.

Was this article helpful?