These are the commands for the command blocks needed for each stage of the ticket barrier system, in order. They do require some specific wiring, usually using comparators/repeaters etc (especially for buying tickets/railcards).
I plan on adding wiring diagrams to these at some later point. Question marks indicate values that need to be changed for every set of systems. Relative points for x/z coords are accepted - these are left out entirely.