From 899f3a811665e2fb72ec94a47335093f1b9d956f Mon Sep 17 00:00:00 2001 From: Claude Date: Sat, 5 Sep 2026 11:28:43 +0000 Subject: [PATCH 1/2] docs(rest): drop the hand-written translatable-type list from translateMetaItem `isTranslatableMetaType` reads `TRANSLATABLE_METADATA_TYPES`, which is derived from `METADATA_DOCUMENT_TRANSLATORS`' keys. The comment restated those keys by hand as a six-item parenthetical, so it went stale the moment the table grew: `translateDataset` registered a seventh key and the parenthetical still named six. The sentence's actual point is that the keys are SINGULAR, which needs no list to make. The enumeration is deleted rather than corrected -- a corrected restatement rots again on the next registration, and the two lines above already name both the derived set and the table, which is where a reader should go. The table's own doc comment states the rule: "Derived from the dispatch table -- never restate it." Comment-only: every changed line is a `//` line comment, so the token stream is unchanged. Co-Authored-By: Claude Opus 5 Claude-Session: https://claude.ai/code/session_01D47qPfEWVPmhguWgBZCi5N --- packages/rest/src/rest-server.ts | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/packages/rest/src/rest-server.ts b/packages/rest/src/rest-server.ts index ed87a658cd..c560045df1 100644 --- a/packages/rest/src/rest-server.ts +++ b/packages/rest/src/rest-server.ts @@ -3250,9 +3250,8 @@ export class RestServer { if (!item || typeof item !== 'object') return item; // [#6349] Normalize HERE, not at the call sites. `isTranslatableMetaType` // reads `TRANSLATABLE_METADATA_TYPES`, which is DERIVED from - // `METADATA_DOCUMENT_TRANSLATORS`' keys — and those are singular-only - // (`view`/`action`/`object`/`app`/`dashboard`/`page`), matching - // `translateMetadataDocument`'s "Canonical metadata type string". The + // `METADATA_DOCUMENT_TRANSLATORS`' keys — and those are singular-only, + // matching `translateMetadataDocument`'s "Canonical metadata type string". The // `/meta` handlers hand this helper the RAW `:type` path segment, and // Prime Directive #3 makes PLURAL the canonical REST spelling, so the // documented spelling missed the set and the whole localization was From 622fb830fb337d14e4c0e6e4b187c44670105fc9 Mon Sep 17 00:00:00 2001 From: Claude Date: Sat, 5 Sep 2026 11:58:50 +0000 Subject: [PATCH 2/2] docs(permissions): re-anchor the five rest-server system-context citations MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The previous commit deleted one comment line from `rest-server.ts`, so the five absolute line anchors that `content/docs/permissions/system-context.mdx` row 51 carries into that file were each one line high. A pure positional shift: `check-system-context-census` reported five `site-without-a-row` and five `anchor-is-not-a-read-site` findings, each pair differing by exactly one. Re-anchored by `node scripts/check-system-context-census.mjs --fix`, which rewrites a pure shift and refuses a population change. Not hand-edited. Verified structurally rather than by comparing line content (several anchored lines in that file are the same string, so content proves nothing): the census was re-derived on both sides of the diff and the population held — sites 107 = 107, identifierAppearances 873 = 873, classified 463 = 463, roleCounts.read 113 = 113, staleLedgerRows 0 = 0, and on the position-blind multiset of (file, receiver, package, text) ARRIVED = 0 and VANISHED = 0. Control `scannedFiles` = 291 on both sides, non-zero and re-validated in the same run. The only movement was positional: per-site delta 0 -1 -1 -1 -1 -1, the one site above the edit unmoved and the five below it shifted by one. Co-Authored-By: Claude Opus 5 Claude-Session: https://claude.ai/code/session_01D47qPfEWVPmhguWgBZCi5N --- content/docs/permissions/system-context.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/content/docs/permissions/system-context.mdx b/content/docs/permissions/system-context.mdx index 6d1f6564ca..f4af1477c5 100644 --- a/content/docs/permissions/system-context.mdx +++ b/content/docs/permissions/system-context.mdx @@ -159,7 +159,7 @@ The largest single consumer — **17 of the 107 sites**. |:--|:---|:---|:---|:---| | 49 | Object API-exposure gate bypassed (`apiEnabled` / `apiMethods`) | runtime | Get: internal self-writes ignore exposure declarations — these govern **external** exposure, not engine self-writes | `action-execution.ts:138` | | 50 | Action `requiredPermissions` bypassed | runtime | Get: engine self-invocation runs any action | `action-execution.ts:401` | -| 51 | `manage_metadata` bypassed on metadata writes | runtime, rest | Get: schema writes without the capability | `domains/meta.ts:471`, `:874`, `rest-server.ts:5084`, `:6510`, `:6758`, `:7189`, `:7382` | +| 51 | `manage_metadata` bypassed on metadata writes | runtime, rest | Get: schema writes without the capability | `domains/meta.ts:471`, `:874`, `rest-server.ts:5083`, `:6509`, `:6757`, `:7188`, `:7381` | | 52 | The shared metadata-write verdict itself returns `allowed` | metadata-core | Get: the one function all of row 51's doors consult answers yes before any capability is examined | `meta-write-capability.ts:134` | | 53 | Anonymous-deny seam satisfied on the domain dispatchers and the package/federation routes | runtime, rest | Get: passes with no `userId` | `domains/actions.ts:421`, `domains/ai.ts:60`, `domains/automation.ts:989`, `domains/meta.ts:232`, `domains/security.ts:78`, `domains/packages.ts:422`, `external-datasource-routes.ts:302`, `package-routes.ts:97` | | 54 | MCP principal check satisfied | runtime | Get: MCP surface reachable with no user | `domains/mcp.ts:61` |