Skip to content
Proud to collaborate with Microsoft for Startups

control.collection.match ​

Match two record lists by exact or decimal-tolerance rules without guessing collisions

Overview ​

PropertyValue
Workflow typeAtomic
LibraryApp-control
Version1.0

Input Schema ​

FieldTypeRequiredDefaultDescription
left_itemsjsonYes—First list of records to match.
right_itemsjsonYes—Second list of records to match.
rulesjsonYes—Non-empty list of {id?, left_field, right_field, op?, tolerance?} rules. Supported ops: eq (default), numeric_within, and numeric_within_abs (compares magnitudes — for ledgers whose sign conventions are opposite, e.g. a receivable against the bank posting that clears it). All rules must pass.
max_comparisonsintegerNo250000Maximum left/right pairs to evaluate; defaults to 250000 and cannot exceed 1000000.

Output Schema ​

FieldTypeRequiredDefaultDescription
left_itemsjsonNo——
right_itemsjsonNo——
rulesjsonNo——
max_comparisonsintegerNo——
matcheslistNo——
ambiguous_pairslistNo——
ambiguous_left_indexeslistNo——
ambiguous_right_indexeslistNo——
unmatched_leftlistNo——
unmatched_rightlistNo——
summaryjsonNo——
summary_textstringNo——
resultjsonNo——
failure_reasonstringNo——
failure_typestringNo——
failed_actionstringNo——
failed_at_statestringNo——
failed_stepstringNo——
failed_layerstringNo——
errorstringNo——
error_typestringNo——

States ​

StateInitialTerminalSuccessAuto-advanceDescription
pendingYesNo—execute—
completedNoYesYes——
failedNoYesNo——

State Diagram ​

Transitions ​

FromActionToDescription
pendingexecutecompleted—
* (any state)failfailed—

API Usage ​

bash
POST /api/workflows/start
Content-Type: application/json

{
  "workflow_type": "control.collection.match",
  "initial_data": {
    "left_items": "value",
    "right_items": "value",
    "rules": "value"
  }
}