Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
21 commits
Select commit Hold shift + click to select a range
5894a02
feat(chat)!: hard-cut chat tenancy to client-minted Interchange tenants
TheGreatAxios Sep 16, 2026
fb50cd9
fix(chat): reuse validated person-DM counterpart instead of re-fetching
TheGreatAxios Sep 16, 2026
fd3a43e
feat(hub)!: cut over to stock Interchange composition
TheGreatAxios Sep 16, 2026
a648d53
docs(hub): fix stale cutover comments and README
Sep 16, 2026
1fadffa
feat(chat)!: purge dead tenancy migrations for hard-refresh cutover
TheGreatAxios Sep 16, 2026
c6b1c80
chore(chat): drop stale report-error baseline entries for deleted ten…
TheGreatAxios Sep 16, 2026
6bb78ca
docs(hub): clear stale signup/tenancy env references post-cutover
TheGreatAxios Sep 16, 2026
1edc1b5
test(hub): rewrite local-rip provision hops against stock tenant/agen…
TheGreatAxios Sep 16, 2026
368cd0b
refactor(hub): cut retained signup env-key code from four packages
TheGreatAxios Sep 16, 2026
c0a9070
refactor(auth): remove /api/auth-config, sign-in buttons from client …
TheGreatAxios Sep 16, 2026
9aff043
test(web): keeper for failed social sign-in surfacing better-auth mes…
TheGreatAxios Sep 16, 2026
c42ce34
Merge branch 'cl-intx-client-driver' into intx-integration-preview
TheGreatAxios Sep 16, 2026
1e9b01e
Merge branch 'cl-intx-chat-cutover' into intx-integration-preview
TheGreatAxios Sep 16, 2026
6388af3
Merge branch 'cl-intx-hub-cutover' into intx-integration-preview
TheGreatAxios Sep 16, 2026
0edcbdf
fix(hub): drop deleted chat tenancy surface, clear stale report-error…
TheGreatAxios Sep 16, 2026
d24b72f
chore(hub): remove orphaned bench-session filler
TheGreatAxios Sep 16, 2026
04b7643
fix(chat): determinize room-activity cursor boundary in drizzle test
TheGreatAxios Sep 16, 2026
30cb373
fix(onboarding): tolerate stock skills 404 in desired-state reconcile
TheGreatAxios Sep 16, 2026
42e066c
fix(onboarding): route seed 404 skip through the pipeline log
TheGreatAxios Sep 16, 2026
ff39495
test(e2e): finish stock-cutover rewrites for remaining red hops
TheGreatAxios Sep 16, 2026
50f565a
test(e2e): publish corbits-tools registry in smoke-webhook before deploy
TheGreatAxios Sep 16, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
39 changes: 7 additions & 32 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -44,27 +44,16 @@ HUB_ALLOW_GIT_INSIDE_WORK_TREE=1
HUB_STATIC_DIR=../web/dist

# The administrator identity `bun run dev` seeds for local development:
# the dev script signs this account up and makes it the owner of the root
# tenant (WORKBENCH_DEFAULT_TENANT below), so a fresh checkout can sign in
# immediately. Unset values fall back to the defaults shown — fine for
# local development, set both for real deployments.
# the dev script signs this account up on the fresh hub, so a fresh
# checkout can sign in immediately. Unset values fall back to the defaults
# shown — fine for local development, set both for real deployments.
# HUB_ADMIN_EMAIL=alice@example.com
# HUB_ADMIN_PASSWORD=password123

# Everything below is optional. Leave a variable unset to leave the
# feature it configures off; the hub never treats a partially-set group
# as configured — it fails loudly at boot instead.

# Slug of the root tenant first signup mints. Every self-served
# personal bench parents under it, and `workbench setup`/`seed` resolve
# the same slug. Unset falls back
# to "workbench". ORG_SLUG is an alias when this is unset — set only one.
# Upgrading a deploy whose existing root was not "workbench": set this
# to that slug (do not leave OPERATOR_TENANT_ID; the hub refuses to boot
# while that stale key is set).
# WORKBENCH_DEFAULT_TENANT=workbench
# ORG_SLUG=workbench

# Per-IP rate limit on email sign-up. Defaults to 5 sign-ups per 60
# seconds when unset.
# SIGNUP_RATE_LIMIT_WINDOW_SECONDS=60
Expand All @@ -79,15 +68,10 @@ HUB_STATIC_DIR=../web/dist
# SIGNIN_RATE_LIMIT_WINDOW_SECONDS=60
# SIGNIN_RATE_LIMIT_MAX=10

# Self-serve signup mode. Hub default is closed (owner adds users or
# shares a copy-link invite). Local `bun run dev` opens signup when this
# is unset so the first admin can seed — set closed explicitly to test
# the closed gate. See docs/TENANCY.md.
# WORKBENCH_SIGNUP=open

# When WORKBENCH_SIGNUP=open, optionally restrict which email domains
# may register (comma-separated). Empty/unset = any domain.
# WORKBENCH_ALLOWED_EMAIL_DOMAINS=acme.example
# Self-serve signup is ungated: stock Interchange composition carries no
# signup mode, domain allowlist, or email-verification gate, so anyone
# can register (rate-limited only — see SIGNUP_RATE_LIMIT_* above). Gate
# access in the composition that embeds the hub if a deployment needs it.

# Provider API keys are no longer read from the environment: hub boot
# plants nothing, and setting ANTHROPIC_API_KEY or any other provider's
Expand Down Expand Up @@ -271,15 +255,6 @@ HUB_STATIC_DIR=../web/dist
# even if this file is copied verbatim.
ALLOW_PLAINTEXT_SECRETS=1

# Opt-out of @workbench/access-policy's email-verification requirement.
# The hub has no transactional email wired yet, so NO account can ever
# become verified — leaving this unset makes `bun run setup` and every
# self-signup provisioning fail with signup_not_allowed. It therefore
# ships ON for local development. Turn it off (and wire verification)
# before exposing a deployment where invite redemption must prove
# address ownership.
ALLOW_UNVERIFIED_EMAILS=1

# Artifacts plane (@corbits/artifacts) uses DATABASE_URL too — different
# schema only (`artifacts.*` FKs into public.tenant/principal). Nothing to
# configure here; `bun run dev` mounts Library automatically.
Expand Down
3 changes: 1 addition & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -169,9 +169,8 @@ in any order:
| File | Proves |
| -------------------------- | --------------------------------------------------------------------------------------------------------------------- |
| `smoke-auth.test.ts` | Email sign-up mints a session cookie that authorizes a session-gated route |
| `smoke-onboarding.test.ts` | `POST /api/onboarding/provision` mints a personal bench and reports it unseeded when no seed model is configured |
| `smoke-onboarding.test.ts` | A brand-new signup starts benchless and mints its first tenant through an ordinary `POST /api/tenants` |
| `smoke-chat.test.ts` | A workbench is created, a message posts and reads back intact, and the invited-agent listing has its documented shape |
| `smoke-library.test.ts` | An artifact uploads through the multipart route and round-trips through list and get-by-id |
| `smoke-webhook.test.ts` | A signed delivery to the public webhook ingress route launches a real run for a routine bound to that trigger |

**Needs:** a reachable Postgres named by `DATABASE_URL` in `.env` (see
Expand Down
20 changes: 11 additions & 9 deletions apps/hub/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,15 +18,18 @@ native tenant middleware.
explicit import plus one `app.route(...)` call, inside or outside the
tenant prefix as the extension requires. `src/index.ts` is the single
file where all of this comes together.
- `src/*-mount.ts` files (`artifacts-mount.ts`, `memory-mount.ts`,
`skills-mount.ts`, `slack-tag-mount.ts`) are wiring helpers that resolve
and mount one extension's routes with its own DB handle/config.
- There are no local `src/*-mount.ts` wiring helpers: each extension's
routes mount directly in `src/index.ts` with the shared DB
handle/config passed inline at the `app.route(...)` call site.
- Serves the built `apps/web` SPA from its own origin
(`HUB_STATIC_DIR` points at `apps/web/dist`), so every `/api` call the
interface makes is same-origin.
- `credential-expiry-sweep.ts`, `cron-due.ts`, `workflow-scheduler.ts`,
`tenant-create-guard.ts` are host-level
background jobs and guards wired at boot, alongside the route mounts.
- `credential-expiry-sweep.ts`, `workflow-scheduler.ts`, and
`inbox-unsnooze-sweep.ts` are host-level periodic sweeps wired at boot,
alongside the route mounts; `cron-due.ts` is a re-export seam onto
`@corbits/workflows`' own cron matcher, not a second implementation.
Tenancy is the stock platform's own middleware — there is no local
tenant-create guard.
- `in-flight-requests.ts` and `shutdown.ts` bound SIGINT/SIGTERM: the hub
waits for Hono handlers that have not yet returned a Response (a
request still in a Postgres transaction, a git write), then
Expand All @@ -47,7 +50,6 @@ bun run start
cd apps/hub && bun test
```

Several suites (`artifacts-mount.test.ts`, `memory-mount.test.ts`,
`memory-workflow-routes.test.ts`) exercise mount wiring against a real
database:
Suites under `test/` exercise composition and wiring; the DB-backed
ones run against a real database:
`DATABASE_URL=postgres://localhost:5432/workbench_e2e bun test`.
80 changes: 0 additions & 80 deletions apps/hub/src/artifacts-mount.test.ts

This file was deleted.

76 changes: 0 additions & 76 deletions apps/hub/src/artifacts-mount.ts

This file was deleted.

110 changes: 0 additions & 110 deletions apps/hub/src/bench-session.ts

This file was deleted.

Loading
Loading