Function makeContentRef

Build a persisted CONTENT REFERENCE to a file in a mount — a {mountId, relPath} pointer your app serializes into ITS OWN content (a board's JSON, an MDX file's frontmatter, an album manifest — the platform doesn't dictate the container) so a later viewer can resolve it. It is exactly the §5.7 capFile shape: ONE capability, two delivery modes — runtime delegation (a task param, authorized by the caller) vs a durable reference (authorized per-viewer by resolveContentRef). relPath is BACKEND-NATURAL, so the reference resolves to the SAME path for every viewer. Cross-app/cross-project references default to ro.

const ref = makeContentRef({ mountId: 'space:ACME', relPath: 'office-seating/desk.mdx' }, { mode: 'ro' });

  • Parameters

    • ref: { mountId: string; relPath: string }
    • opts: { mode: "ro" | "rw" }

    Returns FileCap