ADDITIONS
- feat: add
DeleteEntries
andDeleteADVEntries
to remove entries from a Batch
IMPROVEMENTS
- fix: truncate utf8 strings correctly
IMPROVEMENTS
- doc: mention how ACK/ATX present Refused Acknowledgement Code
- fix: populate CTX receiving company / addenda indicator from JSON
BUILD
- build: setup automated benchmark job
- fix(deps): update module github.com/moov-io/base to v0.53.0
- fix(deps): update module github.com/moov-io/iso4217 to v0.3.2
- fix(deps): update module github.com/prometheus/client_golang to v1.20.5
- fix(deps): update module golang.org/x/net to v0.31.0
BREAKING CHANGES
This release of moov-io/ach adjusts the type of ENRPaymentInformation.EnrolleeClassificationCode
to be a string (was int). This change is needed to properly support the values "A" (consumer) and "B" (company).
This release also changes the parsing functions for ENR PaymentRelatedInformation
to operate outside of a BatchENR
. There was no reason for the method to be a pointer receiver.
This release also changes the parsing functions for DNE PaymentRelatedInformation
to return parsed information for all entries in a DNE batch. Previously only the first DNE record would be returned.
IMPROVEMENTS
- api: ValidateOpts exists on File
- break: unlink ENR PaymentRelatedInformation parser from BatchENR
- cmd/achcli/describe: accept mask flags for ENR payment related information
- cmd/achcli/describe: mask customer SSN in DNE Addenda05 records
- fix: DNE records use prenote TransactionCodes
- fix: cleanup ENR parsing and generation, add tests
- fix: read validateOpts from JSON blobs
- fix: verify ACK and ATX amounts are zero
- test: verify stdlib JSON marshal retains ValidateOpts
BUILD
- build(deps): bump rexml from 3.3.5 to 3.3.6 in /docs
- fix(deps): update module github.com/prometheus/client_golang to v1.20.1
IMPROVEMENTS
- fix: allow ForeignExchangeReferenceIndicator=0 when ForeignExchangeIndicator=FF
- fix: correctly reverse loan transaction codes, test GL credit/debit
BUILD
- build(deps): bump golang from 1.22-alpine to 1.23-alpine
- build(deps): bump golang.org/x/net from 0.27.0 to 0.28.0
- build(deps): bump golang.org/x/text from 0.16.0 to 0.17.0
- build(deps): bump rexml from 3.3.2 to 3.3.3 in /docs
- build(deps-dev): bump github-pages from 231 to 232 in /docs
- build: convert docker-compose to docker compose
IMPROVEMENTS
- feat: add AllowZeroEntryAmount validation option
BUILD
- build(deps): bump ossf/scorecard-action from 2.3.3 to 2.4.0
- build(deps): bump rexml from 3.2.8 to 3.3.2 in /docs
IMPROVEMENTS
- docs: fix capitlization error. Changed '9' to '('
- docs: update CONTRIBUTING.md
- fix: expand which latin characters are accepted
BUILD
- build(deps): bump github.com/moov-io/base from 0.49.4 to 0.50.0
- fix(deps): update module golang.org/x/net to v0.27.0
IMPROVEMENTS
- feat: allow specifying line ending via API
- fix: return checksum error when ImmediateOrigin doesn't validate
BUILD
- build: run oldstable Go in CI
- build(deps): bump github.com/moov-io/base from 0.49.3 to 0.49.4
- build(deps-dev): bump nokogiri from 1.16.2 to 1.16.5 in /docs
- build(deps): bump rexml from 3.2.6 to 3.2.8 in /docs
- build(deps): bump golang.org/x/net from 0.25.0 to 0.26.0
This release of moov-io/ach removes the check verifying Amount is non-zero. This has been removed because returned Prenotes were being incorrectly marked as invalid.
IMPROVEMENTS
- fix: stop checking if .Amount is valid for returns
BUILD
- fix(deps): update module golang.org/x/net to v0.25.0
- build(deps): bump bulma-clean-theme from 0.13.3 to 0.14.0 in /docs
- build(deps): bump golang.org/x/text from 0.14.0 to 0.15.0
IMPROVEMENTS
- fix: make -skip-validation flag not depend on -validate flag being present
This release of moov-io/ach standardizes ValidateOpts
query parameters on the HTTP server. Previously slightly different names
were used, which are still supported and deprecated. The GET/POST /files/{fileID}/validate
endpoints accept ValidateOpts
as
query parameters with this release.
IMPROVEMENTS
- feat: standardize validate opts query params, accept on GET/POST validate
- fix: nil check BatchHeader when reading JSON
- server/test: verify allowUnorderedBatchNumbers
IMPROVEMENTS
- docs: update required fields for CreateFile schema object in openapi.yaml
- fix: add R62 to list of dishonored return codes
BUILD
- build(deps): bump github.com/aws/aws-lambda-go from 1.46.0 to 1.47.0
IMPROVEMENTS
- fix: preserve IAT BatchControl.CompanyIdentification when parsing from json
IMPROVEMENTS
- fix: CTX allows SavingsReturnNOCDebit
BUILD
- build(deps): bump golang.org/x/net from 0.22.0 to 0.24.0
- build(deps): bump golang.org/x/sync from 0.6.0 to 0.7.0
IMPROVEMENTS
- fix: allow "slashed zero" which some OCR software produces
- test: verify trace numbers are kept through HTTP create
IMPROVEMENTS
- perf: improve includesValidCharacters lookups
- perf: isTraceNumberODFI
The latest update to moov-io/ach introduces significant performance enhancements, particularly to the MergeFiles(...)
function. Through rigorous testing, we've ensured that the merging process accurately incorporates all input files. However, should any issues arise, we encourage you to report them.
Furthermore, this update includes a new function, MergeDir(...)
, designed to combine a directory of ACH files efficiently, mirroring the functionality of MergeFiles but with enhanced performance.
Key modifications to the behavior of MergeFiles(..)
include:
- The management of duplicate trace numbers has been refined. They are now allocated to distinct batches within the same output file, in compliance with Nacha regulations, which mandate separation into different batches.
- The merging process now more accurately aligns with the
Conditions
constraints, significantly improving upon previous versions where the limit was seldom fully utilized. - ValidateOpts are now aggregated across all input files, ensuring that any non-zero value (for example,
true
) applies uniformly to all batches and entries within the file, streamlining the validation process.
IMPROVEMENTS
- cmd/achcli: read files in Nacha or JSON automatically
- docs: Update openapi.yaml - addenda17/addenda18/format for entryHash
- docs: add links to http endpoints where features overlap
- docs: clarify what isn't supported by MergeFiles
- feat: MergeFiles now combines
ValidateOpts
from all input files - fix: nil check Addenda records inside FileFromJSON
- fix: recreate batch header to avoid mutations
- merge: delve into subdir with custom FS provided
- merge: option to walk sub directories
- refactor: improve merge performance
- test: add checks for pickOutFile, findOutBatch and lineCount
- test: verify entries that are very close still merge properly
- test: verify more numericField inputs
BUILD
- fix(deps): update module golang.org/x/sync to v0.6.0
- build(deps): bump google.golang.org/protobuf from 1.32.0 to 1.33.0
- build(deps): bump golang.org/x/net from 0.21.0 to 0.22.0
IMPROVEMENTS
- fix: further reuse memory buffers
- fix: nil check inside setEntryRecordType
- fix: parse large files without newlines
BUILD
- build(deps): bump github.com/stretchr/testify from 1.8.4 to 1.9.0
ADDITIONS
- feat: Add
IATCorrectedDataField() string
onAddenda98
to return the expanded field
IMPROVEMENTS
- all: reduce string allocations
- fix: allow IAT corrections to not have IAT addenda records
- fix: read additional corrected data on IAT corrections
BUILD
- build(deps): bump github.com/prometheus/client_golang
IMPROVEMENTS
- fix: check AllowMissingFileHeader and AllowMissingFileControl in reader
IMPROVEMENTS
- fix: Correctly assign Category to IAT entries.
BUILD
- build(deps): bump golang.org/x/net from 0.20.0 to 0.21.0
- chore(deps): update dependency github-pages to v231
IMPROVEMENTS
- fix: skip reserved fields in Dishonored Returns
BUILD
- build(deps): bump golang from 1.21 to 1.22
- build: experiment with ARM M1 builders and releases
- build: print crashers after fuzzing
- fix(deps): update module github.com/aws/aws-lambda-go to v1.46.0
IMPROVEMENTS
- fix: use constructor to create IATEntryDetails in reader
- test/issues: write up scenario for Issue 1312
BUILD
- build(deps): bump actions/download-artifact from 1 to 4
- build(deps): bump actions/upload-artifact from 1 to 4
IMPROVEMENTS
- api: fixup EntryDetail required fields
- api: label required fields on EntryDetail
- feat: Addenda99.SetOriginalEntryReturnDate
- feat: Parse Addenda99.AddendaInformation
- feat: improve addenda99 for dishonored returns
- feat: add CheckingReturnNOCCredit to list of valid ATX txn codes (#21)
- fix BatchHeader.EffectiveEntryDateField (#20)
- fix: Don't truncate Addenda99.AddendaInformation
- fix: trim "R" in dishonored and contested setter
- test: verify "!" is allowed in isAlphanumeric
BUILD
- build(deps): bump actions/download-artifact from 1 to 4
- build(deps): bump actions/upload-artifact from 1 to 4
- build(deps): bump github.com/moov-io/base from 0.48.2 to 0.48.3 (#1341)
- build(deps): bump github.com/aws/aws-lambda-go from 1.41.0 to 1.43.0 (#1346)
- build(deps): bump github/codeql-action from 2 to 3 (#1342)
- build(deps): bump github.com/prometheus/client_golang
- build(deps): bump github.com/aws/aws-lambda-go from 1.43.0 to 1.44.0
- build(deps): bump golang.org/x/net from 0.19.0 to 0.20.0
- build(deps): bump github.com/moov-io/base from 0.48.3 to 0.48.5
- build(deps): bump actions/cache from 3 to 4
- build(deps): bump github.com/aws/aws-lambda-go from 1.44.0 to 1.45.0
- chore(deps): update dependency jekyll-feed to v0.17.0 (#1337)
IMPROVEMENTS
- all: fix errors found by nilaway
- api: update amount to be long to allow handling of amounts larger than 21M (#1335)
- webui: better overflow layout
BUILD
- build(deps): bump actions/setup-go from 4 to 5
- build(deps): bump golang.org/x/net from 0.18.0 to 0.19.0
IMPROVEMENTS
- docs: improve TraceNumber
- fix: check .UnequalAddendaCounts in CTX validation
BUILD
- build(deps): bump golang.org/x/net from 0.17.0 to 0.18.0
- fix(deps): update module github.com/moov-io/base to v0.48.2
IMPROVEMENTS
- fix: Parse FileIdModifier from file header; don't assume 'A'
- fix: revert "reduce allocations when parsing FileHeader"
- test/issues: verify FileIDModifier is read
BUILD
- build(deps): bump github.com/moov-io/base from 0.47.0 to 0.47.1
This release contains multiple performance improvements ontop of what v1.33.0 has included. The comparison to v1.32.2 is below:
v1.32.2 compared to v1.33.1
BenchmarkParsing/Read_../testdata/20110805A.ach-16 1840 632450 ns/op 97797 B/op 1953 allocs/op
BenchmarkParsing/Read_../testdata/20110805A.ach-16 1909 606422 ns/op 57270 B/op 922 allocs/op
BenchmarkParsing/IAT-16 4615 232996 ns/op 45724 B/op 410 allocs/op
BenchmarkParsing/IAT-16 4666 230543 ns/op 31823 B/op 306 allocs/op
BenchmarkFile/String-16 5512 206355 ns/op 35503 B/op 1282 allocs/op
BenchmarkFile/String-16 6181 188959 ns/op 30261 B/op 639 allocs/op
IMPROVEMENTS
- feat: optimize parsing of ADVBatchControl and FileControl
- feat: reduce allocations when parsing records
- fix: allocate returned array in ReadFiles and ReadDir once
- fix: use shared buffer when rendering EntryDetail
- test: verify IAT batches are skipped in Iterator
BUILD
- chore(deps): update ossf/scorecard-action action to v2.3.1
Moov ACH v1.33.0 has undergone some major performance tuning and improvements. Please let us know if you encounter any issues when using the improved code, thanks!
ADDITIONS
- feat: add a File iterator
- feat: add benchmark for ReadFile and Iterator
- fix: produce entries from iterator that are outside of batches
IMPROVEMENTS
- feat: check for valid JSON before parsing
- fix: avoid nil panic with malformed readers
- fix: process entry rune-by-rune without casting between string -> rune -> string
- fix: skip directories in ReadDir
- perf: reduce allocations in formatting strings
- perf: reduce allocations when checking routing numbers
- perf: use sync.Pool of bytes.Buffer objects grown to max field size
- test: benchmark merging files in groups
BUILD
- cmd/webui: force wasm_exec.js to go1.21.0 version
- fix(deps): update module golang.org/x/net to v0.17.0
- fix(deps): update module golang.org/x/oauth2 to v0.13.0
IMPROVEMENTS
- fix: Corrected Data is 29 characters, not 22
- fix: don't print blank line for missing IAT addendas
- test/issues: match IAT output byte-for-byte
BUILD
- build(deps): bump golang from 1.20-alpine to 1.21-alpine
IMPROVEMENTS
- feat: detect Windows-1252 encoding and decode to utf-8
- fix: parse field lengths according by runes instead of bytes
BUILD
- build(deps): bump github.com/moov-io/iso4217 from 0.2.1 to 0.3.0
- fix(deps): update module github.com/moov-io/base to v0.45.1
IMPROVEMENTS
- feat: add Addenda98Refused
- fix: SetTraceNumber should populate contested and dishonored returns
- fix: allow full range of ASCII and EBCDIC characters accepted by Nacha rules
BUILD
- build: run Go tests on Windows
- build(deps): bump github.com/moov-io/base from 0.44.0 to 0.45.0
- build(deps): bump golang.org/x/text from 0.10.0 to 0.11.0
- chore(deps): update ossf/scorecard-action action to v2.2.0
IMPROVEMENTS
- fix: allow .Create() to skip validation when configured
BUILD
- build(deps): bump actions/checkout from 2 to 3
- chore: update github.com/prometheus/client_golang to v1.16.0
- chore: update golang.org/x/text to v0.10.0
IMPROVEMENTS
- fix: return empty strings when records are nil
- build: split "make docker" into its own job
- build: remove docker build and openapi generate from Linux CI
- build: replace fuzzer library with Go standard library
- build: switch to the new moov-io/iso4217 library
- build: fix description of addenda99
BUILD
- fix(deps): update github.com/stretchr/testify to v1.8.4
- build(deps): bump github.com/moov-io/base from 0.42.0 to 0.44.0
- build(deps): bump actions/setup-go from 2 to 4
- fix(deps): update github.com/moov-io/iso4217 to v0.2.1
IMPROVEMENTS
- build: fix openshift image, upgrade to ubi9
- cmd/server: fix log format flag logic
BUILD
- build(deps): bump bulma-clean-theme from 0.13.2 to 0.13.3 in /docs
- build(deps): bump github.com/stretchr/testify from 1.8.2 to 1.8.3
IMPROVEMENTS
- fix: BatchHeaders are different with mismatching CompanyEntryDescription values
BUILD
- build(deps): bump github.com/moov-io/base from 0.41.0 to 0.42.0
- build(deps): bump github.com/aws/aws-lambda-go from 1.40.0 to 1.41.0
- chore(deps): update dependency jekyll-feed to v0.17.0
IMPROVEMENTS
- fix: Allow returned prenotes to have a zero'd Amount field
- fix: make CTX setters/getters return correct results
- fix: validate CTX addenda records and indicator correctly
- test: use a static file header for Contested/Dishonored returns
BUILD
- build(deps): bump golang.org/x/oauth2 from 0.5.0 to 0.7.0
IMPROVEMENTS
- cmd/achcli: return whatever partial file was parsed
- feat: add AllowInvalidAmounts validation option
- feat: add Merge which can override ValidateOpts of files
- server: support AllowInvalidAmounts validation option
BUILD
- build(deps): bump commonmarker from 0.23.8 to 0.23.9 in /docs
- build(deps): bump github.com/aws/aws-lambda-go from 1.39.1 to 1.40.0
- build(deps): bump github.com/moov-io/base from 0.40.1 to 0.40.2
- build(deps): bump nokogiri from 1.13.10 to 1.14.3 in /docs
- build(deps): update github.com/prometheus/client_golang to v1.15.0
Version v1.30.0 of moov-io/ach introduces a new ErrFileConsecutiveBatchHeaders
error which replaces ErrFileBatchHeaderInsideBatch
to better reflect when file parsing failed. The library can now accept ACH files without Batch Control records.
IMPROVEMENTS
- fix: accumulate batches without BatchControl records
IMPROVEMENTS
- fix: allow IAT as transaction type code of addenda10 records
- fix: keep zero-prefix trace numbers during offset creation
BUILD
- build(deps): bump github.com/moov-io/base from 0.39.0 to 0.40.1
- build(deps): bump golang.org/x/text from v0.8.0 to v0.9.0
- chore(deps): update dependency jekyll-feed to v0.17.0
IMPROVEMENTS
- fix: include Offset in API docs and read from JSON
BUILD
- build(deps): bump activesupport from 6.1.7.2 to 7.0.4.3 in /docs
- build(deps): bump bulma-clean-theme from 0.13.1 to 0.13.2 in /docs
- build(deps): bump github.com/aws/aws-lambda-go from 1.38.0 to 1.39.1
- build(deps): bump github.com/stretchr/testify from 1.8.1 to 1.8.2
- build(deps): bump ossf/scorecard-action from 2.1.2 to 2.1.3
Shout-out to @ckbaum for contributing a major improvement to File Flattening.
IMPROVEMENTS
- feat: Don't combine two batches if they share any trace numbers.
- feat: Make an effort to preserve original batch ordering.
- feat: expose named errors (and ask for bug reports) from FlattenFile
BUILD
- build: tighten up GITHUB_TOKEN permissions
- build: Apply security best practices from StepSecurity
- build(deps): bump ossf/scorecard-action from 2.0.6 to 2.1.2
- chore(deps): update dependency tzinfo to "~> 2.0"
- fix(deps): update module github.com/juju/ansiterm to v1
IMPROVEMENTS
- chore: remove wasteful debug printf
- fix: validate amounts in non-prenote entries
- test: convert log.Fatal over to t.Fatal
- test: verify ValidAmountForCodes works as expected
BUILD
- build: update golang.org/x/sys/unix
- build(deps): bump activesupport from 6.0.3.7 to 6.0.6.1 in /docs
- chore(deps): update golang docker tag to v1.20
- fix(deps): update module github.com/moov-io/base to v0.39.0
- fix(deps): update module golang.org/x/text to v0.7.0
ADDITIONS
- Add
ValidateOpts
to BatchControl. - Add use of
PreserveSpaces
validate opt in BatchControl, BatchHeader, and EntryDetail.
IMPROVEMENTS
- fix: trim DFIAccountNumber by default
BUILD
- chore: generate iso3166 and iso4217 code, no changes
- fix(deps): update module github.com/aws/aws-lambda-go to v1.37.0
- test: use testify assert package for Valid unit tests change packages to *_test
ADDITIONS
- Add
-pretty.amounts
CLI flag to show human readable amounts - Add
-skip-validation
add option to skip all validations - Add
-validate
CLI flag to read files with ValidateOpts - feat: add option to skip all validations
IMPROVEMENTS
- fix: properly count string lengths when padding fields
- test: verify EntryDetail record lengths are valid for all return codes
BUILD
- build: enable Go test shuffle
- fix(deps): update module golang.org/x/oauth2 to v0.4.0
- fix(deps): update module golang.org/x/text to v0.6.0
IMPROVEMENTS
- fix: allow missing TerminalIdentificationCode in Addenda02
IMPROVEMENTS
- fix: don't re-check whether the file is ADV while writing each batch
BUILD
- build: update moov-io/base to v0.38.1 and tidy up
IMPROVEMENTS
- fix: remove unused x-idempotency-key from api docs
BUILD
- fix(deps): update module github.com/moov-io/base to v0.38.0
IMPROVEMENTS
- cmd/achcli/describe: mask left-aligned spaces
- cmd/achcli/describe: fixup padding when fields are padded
IMPROVEMENTS
- cmd/achcli/describe: return masked account number length unchanged, show spaces
- cmd/achcli: reunify entrydetail transaction type formatting
- cmd/webui: add a Reversal button
- fix: update fields required for reversed files to validate
BUILD
- build(deps): bump nokogiri from 1.13.9 to 1.13.10 in /docs
- fix(deps): update module github.com/aws/aws-lambda-go to v1.36.0
- fix(deps): update module github.com/moov-io/base to v0.37.0
IMPROVEMENTS
- cmd/achcli: align tabwriter columns better across batches
ADDITIONS
- feat: add
CalculateCheckDigit
- feat: add
.SetMaxLines(int)
to Reader - feat: add
UnequalAddendaCounts
validation option
IMPROVEMENTS
- api: add missing unorderedBatchNumbers and allowInvalidCheckDigit
BUILD
- fix(deps): update module github.com/aws/aws-lambda-go to v1.35.0
IMPROVEMENTS
- cmd/achcli: support masking corrected data, option to prettify amounts
BUILD
- fix(deps): update module github.com/moov-io/base to v0.36.2
- fix(deps): update module golang.org/x/oauth2 to v0.2.0
IMPROVEMENTS
- docs: fix link to creating file over HTTP
- fix: allow mixed-case Addenda10 TransactionType codes
- validator: include missing secondary SEC codes for Addenda10
BUILD
- fix(deps): update module github.com/prometheus/client_golang to v1.14.0
IMPROVEMENTS
- docs: Fix spelling mistake in Original RDFI identification
- server: read ValidateOpts before file to segment
IMPROVEMENTS
- docs: rename 'payment code' to transaction code
- examples: add micro-entries / micro-deposits (#1103)
- feat: add
ReadJSONFile
andReadJSONFileWith
helpers - feat: add
Reversal()
to files - feat: add
AllowInvalidCheckDigit
validation option - feat: add achcli IAT Support (#1100)
- feat: allow empty strings when allow missing file header opt is set
BUILD
- build(deps): bump nokogiri from 1.13.6 to 1.13.9 in /docs
- fix(deps): update module github.com/moov-io/base to v0.36.1
- fix(deps): update module github.com/stretchr/testify to v1.8.1
- fix(deps): update module golang.org/x/oauth2 to v0.1.0
IMPROVEMENTS
- fix: copy forward the validate options when segmenting a file
- fix: passing validate opts to http handler
- test: verify ValidateOpts are set in segment http response
BUILD
- meta: add feature request template
IMPROVEMENTS
- docs: clarified lambda_json_to_nacha example
- server: read ValidateOpts in SegmentFile endpoints
BUILD
- build: require go1.19.1 in CI/CD
IMPROVEMENTS
- fix: lowercase
ID
in OpenAPI spec
ADDITIONS
- feat: add
ValidateOpts
forIATBatch
andIATEntryDetail
IMPROVEMENTS
- fix(deps): update golang.org/x/oauth2 digest to f213421
- fix(deps): update module github.com/moov-io/base to v0.35.0
- test: verify we pad to 10 lines in writer
Moov ACH v1.19.3 fixes an issue where Entry Hash values were not properly calculated.
- IATBatch hash values would not overflow properly.
- If
RDFIIdentification
was not properly trimmed to the "ABA 8" characters.
IMPROVEMENTS
- fix: calculate EntryHash from ABA8, properly format string value
IMPROVEMENTS
- Allow MixedDebitsAndCredits in ARC, BOC, CIE, POP, RCK, TRC, TRC, XCK entries
BUILD
- fix(deps): update golang.org/x/oauth2 digest to 0ebed06
This is the same release as v1.19.0 but with deployment issues fixed.
IMPROVEMENTS
- Remove recordType and reserved fields from all models
- docs: update OpenAPI spec with /segment endpoint
- feat: add endpoint to segment files without a fileID
- feat: read fileID path parameter on creation
- feat: return ACH file with creation, flatten, and segment endpoints
IMPROVEMENTS
- docs: clarify TEL/WEB payment type code field
- fix: contested return addenda parsing of dishonored returns
- server: verify fileID specified in JSON is kept
BUILD
- build: remove deprecated ioutil functions, gofmt from go1.19
- fix(deps): update golang.org/x/oauth2 digest to 128564f
- fix(deps): update module github.com/aws/aws-lambda-go to v1.34.1
IMPROVEMENTS
- docs: update ppd-valid.json ID values
- feat: add R36 return code
IMPROVEMENTS
- Fix entry category assignment in Reader
IMPROVEMENTS
- feat: add R62 and R77 return codes
BUILD
- fix(deps): update module github.com/moov-io/base to v0.33.0
IMPROVEMENTS
- fix: reduce memory usage during MergeFiles
BUILD
- fix(deps): update module github.com/aws/aws-lambda-go to v1.32.1
- fix(deps): update module github.com/moov-io/base to v0.32.0
- fix(deps): update module github.com/stretchr/testify to v1.8.0
IMPROVEMENTS
- feat: support Refused COR/NOC codes
BUILD
- fix(deps): update module github.com/moov-io/base to v0.31.1
IMPROVEMENTS
- Export the SettlementDate field in BatchHeader and IATBatchHeader
BUILD
- fix(deps): update module github.com/moov-io/base to v0.30.0
- fix(deps): update module github.com/stretchr/testify to v1.7.2
ADDITIONS
- feat: add build file endpoint
IMPROVEMENTS
- cmd/webui: update wasm_exec.js bundle
- cmd/webui: write library version to page
- feat: set Addenda trace numbers in (EntryDetail).SetTraceNumber
IMPROVEMENTS
- server: read unorderedBatchNumbers query param
ADDITIONS
- Add
AllowUnorderedBatchNumbers
validate option to skip ascending batch sequence validation
IMPROVEMENTS
- api: add missing validate opts query params, Addenda99 Dishonored and Contested returns
- batch: skip addendaFieldInclusion with Offset entries
BUILD
- build: update base images
- build: update codeql action
- build(deps): bump nokogiri from 1.13.4 to 1.13.6 in /docs
- fix(deps): update module github.com/aws/aws-lambda-go to v1.32.0
- fix(deps): update module github.com/go-kit/log to v0.2.1
- fix(deps): update module github.com/moov-io/base to v0.29.2
- fix(deps): update module github.com/prometheus/client_golang to v1.12.2
IMPROVEMENTS
- feat: improve performance of getTraceNumbers
ADDITIONS
- merge: allow splitting files on their maximum dollar amounts
IMPROVEMENTS
- docs: provide specific actions of CustomTraceNumbers
- fix(deps): update module github.com/aws/aws-lambda-go to v1.31.1
ADDITIONS
- feat: add support for "Dishonored Returns" with addenda records
- feat: support parsing out Contested Dishonored Returns
BUILD
- build: install git in builder image
- meta: update moov-io/base and our logging library
IMPROVEMENTS
- fix: better date validation
BUILD
- build(deps): bump nokogiri from 1.12.5 to 1.13.3 in /docs
ADDITIONS
- file: include ValidateOpts with JSON representations
IMPROVEMENTS
- merge: carry through ValidateOpts from files
- server: verify balanced file validates
BUILD
- build: enforce a coverage threshold
BUG FIXES
- batch: check ValidateOpts prior to TraceNumber ascending verification
- file: pass through ValidateOpts for inner JSON unmarshals
BUILD
- fix(deps): update module github.com/moov-io/base to v0.24.0
BUG FIXES
- batch: check ValidateOpts for bypassing trace number ordering requirement
BUILD
- fix(deps): update module github.com/mattn/go-isatty to v0.0.14
ADDITIONS
- file: during creation check ValidateOpts for allowing empty headers
- server: include missing FileHeader and missing FileControl query params
IMPROVEMENTS
- file: allow for missing file header and control
BUG FIXES
- file: unmarshal with ValidateOpts if set
ADDITIONS
- batch: allow unequal ServiceClassCodes to be used
- server: allow unequalServiceClassCode query param
IMPROVEMENTS
- addenda99: Use updated R17 title / description from Nacha update (#971)
BUILD
- fix(deps): update golang.org/x/oauth2 commit hash to faf39c7
- fix(deps): update module github.com/aws/aws-lambda-go to v1.26.0 (#968)
- fix(deps): update module github.com/moov-io/base to v0.22.0
- meta: fixup from gosec linter
BUG FIXES
- cmd/achcli/describe: include EffectiveEntryDate on human readable output (#967)
ADDITIONS
- Implementing CustomReturnCode validation (#966)
- Keep settlement date when parsing files. (#960)
- file,server: add method for parsing JSON with custom validation
IMPROVEMENTS
- file: update docs on FileFromJSON validation
BUILD
- build: use debian stable's slim image in webui
- build(deps): bump addressable from 2.7.0 to 2.8.0 in /docs
- fix(deps): update github.com/juju/ansiterm commit hash to 9283cdf (#952)
- fix(deps): update module github.com/aws/aws-lambda-go to v1.25.0
- fix(deps): update module github.com/go-kit/kit to v0.11.0
- fix(deps): update module github.com/moov-io/base to v0.21.1
BUG FIXES
- api: fixup openapi spec and generate client in CI
BUILD
- fix(deps): update module github.com/moov-io/base to v0.20.1 (#947)
BUG FIXES
- ADV: fix entry hash err msg (#939)
- CTX: allow batches to be pre-notifications
IMPROVEMENTS
- docs: clean up api documentation (#938)
BUILD
- fix(deps): update module github.com/aws/aws-lambda-go to v1.24.0 (#935)
- fix(deps): update module github.com/mattn/go-isatty to v0.0.13 (#937)
- fix(deps): update module github.com/prometheus/client_golang to v1.11.0 (#941)
ADDITIONS
- webui: Add human-readable ACH parsing (#933)
BUILD
- build(deps): bump nokogiri from 1.11.3 to 1.11.5 in /docs (#934)
ADDITIONS
- reader: add
ReadFiles(...)
method for consuming a slice of filepaths (#932)
BUG FIXES
- set batchID from header on POST to create file (#926)
IMPROVEMENTS
- merge: combine entries together when Batch Headers match
- merge: don't include TraceNumbers that collide in merged files
BUILD
- build(deps): bump kramdown from 2.3.0 to 2.3.1 in /docs
- fix(deps): update module github.com/moov-io/base to v0.19.0 (#929)
IMPROVEMENTS
- cmd/achcli: include last error message in -reformat
BUG FIXES
- reader: reset the
currentBatch
when aBatchControl
is read to avoid setting EntryDetail records in the wrong batch - file: force a 10-digit entry hash in
File.Create
andFile.calculateEntryHash
to ensure the file assembled into a valid state
ADDITIONS
- writer: add
BypassValidation
option - converters: add method to return the least significant digits of a number
- server: accept
customTraceNumbers
as a query param to set the corresponding validation option
IMPROVEMENTS
- file: update documentation for
Read
,Create
, andValidate/ValidateWith
to clarify behavior - docs: describe validation query params on the HTTP request to create a file
- docs: remove function parentheses from code comments
- tests: add a regression test for issue #915
There are no changes from v1.7.0. This release fixes issues during the release process.
ADDITIONS
- webui: add button to support JSON to ACH conversions
- achcli: add
describe
package to allow human-readable printing to be reused in other tools - batch: add validation option,
bypassCompanyIdentificationMatch
, to allow batches in which theCompanyIdentification
field in the batch header and control do not match
IMPROVEMENTS
- merge: optimize performance of
lineCount(..)
and reduce errors returned
ADDITIONS
- Add option to create a file with zero batches (#884)
IMPROVEMENTS
- iso3166,iso4217: generate lists again after long hiatus
BUG FIXES
- file: sort EntryDetail records when flattening batches
BUILD
- fix(deps): update module github.com/prometheus/client_golang to v1.10.0 (#875)
- fix(deps): update module github.com/moov-io/base to v0.18.2
BUG FIXES
- file: updated
File.MergeFiles(..)
to override batch numbers in each file to prevent them from colliding
IMPROVEMENTS
- file: optimized and refactored
File.FlattenBatches(..)
and added benchmarks - api: added missing required fields in models in the OpenAPI spec and removed unnecessary
omitempty
tags for required fields in Go models - docs: removed extra spaces in the request body for creating a file to fix broken example
- docs: added a section about where to find Nacha Operating Rules and Nacha's ACH guide for developers
- docs: updated links in README to point to project documentation site
IMPROVEMENTS
- api: update OpenAPI spec to include more details about data types
- file: ability to set custom batch sequence numbers
- docs: new project documentation site with updated styles and navigation
- docs: add page about Notification of Change (NOC) files
- docs: add read and write examples for CIE batches
- docs: update R10 and R11 return code descriptions
- docs: additional fixes and improvements to the README
BUG FIXES
- fileHeader:
ImmediateDestination
andImmediateOrigin
should be separated by a space unless bypass validation is set and the routing number is 10 digits
IMPROVEMENTS
- docs: improvements to README by adding a new header, table of contents, related projects, and FAQ
- docs: clarified code comments related to
File.ValidateWith(..)
and fixed minor documentation errors
BUG FIXES
- fileHeader: fix
ImmediateDestination
formatting whenBypassDestinationValidation
is set
ADDITIONS
- batch: allow addenda in CIE batches to be optional
- batch: allow POS batches to contain credits
- reader: allow backtick in the valid character set
- build: add tagged-release script to automate the release process
IMPROVEMENTS
- reader: report error when extra characters are found in one-line ACH files
- webui: display error when parsing fails
- deps: remove moov-io/customers and moov-io/paygate as dependencies
- docs: improvements to README by fixing typos, dead links, and formatting
BUG FIXES
- server: pass validation options through to ACH reader and underlying batch
IMPROVEMENTS
- build: push ach-webui image and split up commands for each docker build
There are no changes from v1.5.0. This release fixes issues during the release process.
ADDITIONS
- cmd/webui: initial setup for client-side ACH file parsing to their JSON forms
- entries: allow custom
TransactionCode
validation - entries: allow custom
TraceNumber
values - writer: allow setting
Writer.LineEnding
to use custom values for ending each outputted - server: allow
ValidateOpts
to be set through HTTP query parameters
IMPROVEMENTS
- build: check and lint OpenAPI spec in CI
- api: update summaries of endpoints
- api: clean up OpenAPI spec after running Speccy
- docs: update content for moov-io.github.io/ach/
- docs: add page on return files
- docs: add link to Moov's ACH blog post
- docs: fix filepath example in segmented files
- github: request version in bug reports
- github: add codeowners
- chore(deps): update golang docker tag to v1.15
BUG FIXES
- server: fix batch additions by shimming JSON reading
BUG FIXES
- entries: detect overflow when printing large amounts
- reader: only parse IAT entries when we're accumulating an IAT batch
IMPROVEMENTS
- achcli: print BatchControl records as well
- achcli: update help/usage text
BUILD
- build: upload achcli binaries on each release
IMPROVEMENTS
- api: add example plaintext file for create route
- docs: flip Usage section priority, link to godocs and examples
- file: include the struct field in Unmarshal errors
BUG FIXES
- api: clarify batchNumber in BatchHeader is an integer
- api: include missing CompanyIdentification field on BatchHeader docs
- api: include missing
CompanyIdentification
field onBatchHeader
docs - api: quote number-looking example values
BUG FIXES
- batch: error if our offset account type is unknown
BUILD
- build: add openshift docker image
- build: enable codeql via github actions
- build: release via Actions, not TravisCI
Version v1.4.0 of ACH adds several notable features such as custom validation, a command-line tool achcli
to describe files, and improvements for verifying NACHA compatibility on slightly malformed files. This release also contains enhanced testing and documentation improvements.
Custom Validation
The ACH library (and HTTP server) now supports custom validation with the ValidateOpts
struct by calling File.SetValidation(..)
and Reader.SetValidation(...)
. This offers various options:
RequireABAOrigin bool
: Enable or disable routing number validation over theImmediateOrigin
file header fieldBypassOriginValidation
: Skip validation for theImmediateOrigin
file header field and allow customTraceNumber
valuesBypassDestinationValidation
: Skip validation for theImmediateDestination
file header field and allow customTraceNumber
values
The HTTP server also supports reading this struct with camel-cased names when calling the validation route.
achcli
achcli
is a command-line utility for viewing ACH files in a more human readable format. This tool also allows masking DFIAccountNumber
values with the -mask
flag.
$ achcli -mask 20200601-1002-01.ach
Describing ACH file '20200601-1002-01.ach'
Origin OriginName Destination DestinationName FileCreationDate FileCreationTime
691000134 ASF APPLICATION SUPERVI 091400606 FIRST BANK & TRUST 181017 0306
BatchNumber SECCode ServiceClassCode CompanyName CompanyDiscretionaryData CompanyIdentification CompanyEntryDescription
1 WEB 200 CoinLion 123456789 TRANSFER
TransactionCode RDFIIdentification AccountNumber Amount Name TraceNumber Category
26 09140060 *******89 12354 Paul Jones 091000017611242 Return
Addenda99
ReturnCode OriginalTrace DateOfDeath OriginalDFI AddendaInformation TraceNumber
R01 091400600000001 09100001 091000017611242
BatchCount BlockCount EntryAddendaCount TotalDebitAmount TotalCreditAmount
1 1 1 12354 0
Malformed Files
ACH files with lines that are not 94 characters are now adjusted in-memory (missing or extra spaces) in an attempt to comply with NACHA standards. The underlying file on disk is not modified during this reading.
ADDITIONS
- batches: Add
LiftEffectiveEntryDate()
to offer parsedtime.Time
values ofEffectiveEntryDate
- cmd/server: add version handler to admin HTTP server
- file: add BypassDestinationValidation to ValidateOpts
- file: add
ValidateWith
to override specific default validations - file: support setting ValidateOpts on struct for calling Create()
- reader: morph lines to 94 characters if they end in spaces
- server: read
ValidateOpts
in HTTP validate route - server: return fileID on create errors, enforce marshaled errors as strings
- file: support setting
ValidateOpts
on struct for callingCreate()
- file: struct unmarshaling works again, it was depreciated for a couple releases
- reader: morph lines to 94 characters with spaces if they are some other length
- reader: allow setting ValidateOpts
- cmd/ach: initial setup of CLI tool to pretty print ACH files
BUG FIXES
- all: replace
Ç
withC
across the project - all: use filepath.Join instead of unix paths
- api: fixup flatten files OpenAPI spec
- api: note POST /files/create can return an error
- file: don't validate before flattening batches
- file: keep TraceNumbers when segmenting files
- server: fix segment OpenAPI spec and accept config body
- server: read empty SegmentFileConfiguration
- file: don't validate before flattening batches
IMPROVEMENTS
- api: used shared Error model
- api: use shorter summaries
- api: include AddendaXX, ADV, and IAT records that were missing from OpenAPI spec
- chore(deps): update module prometheus/client_golang to v1.4.1
- chore(deps): update module gorilla/mux to v1.7.4
- reader: write a test for what partial file comes back from invalid EntryDetails
- reader: allow zero-entry files if their controls signify as such
- server: use FoundABug error with mismatched routing
- validators: ensure alpha routing number check digit is invalid
- all: use filepath.Join instead of unix paths
- reader: append a lingering batch even if there's no batch control
BUILD
- chore(deps): update golang docker tag to v1.14
- build: run sonatype-nexus-community/nancy in CI
- build: leverage moov-io/infra's Go linter script
BUG FIXES
- api,client: There was a mistaken character in the OpenAPI docs
Ç
which should have beenC
.
IMPROVEMENTS
- build: upgrade golang.org/x/crypto
BUILD
- build: run sonatype-nexus-community/nancy in CI
BREAKING CHANGES
ImmediateOrigin
values are written with a leading space instead of a zero (0
) due to post-2013 NACHA guidelines.
BUG FIXES
addenda98
fix parsing with no spaces between routing and account number
ADDITIONS
- Add random names, amounts, and memo lines in test file generation script
cmd/writeACH/main.go
BUG FIXES
- fileHeader: Remove requirement of ImmediateOrigin to be a routing number
ADDITIONS
- Add
FlattenBatches() (*File, error)
toach.File
- FlattenBatches minimizes File Batches by consolidating them with the same BatchHeader data into one batch.
- Add
POST /files/:id/flatten
which callsFlattenBatches()
on a specific ACH file - Add
POST /files/:id/balance
to add Offset records onto each Batch in an ACH File. - Addenda98: Add
ChangeCodeField()
for detailed information about a NOC/COR change file (ChangeCode
) - Addenda99: Add
ReturnCodeField()
for detailed information about file returns (ReturnCode
)
BUG FIXES
- reader: set EntryDetail.Category to Return when Addenda99 is present
- batch: inspect Entrydetail records for Category
- batch: check ADV entries for Category
- reader: set EntryDetail.Category to NOC when Addenda98 is present
- file: Validate files after reading them from their JSON representation
- server: actaully render new Credit and Debit files from segmentation
IMPROVEMENTS
- created example files for HTTP routes
- file: parse ISO8601 and RFC3339 timestamps in JSON blobs
BUILD
- upgrade to Go 1.13
- build: download CI tools rather than install
- build: update staticcheck with Go 1.13
BREAKING CHANGES
In our OpenAPI we've renamed fields generated as Id
to ID
, which is more in-line with Go's style conventions.
BUG FIXES
- fileHeader: allow immediate origin to be a 10 digit value (See: #513 by @eduardev)
- Fix JSON omitempty typo in
ADVEntryDetail
- fileHeader: trim padded 0's from ImmediateOriginField() and fixup docs
- batch: only check DNE specifics if the SEC code is DNE
- files: FileHeader validate CheckRoutingNumber
- files: on empty FileCreation dates or times render today's value
- reader: return ErrFileAddendaOutsideBatch from parseAddenda when currentBatch is nil
ADDITIONS
- batch: add Equal method
- Addenda99: Add
ReturnCodeField()
for detailed information about a returned file - files: support arbitrary merging of ACH files (See #529)
- entryDetail: validate that Amount is non-negative
- batch: create Debit and Credit EntryDetail offset records if needed (via
WithOffset
) - addenda types: Add RuneCountInString check to Parse(record string) function
- file: create debit ach file and credit ach file from a mixed debit and credit ach file (via
SegmentFile
) (see #528) - cmd/server: add environment variables to override command line flags (
-http.addr
and-log.format
) - file: support ADV and IAT files in (*File).SegmentFile(...)
- cmd/server: bind HTTP server with TLS if HTTPS_* variables are defined
- cmd/server: add endpoints for segmenting files into debits and credits
BUILD
- vendor: update dependencies
- Fix
moov/achfuzz
docker image build - api: inline parameters to fix codegen crash
- build: push moov/ach:latest and update docs accordingly
- chore(deps): update module prometheus/client_golang to v1.1.0
- No changes from v0.6.0
BREAKING CHANGES
file.NotificationOfChange
acceptsBatcher
instead of*BatchCOR
to comply with linter errors
ADDITIONS
- Add const values for
BatchHeader.StandardEntryClassCode
(See #392) - Add const values for
BatchHeader.ServiceClassCode
andBatchControl.ServiceClassCode
. (See #391) - Add const values for
EntryDetail.TransactionCode
(See #363) - server: Record
ach_files_deleted
metric. (See: #408) - server: log x-request-id header if present. (See: #407)
- server: Delete old
ach.File
objects from in-memory repository according toACH_FILE_TTL
env variable. - server: Support
-log.format=json
for JSON formatted logs
BUG FIXES
- Accept File's without an ID specified. Generate a random ID. (See: #405)
- server: Fix nil panics. (See: #406)
- server: Fix type-casting panics. (See: #423)
- server: validate file endpoint returns 400 instead of 500 (See: #488)
- server: set CORS headers on
GET /ping
route
BUILD
megacheck
is deprecated. staticcheck should be used instead. (See #430)- Automate releases with Docker and binary uploads to release page.
- Update dependencies to their latest versions
- Update to Go 1.12
BREAKING CHANGES
TraceNumber
has been changed fromint
to astring
. (See #366)- Previously zero-prefixed ABA routing numbers would have their leading zero truncated.
OriginalTrace
has been changed fromint
to astring
. (See #366)
ADDITIONS
- Support
StandardEntryClassCode
(Batch types): TransactionCode
matchServiceClassCode
(See #56)Addenda02.TerminalState
validation for BatchPOS and BatchSHR (See #375)
REMOVALS
- Remove deprecated functions from
EntryDetail
(See #385)
BREAKING CHANGES
EntryDetail.Addendum
has been broken out intoAddenda02
,Addenda05
,Addenda98
, andAddenda99
fields onEntryDetail
.- IAT
EntryDetail.Addendum
has been broken out into Addenda 10-18, 98 and 99.
ADDITIONS
- Support
StandardEntryClassCode
(Batch types): - Support NOC for IAT Entries (See #328)
- Add
FileFromJson
for readingFile
objects as JSON. - Add
X-Total-Count
response headers onGET /files/:id/batches
(See #280)
IMPROVEMENTS
- Multiple parsing errors are returned in
Reader.Read() error
's error message. - IAT: Validate ISODestinationCountryCode according to ISO 3166
- IAT: Validate ISOOriginatingCurrencyCode and ISODestinationCurrencyCode according to ISO 4217
- build: Run CI tests against Windows
- Verify record lengths in [IAT] BatchHeader, [IAT] BatchControl, FileControl, FileHeader, and [IAT] EntryDetail.
BUG FIXES
cmd/server
: don't expect trailing slash on endpointscmd/server
: Grab write lock on delete requests- Several panics are fixed from fuzzing
- Reject invalid ABA routing numbers
ADDITIONS
- Expose
TypeCode
on Addenda records
IMPROVEMENTS
- Run as unprivileged user in Docker image
cmd/readACH
: add -json to printFile
as JSONcmd/writeACH
: validate file before writingcmd/writeACH
: add -json to outputFile
as JSON
BUG FIXES
- Fix reading batches out from JSON endpoint
- Fix plaintext ACH file rendering endpoint
ADDITIONS
- Handle pre-flight requests and proxy back CORS headers
ADDITIONS
- Add
X-Total-Count
on GET responses - Proxy back CORS headers if sent on the request
BUG FIXES
- Drop requirement for /-suffix on GET /files
- Don't trample content-type in encodeResponse
FEATURES
- Added HTTP Server
- SEC Code CIE (Customer-Initiated Entry) (#209)
- Support IAT (#211)
- IAT Returns (#233)
- Support CTX (#212)
IMPROVEMENTS
- Added admin HTTP service.
- Added
GET /ping
route (unauthed)
BUG FIXES
- Fixes to parsing and validation.