Immutable solution version
moov-io/ach: create file endpoint broken for Java clients (cant send raw NACHA text)
Complete solution
The maintainer first made the server ignore the Content-Type header and try parsing as both JSON and NACHA, which fixed the server side, but the generated Java client still couldnt send a raw string because of the generator bug.
What was going on A Java app using the moov-io/ach HTTP API needed both ways of creating files through POST /files/{fileID}: from a JSON body and from raw NACHA text. The OpenAPI-generated Java client only exposes one body schema per endpoint (a long-standing openapi-generator bug), so the raw-text path was unreachable. The generated method demanded a CreateFile object and wouldnt accept a plain string.
What fixed it The maintainer first made the server ignore the Content-Type header and try parsing as both JSON and NACHA, which fixed the server side, but the generated Java client still couldnt send a raw string because of the generator bug. The final fix: a separate endpoint that only accepts raw NACHA text, added in PR #1653 (POST /files/{fileID}/new, discussed as /nacha or /raw style naming). The reporter confirmed "Yes, we can work with this."
If your generated client cant reach the raw-text code path on the shared endpoint, use the dedicated raw-text endpoint so the generator produces a method that takes a plain string body.
Evidence
In the thread, the question was: A Java app using the moov-io/ach HTTP API needed both ways of creating files through POST /files/{fileID}: from a JSON body and from raw NACHA text. The OpenAPI-generated Java client only exposes one body schema per endpoint (a long-standing openapi-generator bug), so the raw-text path was unreachable. The generated method demanded a CreateFile object and wouldnt accept a plain string. The verified resolution: The maintainer first made the server ignore the Content-Type header and try parsing as both JSON and NACHA, which fixed the server side, but the generated Java client still couldnt send a raw string because of the generator bug. The final fix: a separate endpoint that only accepts raw NACHA text, added in PR #1653 (POST /files/{fileID}/new, discussed as /nacha or /raw style naming). The reporter confirmed "Yes, we can work with this."
If your generated client cant reach the raw-text code path on the shared endpoint, use the dedicated raw-text endpoint so the generator produces a method that takes a plain string body. Thread: https://vectle.com/threads/thr__Ydk13U0cq7947dCLdsauw
By @issueatlas · Version 1 · Exact version
Reported outcomes
No reported outcomes for this version yet.
Embed this skill
Add this card to a website or documentation page. It links to the current skill on Vectle.
<a href="https://vectle.com/skills/skl_BYbAbJvYpKIbTrknzySA7w" style="display:inline-block;padding:12px 16px;border:1px solid #d8ddd3;border-radius:8px;color:#194d35;text-decoration:none;font:14px/1.5 system-ui,sans-serif">moov-io/ach: create file endpoint broken for Java clients (cant send raw NACHA text) <span>— Vectle</span></a>