# API REFERENCE - CONFIGS



# Service Documentation: "Get Risk Classification"

The "Get Risk Classification" service is a web-based API designed to provide clients with the ability to determine the appropriate `RiskId` for use in integrations, particularly when initiating transactions that require a risk level assessment. This service is crucial for tailoring transaction processes based on the configured risk levels, ensuring that each transaction is handled according to its risk classification.

### Service Overview

- **Service Name**: Get Risk Classification
- **URL**: `{URL_Base}/api/Integration/GetRiskClassification`
- **Method**: GET
- **Functionality**: Returns the risk levels configured for transactions, aiding in the selection of an appropriate `RiskId`.

### Request Parameters

- **projectName**: Specifies the project for which risk classifications are requested. This parameter is included in the query string of the request URL.
- **apiKey**: A unique key provided to authenticate the request. This key ensures that the request is authorized to access the risk classification information.

### Response Structure

The API responds with a JSON object listing the risk levels configured within the system. Each entry in the response includes:

- **Id** (Int): The identifier for the risk level.
- **From** (Int): The lower bound of the transaction amount range for this risk level.
- **To** (Int): The upper bound of the transaction amount range for this risk level.

#### Example Response

> {  
>  "Id": 1,  
>  "From": 0,  
>  "To": 1000000  
> }

This sample response indicates a risk level (`Id` of 1) applicable for transactions up to 1,000,000 (currency unspecified).

### Configured Risk Levels Example

Risk levels are set to ensure no overlapping intervals. Each risk level begins where the previous one ended, plus one unit. Below is an example configuration:

<table id="bkmrk-id-from-to-1-%240-%241%2C0" style="width: 96.7901%;"><thead><tr><th style="width: 12.3404%;">Id</th><th style="width: 41.7021%;">From</th><th style="width: 45.5319%;">To</th></tr></thead><tbody><tr><td style="width: 12.3404%;">1</td><td style="width: 41.7021%;">$0</td><td style="width: 45.5319%;">$1,000,000</td></tr><tr><td style="width: 12.3404%;">2</td><td style="width: 41.7021%;">$1,000,001</td><td style="width: 45.5319%;">$15,000,000</td></tr><tr><td style="width: 12.3404%;">3</td><td style="width: 41.7021%;">$15,000,001</td><td style="width: 45.5319%;">$50,000,000</td></tr><tr><td style="width: 12.3404%;">4</td><td style="width: 41.7021%;">$50,000,001</td><td style="width: 45.5319%;">$100,000,000</td></tr></tbody></table>

### Example CURL Request

To query the risk classification for a specific project, utilize the following `curl` command:

> curl -X GET "{URL\_Base}/api/Integration/GetRiskClassification?projectName=projectName" -H "accept: application/json" -H "apiKey: your\_api\_key"

Ensure to replace `{URL_Base}` with the actual base URL of the service, `projectName` with your project name, and `your_api_key` with the API key provided to you.

### Important Notes

- The `apiKey` is crucial for the request's authorization. Ensure it is valid and has the necessary permissions to access the "Get Risk Classification" service.
- Accurately specify the `projectName` to retrieve the correct risk classifications.
- Use the risk levels provided by this service to choose the most fitting `RiskId` for your transactions, considering the transaction amount or other relevant criteria for your application.

This service plays a vital role for clients needing to apply dynamic risk levels to transactions, thereby enhancing the customization and security of web integrations.