ⓘ Reference
A Rail is a money-movement contract — one well-known way value flows between roles. ACH origination, wire settlement, intra-day pool balancing, fee debits all live as Rails. Every transaction must match a rail by (rail_name, source_role, destination_role).
Required: name (unique identifier; chains, templates, and limit schedules all reference rails by this name — it doubles as the L1 matview's rail_name column value). Endpoint roles (source_role / destination_role) are edited on the rail itself after it's created — required for the validator to accept the rail as connected.
Two-leg rail requires:
source_role+destination_role— Role(s) the debit + credit legs post to. Use multi-select for unioned roles (validator F1).expected_net— the standalone-firing Conservation contract. Typically0; leave blank ONLY when this rail is exclusively used as a TransferTemplate leg (the template owns the bundle's net then).
Both legs auto-balance to expected_net by the template's completion deadline (or on the rail's own firing when standalone).