API reference OpenAPI 3.1
PUT /risk-model

Put risk model

Bearer API key or staff session application/json operation putRiskModel

Request

Content type: application/json · required

The contract does not publish field-level properties for this request; the example below sends an empty object. Replace it with the payload described by the endpoint.

curl -X PUT "$MONICHEK_API/risk-model" \
  -H "Authorization: Bearer $MONICHEK_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'
const res = await fetch(`${MONICHEK_API}/risk-model`, {
  method: "PUT",
  headers: {
    Authorization: `Bearer ${MONICHEK_API_KEY}`,
    "Content-Type": "application/json",
  },
  body: JSON.stringify({}),
});

const data = await res.json();
import os
import requests

res = requests.put(
    f"{os.environ['MONICHEK_API']}/risk-model",
    headers={"Authorization": f"Bearer {os.environ['MONICHEK_API_KEY']}"},
    json={},
)
print(res.json())
$ch = curl_init(getenv('MONICHEK_API') . '/risk-model');
curl_setopt_array($ch, [
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_CUSTOMREQUEST => 'PUT',
    CURLOPT_HTTPHEADER => [
        'Authorization: Bearer ' . getenv('MONICHEK_API_KEY'),
        'Content-Type: application/json',
    ],
    CURLOPT_POSTFIELDS => json_encode([]),
]);
$response = curl_exec($ch);
curl_close($ch);
echo $response;

Responses

200 OK saved application/json
{
  "model": {
    "weights": {
      "base": 10,
      "screening_match": 25,
      "screening_review": 10,
      "pep": 25,
      "kyc_tier1": 15,
      "high_risk_country": 20
    },
    "bands": {
      "low": 35,
      "medium": 65,
      "high": 85
    }
  }
}