Skip to main content
POST
curl

Authorizations

x-api-key
string
header
required

Body

application/json

Creates a CUSTOM rule. Rules in ACTIVE mode take effect immediately for new transactions - create in TEST mode and backtest first.

title
string
required

Rule name. Unique per application among non-deleted rules; duplicates return 400.

category
string
required

Risk theme used for grouping and reporting, e.g. finance, aml_ctf, anomaly_detection, fatf, device_intelligence, crypto_monitoring, travel_rule, responsible_gaming, e_commerce.

mode
enum<string>
required

ACTIVE evaluates live. TEST evaluates and records rule runs but never touches score or status - the recommended starting mode. DISABLED is skipped.

Available options:
ACTIVE,
DISABLED,
TEST
description
string | null
evaluation_mode
enum<string>
default:ALL

Whether every condition must match (ALL) or at least one (ANY). Ignored when conditions use group_index.

Available options:
ALL,
ANY
scope
object

Which transactions the rule applies to. Only these three keys are accepted.

conditions
object[]
aggregation
object[]
actions
object[]

One rule action. A rule can carry several; all are applied together when it matches. Rules in TEST mode record what they would have done without applying any action.

metadata
object

Free-form metadata stored on the rule.

Response

The created rule.

uuid
string<uuid>
title
string

Rule name. Unique per application among non-deleted rules; duplicates return 400.

description
string | null
category
string

Risk theme used for grouping and reporting, e.g. finance, aml_ctf, anomaly_detection, fatf, device_intelligence, crypto_monitoring, travel_rule, responsible_gaming, e_commerce.

mode
enum<string>

ACTIVE evaluates live. TEST evaluates and records rule runs but never touches score or status - the recommended starting mode. DISABLED is skipped.

Available options:
ACTIVE,
DISABLED,
TEST
evaluation_mode
enum<string>
default:ALL

Whether every condition must match (ALL) or at least one (ANY). Ignored when conditions use group_index.

Available options:
ALL,
ANY
scope
object

Which transactions the rule applies to. Only these three keys are accepted.

conditions
object[]
aggregation
object[]
actions
object[]

One rule action. A rule can carry several; all are applied together when it matches. Rules in TEST mode record what they would have done without applying any action.

metadata
object

Free-form metadata stored on the rule.

severity
enum<string> | null

Informational severity carried by library rules; not settable on custom rules.

Available options:
UNKNOWN,
LOW,
MEDIUM,
HIGH,
CRITICAL
source
enum<string>

PRESET rules come from the library (install/uninstall, mode-only edits); CUSTOM rules are fully yours.

Available options:
PRESET,
CUSTOM
library_key
string | null

Stable library identifier; null for custom rules.

latest_triggered_at
string<date-time> | null
run_count
integer

How many transactions matched this rule.

approved_count
integer
reviewed_count
integer
declined_count
integer
awaiting_user_count
integer
approved_pct
number
reviewed_pct
number
declined_pct
number
created_at
string<date-time>
updated_at
string<date-time>