Skip to main content
This page is a reference for every building block available when defining rule conditions and actions. For a guided walkthrough of the Rule Builder, see Building rules.

Condition logic

Conditions are organized into a tree of groups:
  • all (AND) — Every condition in the group must match.
  • any (OR) — At least one condition in the group must match.
At the top level, a rule can have multiple paths connected with OR logic. If any path matches, the rule triggers. Within each path, you nest all / any groups to express complex boolean logic.
{
  "any": [
    {
      "all": [
        { "entity": "transaction", "property": "amount", "operator": "greaterThan", "value": 50000 },
        { "entity": "client", "property": "riskTier", "operator": "equal", "value": "HIGH" }
      ]
    },
    {
      "all": [
        { "entity": "transaction", "property": "amount", "operator": "greaterThan", "value": 100000 }
      ]
    }
  ]
}
This rule triggers if the transaction amount exceeds 50,000andtheclientishighrisk,oriftheamountexceeds50,000 **and** the client is high-risk, **or** if the amount exceeds 100,000 regardless of risk tier.

Entities

Each condition targets one of four entities:
EntityKeyDescription
TransactiontransactionThe transaction being evaluated — amount, type, currency, status, timestamps.
ClientclientThe customer associated with the transaction — risk tier, country, KYC status.
WalletwalletBlockchain wallets involved in the transaction — address, chain, labels.
Bank accountbankAccountFiat bank accounts involved — account number, bank country, routing info.

Entity relationships

For non-transaction entities, you can specify which participant the condition applies to:
RelationshipDescription
allMatches if the condition is true for any participant (sender or receiver).
senderOnly evaluate the sending party.
receiverOnly evaluate the receiving party.

Operators

Comparison operators

OperatorDescriptionExample
equalExact matchamount equal to 10000
notEqualNot equalstatus not equal to COMPLETED
greaterThanStrictly greateramount greater than 50000
greaterThanInclusiveGreater or equalamount greater than or equal to 50000
lessThanStrictly lessamount less than 100
lessThanInclusiveLess or equalamount less than or equal to 1000

Array operators

OperatorDescriptionExample
inValue is in the listcountry in ["US", "GB", "DE"]
notInValue is not in the listtype not in ["INTERNAL_TRANSFER"]
containsField contains the valuetags contains "high-risk"
doesNotContainField does not contain the valuetags does not contain "whitelisted"

Range operator

OperatorDescriptionExample
betweenValue falls within a range (inclusive)amount between [1000, 50000]

Aggregation operators

Aggregation conditions compute a value over a set of historical transactions before comparing with the operator and value. This enables velocity checks, cumulative thresholds, and statistical analysis.
OperatorDescription
sumTotal of the aggregated property.
countNumber of matching transactions.
avgAverage value.
minMinimum value.
maxMaximum value.
medianMedian value.
stddevStandard deviation.
percentileValue at a given percentile (requires aggregationPercentile field).
countDistinctNumber of distinct values for the aggregated property.

Aggregation fields

When using an aggregation, provide these additional fields on the condition:
FieldRequiredDescription
aggregationOperatorYesOne of the operators above.
aggregationPropertyYesThe field to aggregate (e.g., amount, convertedAmount).
aggregationTimeTypeYesThe time window type (see below).
aggregationTimeValueConditionalThe numeric value for the window (required for in_the_last, after, before).
aggregationTimePeriodConditionalThe time unit (required when aggregationTimeValue is set).
aggregationFiltersNoArray of sub-conditions to narrow which transactions are aggregated.
aggregationPercentileConditionalThe percentile target (required when operator is percentile).

Time windows

Time windows define the lookback period for aggregation conditions.

Time types

TypeDescription
all_timeAll historical transactions with no time boundary.
in_the_lastRolling window from now minus the specified period.
afterTransactions after a point in time.
beforeTransactions before a point in time.
betweenTransactions within a date range.

Time periods

Used with aggregationTimeValue to define the window length:
PeriodExample
minutesLast 30 minutes
hoursLast 24 hours
daysLast 7 days
weeksLast 2 weeks
monthsLast 3 months
yearsLast 1 year

Example: velocity check

“Count of deposits in the last 24 hours exceeds 10”:
{
  "entity": "transaction",
  "aggregationOperator": "count",
  "aggregationProperty": "id",
  "aggregationTimeType": "in_the_last",
  "aggregationTimeValue": 24,
  "aggregationTimePeriod": "hours",
  "aggregationFilters": [
    { "property": "type", "operator": "equal", "value": "DEPOSIT" }
  ],
  "operator": "greaterThan",
  "value": 10
}

Aggregation filters

Filters narrow which transactions are included in the aggregation. Each filter is a simple condition with property, operator, and value — the same comparison operators listed above apply. Common filter patterns:
  • Filter by transaction type: { "property": "type", "operator": "equal", "value": "WITHDRAW" }
  • Filter by currency: { "property": "currency", "operator": "in", "value": ["USD", "EUR"] }
  • Filter by direction: { "property": "direction", "operator": "equal", "value": "OUTGOING" }

Actions

Actions define what happens when a rule matches. Each rule must have at least one action.

CREATE_ALERT

Creates a compliance alert for analyst review.
Config fieldRequiredDescription
categoryYesAlert category. Use TRANSACTION_MONITORING for TM rules.
priorityYesLOW, MEDIUM, or HIGH.
statusYesInitial alert status. Typically NEW.
{
  "type": "CREATE_ALERT",
  "config": {
    "category": "TRANSACTION_MONITORING",
    "priority": "HIGH",
    "status": "NEW"
  }
}

HALT_TRANSACTION

Freezes the transaction until an analyst resolves the associated alert. Always used alongside CREATE_ALERT.
{
  "type": "HALT_TRANSACTION",
  "config": {}
}
A rule with HALT_TRANSACTION blocks settlement on every match. Reserve this for high-confidence patterns where false positives are rare.

Common rule patterns

Large transaction detection

Alert when a single transaction exceeds a threshold:
{
  "all": [
    {
      "entity": "transaction",
      "property": "amount",
      "operator": "greaterThanInclusive",
      "value": 100000
    }
  ]
}

Velocity check (structuring detection)

Alert when a customer makes more than 5 deposits under $10,000 in 24 hours:
{
  "all": [
    {
      "entity": "transaction",
      "aggregationOperator": "count",
      "aggregationProperty": "id",
      "aggregationTimeType": "in_the_last",
      "aggregationTimeValue": 24,
      "aggregationTimePeriod": "hours",
      "aggregationFilters": [
        { "property": "type", "operator": "equal", "value": "DEPOSIT" },
        { "property": "amount", "operator": "lessThan", "value": 10000 }
      ],
      "operator": "greaterThan",
      "value": 5
    }
  ]
}

High-risk customer with large withdrawal

Combine entity conditions for targeted detection:
{
  "all": [
    {
      "entity": "client",
      "property": "riskTier",
      "operator": "equal",
      "value": "HIGH"
    },
    {
      "entity": "transaction",
      "property": "type",
      "operator": "equal",
      "value": "WITHDRAW"
    },
    {
      "entity": "transaction",
      "property": "amount",
      "operator": "greaterThanInclusive",
      "value": 50000
    }
  ]
}

Cumulative threshold

Alert when total outgoing volume exceeds $200,000 in 30 days:
{
  "all": [
    {
      "entity": "transaction",
      "aggregationOperator": "sum",
      "aggregationProperty": "amount",
      "aggregationTimeType": "in_the_last",
      "aggregationTimeValue": 30,
      "aggregationTimePeriod": "days",
      "aggregationFilters": [
        { "property": "direction", "operator": "equal", "value": "OUTGOING" }
      ],
      "operator": "greaterThanInclusive",
      "value": 200000
    }
  ]
}