Skip to main content

Policy Rules Reference

This page documents every condition type available in the Klear policy builder and how they are evaluated.

Condition types

ConditionFieldExample
Amount thresholdsgd_amountsgd_amount > 1000
Category matchcategorycategory in [Alcohol, Gambling]
Department scopedepartment_iddepartment = Sales
Submission lagtransaction_datetransaction_date < now - 60d
Missing receipthas_receiptsgd_amount > 50 AND has_receipt = false
GST codegst_codegst_code = BL

Actions

ActionEffect
Flag (soft)Warning shown to submitter; expense can still be submitted; flag visible to approvers
Block (hard)Expense cannot be submitted until the condition is resolved
Require extra approvalAdds chain steps beyond the base policy chain

Fraud signals (automatic)

Klear runs deterministic fraud checks on every submission. These are not configurable policies — they are system-level signals flagged automatically:

SignalTrigger
DuplicateSame amount + merchant + date within 7 days by same user
Round amountAmount is a round number (e.g. SGD 500.00)
Split expenseMultiple expenses from same merchant on same day summing to a policy threshold
OutlierAmount is more than 3x the user's average for that category
Fake merchantMerchant name matches known test/fictitious patterns

Fraud signals are visible to Admins and Approvers on the expense detail page. They do not block submission by default but they are recorded in the audit trail.

Priority and conflict resolution

When multiple policies match a single expense:

  1. Policies are evaluated in descending Priority order (higher number first)
  2. The first hard block encountered stops all further evaluation
  3. All soft flags from all matching policies are shown cumulatively
  4. The most specific approval chain (department over company-wide) is applied

Locked chain steps

Company-wide policy steps marked Locked cannot be removed or reordered by department-scoped policies. They are always present in the final resolved chain, regardless of department overrides.