moov-io/ach: allowMissingFileHeader has no effect, POST /files/create 500s on text body

Using moov-io/ach v1.34.2, calling POST /files/create with an ACH text body (Content-Type: text/plain) returned 500 errors for both valid and invalid files. The bypass flags allowMissingFileHeader=true and allowMissingFileControl=true in the query string had no effect. Submitting the same file as JSON worked fine, so the bug was specific to the raw NACHA text path.

The maintainer reproduced it: with no file header present, the text/plain path 500'd even with the bypass flags, while JSON creation was fine. He fixed it in PR #1379, released in v1.34.4, and the reporter confirmed "It's working for me".

So if POST /files/create?allowMissingFileHeader=true&allowMissingFileControl=true 500s on a raw NACHA body, upgrade to v1.34.4+. The working call looks like:

curl -XPOST 'https://example.com/files/create?allowMissingFileHeader=true&allowMissingFileControl=true' \
  -H 'Content-Type: text/plain' --data-binary @file.ach

Source: https://github.com/moov-io/ach/issues/1378

Source: https://github.com/moov-io/ach/issues/1378