Skip to content

id(serve): design — how does a program appear as a website? (program-only ports, mixed ports, path mounts) #2146

Closed

Description

@dezren39

Design question from Drew (2026-10-29): how does a program appear as a website in id?

Today id serve can host a world (--world, --world-module <wasm>), but the program is only reachable through the World Explorer's /world page, behind an interactive guest join. There is no way to give a program its own web presence. Define the serving model for programs, covering at least these launch shapes:

  1. Program-only port: launch flags bind a specific program to a port — that port serves the program and NOT the World Explorer.
  2. Mixed ports, one process: the Explorer on one port and a program on another port, from the same serve invocation.
  3. Path mount: a program served at a path on the same listener as the Explorer.

Questions the design must answer:

  • What is a "program" for serving purposes — a world program (Roc/Wasm module) only, or any addressable program/document in the node? How is the program identified on the command line / in config (name, id, path)?
  • Per-listener and per-mount authentication: does the --web-token model extend, and what is public-by-default?
  • How does this relate to the existing world hosting (--world-admin-token, guest capabilities) — is a served program a world with a web front door, or a separate concept?
  • What does the program receive per request/session (identity, capabilities), and what can it render?

Companions: the bindings model (multiple listeners by flag/config) and dynamic publish/unpublish are separate issues; this one is the model they implement.

Activity

  1. added
    task/triageQueue packet kind: verify, reproduce, and route this item
    source/humanFiled directly by a human
    priority/normalOrdinary priority (the default)
    queue/queuedHas a queued task in the Supabase agent queue
    app/idPackage/app: id (pkgs/ or apps/ in this repo)
    effort/mMedium: expected under 1 day of work
    kind/designA design proposal (design-architect): multi-step, phased, decision-bearing
    on Oct 29, 2026
  2. developing-today commented on Oct 29, 2026

    @developing-today
    Contributor
  3. dezren39 commented on Oct 29, 2026

    @dezren39
    MemberAuthor

    agent-note:v1
    state: filing set (Drew, 2026-10-29, from the id web walkthrough)
    Found via: walkthrough gaps + Drew's serving direction in chat

    This design issue is the hub of a five-issue set filed together:

    Suggested order: #2146 (model) and #2145 (bindings) first; #2147 builds on both. #2143 and #2144 are independent.

  4. dezren39 commented on Nov 1, 2026

    @dezren39
    MemberAuthor

    Design decision record is ready: PR #3836.

    Summary

    • V1 targets a hosted world by WorldName, not arbitrary documents or guest-authored HTML.
    • The website uses the trusted text/screen presenter; the program remains host-run.
    • Bindings select Explorer or Program(WorldName): program-only root, mixed listeners in one process, or a canonical path mount.
    • Web-token auth stays listener-wide; mounts inherit it. World sessions separately require guest capabilities; admin and web tokens grant no guest authority.
    • Explorer route collisions fail by default; mounts must scope paths, assets, and WebSockets.
    • The note records invariants, implementation acceptance criteria, and source-line evidence.

    Phases: (1) surface/target contract after #2145, (2) program-only listener, (3) mixed listeners, (4) canonical path mounts and conflict checks, (5) publication integration with #2147.

    Question for Drew: Should a later explicit public mode mint anonymous, least-privilege guest sessions, or should every visitor always need an invite capability? Recommendation: invite-capability gated for v1; consider public access only as an explicit opt-in with a configured capability ceiling and rate/session limits. This does not block the initial serving model.

  5. added a commit that references this issue on Nov 2, 2026
  6. added
    work/assignedQueue worker lifecycle state
    queue/claimedQueue worker lifecycle state
    and removed
    queue/queuedHas a queued task in the Supabase agent queue
    on Nov 2, 2026
  7. dezren39 commented on Nov 2, 2026

    @dezren39
    MemberAuthor

    agent-note:v1 — picked up triage task 3156 (worker repo-worker-code, lane aea12c82, origin openchamber-scheduled-lane) at 2026-11-02T23:07:45Z.

    Triage verdict: already done — design delivered by merged PR #3836.

  8. added 2 commits that reference this issue on Nov 4, 2026
  9. dezren39 commented on Nov 5, 2026

    @dezren39
    MemberAuthor

    Ruling (Drew, 2026-11-04): anonymous public program sessions are the norm AND invite-gating gets built — both modes. Anonymous still requires an iroh ID at minimum; there is no zero-identity access. The generic invite/delegation design (iroh tickets + links, worlds and groups, one-time and bearer forms, delegation provenance) is filed as its own issue extending this one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

app/idPackage/app: id (pkgs/ or apps/ in this repo)effort/mMedium: expected under 1 day of workkind/designA design proposal (design-architect): multi-step, phased, decision-bearingpriority/normalOrdinary priority (the default)source/humanFiled directly by a humantask/triageQueue packet kind: verify, reproduce, and route this item

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions