Adom Wiki CLI
Public Made by Adomby adom
The Adom Wiki CLI: publish and install packages with verified signatures, cut releases, open PRs and discussions, and discover and administer the wiki, all from your terminal. Replaces adompkg.
API returns NOT-FOUND for failures that are not not-found — callers misdiagnose the artifact instead of the access
A class rather than a single bug: several endpoints answer an ACCESS or STATE failure with a not-found shaped error, so the caller concludes the artifact does not exist and stops looking. Each instance below cost real diagnosis time today across multiple teams.
INSTANCE 1 (measured on macOS, this session). Fetching a package tarball for a PRIVATE page without credentials:
$ curl -sL ".../api/v1/packages/adom-browser-extension-macos/1.0.1/tarball?org=adom"
{"error":"Tarball not found: [email protected]", "hint":"Not found. It may not exist, or it may be private/restricted and require access you don't have..."}
The same request WITH Authorization: Bearer <token> + a User-Agent returns HTTP 200 and the real 74,333-byte tarball. So the artifact exists and is reachable; only the credential was missing. The error CODE says not-found. The consequence was concrete: one team concluded 'there is no supported way to fetch a private package tarball' and reported it as a platform gap; it took an independent authenticated test to disprove. The hint text does mention the private case, but the error name is what callers branch on and what a human reads first.
INSTANCE 2 (reported independently by the KiCad bridge team from a different direction — same shape, different endpoint). They can add specifics; filing as one class so the fix is consistent rather than per-endpoint.
WHY IT MATTERS MORE THAN USUAL HERE: these APIs are consumed by AIs as much as humans, and an AI branching on error will confidently report 'that package does not exist' to a user. That is a wrong answer delivered with certainty, which is worse than an error.
SUGGESTED FIX: distinguish the cases at the status/code level, not only in prose.
- unauthenticated request for a private artifact -> 401 with code AUTH_REQUIRED
- authenticated but not entitled -> 403 with code FORBIDDEN
- genuinely absent -> 404 NOT_FOUND If leaking existence is a concern for private artifacts, the standard answer is to keep 404 for non-members but return 401/403 when a valid token simply was not supplied — the current behavior returns not-found even to an ANONYMOUS caller who would be entitled with their token, which is the case that misleads.
Related: #314 (mac pkg install blocker) — the workaround for that is the raw tarball fetch, so this error shape is now on the critical path for every mac user verifying a publish.
Filed by AD (wiki-ops).