spec: community app pairing — the descriptor and config server on the gateway, the S3a wallet choice and S3a-APP, the Coa submission at the pipeline tail, the app card, and the signin/app blocks #1492 waits on (map #1293, ADR 0226 / DDR 0228) #1495

Open
opened 2026-09-15 16:13:16 +00:00 by ben · 0 comments
Owner

Parent

Wayfinder map #1293 — the community wallet. This is the child spec for the community app pairing slice: the community backend descriptor served from the gateway (ADR 0226, amended by ADRs 0235, 0236, 0238), the IDSS-first pairing walk (DDR 0228, amended by DDR 0239), and the two blocks the sign-in spec #1492 waits on — the descriptor's signin{url} and the app card's ready state. Cross-feature constraints inherited from the map's Decisions-so-far: sovereignty first (Mātou is never a gate on founding; a refused or unreachable Coa never fails a founding); the operator's choice is always kept ("later" costs nothing and the door stays open on the dashboard); the browser twelve-words door stays the interim until the app is downloadable; the control plane is the roster's single writer (ADR 0198) and therefore the descriptor's single writer; nothing built for the browser path is thrown away.

Flow: docs/ux/flows/p1-founding.mermaid (amended 2026-09-15 with S3a-APP, the pipeline tail and the app card) and the cross-feature view docs/ux/flows/community-app-journey.mermaid. Wireframes: docs/ux/wireframes/p1-founding/p1-s3a-identity.html (the wallet choice and the new "later" line), p1-s3a-community-app.html (S3a-APP and the HO/DO app card, four states). Research: #1294 (what each backend serves), #1314 (any-sync and the config server on NixOS).

Problem Statement

A community that founds on the IDIP path has told its members they will sign in with a wallet app on their own device — and then has no app. The wallet is matou-app, built and branded by Coa, and a Coa build bakes exactly one backend address. Today Coa's form and IDSS founding each mint a community that knows nothing of the other: the gateway publishes no document a Coa build could point at, Coa's form asks for brand and backend details founding already holds, and a founder who wants the app must leave founding, fill Coa's form by hand, wait for a Mātou-triggered build, and never sees on their dashboard whether the app exists. The sign-in feature (#1492) cannot ship at all until the gateway serves the descriptor that tells a wallet where its sign-in site is, and the operator's surfaces cannot say "your app is ready" because nothing records it.

Solution

Founding on IDIP offers the community's own app as one choice on the identity step and one extra screen of feature toggles, then does the rest itself: the gateway installs Mātou's config server as one more unit of the identity stack and serves matou-app's client-config at the apex as the community backend descriptor — the community's identity, its doors, its schemas, its sign-in site, and (once it exists) its app. At the end of the deployment pipeline, once the outside can read that descriptor, founding submits the app to Coa on the operator's behalf — brand from the kit, backend the apex, marked as IDSS-originated so Coa builds it without a relationship gate — and finishes without waiting. The operator home and the dashboard overview carry one app card that follows Coa's public status document from being built to downloads available (or failed, with try again), and ready writes the app's downloads address back into the descriptor so invites and the sign-in page can say "get the app". A founder who chooses "later" gets the same card at not yet designed, and designs the app from the dashboard when they are ready.

User Stories

Actors: operator (founds and runs the community — the glossary's word; never "admin"), member (a person with a wallet), wallet (matou-app, the community's branded build), Coa (Mātou's app builder), control plane (the gateway's single writer).

A. The founding walk

  1. As an operator on the IDIP path, I want the identity step to tell me plainly that members will sign in with a wallet app and offer to build ours now, so that the app is part of founding and not a later chore.

    • Given S3a with IDIP selected, when the step renders, then the wallet statement and the wallet choice appear under the two identity cards (data-field="wallet-choice"), with Option 1 Create your own community wallet app now preselected and Option 2 Use the IDIP wallet app rendered data-status="disabled" with "Coming soon", never selectable.
    • Given S3a with passwords & passkeys (kanidm) selected, when the step renders, then the wallet choice is hidden and nothing about an app is asked or recorded.
    • Given Option 1 selected, when I press Continue, then S3a-APP opens; given "later" chosen (story 3), then Continue goes straight to Access.
  2. As an operator, I want S3a-APP to show only what founding cannot fill in for Coa — the feature toggles beside a live preview of my app wearing my kit — so that I never see Coa's form.

    • Given S3a-APP, when it renders, then data-field="features" lists Coa's toggleable features with Coa's defaults (identity locked on; notices, events, chat on; projects, proposals off; maramataka on), data-field="contact-email" is prefilled with my email, and data-field="platforms" names macOS, Windows, Linux and Android with the iPhone / app-store caveat.
    • Given the kit from P1-S3 (name, accent, secondary colour, round logo — DDR 0227), when the preview (data-field="app-preview") renders, then it wears them and its tab bar follows the toggles: the first three enabled features keep tabs, the rest roll into More.
    • Given I toggle a feature, when the preview updates, then the tab bar reflects it without a round trip.
  3. As an operator, I want a plain "not now" on the identity step, so that choosing later costs nothing and keeps the door open.

    • Given S3a with IDIP selected, when it renders, then one hint line data-field="wallet-later" / data-action="wallet:later" reads Not now — I'll design the app later from my dashboard, with costs nothing; members sign in through the browser until then.
    • Given I choose it, when I Continue, then S3a-APP is skipped, the draft records the app as "later", and the app card opens at none after hand-off.
    • Given "later" chosen, when I return to S3a before deploy and pick Option 1, then S3a-APP opens and the draft records the app again (the S3a re-choice rule).
  4. As an operator, I want Continue on S3a-APP to record my choices and send nothing, so that nothing leaves my computer before Review and nothing waits on Mātou.

    • Given S3a-APP, when I press Continue, then the founding draft carries the app submission (features, contact email, chosen-now) and no network request to Coa is made; when I press Back, then S3a shows Option 1 still selected.
    • Given the reopened walk before deploy, when I reach S3a-APP, then it is re-editable; given the community is Founded, then S3a and S3a-APP are locked like the other settled steps.
  5. As an operator, I want Review to say what will happen with the app, so that the submission is a confirmed choice, not a surprise.

    • Given Option 1 in the draft, when S6 renders, then an identity-section row reads Your community app — submitted to Coa once your gateway is live; you'll see it being built on your home screen and names the enabled features.
    • Given "later", when S6 renders, then the row reads Your community app — not now; design it later from your dashboard.

B. The descriptor and the config server on the gateway

  1. As an operator on the IDIP path, I want my gateway to be a community backend by construction, so that any Coa build can point at it with one address and no rebuild.

    • Given an IDIP founding (rented, own-VPS, machine-at-your-place or private path), when the identity stack stands up, then Mātou's config server runs as its own unit beside KERIA, the witness and the schema server, with a declared health check (ADR 0112) the deploy waits on, its admin token minted as a clan-vars secret, and its data directory in the gateway's declared state.
    • Given a kanidm founding, when the gateway stands up, then no config server unit, no apex routes and no descriptor exist.
  2. As a wallet or as Coa, I want the descriptor at the community's apex, so that the address a build bakes is the address people already know.

    • Given the front door, when it renders, then GET https://<apex>/api/client-config and GET https://<apex>/api/config proxy to the config server over loopback and every other path on the apex stays the control plane's (the Portal, /authz/signin, the steward API); the identity doors stay the subdomains they are today.
    • Given the private path, when the guest's front door renders, then the same two routes exist on the in-guest apex.
  3. As a wallet, I want the descriptor to be the 1.1 shape ADR 0226 ruled, so that a 1.0 wallet keeps working and a 1.1 wallet learns everything it needs from one document.

    • Given a live IDIP gateway, when /api/client-config is fetched from outside, then the document carries version: "1.1", the KERI block with the gateway's real doors (keria.<apex>, keria-cesr.<apex>, keria-boot.<apex>, witness.<apex>, schema.<apex>) and the one community witness's runtime-minted AID and OOBI, community{name, slug, aid, oobi, registry}, api_url (the steward API root on the apex), schemas (each credential kind's SAID and public OOBI, the gateway's own), boot{gated: false, join_url}, backend_kind: "idss", stack (KERIA / keripy / signify-ts generations from the pins), signin{url} (the bridge's sign-in endpoint as #1492 defines it), and app only once the card is ready.
    • Given no any-sync installed, when the document is fetched, then it has no anysync key; given any-sync installed, then the block names the gateway's nodes.
    • Given a 1.0 loader, when it reads the document, then unknown keys are dropped and boot succeeds (matou-app's existing behaviour, asserted against the served document).
    • Given the document, when inspected, then no doorkeeper block exists and nothing secret rides in it (no admin token, no passcode, no private key material).
  4. As the control plane, I want to be the descriptor's only writer, so that the roster stays single-writer and the app never founds on IDSS.

    • Given founding reaches the identity rows, when the community identity and registry exist, then the control plane posts org-config (the community's AID, OOBI, name, slug, registry, the steward set and their OOBIs) to the config server over loopback with the admin token, and the descriptor's community block reflects it.
    • Given a steward change (promotion, removal, rotation), when the roster settles, then the control plane rewrites org-config in place (an update, not delete-then-post) and the served document changes within one poll of the change.
    • Given a request to the config server's write door from anywhere but loopback, when it arrives, then the front door does not route it — the write door is never public.
  5. As the outside-in door probe, I want to prove the descriptor is readable from outside before anything is submitted to Coa, so that a build never bakes an address that does not answer.

    • Given the deploy's existing outside-in probe passes, when the pipeline tail runs, then a second probe fetches https://<apex>/api/client-config from outside and requires version and community.aid; given it fails within the same bounded attempts the door probe uses, then the Coa submission is skipped and the app card opens at failed with the outside could not read your community's details yet, and try again re-probes.

C. The submission at the end of the pipeline

  1. As an operator who chose Option 1, I want founding to submit my app to Coa for me, after my gateway is live, so that I never fill Coa's form and never wait on the build.

    • Given the door probe and the descriptor probe both pass, when the tail runs, then one multipart submission goes to Coa's submit door: brand (name, slug, primary and secondary colours, contact email) from the kit and the draft, features from S3a-APP, backend self-hosted with the apex as the config address, the round logo as the logo file, and the IDSS-originated marker.
    • Given Coa accepts, when it answers, then the card record stores the slug, Coa's page address and submitted at, and the card opens at pending; the hand-off (S12-IDIP) proceeds exactly as today — founding never waits on the build.
    • Given the private path, when the tail runs, then no submission is made (Coa cannot reach a private apex) and the card opens at none with the copy naming that the app needs a public address.
  2. As an operator, I want a refused or unreachable Coa to be non-fatal, so that Mātou is never a gate on my founding.

    • Given Coa answers a refusal (the name is taken at Coa, the backend probe failed, validation), when the tail continues, then founding completes, the card opens at failed with Coa's reason in plain words, and data-action="rebuild" re-submits from the dashboard.
    • Given Coa is unreachable or times out, when the tail continues, then founding completes and the card opens at failed with could not reach Coa and try again.
    • Given a refused or unreachable Coa, when the hand-off card renders, then nothing about the app is counted as a failed founding step.
  3. As an operator who chose Option 1, I want any-sync installed at founding, so that my members' app has its content layer from day one.

    • Given Option 1 (and not the Coa-first branch), when the gateway deploys, then the any-sync set (coordinator, tree node, consensus node, file node with their stores) runs on the gateway, its network and node keys minted as clan-vars secrets, its three public TCP ports opened with the mail-port precedent, and the descriptor's anysync block served once the coordinator answers.
    • Given "later", when the gateway deploys, then no any-sync unit runs and the descriptor has no anysync key.
    • Given any-sync installed, when the gateway's declared datasets are listed, then any-sync's stores are a port-declared dataset of their own (ADR 0080) with a quiesce-or-dump backup step; the identity dataset's window is unchanged.

D. The app card

  1. As an operator, I want one app card on my operator home and my dashboard overview, so that I always know where my app is.

    • Given an IDIP community, when HO or DO renders, then one data-field="community-app" row sits with the standing checks with exactly one data-status of pending | ready | failed | none, and both surfaces read the same record.
    • Given a kanidm community, when HO or DO renders, then no app card renders.
    • Given the card in any state, when the surface's health, hand-off or blocking checks are computed, then the card never contributes — it blocks nothing.
  2. As an operator, I want the card at pending to show that the app is being built and let me see the details, so that waiting is honest.

    • Given a submission accepted, when the card renders, then it reads Your community app — being built, submitted to Coa ‹relative time›, and data-action="app-details" opens Coa's page for the community.
  3. As the control plane, I want to poll Coa's public status document for the slug, so that no Mātou credential ever points at a community.

    • Given a record at pending, when the poll runs (on a fixed interval with backoff, and on demand when a surface opens), then it fetches Coa's public status document beside the community's page, unauthenticated, and maps ready → ready (with the downloads address and platforms), failed → failed (with the recorded reason), anything else → still pending.
    • Given the status document is unreachable, when the poll runs, then the record stays pending and the card shows last checked ‹time› — never a false failed.
  4. As an operator, I want ready to mean downloads available, so that I can share the app.

    • Given Coa reads ready, when the record updates, then the card reads Your community app — downloads available, lists the platforms, data-action="open-downloads" opens the downloads page, and the copy names the Members tab as where to share it.
    • Given ready, when the descriptor is next served, then app{downloads_url, name} is present — written by the control plane's org-config writer, the same path story 9 uses.
    • Given ready, when the Members tab's invite (P6-S2i) renders, then its copy gains get the app with the downloads address (the invite's app-first opening itself is DDR 0230's, spec'd with adoption).
  5. As an operator, I want failed to tell me why and let me try again, so that a build failure is a moment, not a dead end.

    • Given Coa reads failed or the tail's submit was refused, when the card renders, then it reads Your community app — the build failed, data-action="app-details" shows the reason, and data-action="rebuild" re-submits the same submission from the record.
    • Given a re-submit, when Coa answers slug-taken because the earlier submission exists, then the card names it plainly (Coa already holds a page for this name) and points at Coa's page rather than looping.
  6. As an operator who chose later, or whose community pre-dates this, I want the card at none to be the way in, so that the offer never expires.

    • Given the draft recorded "later", the private path, or an IDIP community founded before this slice, when the card renders, then it reads Your community app — not yet designed, your members sign in through the browser until you build one, and data-action="design-app" opens the dashboard twin (section E).
  7. As an operator, I want the card's record to survive restarts and be the same on both surfaces, so that I never see two truths.

    • Given the record, when written, then it lives in the config repo under the control plane's single-writer rule (the service-access matrix precedent), holds slug, Coa page address, state, reason, submitted-at, last-checked, downloads address; when the operator app restarts or the dashboard reloads, then the card renders from it via the control API.

E. Designing the app later, from the dashboard

  1. As an operator, I want to design the app from the dashboard with the same screen founding showed, so that later is the same walk, not a lesser one.
    • Given data-action="design-app", when it opens, then the dashboard shows S3a-APP's twin (data-field="features", data-field="contact-email", the kit-wearing preview) prefilled from the brand kit; when I submit, then the control plane runs the same submission as the pipeline tail (descriptor probe, then Coa) and the card moves to pending or failed by the same rules.
    • Given a submit from the dashboard on a community with no any-sync, when the submission is accepted, then the control plane installs the any-sync set as a deploy (the catalogue-service precedent), and the descriptor gains anysync once the coordinator answers.
    • Given the private path, when the twin opens, then it says the app needs a public address and offers nothing to submit.

F. What matou-app, matou-infrastructure and Coa owe

  1. As a wallet, I want to boot against an IDSS descriptor, so that a Coa build pointed at a gateway simply works. (matou-app)

    • Given a 1.1 document, when the wallet loads it, then anysync absent is tolerated (content surfaces show their empty state, sign-in and credentials work), a single witness satisfies the witness floor, schema OOBIs come from schemas, absent doorkeeper and app are tolerated, signin.url becomes the home sign-in site (#1492), and a stack mismatch is a diagnostics warning, never a refusal; only an unknown version major refuses.
  2. As the gateway, I want the config server to serve the 1.1 shape from sources a gateway has, so that one implementation owns the document. (matou-infrastructure)

    • Given the config server 1.1, when configured with per-door absolute URLs, a witness file (URLs and AIDs) and a rendered JSON of the gateway blocks, then it serves them instead of the raw-port or path-prefix layouts and the hard-coded demo witnesses; signin replaces doorkeeper; anysync stays optional; org-config gains an authenticated update path; the subprocess test suite gains the 1.1 file.
  3. As Coa, I want an IDSS-originated submission to build on submit, so that the founding is the relationship. (coa)

    • Given a submission carrying the IDSS-originated marker whose backend probe passed, when it is stored, then the build dispatches without the relationship-first parking; a submission from Coa's own form keeps parking as today.
    • Given the backend probe, when it fetches, then it reads /api/client-config (not /config) and accepts a document without anysync when the submission promises it (or the prober is told to require it only when present).
    • Given a community's status document, when fetched unauthenticated at its public address, then it answers with the state, the downloads address and the platforms once ready, and the reason once failed (already so; asserted).

G. The community's any-sync spaces (ADR 0226 amendment, 2026-09-15 — re-ruled the same day)

  1. As an operator who chose Option 1, I want founding to create my community's spaces for me, so that the content layer exists before anyone installs the app. (idss)

    • Given any-sync is installed and its coordinator answers from outside, when the pipeline tail runs (before the Coa submission), then the operator app creates the community, read-only and admin spaces as the founder, with the keys the wallet derives from the founder's twelve words (which the laptop still holds — the scrub has not run), seeds what org setup seeds, and records the three IDs in the config repo; the descriptor writer (story 9) rewrites org-config so the first outside read of the descriptor names them.
    • Given the words, when the spaces are created, then the creation runs on the laptop over the public any-sync ports and the words never leave the laptop.
    • Given the founder later adopts their identity into the app (DDR 0230), when the wallet boots, then it finds the three spaces with its own identity as owner and creates nothing.
    • Given any-sync does not answer from outside within the tail's bounded attempts, when the tail continues, then founding completes, the spaces are not created, the descriptor carries anysync without space IDs, and the app card's details name it; the first-steward fallback (story 26) then applies.
    • Given "later" or the Coa-first branch, when the tail runs, then no spaces are created.
  2. As the first steward whose wallet lands against a gateway whose descriptor names no spaces, I want my wallet to create them, so that "later" and older communities get their content layer too. (matou-app — the fallback)

    • Given a wallet holding a steward credential issued into the community ledger, when it boots against a descriptor that carries anysync and whose org-config names no space IDs, then it creates the three spaces exactly as founding does and posts the IDs to api_url with its existing steward authentication; nothing else of org setup runs.
    • Given the post is refused because IDs are already recorded, when the wallet continues, then it re-reads the descriptor and joins the recorded spaces.
    • Given a wallet holding no steward credential, when it boots against such a descriptor, then it creates nothing and shows the content surfaces' empty state.
  3. As the control plane, I want to record the space IDs once, so that org-config stays single-writer and every wallet joins the same spaces. (idss)

    • Given founding's own creation (story 25), when the IDs are recorded, then the descriptor writer rewrites org-config; no steward-API post is involved.
    • Given a steward-authenticated post of three IDs to the steward API when none are recorded, when it arrives, then the control plane records them and rewrites org-config; given IDs already recorded, then it answers a conflict naming the recorded set and writes nothing; given a non-steward or any other authentication, then it is refused.
  4. As the wallet's maintainers, I want space creation to live in one package, so that founding and the wallet can never drift apart. (matou-app)

    • Given matou-app's space creation (key derivation from the mnemonic at indexes 1–3, header seeds, the ACL owner, the seeded profile), when it is exported as a Go package with no dependency on the wallet's server wiring, then the operator app imports it for story 25 and the wallet's own org setup and story 26 call the same code; a change to the convention is one change.

Implementation Decisions

Repos. Work lands in four repos; this spec is the one place they are named together, and to-tickets emits per-repo tickets. Anything not listed for a repo is that repo's "nothing new".

idss

  • Founding draft and steps. The draft gains an app submission record: chosen (now | later), features (the toggle map, Coa's keys), contact email. S3a-APP is a step of the founding page between S3a and S4 on the IDIP + Option 1 branch; "later" is the wallet:later action on S3a. The reopened-walk rules follow S3a's (editable until deploy, locked after Founded). The preview is the founding page's own mini, built from the kit compile the brand-kit step already has — not an iframe of Coa.
  • The config server unit. Rendered with the identity stack's other units (ADR 0062 part 1, the keria / keri-witness / keri-schema shape), as a distinct systemd unit with a declared health check on its health door, packaged the way the schema server is (a Python file wrapped as a binary), env from a clan-vars generator (admin token) plus a rendered JSON file the control plane owns for the gateway blocks. Always on the IDIP path, never on kanidm. Its data directory joins the identity dataset's declared state (it is a rendering of the roster, small and rebuildable).
  • Front door. Two path routes on the bare apex, /api/config and /api/client-config, proxied to the config server's loopback port; no other apex path changes; the unserved-host fall-through and the KERI subdomain doors are untouched.
  • The writer. One control-plane component owns org-config: it builds the document from the roster (community AID, OOBI, name, slug, registry, stewards), the credential schemas' SAIDs and public OOBIs, the pins (stack), the apex (api_url, boot.join_url, signin.url), and the app record (app), and writes it over loopback with the admin token — at the identity rows during founding, on every steward change, and when the app record reaches ready. Loopback only; the token is a clan-vars secret the bridge and the control plane read, never the app.
  • Probes. The descriptor probe reuses the outside-in door probe's shape (bounded attempts, injected for the seam) and adds the /api/client-config fetch with the two required fields.
  • The pipeline tail. After the door probe (rented checklist and own-VPS/manual deploy alike): descriptor probe → Coa submit → record written → hand-off. Every failure is recorded on the app record and never on the stand-up's step status. The Coa client is one adapter (submit, status fetch) injected like the broker client, with a scripted fake in the seam.
  • Coa submission shape. Coa's existing multipart submit door: brand {name, slug, primaryColour, secondaryColour, contactEmail}, features {identity: true, chat, projects, proposals, notices, events} (maramataka rides as Coa's default until Coa exposes it), backend {kind: "self-hosted", configServerUrl: "https://<apex>"}, the logo as a PNG rendered from the kit's round logo, plus the IDSS-originated marker as a form field (origin: idss). The slug is the founding slug; a slug-taken answer is a failed reason.
  • The app record. A config-repo document (the matrix-store precedent: single writer, read by both surfaces through the control API, OpenAPI regenerated for the client): {state, slug, pageUrl, submittedAt, lastCheckedAt, reason, downloadsUrl, platforms}. none is the absence of a record or a record with chosen: later.
  • The poll. A control-plane ticker (interval on the order of a minute, exponential backoff while unreachable, capped) plus an on-open refresh from either surface; it fetches Coa's public status document for the slug and maps its states. It runs only while a record is pending.
  • The card. One component per surface reading the same API shape, the data-field="community-app" / data-status / data-action contract from the wireframe. On HO it sits with the gateway's standing checks; on DO beside the health and backups headlines. Never part of any health verdict.
  • The dashboard twin. A dashboard screen reachable from the card's design-app action, the same fields as S3a-APP, submitting through the same control-plane path; the any-sync install-later runs as a deploy of the any-sync units (the catalogue-service deploy precedent) before the submission is sent, so the descriptor probe Coa runs sees a complete document.
  • any-sync on the gateway. Installed when Option 1 is chosen (founding tail) or when the dashboard twin submits; never on the Coa-first branch (ADR 0238 §12). Shape: the five any-sync daemons and their stores run as OCI containers under podman with pinned digests (the archive-port precedent; research #1314 §2.3 — Mongo's licence and Redis-Bloom make a source build the costlier door), a single-member Mongo replica set, MinIO for file bytes; network and node keys from a clan-vars generator (regenerating re-mints the network, like the witness salt); three public TCP ports declared with the mail-port precedent; stores declared as their own dataset (ADR 0080) with mongodump + store copy at backup. Two-way door: source-built units can replace the containers behind the same unit names.
  • Space creation at the tail. One step between the any-sync outside probe and the Coa submission, on the laptop, importing matou-app's space-creation package (below) and deriving from the draft's twelve words — the same mnemonic the founder's KERIA passcode was derived from. Bounded attempts; failure is recorded on the app record's details, never on a stand-up step. The IDs go into the config repo beside the app record and reach org-config through the descriptor writer.
  • The space-ID door. One steward-API route (the existing steward authentication, ADR 0199's key challenge) accepting the three space IDs; the control plane records them in the config repo beside the app record, first write wins with a conflict answer naming the recorded set, and the descriptor writer (above) rewrites org-config. No config-server token ever reaches a wallet.
  • Copy. Glossary words throughout: operator, member, wallet, community backend, sign-in site. "Coa" appears in operator-facing copy as Coa, Mātou's app builder on first use per screen. Never "tenant", "config server", "KERIA" in copy.

matou-infrastructure

  • Config server 1.1: a third URL layout of per-door absolute URLs; witnesses from a file (URLs and AIDs) instead of the six demo AIDs; the new blocks (community, api_url, schemas, boot, backend_kind, stack, signin, app) read from a rendered JSON path and merged over org-config; doorkeeper gone; anysync optional stays; an authenticated update path for org-config (replace-in-place with the admin token) beside the first-write-wins post; the public-URL and tenant behaviours unchanged. The subprocess test suite gains a 1.1 file.

matou-app

  • The space-creation package (ADR 0226 amendment): key derivation, header seeds, ACL owner and profile seeding exported as an importable Go package, free of server wiring; the wallet's org setup and the fallback call it; the operator app imports it. Precedes the idss tail ticket.
  • Space creation by the first steward — the fallback (ADR 0226 amendment): the org-setup space-creation call, run on first landing when the descriptor carries anysync and org-config names no space IDs, gated on holding a steward credential; the IDs posted to api_url; on conflict, re-read and join.
  • As ADR 0226 and ADR 0236 obligate: anysync optional in the loader and the Go backend (content surfaces show their empty state without it); witness floor of one; schema OOBIs from schemas; tolerate absent doorkeeper and app; read signin.url as the home sign-in site; stack mismatch as a diagnostics warning; refuse only an unknown version major.

coa

  • The submit door accepts and stores the IDSS-originated marker; the build dispatches on submit for those submissions when the backend probe passed (DDR 0228 §4 — Ben's exception to Coa's DDR 0007), a per-origin flag; Coa's own form keeps parking.
  • The backend prober fetches /api/client-config; anysync is optional in the probe when absent (the IDSS founding installs it before submitting, so in practice it is present; the prober must not 422 a KERI-only document from the dashboard twin's probe-first path).
  • The status document stays public per slug and carries the downloads address and platforms on ready (already so).

Testing Decisions

A good test drives a public face with fakes behind it and asserts what an operator, a wallet or Coa would observe — the served document, the card's state, the request Coa received — never an internal call sequence.

Seams (existing, reused; one new fake each):

  1. The founding orchestrator seam (internal/founding, the scripted-fake precedent: FakeFleet, the injected door probe, the story-numbered tests such as the S12 hand-off and identity seed-leg tests). Add a scripted fake Coa (accepts / refuses with a reason / unreachable) and a fake descriptor probe. Stories 1–5, 10–13 (draft, tail, non-fatal failures, private path) are proven here end to end from S3a to the hand-off, including that a refused Coa leaves every stand-up step green.
  2. The clan render seam (internal/clan, the RenderKeri_* / RenderFrontDoor_* / RenderIdssIdp_* tests): the config server unit with its declared health check and secret generator; the two apex routes present on IDIP and absent on kanidm; the any-sync units, ports, dataset and key generator when chosen; determinism.
  3. The control API integration seam (internal/controlapi, the *_integration_test.go precedent): the app record's read and write, the poll against a fake status document (ready / failed / unreachable), the descriptor writer's org-config over a fake config server (founding write, steward-change update, app on ready), and that the served-document shape matches the 1.1 contract (a golden document per branch: no any-sync, any-sync, ready).
  4. Dashboard and operator-app component tests (the existing Vitest suites): the card's four states from the API shape, the twin's form, the S3a "later" line and S3a-APP's preview following the toggles.
  5. matou-infrastructure's subprocess tests for the 1.1 layout; coa's Vitest for the origin flag and the prober path; matou-app's loader tests against the golden 1.1 document from seam 3 (the document is checked into both repos' fixtures, one source).

Drive. The rented IDIP rehearsal drive gains one leg: with the harness's fake Coa, the app card reads pending at hand-off and ready after the fake flips its status document, and the descriptor served at the apex carries app and signin. A real Coa build is not on the drive (minutes to hours, and a Mātou-side dependency); the live proof against real Coa is a manual trial step, recorded in the trial guide.

What is not tested here: the wallet's sign-in round trip (#1492's seam), any-sync's content behaviour in the app (the initialisation pipeline, below).

Out of Scope

  • Members whose membership credential carries no invite key. On coa-shared the community-space invite key is embedded in the membership credential at issue time; the dashboard's browser-era issuance on IDSS embeds none, whenever the spaces were created. How that member's wallet joins the spaces later is the adoption spec's (DDR 0230's first-landing edge) — recorded on the map. A member's private space when any-sync arrives after they adopted is the same map note.
  • The Coa-first branch (ADR 0238, DDR 0239): S3a's "we already have an app" question, S3a-JOIN, the hosted-identity row, the rehost walk, the descriptor handing back Mātou's addresses. Its own /wireframe and spec; this spec's descriptor writer must not assume the addresses it serves are its own (they are data, read from the record).
  • Member adoption and the app-first invite (DDR 0230, wallet/): W-S0, the invite opening app-first, the reaper. This spec only flips the invite's copy on ready.
  • Wallet sign-in (#1492): the bridge routes, the verifier, the App-only switch. This spec serves signin{url} for it.
  • Option 2, the IDIP wallet app — visible, disabled, never selectable.
  • Coa's downloads-URL write-back to the gateway (ADR 0226 §5 fog) — the gateway pulls the status document instead.
  • A signed descriptor, the recognition hint, per-community schemas beyond what schemas carries, iPhone builds and store listings.
  • Changing features after the build ("the app updates without a rebuild where it can") — Coa's, later.

Further Notes

  • Ruled 2026-09-15, twice (ADR 0226 amended): founding creates the three community any-sync spaces at the pipeline tail as the founder, from the twelve words it still holds, through a package matou-app exports (stories 25, 27, 28); the first steward's wallet is the fallback for "later" and pre-dating communities (story 26). Rejected: creation on the gateway (the words would travel); a second any-sync convention in idss; Mātou creating them; the fallback alone.
  • Sequencing for to-tickets. The descriptor and config server (B) come first — #1492's tickets block on signin{url}. Then the founding walk (A) and the tail (C), then the card (D), then the twin (E). Story 28 (matou-app's space-creation package) precedes story 25's tail ticket. Story 24 (coa auto-build) and story 23 (config server 1.1) are external tickets the tail's real-Coa trial waits on; the fake-Coa seam does not.
  • DDR 0228's Coa form facts (from research #1294): Coa's form is brand → features → backend → review, TOGGLEABLE_FEATURES = chat, projects, proposals, notices, events; builds are macOS (Intel, Apple silicon), Windows, Linux AppImage, Android APK; no iPhone build. Maramataka is not a Coa toggle today — S3a-APP shows it as on, and the submission does not carry it until Coa exposes it.
  • Naming. The wireframe index rows for S3a, S3a-APP and the app card, and the founding flow's amendment, landed with this spec (2026-09-15). The cross-feature journey community-app-journey.mermaid is the reader's map of where this slice sits between founding and App-only.
## Parent Wayfinder map **#1293** — *the community wallet*. This is the child spec for the **community app pairing** slice: the community backend descriptor served from the gateway (ADR 0226, amended by ADRs 0235, 0236, 0238), the IDSS-first pairing walk (DDR 0228, amended by DDR 0239), and the two blocks the sign-in spec #1492 waits on — the descriptor's `signin{url}` and the app card's `ready` state. Cross-feature constraints inherited from the map's Decisions-so-far: sovereignty first (Mātou is never a gate on founding; a refused or unreachable Coa never fails a founding); the operator's choice is always kept ("later" costs nothing and the door stays open on the dashboard); the browser twelve-words door stays the interim until the app is downloadable; the control plane is the roster's single writer (ADR 0198) and therefore the descriptor's single writer; nothing built for the browser path is thrown away. Flow: `docs/ux/flows/p1-founding.mermaid` (amended 2026-09-15 with S3a-APP, the pipeline tail and the app card) and the cross-feature view `docs/ux/flows/community-app-journey.mermaid`. Wireframes: `docs/ux/wireframes/p1-founding/p1-s3a-identity.html` (the wallet choice and the new "later" line), `p1-s3a-community-app.html` (S3a-APP and the HO/DO app card, four states). Research: #1294 (what each backend serves), #1314 (any-sync and the config server on NixOS). ## Problem Statement A community that founds on the IDIP path has told its members they will sign in with a wallet app on their own device — and then has no app. The wallet is matou-app, built and branded by Coa, and a Coa build bakes exactly one backend address. Today Coa's form and IDSS founding each mint a community that knows nothing of the other: the gateway publishes no document a Coa build could point at, Coa's form asks for brand and backend details founding already holds, and a founder who wants the app must leave founding, fill Coa's form by hand, wait for a Mātou-triggered build, and never sees on their dashboard whether the app exists. The sign-in feature (#1492) cannot ship at all until the gateway serves the descriptor that tells a wallet where its sign-in site is, and the operator's surfaces cannot say "your app is ready" because nothing records it. ## Solution Founding on IDIP offers the community's own app as one choice on the identity step and one extra screen of feature toggles, then does the rest itself: the gateway installs Mātou's config server as one more unit of the identity stack and serves matou-app's `client-config` at the apex as the **community backend descriptor** — the community's identity, its doors, its schemas, its sign-in site, and (once it exists) its app. At the end of the deployment pipeline, once the outside can read that descriptor, founding submits the app to Coa on the operator's behalf — brand from the kit, backend the apex, marked as IDSS-originated so Coa builds it without a relationship gate — and finishes without waiting. The operator home and the dashboard overview carry one **app card** that follows Coa's public status document from *being built* to *downloads available* (or *failed*, with try again), and *ready* writes the app's downloads address back into the descriptor so invites and the sign-in page can say "get the app". A founder who chooses "later" gets the same card at *not yet designed*, and designs the app from the dashboard when they are ready. ## User Stories Actors: **operator** (founds and runs the community — the glossary's word; never "admin"), **member** (a person with a wallet), **wallet** (matou-app, the community's branded build), **Coa** (Mātou's app builder), **control plane** (the gateway's single writer). ### A. The founding walk 1. **As an operator on the IDIP path, I want the identity step to tell me plainly that members will sign in with a wallet app and offer to build ours now, so that the app is part of founding and not a later chore.** - Given S3a with IDIP selected, when the step renders, then the wallet statement and the wallet choice appear under the two identity cards (`data-field="wallet-choice"`), with **Option 1** *Create your own community wallet app now* preselected and **Option 2** *Use the IDIP wallet app* rendered `data-status="disabled"` with "Coming soon", never selectable. - Given S3a with passwords & passkeys (kanidm) selected, when the step renders, then the wallet choice is hidden and nothing about an app is asked or recorded. - Given Option 1 selected, when I press Continue, then S3a-APP opens; given "later" chosen (story 3), then Continue goes straight to Access. 2. **As an operator, I want S3a-APP to show only what founding cannot fill in for Coa — the feature toggles beside a live preview of my app wearing my kit — so that I never see Coa's form.** - Given S3a-APP, when it renders, then `data-field="features"` lists Coa's toggleable features with Coa's defaults (identity locked on; notices, events, chat on; projects, proposals off; maramataka on), `data-field="contact-email"` is prefilled with my email, and `data-field="platforms"` names macOS, Windows, Linux and Android with the iPhone / app-store caveat. - Given the kit from P1-S3 (name, accent, secondary colour, round logo — DDR 0227), when the preview (`data-field="app-preview"`) renders, then it wears them and its tab bar follows the toggles: the first three enabled features keep tabs, the rest roll into More. - Given I toggle a feature, when the preview updates, then the tab bar reflects it without a round trip. 3. **As an operator, I want a plain "not now" on the identity step, so that choosing later costs nothing and keeps the door open.** - Given S3a with IDIP selected, when it renders, then one hint line `data-field="wallet-later"` / `data-action="wallet:later"` reads *Not now — I'll design the app later from my dashboard*, with *costs nothing; members sign in through the browser until then*. - Given I choose it, when I Continue, then S3a-APP is skipped, the draft records the app as "later", and the app card opens at `none` after hand-off. - Given "later" chosen, when I return to S3a before deploy and pick Option 1, then S3a-APP opens and the draft records the app again (the S3a re-choice rule). 4. **As an operator, I want Continue on S3a-APP to record my choices and send nothing, so that nothing leaves my computer before Review and nothing waits on Mātou.** - Given S3a-APP, when I press Continue, then the founding draft carries the app submission (features, contact email, chosen-now) and no network request to Coa is made; when I press Back, then S3a shows Option 1 still selected. - Given the reopened walk before deploy, when I reach S3a-APP, then it is re-editable; given the community is Founded, then S3a and S3a-APP are locked like the other settled steps. 5. **As an operator, I want Review to say what will happen with the app, so that the submission is a confirmed choice, not a surprise.** - Given Option 1 in the draft, when S6 renders, then an identity-section row reads *Your community app — submitted to Coa once your gateway is live; you'll see it being built on your home screen* and names the enabled features. - Given "later", when S6 renders, then the row reads *Your community app — not now; design it later from your dashboard*. ### B. The descriptor and the config server on the gateway 6. **As an operator on the IDIP path, I want my gateway to be a community backend by construction, so that any Coa build can point at it with one address and no rebuild.** - Given an IDIP founding (rented, own-VPS, machine-at-your-place or private path), when the identity stack stands up, then Mātou's config server runs as its own unit beside KERIA, the witness and the schema server, with a declared health check (ADR 0112) the deploy waits on, its admin token minted as a clan-vars secret, and its data directory in the gateway's declared state. - Given a kanidm founding, when the gateway stands up, then no config server unit, no apex routes and no descriptor exist. 7. **As a wallet or as Coa, I want the descriptor at the community's apex, so that the address a build bakes is the address people already know.** - Given the front door, when it renders, then `GET https://<apex>/api/client-config` and `GET https://<apex>/api/config` proxy to the config server over loopback and every other path on the apex stays the control plane's (the Portal, `/authz/signin`, the steward API); the identity doors stay the subdomains they are today. - Given the private path, when the guest's front door renders, then the same two routes exist on the in-guest apex. 8. **As a wallet, I want the descriptor to be the `1.1` shape ADR 0226 ruled, so that a 1.0 wallet keeps working and a 1.1 wallet learns everything it needs from one document.** - Given a live IDIP gateway, when `/api/client-config` is fetched from outside, then the document carries `version: "1.1"`, the KERI block with the gateway's real doors (`keria.<apex>`, `keria-cesr.<apex>`, `keria-boot.<apex>`, `witness.<apex>`, `schema.<apex>`) and the one community witness's runtime-minted AID and OOBI, `community{name, slug, aid, oobi, registry}`, `api_url` (the steward API root on the apex), `schemas` (each credential kind's SAID and public OOBI, the gateway's own), `boot{gated: false, join_url}`, `backend_kind: "idss"`, `stack` (KERIA / keripy / signify-ts generations from the pins), `signin{url}` (the bridge's sign-in endpoint as #1492 defines it), and `app` only once the card is `ready`. - Given no any-sync installed, when the document is fetched, then it has no `anysync` key; given any-sync installed, then the block names the gateway's nodes. - Given a 1.0 loader, when it reads the document, then unknown keys are dropped and boot succeeds (matou-app's existing behaviour, asserted against the served document). - Given the document, when inspected, then no `doorkeeper` block exists and nothing secret rides in it (no admin token, no passcode, no private key material). 9. **As the control plane, I want to be the descriptor's only writer, so that the roster stays single-writer and the app never founds on IDSS.** - Given founding reaches the identity rows, when the community identity and registry exist, then the control plane posts org-config (the community's AID, OOBI, name, slug, registry, the steward set and their OOBIs) to the config server over loopback with the admin token, and the descriptor's `community` block reflects it. - Given a steward change (promotion, removal, rotation), when the roster settles, then the control plane rewrites org-config in place (an update, not delete-then-post) and the served document changes within one poll of the change. - Given a request to the config server's write door from anywhere but loopback, when it arrives, then the front door does not route it — the write door is never public. 10. **As the outside-in door probe, I want to prove the descriptor is readable from outside before anything is submitted to Coa, so that a build never bakes an address that does not answer.** - Given the deploy's existing outside-in probe passes, when the pipeline tail runs, then a second probe fetches `https://<apex>/api/client-config` from outside and requires `version` and `community.aid`; given it fails within the same bounded attempts the door probe uses, then the Coa submission is skipped and the app card opens at `failed` with *the outside could not read your community's details yet*, and try again re-probes. ### C. The submission at the end of the pipeline 11. **As an operator who chose Option 1, I want founding to submit my app to Coa for me, after my gateway is live, so that I never fill Coa's form and never wait on the build.** - Given the door probe and the descriptor probe both pass, when the tail runs, then one multipart submission goes to Coa's submit door: brand (name, slug, primary and secondary colours, contact email) from the kit and the draft, features from S3a-APP, backend self-hosted with the apex as the config address, the round logo as the logo file, and the IDSS-originated marker. - Given Coa accepts, when it answers, then the card record stores the slug, Coa's page address and *submitted at*, and the card opens at `pending`; the hand-off (S12-IDIP) proceeds exactly as today — founding never waits on the build. - Given the private path, when the tail runs, then no submission is made (Coa cannot reach a private apex) and the card opens at `none` with the copy naming that the app needs a public address. 12. **As an operator, I want a refused or unreachable Coa to be non-fatal, so that Mātou is never a gate on my founding.** - Given Coa answers a refusal (the name is taken at Coa, the backend probe failed, validation), when the tail continues, then founding completes, the card opens at `failed` with Coa's reason in plain words, and `data-action="rebuild"` re-submits from the dashboard. - Given Coa is unreachable or times out, when the tail continues, then founding completes and the card opens at `failed` with *could not reach Coa* and try again. - Given a refused or unreachable Coa, when the hand-off card renders, then nothing about the app is counted as a failed founding step. 13. **As an operator who chose Option 1, I want any-sync installed at founding, so that my members' app has its content layer from day one.** - Given Option 1 (and not the Coa-first branch), when the gateway deploys, then the any-sync set (coordinator, tree node, consensus node, file node with their stores) runs on the gateway, its network and node keys minted as clan-vars secrets, its three public TCP ports opened with the mail-port precedent, and the descriptor's `anysync` block served once the coordinator answers. - Given "later", when the gateway deploys, then no any-sync unit runs and the descriptor has no `anysync` key. - Given any-sync installed, when the gateway's declared datasets are listed, then any-sync's stores are a port-declared dataset of their own (ADR 0080) with a quiesce-or-dump backup step; the identity dataset's window is unchanged. ### D. The app card 14. **As an operator, I want one app card on my operator home and my dashboard overview, so that I always know where my app is.** - Given an IDIP community, when HO or DO renders, then one `data-field="community-app"` row sits with the standing checks with exactly one `data-status` of `pending | ready | failed | none`, and both surfaces read the same record. - Given a kanidm community, when HO or DO renders, then no app card renders. - Given the card in any state, when the surface's health, hand-off or blocking checks are computed, then the card never contributes — it blocks nothing. 15. **As an operator, I want the card at `pending` to show that the app is being built and let me see the details, so that waiting is honest.** - Given a submission accepted, when the card renders, then it reads *Your community app — being built*, *submitted to Coa ‹relative time›*, and `data-action="app-details"` opens Coa's page for the community. 16. **As the control plane, I want to poll Coa's public status document for the slug, so that no Mātou credential ever points at a community.** - Given a record at `pending`, when the poll runs (on a fixed interval with backoff, and on demand when a surface opens), then it fetches Coa's public status document beside the community's page, unauthenticated, and maps `ready` → `ready` (with the downloads address and platforms), `failed` → `failed` (with the recorded reason), anything else → still `pending`. - Given the status document is unreachable, when the poll runs, then the record stays `pending` and the card shows *last checked ‹time›* — never a false `failed`. 17. **As an operator, I want `ready` to mean downloads available, so that I can share the app.** - Given Coa reads `ready`, when the record updates, then the card reads *Your community app — downloads available*, lists the platforms, `data-action="open-downloads"` opens the downloads page, and the copy names the Members tab as where to share it. - Given `ready`, when the descriptor is next served, then `app{downloads_url, name}` is present — written by the control plane's org-config writer, the same path story 9 uses. - Given `ready`, when the Members tab's invite (P6-S2i) renders, then its copy gains *get the app* with the downloads address (the invite's app-first opening itself is DDR 0230's, spec'd with adoption). 18. **As an operator, I want `failed` to tell me why and let me try again, so that a build failure is a moment, not a dead end.** - Given Coa reads `failed` or the tail's submit was refused, when the card renders, then it reads *Your community app — the build failed*, `data-action="app-details"` shows the reason, and `data-action="rebuild"` re-submits the same submission from the record. - Given a re-submit, when Coa answers slug-taken because the earlier submission exists, then the card names it plainly (*Coa already holds a page for this name*) and points at Coa's page rather than looping. 19. **As an operator who chose later, or whose community pre-dates this, I want the card at `none` to be the way in, so that the offer never expires.** - Given the draft recorded "later", the private path, or an IDIP community founded before this slice, when the card renders, then it reads *Your community app — not yet designed*, *your members sign in through the browser until you build one*, and `data-action="design-app"` opens the dashboard twin (section E). 20. **As an operator, I want the card's record to survive restarts and be the same on both surfaces, so that I never see two truths.** - Given the record, when written, then it lives in the config repo under the control plane's single-writer rule (the service-access matrix precedent), holds slug, Coa page address, state, reason, submitted-at, last-checked, downloads address; when the operator app restarts or the dashboard reloads, then the card renders from it via the control API. ### E. Designing the app later, from the dashboard 21. **As an operator, I want to design the app from the dashboard with the same screen founding showed, so that later is the same walk, not a lesser one.** - Given `data-action="design-app"`, when it opens, then the dashboard shows S3a-APP's twin (`data-field="features"`, `data-field="contact-email"`, the kit-wearing preview) prefilled from the brand kit; when I submit, then the control plane runs the same submission as the pipeline tail (descriptor probe, then Coa) and the card moves to `pending` or `failed` by the same rules. - Given a submit from the dashboard on a community with no any-sync, when the submission is accepted, then the control plane installs the any-sync set as a deploy (the catalogue-service precedent), and the descriptor gains `anysync` once the coordinator answers. - Given the private path, when the twin opens, then it says the app needs a public address and offers nothing to submit. ### F. What matou-app, matou-infrastructure and Coa owe 22. **As a wallet, I want to boot against an IDSS descriptor, so that a Coa build pointed at a gateway simply works.** (matou-app) - Given a 1.1 document, when the wallet loads it, then `anysync` absent is tolerated (content surfaces show their empty state, sign-in and credentials work), a single witness satisfies the witness floor, schema OOBIs come from `schemas`, absent `doorkeeper` and `app` are tolerated, `signin.url` becomes the home sign-in site (#1492), and a `stack` mismatch is a diagnostics warning, never a refusal; only an unknown `version` major refuses. 23. **As the gateway, I want the config server to serve the 1.1 shape from sources a gateway has, so that one implementation owns the document.** (matou-infrastructure) - Given the config server 1.1, when configured with per-door absolute URLs, a witness file (URLs and AIDs) and a rendered JSON of the gateway blocks, then it serves them instead of the raw-port or path-prefix layouts and the hard-coded demo witnesses; `signin` replaces `doorkeeper`; `anysync` stays optional; org-config gains an authenticated update path; the subprocess test suite gains the 1.1 file. 24. **As Coa, I want an IDSS-originated submission to build on submit, so that the founding is the relationship.** (coa) - Given a submission carrying the IDSS-originated marker whose backend probe passed, when it is stored, then the build dispatches without the relationship-first parking; a submission from Coa's own form keeps parking as today. - Given the backend probe, when it fetches, then it reads `/api/client-config` (not `/config`) and accepts a document without `anysync` when the submission promises it (or the prober is told to require it only when present). - Given a community's status document, when fetched unauthenticated at its public address, then it answers with the state, the downloads address and the platforms once `ready`, and the reason once `failed` (already so; asserted). ### G. The community's any-sync spaces (ADR 0226 amendment, 2026-09-15 — re-ruled the same day) 25. **As an operator who chose Option 1, I want founding to create my community's spaces for me, so that the content layer exists before anyone installs the app.** (idss) - Given any-sync is installed and its coordinator answers from outside, when the pipeline tail runs (before the Coa submission), then the operator app creates the community, read-only and admin spaces as the founder, with the keys the wallet derives from the founder's twelve words (which the laptop still holds — the scrub has not run), seeds what org setup seeds, and records the three IDs in the config repo; the descriptor writer (story 9) rewrites org-config so the first outside read of the descriptor names them. - Given the words, when the spaces are created, then the creation runs on the laptop over the public any-sync ports and the words never leave the laptop. - Given the founder later adopts their identity into the app (DDR 0230), when the wallet boots, then it finds the three spaces with its own identity as owner and creates nothing. - Given any-sync does not answer from outside within the tail's bounded attempts, when the tail continues, then founding completes, the spaces are not created, the descriptor carries `anysync` without space IDs, and the app card's details name it; the first-steward fallback (story 26) then applies. - Given "later" or the Coa-first branch, when the tail runs, then no spaces are created. 26. **As the first steward whose wallet lands against a gateway whose descriptor names no spaces, I want my wallet to create them, so that "later" and older communities get their content layer too.** (matou-app — the fallback) - Given a wallet holding a steward credential issued into the community ledger, when it boots against a descriptor that carries `anysync` and whose org-config names no space IDs, then it creates the three spaces exactly as founding does and posts the IDs to `api_url` with its existing steward authentication; nothing else of org setup runs. - Given the post is refused because IDs are already recorded, when the wallet continues, then it re-reads the descriptor and joins the recorded spaces. - Given a wallet holding no steward credential, when it boots against such a descriptor, then it creates nothing and shows the content surfaces' empty state. 27. **As the control plane, I want to record the space IDs once, so that org-config stays single-writer and every wallet joins the same spaces.** (idss) - Given founding's own creation (story 25), when the IDs are recorded, then the descriptor writer rewrites org-config; no steward-API post is involved. - Given a steward-authenticated post of three IDs to the steward API when none are recorded, when it arrives, then the control plane records them and rewrites org-config; given IDs already recorded, then it answers a conflict naming the recorded set and writes nothing; given a non-steward or any other authentication, then it is refused. 28. **As the wallet's maintainers, I want space creation to live in one package, so that founding and the wallet can never drift apart.** (matou-app) - Given matou-app's space creation (key derivation from the mnemonic at indexes 1–3, header seeds, the ACL owner, the seeded profile), when it is exported as a Go package with no dependency on the wallet's server wiring, then the operator app imports it for story 25 and the wallet's own org setup and story 26 call the same code; a change to the convention is one change. ## Implementation Decisions **Repos.** Work lands in four repos; this spec is the one place they are named together, and `to-tickets` emits per-repo tickets. Anything not listed for a repo is that repo's "nothing new". ### idss - **Founding draft and steps.** The draft gains an app submission record: chosen (`now | later`), features (the toggle map, Coa's keys), contact email. S3a-APP is a step of the founding page between S3a and S4 on the IDIP + Option 1 branch; "later" is the `wallet:later` action on S3a. The reopened-walk rules follow S3a's (editable until deploy, locked after Founded). The preview is the founding page's own mini, built from the kit compile the brand-kit step already has — not an iframe of Coa. - **The config server unit.** Rendered with the identity stack's other units (ADR 0062 part 1, the `keria` / `keri-witness` / `keri-schema` shape), as a distinct systemd unit with a declared health check on its health door, packaged the way the schema server is (a Python file wrapped as a binary), env from a clan-vars generator (admin token) plus a rendered JSON file the control plane owns for the gateway blocks. Always on the IDIP path, never on kanidm. Its data directory joins the identity dataset's declared state (it is a rendering of the roster, small and rebuildable). - **Front door.** Two path routes on the bare apex, `/api/config` and `/api/client-config`, proxied to the config server's loopback port; no other apex path changes; the unserved-host fall-through and the KERI subdomain doors are untouched. - **The writer.** One control-plane component owns org-config: it builds the document from the roster (community AID, OOBI, name, slug, registry, stewards), the credential schemas' SAIDs and public OOBIs, the pins (`stack`), the apex (`api_url`, `boot.join_url`, `signin.url`), and the app record (`app`), and writes it over loopback with the admin token — at the identity rows during founding, on every steward change, and when the app record reaches `ready`. Loopback only; the token is a clan-vars secret the bridge and the control plane read, never the app. - **Probes.** The descriptor probe reuses the outside-in door probe's shape (bounded attempts, injected for the seam) and adds the `/api/client-config` fetch with the two required fields. - **The pipeline tail.** After the door probe (rented checklist and own-VPS/manual deploy alike): descriptor probe → Coa submit → record written → hand-off. Every failure is recorded on the app record and never on the stand-up's step status. The Coa client is one adapter (submit, status fetch) injected like the broker client, with a scripted fake in the seam. - **Coa submission shape.** Coa's existing multipart submit door: brand `{name, slug, primaryColour, secondaryColour, contactEmail}`, features `{identity: true, chat, projects, proposals, notices, events}` (maramataka rides as Coa's default until Coa exposes it), backend `{kind: "self-hosted", configServerUrl: "https://<apex>"}`, the logo as a PNG rendered from the kit's round logo, plus the IDSS-originated marker as a form field (`origin: idss`). The slug is the founding slug; a slug-taken answer is a `failed` reason. - **The app record.** A config-repo document (the matrix-store precedent: single writer, read by both surfaces through the control API, OpenAPI regenerated for the client): `{state, slug, pageUrl, submittedAt, lastCheckedAt, reason, downloadsUrl, platforms}`. `none` is the absence of a record or a record with `chosen: later`. - **The poll.** A control-plane ticker (interval on the order of a minute, exponential backoff while unreachable, capped) plus an on-open refresh from either surface; it fetches Coa's public status document for the slug and maps its states. It runs only while a record is `pending`. - **The card.** One component per surface reading the same API shape, the `data-field="community-app"` / `data-status` / `data-action` contract from the wireframe. On HO it sits with the gateway's standing checks; on DO beside the health and backups headlines. Never part of any health verdict. - **The dashboard twin.** A dashboard screen reachable from the card's `design-app` action, the same fields as S3a-APP, submitting through the same control-plane path; the any-sync install-later runs as a deploy of the any-sync units (the catalogue-service deploy precedent) before the submission is sent, so the descriptor probe Coa runs sees a complete document. - **any-sync on the gateway.** Installed when Option 1 is chosen (founding tail) or when the dashboard twin submits; never on the Coa-first branch (ADR 0238 §12). Shape: the five any-sync daemons and their stores run as OCI containers under podman with pinned digests (the archive-port precedent; research #1314 §2.3 — Mongo's licence and Redis-Bloom make a source build the costlier door), a single-member Mongo replica set, MinIO for file bytes; network and node keys from a clan-vars generator (regenerating re-mints the network, like the witness salt); three public TCP ports declared with the mail-port precedent; stores declared as their own dataset (ADR 0080) with `mongodump` + store copy at backup. Two-way door: source-built units can replace the containers behind the same unit names. - **Space creation at the tail.** One step between the any-sync outside probe and the Coa submission, on the laptop, importing matou-app's space-creation package (below) and deriving from the draft's twelve words — the same mnemonic the founder's KERIA passcode was derived from. Bounded attempts; failure is recorded on the app record's details, never on a stand-up step. The IDs go into the config repo beside the app record and reach org-config through the descriptor writer. - **The space-ID door.** One steward-API route (the existing steward authentication, ADR 0199's key challenge) accepting the three space IDs; the control plane records them in the config repo beside the app record, first write wins with a conflict answer naming the recorded set, and the descriptor writer (above) rewrites org-config. No config-server token ever reaches a wallet. - **Copy.** Glossary words throughout: operator, member, wallet, community backend, sign-in site. "Coa" appears in operator-facing copy as *Coa, Mātou's app builder* on first use per screen. Never "tenant", "config server", "KERIA" in copy. ### matou-infrastructure - Config server **1.1**: a third URL layout of per-door absolute URLs; witnesses from a file (URLs and AIDs) instead of the six demo AIDs; the new blocks (`community`, `api_url`, `schemas`, `boot`, `backend_kind`, `stack`, `signin`, `app`) read from a rendered JSON path and merged over org-config; `doorkeeper` gone; `anysync` optional stays; an authenticated **update** path for org-config (replace-in-place with the admin token) beside the first-write-wins post; the public-URL and tenant behaviours unchanged. The subprocess test suite gains a 1.1 file. ### matou-app - **The space-creation package** (ADR 0226 amendment): key derivation, header seeds, ACL owner and profile seeding exported as an importable Go package, free of server wiring; the wallet's org setup and the fallback call it; the operator app imports it. Precedes the idss tail ticket. - **Space creation by the first steward — the fallback** (ADR 0226 amendment): the org-setup space-creation call, run on first landing when the descriptor carries `anysync` and org-config names no space IDs, gated on holding a steward credential; the IDs posted to `api_url`; on conflict, re-read and join. - As ADR 0226 and ADR 0236 obligate: `anysync` optional in the loader and the Go backend (content surfaces show their empty state without it); witness floor of one; schema OOBIs from `schemas`; tolerate absent `doorkeeper` and `app`; read `signin.url` as the home sign-in site; `stack` mismatch as a diagnostics warning; refuse only an unknown `version` major. ### coa - The submit door accepts and stores the IDSS-originated marker; the build dispatches on submit for those submissions when the backend probe passed (DDR 0228 §4 — Ben's exception to Coa's DDR 0007), a per-origin flag; Coa's own form keeps parking. - The backend prober fetches `/api/client-config`; `anysync` is optional in the probe when absent (the IDSS founding installs it before submitting, so in practice it is present; the prober must not 422 a KERI-only document from the dashboard twin's probe-first path). - The status document stays public per slug and carries the downloads address and platforms on `ready` (already so). ## Testing Decisions A good test drives a public face with fakes behind it and asserts what an operator, a wallet or Coa would observe — the served document, the card's state, the request Coa received — never an internal call sequence. **Seams (existing, reused; one new fake each):** 1. **The founding orchestrator seam** (`internal/founding`, the scripted-fake precedent: `FakeFleet`, the injected door probe, the story-numbered tests such as the S12 hand-off and identity seed-leg tests). Add a scripted fake Coa (accepts / refuses with a reason / unreachable) and a fake descriptor probe. Stories 1–5, 10–13 (draft, tail, non-fatal failures, private path) are proven here end to end from S3a to the hand-off, including that a refused Coa leaves every stand-up step green. 2. **The clan render seam** (`internal/clan`, the `RenderKeri_*` / `RenderFrontDoor_*` / `RenderIdssIdp_*` tests): the config server unit with its declared health check and secret generator; the two apex routes present on IDIP and absent on kanidm; the any-sync units, ports, dataset and key generator when chosen; determinism. 3. **The control API integration seam** (`internal/controlapi`, the `*_integration_test.go` precedent): the app record's read and write, the poll against a fake status document (ready / failed / unreachable), the descriptor writer's org-config over a fake config server (founding write, steward-change update, `app` on ready), and that the served-document shape matches the 1.1 contract (a golden document per branch: no any-sync, any-sync, ready). 4. **Dashboard and operator-app component tests** (the existing Vitest suites): the card's four states from the API shape, the twin's form, the S3a "later" line and S3a-APP's preview following the toggles. 5. **matou-infrastructure's subprocess tests** for the 1.1 layout; **coa's Vitest** for the origin flag and the prober path; **matou-app's loader tests** against the golden 1.1 document from seam 3 (the document is checked into both repos' fixtures, one source). **Drive.** The rented IDIP rehearsal drive gains one leg: with the harness's fake Coa, the app card reads `pending` at hand-off and `ready` after the fake flips its status document, and the descriptor served at the apex carries `app` and `signin`. A real Coa build is not on the drive (minutes to hours, and a Mātou-side dependency); the live proof against real Coa is a manual trial step, recorded in the trial guide. **What is not tested here:** the wallet's sign-in round trip (#1492's seam), any-sync's content behaviour in the app (the initialisation pipeline, below). ## Out of Scope - **Members whose membership credential carries no invite key.** On coa-shared the community-space invite key is embedded in the membership credential at issue time; the dashboard's browser-era issuance on IDSS embeds none, whenever the spaces were created. How that member's wallet joins the spaces later is the adoption spec's (DDR 0230's first-landing edge) — recorded on the map. A member's private space when any-sync arrives after they adopted is the same map note. - **The Coa-first branch** (ADR 0238, DDR 0239): S3a's "we already have an app" question, S3a-JOIN, the hosted-identity row, the rehost walk, the descriptor handing back Mātou's addresses. Its own `/wireframe` and spec; this spec's descriptor writer must not assume the addresses it serves are its own (they are data, read from the record). - **Member adoption and the app-first invite** (DDR 0230, `wallet/`): W-S0, the invite opening app-first, the reaper. This spec only flips the invite's copy on `ready`. - **Wallet sign-in** (#1492): the bridge routes, the verifier, the App-only switch. This spec serves `signin{url}` for it. - **Option 2, the IDIP wallet app** — visible, disabled, never selectable. - **Coa's downloads-URL write-back to the gateway** (ADR 0226 §5 fog) — the gateway pulls the status document instead. - **A signed descriptor**, the recognition hint, per-community schemas beyond what `schemas` carries, iPhone builds and store listings. - **Changing features after the build** ("the app updates without a rebuild where it can") — Coa's, later. ## Further Notes - **Ruled 2026-09-15, twice (ADR 0226 amended):** founding creates the three community any-sync spaces at the pipeline tail as the founder, from the twelve words it still holds, through a package matou-app exports (stories 25, 27, 28); the first steward's wallet is the fallback for "later" and pre-dating communities (story 26). Rejected: creation on the gateway (the words would travel); a second any-sync convention in idss; Mātou creating them; the fallback alone. - **Sequencing for `to-tickets`.** The descriptor and config server (B) come first — #1492's tickets block on `signin{url}`. Then the founding walk (A) and the tail (C), then the card (D), then the twin (E). Story 28 (matou-app's space-creation package) precedes story 25's tail ticket. Story 24 (coa auto-build) and story 23 (config server 1.1) are external tickets the tail's real-Coa trial waits on; the fake-Coa seam does not. - **DDR 0228's Coa form facts** (from research #1294): Coa's form is brand → features → backend → review, `TOGGLEABLE_FEATURES` = chat, projects, proposals, notices, events; builds are macOS (Intel, Apple silicon), Windows, Linux AppImage, Android APK; no iPhone build. Maramataka is not a Coa toggle today — S3a-APP shows it as on, and the submission does not carry it until Coa exposes it. - **Naming.** The wireframe index rows for S3a, S3a-APP and the app card, and the founding flow's amendment, landed with this spec (2026-09-15). The cross-feature journey `community-app-journey.mermaid` is the reader's map of where this slice sits between founding and App-only.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Matou/idss#1495
No description provided.