I installed todoist-cli today and could not get it to work with td auth login failing after showing success in the browser and other unsuccessful API response parsing. I let claude code diagnose the issue and below is what it came up with.
You can probably take it from here with your own claude. Let me know if you need anything else from me (the human) or if such bug reports are not suitable here.
On Node 26 / undici 7, @doist/todoist-cli@1.62.0 cannot parse any gzip-encoded
response from the Todoist API. Every command that calls a gzipped endpoint fails
with a Zod validation error against the response shape, even though the API
returned 200 OK with valid JSON in the body.
The cause is in @doist/todoist-sdk (currently 10.1.2): it installs an
EnvHttpProxyAgent from undici as the dispatcher for every fetch() call, and
on Node 26 that agent does not include the gzip-decompression interceptor that
Node's default fetch dispatcher uses. Compressed bytes reach JSON.parse,
parsing fails silently, and the SDK's try/catch falls back to assigning the
raw text to response.data. Subsequent destructuring (data.results,
data.fullName, …) produces undefined, which Zod then rejects at the root.
I installed todoist-cli today and could not get it to work with
td auth loginfailing after showing success in the browser and other unsuccessful API response parsing. I let claude code diagnose the issue and below is what it came up with.You can probably take it from here with your own claude. Let me know if you need anything else from me (the human) or if such bug reports are not suitable here.
On Node 26 / undici 7,
@doist/todoist-cli@1.62.0cannot parse any gzip-encodedresponse from the Todoist API. Every command that calls a gzipped endpoint fails
with a Zod validation error against the response shape, even though the API
returned
200 OKwith valid JSON in the body.The cause is in
@doist/todoist-sdk(currently10.1.2): it installs anEnvHttpProxyAgentfrom undici as the dispatcher for everyfetch()call, andon Node 26 that agent does not include the gzip-decompression interceptor that
Node's default
fetchdispatcher uses. Compressed bytes reachJSON.parse,parsing fails silently, and the SDK's
try/catchfalls back to assigning theraw text to
response.data. Subsequent destructuring (data.results,data.fullName, …) producesundefined, which Zod then rejects at the root.