Rewrite the README API reference to match the implementation #13
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Problem
The README's API reference section says outright that it "is from an earlier draft and does
not fully reflect the current implementation". This is a
TODO.mdFuture Step and anunchecked README TODO box. The specific defects found in a full audit:
BackupResult,BackupError,MissingThumbnailInfoandThumbnailFixResultas API. None of them is exported fromsrc/index.ts, nor arerunBackup,runMetadataBackup,listMissingThumbnailsorfixMissingThumbnails.RawMagicMetadataas part ofsrc/model/types.ts's public surface.src/index.tsdoes not re-export it, thoughsrc/model/index.tsdoes and it appears in thepublic
RawCollectionandRawEnteFileshapes.are also rerouted, to
/files/preview/<id>.POST /files/data/fetch, used by the metadata backup path.make testmust complete in under 20 seconds;script/testenforces 30.
test/api/client.test.tsdocuments anENTE_API_ENDPOINTenvironmentvariable that nothing in
src/orbin/reads.Definition of done
src/index.tswith actualsignatures: every value export and every type export, grouped sensibly, each with a
one-line description of what it is for.
Client's static-only construction (the constructor is private) is stated explicitly, andevery public method is listed with its signature.
ApiClientandApiErrorare documented with their real shapes, including thatApiErrorcarries
status,code,requestIDandbody.the reference or noted as internal — matching whatever the packaging issue settles on.
script/testactually enforces.ENTE_API_ENDPOINTcomment intest/api/client.test.tsis corrected or removed.TODO.mdupdated in the samecommit.
make fmthas been run so the markdown is prettier-clean at 4-space tabs withproseWrap: always, andmake checkis green.Depends on
The packaging issue, which decides which of the currently-internal symbols become public.
Do not start this until that question is settled, or the reference will be wrong again.