Skip to content

MetadataProtocol declares no historyMetaItem member, so the REST history door's request literal is compiled against nothing — the last undeclared read door of the audit/history pair #12005

Description

@claude

Found while implementing #11678 (the auditMetaItem declaration; PR #12003) — the history door is the audit door's explicitly named twin (rest-server.ts: "Same Number(...) -> NaN -> dropped-limit shape as the history twin above"; the audit route serves the Studio 审计日志 tab, this one serves the History tab) and it is now in exactly the state the audit door just left. Filed rather than touched: same packages/spec contract decision, one door over, outside the #11678+#11679 fold's declared scope.

Measured on the PR #12003 merge head 2c8a3183 (base d63b0143)

historyMetaItem appears zero times in packages/spec/src/api/protocol.zod.ts (grep -c → 0; positive control: auditMetaItem now returns 5 there via PR #12003).

The REST door (GET /meta/:type/:name/history, packages/rest/src/rest-server.ts ~:5779-5817 on that head) reaches the verb through casts twice — guard if (!(p as any).historyMetaItem) and call await (p as any).historyMetaItem({ ... }) — sending type, name, and conditionally environmentId, sinceSeq, limit.

The implementation (ObjectStackProtocolImplementation.historyMetaItem, packages/metadata-protocol/src/protocol.ts:14585) declares { type, name, organizationId?, sinceSeq?, limit? } and returns { events: MetadataEvent[] }.

Two secondary facts a future card should weigh, both measured on the same head:

Precedents: #11006 (maintainer ruling 2026-08-22, option B) · #11426 (publish) · PR #12003 (#11678 audit — the twin — and #11679 delete).

⛔ Nothing about this door is addressed in PR #12003; its casts and payload are byte-identical there.


Generated by Claude Code

Metadata

Metadata

Assignees

No one assigned

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions