# Split Tender Collect installments in minor units and prevent capture above the outstanding order balance. Commerce and fulfillment · framework · 0.1.0 ## Drive the workflow Start with `split_tender_start()`. For each event call `split_tender_step(snapshot, event, value)`, persist the returned snapshot, and dispatch `split_tender_command(snapshot)` to your application’s adapter. The host owns I/O, event ordering, duplicate detection and durable command delivery. A matching event produces one command. Rejected events retain the phase and saved quantity. An invalid snapshot yields an empty vector. The snapshot contains phase ID, saved quantity and last command ID. Event values are whole numbers from zero through one billion. In the table, **x** is the event value and **r** is the saved quantity. Rules match in listed order. To validate a whole history without running effects use `split_tender_replay(events, values)`. It returns the final snapshot or an empty vector on rejection. | Current phase | Event | Guard | Next phase | Command | New quantity | |---|---|---|---|---|---| | idle | invoice | x>0 | due | request_payment | x | | due | pay | x>0 and x