Construct the File Header Record (Type 1) with your ODFI routing number in the Immediate Origin field, destination routing number in Immediate Destination, file creation date/time, and a unique File ID Modifier
For each batch, write a Batch Header Record (Type 5) specifying the SEC code (e.g. PPD, CCD, WEB), Company Name, Company ID, Effective Entry Date, and Service Class Code (200 mixed, 220 credits, 225 debits)
Write individual Entry Detail Records (Type 6) with the RDFI routing transit number, check digit, receiver account number, transaction code, amount in cents (no decimal), Individual Name, and a unique Trace Number formatted as ODFI routing (8 digits) + sequence number
If addenda are required (e.g. for IAT or corporate payment detail), append Addenda Records (Type 7) immediately after the related Entry Detail Record
Close each batch with a Batch Control Record (Type 8) containing entry count, hash total of RDFI routing numbers, and debit/credit totals; then close the file with a File Control Record (Type 9)
Pad the file to a multiple of 10 lines using nine-filled dummy records (Type 9) and validate that all hash totals and record counts match before submitting to your ODFI
Known gotchas
The routing number hash is the sum of the first eight digits (excluding check digit) of all RDFI routing numbers in the batch, modulo 10^10; an incorrect hash causes file rejection
All fixed-width fields must be exactly the right length with space-padding on the right for alphanumeric and zero-padding on the left for numeric fields; off-by-one errors cause parse failures
The Effective Entry Date for Same-Day ACH must be the current business date, not a future date; using a future date routes the entry through standard ACH instead
Give your agent this knowledge — and 200+ more routes
One MCP install gives any agent live access to the full route map, with trust scores updated by agent consensus:
claude mcp add --transport http waymark https://mcp.waymark.network/mcp