📘 Public beta · Endpoints are stable; OpenAPI specs and SDKs ship monthly. See changelog →
Products
Anti-Fraud Platform
Risk evaluation

Risk evaluation

The single most important endpoint in Anti-Fraud Platform. Call it on every onboarding application and every transaction.

POST/api/evaluate
Auth · API keyScope · evaluate:writeRate limit · 100/min default · provisioning up to 20k/min

Request

customerIdstringRequired
Your customer ID. Use the same ID across Identity / AML / Anti-Fraud — we cross-reference.
laneenumRequired
"onboarding" (application risk) · "transaction" (per-tx risk). Different rule pack per lane.
orgIdstring
Defaults to the API key's org; useful when an admin key acts across multiple sub-orgs.
sessionTokenstring
From POST /api/device-session, when the call originates from a mobile/web client.
externalIdstring
Your transaction/application ID for idempotent retries.
amountinteger
Transaction amount in the smallest currency unit. IDR uses rupiah directly.
currencystring (ISO-4217)
Three-letter code. Default "IDR".
dataobject
Free-form context — see common fields below.

Common data fields (transaction lane)

FieldNotes
channeltransfer · qris · card · atm · topup · withdrawal
beneficiaryNameCounterparty name
beneficiaryAccountCounterparty bank account / wallet ID
beneficiaryBankBank code (BCA, MANDIRI, …)
merchantCategoryMCC code for card / QRIS
ipAddressSource IP if available
userAgentSource UA if available

Common data fields (onboarding lane)

FieldNotes
fullNameAs entered by the applicant
nik16-digit Indonesian NIK
emailAs entered
phoneE.164 format
dateOfBirthYYYY-MM-DD
referralSourceHow the user found you
ipAddress, userAgentSource signals

data is intentionally open-ended — rules read whatever fields they reference, so you can pass everything you have.

Response

{
  "data": {
    "decision": "allow | flag | review | block",
    "fraudScore": 0-100,
    "subScores": {
      "rules": 0-100,
      "velocity": 0-100,
      "ml": 0-100
    },
    "appliedRules": [
      {
        "code": "VL-003",
        "name": "High amount unverified counterparty",
        "action": "review",
        "severity": "high",
        "score": 20
      }
    ],
    "sessionId": "alt_01HXY..."
  },
  "ok": true
}

fraudScore is the headline figure — a weighted blend of subScores. Use it for downstream analytics; use decision for the actual gate.

Decision logic

       ┌──────────────┐
       │   subScores  │
       │  rules: R    │
       │  velocity: V │
       │  ml: M       │
       └──────┬───────┘

       fraudScore = weighted(R, V, M)   ← weights configurable per-org


       applied rules' actions are merged.
       If a rule with action "block" fires AND its bypass-ML flag is true, decision = "block".
       Otherwise:
         fraudScore ≥ blockThreshold  → block
         fraudScore ≥ reviewThreshold → review
         fraudScore ≥ flagThreshold   → flag
         else                          → allow

Default thresholds: flag 30 · review 50 · block 75. Configurable via dashboard.

ML suppression

Rules can be marked bypassMl: true. These enforce their action regardless of ML confidence — useful for hard regulatory rules (blocked country, blocked NIK).

Non-bypass rules may have their action downgraded when ML confidence is below the org's per-lane mlThresholds:

block  → review  → flag  → allow

This prevents over-blocking when the ML model is uncertain. Disable by setting mlThresholds.onboarding = 0 (never downgrade) or mlThresholds.transaction = 0.

Idempotency

Pass externalId. Within 24 hours, replays return the original decision with data.idempotent: true.

Test mode

For unit-testing without persisting alerts:

POST/api/test-evaluate
Auth · API keyScope · evaluate:write

Accepts the same body plus an optional scenario:

{
  "lane": "onboarding",
  "scenario": "clean | medium | high",
  "payload": { /* same shape as /api/evaluate */ }
}

scenario injects a fake risk score (40 / 60 / 90) to deterministically force a decision path. Useful for testing your downstream handling without depending on actual rules firing.

Latency expectations

Sandbox is configured for low fixed cost, not low latency — expect p95 ~120ms.

Production p95 SLAs:

Tierp95Use case
Standard80msMost banking / lending traffic
Premium40msReal-time payments, QRIS at POS
Enterprise20msCo-located inside your VPC

Per-tier contracts are in your MSA — talk to sales@quantumelixir.tech if your latency budget is tight.

Don't put evaluate behind a queue

This endpoint is designed to sit on the critical path. Putting it behind an async queue forfeits the most valuable property — actionable risk decision before the transaction commits.