|
| 1 | +--- |
| 2 | +sidebar_position: 2 |
| 3 | +title: Features |
| 4 | +description: What ships in OpenBuilt today — the citizen-developer app builder for Nextcloud. |
| 5 | +--- |
| 6 | + |
| 7 | +# Features |
| 8 | + |
| 9 | +OpenBuilt is a citizen-developer app builder for Nextcloud. Every feature below is shipped and verified by the spec gate (PHPUnit + Vitest + Newman + Playwright + Hydra mechanical gates — see [Technical](../Technical/) for the matrix). |
| 10 | + |
| 11 | +## App creation wizard |
| 12 | + |
| 13 | +A three-step modal that creates the parent Application, an admin-defined version chain (development → staging → production by default), and one per-version OpenRegister register per tier. The wizard is atomic: a failure at any step rolls back every resource it provisioned so the org-wide unique slug isn't squatted. |
| 14 | + |
| 15 | +Highlights: |
| 16 | + |
| 17 | +- **Identity step** — slug + name + description with live duplicate-slug detection. |
| 18 | +- **Versions step** — pick a preset (`single`, `dev-prod`, `dev-staging-prod`) or hand-design the chain. The wizard enforces ADR-002's linear-chain rule (no fan-out, no cycles, exactly one terminal `production` tier). |
| 19 | +- **Permissions step** — owners / editors / viewers, with the caller pre-filled into `owners`. Group `group:*` means "all signed-in users" (REQ-OBRBAC-004). |
| 20 | + |
| 21 | +Spec: [`openbuilt-app-creation-wizard`](https://github.com/ConductionNL/openbuilt/tree/main/openspec/changes/archive/2026-05-17-openbuilt-app-creation-wizard). |
| 22 | + |
| 23 | +## Versioned app deployment |
| 24 | + |
| 25 | +Per ADR-002, every Application carries N ApplicationVersion rows on a linear `promotesTo` chain. Each version owns: |
| 26 | + |
| 27 | +- a per-version OpenRegister register (`openbuilt-{appSlug}-{versionSlug}`) so dev data, staging data, and production data are physically isolated; |
| 28 | +- its own manifest (the page + menu + widget declaration); |
| 29 | +- its own semver — auto-bumped when the manifest changes meaningfully, untouched on metadata-only edits (the no-op-detect rule). |
| 30 | + |
| 31 | +The `Application.productionVersion` pointer decides which version answers at `/apps/openbuilt/{slug}`. Switching `productionVersion` is a single OR write — rollback is instant, no redeploy. |
| 32 | + |
| 33 | +Spec: [`openbuilt-versioning-model`](https://github.com/ConductionNL/openbuilt/tree/main/openspec/changes/archive/2026-05-17-openbuilt-versioning-model). |
| 34 | + |
| 35 | +## Version promotion (dev → staging → prod) |
| 36 | + |
| 37 | +Three strategies for moving one version forward into the next: |
| 38 | + |
| 39 | +- **`migrate-existing-data`** — schema-import the source version's columns onto the target's existing rows (default when target IS the production version; preserves production data). |
| 40 | +- **`start-with-source-data`** — wipe target rows, copy source rows over (default for mid-chain targets; reproducible from-source build). |
| 41 | +- **`empty-start`** — wipe target rows entirely and start clean. Gated by a type-the-slug confirmation in the UI. |
| 42 | + |
| 43 | +Failure handling: target flips to `archived`, OR lock releases, response carries `code: "promotion_failed"`. Source register is read-only throughout — a failed promotion never mutates the source. |
| 44 | + |
| 45 | +Spec: [`openbuilt-version-promotion`](https://github.com/ConductionNL/openbuilt/tree/main/openspec/changes/archive/2026-05-17-openbuilt-version-promotion). |
| 46 | + |
| 47 | +## `?_version=` URL routing (bookmarkable preview) |
| 48 | + |
| 49 | +Every builder URL accepts an optional `?_version=<slug>` query that pins the rendered manifest to a specific ApplicationVersion. The leading underscore (`_version`, not `version`) is OpenBuilt's system-reserved namespace so citizen developers can ship their own `?version=` query params without collision. |
| 50 | + |
| 51 | +- Without the param: the production manifest answers — accessible to everyone in the org. |
| 52 | +- With the param + production slug: also accessible to everyone. |
| 53 | +- With the param + non-production slug: only callers in `permissions.editors ∪ permissions.owners` see it. Viewers / non-members get a security-shaped 404 (no existence leak). |
| 54 | + |
| 55 | +Spec: [`openbuilt-version-routing`](https://github.com/ConductionNL/openbuilt/tree/main/openspec/changes/archive/2026-05-17-openbuilt-version-routing). |
| 56 | + |
| 57 | +## Application detail overview (maintainer dashboard) |
| 58 | + |
| 59 | +The detail page for each Application packs the maintainer's daily working surface into one screen: |
| 60 | + |
| 61 | +- **Hero strip** — icon, name, description, status, your role badge, productionVersion semver. |
| 62 | +- **Version pill strip** — one pill per version (most-upstream first), with `*` marking production. Click a pill to switch the rest of the page to that version. |
| 63 | +- **Window toggle (7d / 30d / 90d)** — drives the KPI + activity calls. |
| 64 | +- **KPI grid** — Active users, Object count, Files, Audit events for the selected (version, window). |
| 65 | +- **Activity graph** — daily event counts; empty-state when the window has no traffic. |
| 66 | +- **Structural widgets** — Register, Schemas, Pages, Menu cards with deep-links into OpenRegister, Schema Designer, Page Designer. |
| 67 | + |
| 68 | +Spec: [`openbuilt-app-detail-overview`](https://github.com/ConductionNL/openbuilt/tree/main/openspec/changes/archive/2026-05-17-openbuilt-app-detail-overview). |
| 69 | + |
| 70 | +## Nextcloud nav integration (one top-bar entry per published app) |
| 71 | + |
| 72 | +Every published Application gets its own top-bar entry alongside Files, Mail, Talk etc. The entry's icon is served by `GET /apps/openbuilt/icons/{slug}.svg` (light) / `{slug}-dark.svg` (dark) and falls back to the app icon when the OR-attached file is missing. |
| 73 | + |
| 74 | +Visibility is per-app: only callers who hold any role on the Application (or are listed via `group:*` wildcard) see the entry. Draft and archived apps stay hidden. |
| 75 | + |
| 76 | +Spec: [`openbuilt-nextcloud-nav`](https://github.com/ConductionNL/openbuilt/tree/main/openspec/changes/archive/2026-05-17-openbuilt-nextcloud-nav). |
| 77 | + |
| 78 | +## Templates marketplace |
| 79 | + |
| 80 | +The "New from template" path clones a marked Application + its companion schemas into the caller's namespace. The same-user-same-slug case returns `slug_collision` 409 so the caller can pick a fresh slug; the cross-user case provisions an owner-namespaced register (`openbuilt-{ownerUid}-{slug}`) so two users can clone the same template without colliding on OR's organisation-wide unique constraint. |
| 81 | + |
| 82 | +## Schema designer |
| 83 | + |
| 84 | +A visual editor for the per-version schema set. Field types, lifecycle states + transitions, RBAC, relations to other schemas, widgets, aggregations, calculations and notifications all live in the schema's declarative annotations (ADR-031) — readable by humans, executable by OpenRegister at runtime. |
| 85 | + |
| 86 | +## Page editor v1.1 |
| 87 | + |
| 88 | +JSON-driven page declaration with type-aware sub-editors per page type (`index`, `detail`, `form`, `dashboard`, `chat`, `logs`, `settings`, `files`, `custom`). Inline validator marks paint the offending field on save; an undo/redo stack covers the in-flight manifest; the Raw JSON tab is the integrator fallback for shapes the Design tab can't yet author. |
| 89 | + |
| 90 | +## MCP authoring surface (for AI assistants) |
| 91 | + |
| 92 | +OpenBuilt registers eight tools on the OpenRegister MCP bus so an LLM can author apps directly: `listApps`, `getAppManifest`, `createApp`, `promoteVersion`, `upsertSchema`, `upsertPage`, `addWidget`, `upsertMenuItem`. Each tool carries the per-app RBAC gate; an LLM acting on behalf of a user can only modify apps where that user holds owner or editor role. |
| 93 | + |
| 94 | +## Export to a real Nextcloud app (Phase 2) |
| 95 | + |
| 96 | +A built app is *virtual* by default — it lives as a record in OpenBuilt's register and is rendered inside the OpenBuilt shell at `/apps/openbuilt/{slug}`. Phase 2 export bakes the manifest, register, and schemas into a standalone Nextcloud app you can install on any Nextcloud instance — no OpenBuilt dependency at runtime. |
0 commit comments