Skip to main content

Advanced Routing Example

Use algorithm.type = advanced when a merchant needs conditional rule-based routing instead of a fixed connector order. Advanced rules evaluate payment attributes, choose the first matching rule output, and fall back to default_selection when no rule matches.

Advanced Program Shape

Full Create Request

Logic Variants

AND Rule

Use one condition array when all conditions must match.

OR Rule

Use multiple statements when any statement can trigger the rule.

Nested AND + OR Rule

Use nested when a parent condition must match and then one nested branch can match.

Output Variants

Priority Output

Volume Split Output

Volume Split Priority Output

Use volume_split_priority when each split should return a priority list rather than a single connector.

Value Variants

Enum Variant Array

Number Array

Number Comparison Array

Notes

  • Advanced algorithms require statements; top-level single, priority, and volume_split algorithms do not.
  • Conditions in the same condition array behave like AND.
  • Multiple statements behave like OR.
  • nested allows a parent condition plus nested branch matching.
  • volume_split percentages should add up to 100.