create-stitchkit 0.6.17 → 0.6.19

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (80) hide show
  1. package/CHANGELOG.md +42 -0
  2. package/dist/cli.js +62 -27
  3. package/examples/repository/packages/frontend/src/app/[locale]/page.tsx +2 -0
  4. package/examples/repository/packages/frontend/src/app/[locale]/starter-page.tsx +12 -8
  5. package/examples/repository/project.json +9 -0
  6. package/package.json +10 -9
  7. package/template/README.md +7 -0
  8. package/template/_env.example +5 -0
  9. package/template/biome.json +4 -1
  10. package/template/bun.lock +303 -301
  11. package/template/docs/ADMIN_MOCK.md +38 -0
  12. package/template/e2e/starter.spec.ts +2 -2
  13. package/template/package.json +17 -16
  14. package/template/packages/backend/package.json +6 -6
  15. package/template/packages/backend/src/cleanup.ts +4 -7
  16. package/template/packages/backend/src/index.ts +2 -1
  17. package/template/packages/backend/src/surface-manifest.test.ts +3 -3
  18. package/template/packages/backend/src/surface.ts +7 -6
  19. package/template/packages/backend/src/trusted-origins.test.ts +40 -0
  20. package/template/packages/backend/src/trusted-origins.ts +21 -0
  21. package/template/packages/config/package.json +3 -3
  22. package/template/packages/config/src/shutdown.ts +3 -4
  23. package/template/packages/config/src/variables.ts +21 -9
  24. package/template/packages/db/package.json +4 -4
  25. package/template/packages/frontend/next.config.ts +10 -1
  26. package/template/packages/frontend/package.json +29 -29
  27. package/template/packages/frontend/scripts/serve.ts +4 -4
  28. package/template/packages/frontend/src/app/[locale]/admin/[[...section]]/page.dev.tsx +21 -0
  29. package/template/packages/frontend/src/app/[locale]/page.tsx +2 -1
  30. package/template/packages/frontend/src/app/[locale]/starter-page.tsx +12 -8
  31. package/template/packages/frontend/src/app/api/[...path]/route.ts +2 -37
  32. package/template/packages/frontend/src/app/sitemap.ts +4 -1
  33. package/template/packages/frontend/src/components/ui/toaster.tsx +2 -2
  34. package/template/packages/frontend/src/env.ts +12 -3
  35. package/template/packages/frontend/src/features/admin/admin-data.ts +13 -0
  36. package/template/packages/frontend/src/features/admin/admin-sections.ts +78 -0
  37. package/template/packages/frontend/src/features/admin/admin-workspace.test.tsx +59 -0
  38. package/template/packages/frontend/src/features/admin/admin-workspace.tsx +127 -0
  39. package/template/packages/frontend/src/features/admin/fixture/admin-fixture.ts +35 -0
  40. package/template/packages/frontend/src/lib/api-proxy.test.ts +131 -0
  41. package/template/packages/frontend/src/lib/api-proxy.ts +89 -0
  42. package/template/packages/frontend/src/lib/query-client.test.ts +1 -1
  43. package/template/packages/frontend/src/lib/query-client.ts +2 -3
  44. package/template/packages/frontend/src/lib/seo/cache-by-origin.ts +2 -2
  45. package/template/packages/frontend/src/lib/seo/request-origin.ts +5 -5
  46. package/template/packages/frontend/src/proxy.ts +12 -1
  47. package/template/packages/shared/package.json +2 -2
  48. package/template/packages/shared/src/contracts/board.ts +1 -3
  49. package/template/packages/shared/src/contracts/system.ts +1 -3
  50. package/template/project.json +9 -0
  51. package/template/scripts/acceptance-database.test.ts +4 -4
  52. package/template/scripts/acceptance-database.ts +4 -6
  53. package/template/scripts/acceptance-local.ts +14 -9
  54. package/template/scripts/build-stamp.test.ts +3 -5
  55. package/template/scripts/build-stamp.ts +8 -11
  56. package/template/scripts/check-authored.test.ts +16 -1
  57. package/template/scripts/check-authored.ts +7 -6
  58. package/template/scripts/client-boundary.test.ts +26 -8
  59. package/template/scripts/client-boundary.ts +30 -27
  60. package/template/scripts/declaration.test.ts +5 -7
  61. package/template/scripts/declaration.ts +14 -19
  62. package/template/scripts/deployment-preflight.ts +2 -3
  63. package/template/scripts/dev.ts +6 -8
  64. package/template/scripts/fixture-boundary.test.ts +34 -0
  65. package/template/scripts/fixture-boundary.ts +25 -0
  66. package/template/scripts/guide-paths.ts +2 -4
  67. package/template/scripts/readiness.ts +4 -5
  68. package/template/scripts/release-steps.test.ts +2 -4
  69. package/template/scripts/release-steps.ts +2 -2
  70. package/template/scripts/runtime-smoke.test.ts +6 -7
  71. package/template/scripts/serve-mode.test.ts +2 -2
  72. package/template/scripts/service-surfaces-closed.ts +13 -0
  73. package/template/scripts/shutdown-budget.fixture.ts +3 -5
  74. package/template/scripts/shutdown-budget.test.ts +4 -8
  75. package/template/scripts/supervision-signal.test.ts +1 -1
  76. package/template/scripts/web-surface-smoke.ts +38 -8
  77. package/templates/agent/biome.json +4 -1
  78. package/templates/agent/package.json +11 -7
  79. package/templates/telegram-bot/biome.json +4 -1
  80. package/templates/telegram-bot/package.json +8 -4
package/CHANGELOG.md CHANGED
@@ -12,6 +12,48 @@ step is overwritten by the next release.
12
12
 
13
13
  ## [Unreleased]
14
14
 
15
+ ## [0.6.19] - 2026-11-04
16
+
17
+ ### Changed
18
+
19
+ - Generated projects resolve stitchkit 0.119.0 and the template's dependencies at their latest
20
+ stable versions: Biome 2.6.5 (pinned to the version the scaffolder formats with), Playwright
21
+ 1.64.1, Next 16.4, framer-motion 14, `@wrksz/themes` 2, the MCP SDK 2.4 and Zod 4.6.7. The
22
+ template's code needs no change for the 0.119.0 breaking items: it uses the no-config factory with
23
+ literal endpoints, no tracking client and no GeoIP resolver.
24
+
25
+ ### Fixed
26
+
27
+ - Shared contracts create their factory without configuration and declare HTTP exposure on each
28
+ endpoint.
29
+ - Generated application workspaces use the destination slug as their package scope in manifests,
30
+ imports, scripts, guides and the lockfile, including the repository example. Browser-boundary
31
+ checks identify workspace packages by their manifests, so renaming a scope keeps the checks active.
32
+ - Scaffolding formats the completed project and organizes imports with its Biome configuration,
33
+ including with `--no-install`, so scope length and sort order do not leave a failing lint check.
34
+ The bounded formatter runs the native binary directly, so a timeout stops it before rollback.
35
+ - Agent and Telegram templates declare their own Biome dependency instead of inheriting a formatter
36
+ from a parent directory or downloading an undeclared version.
37
+ - Template comments describe current constraints and their reasons rather than narrating edits.
38
+ - Local Agent and Telegram template dependencies link the current workspace rather than retaining a
39
+ copied dependency snapshot. Both templates pin transitive Zod resolution to the repository's version
40
+ so frozen installs keep one schema type identity.
41
+
42
+ ## [0.6.18] - 2026-11-02
43
+
44
+ ### Added
45
+
46
+ - `/en/admin`: an admin panel on fixture for development, with sections, roles, a table and a dialog, and no
47
+ database. A production build drops it and its rows, which `bun run acceptance:local` proves on the built
48
+ files. [`docs/ADMIN_MOCK.md`](template/docs/ADMIN_MOCK.md) holds its addresses and the way off fixture.
49
+
50
+ ### Fixed
51
+
52
+ - The web role's `/api` forwarding keeps a session and a download: `cookie`, `origin`, each `set-cookie`,
53
+ `content-disposition`, `content-length` and `location` now pass.
54
+ - The component catalogue and `/openapi.json` answer 404 in production unless the deployment sets
55
+ `SERVICE_SURFACES=open`. `bun run acceptance:local` proves both answers on one artifact.
56
+
15
57
  ## [0.6.17] - 2026-10-20
16
58
 
17
59
  ### Changed
package/dist/cli.js CHANGED
@@ -3,7 +3,7 @@
3
3
 
4
4
  // src/cli.ts
5
5
  import { readFile as readFile2 } from "fs/promises";
6
- import { basename as basename3, join as join2, resolve as resolve2 } from "path";
6
+ import { basename as basename3, join as join3, resolve as resolve2 } from "path";
7
7
  var {spawn } = globalThis.Bun;
8
8
 
9
9
  // src/identity.ts
@@ -272,8 +272,41 @@ function parseOptions(args) {
272
272
  // src/scaffold.ts
273
273
  import { lstat, mkdir, readdir, readFile, rm, writeFile } from "fs/promises";
274
274
  import { homedir } from "os";
275
- import { basename as basename2, dirname, extname, join, parse, relative, resolve, sep } from "path";
275
+ import { basename as basename2, dirname, extname, join as join2, parse, relative, resolve, sep } from "path";
276
+ import { z as z3 } from "zod";
277
+
278
+ // src/format.ts
279
+ import { execFileSync } from "child_process";
280
+ import { existsSync } from "fs";
281
+ import { createRequire } from "module";
282
+ import { join } from "path";
276
283
  import { z as z2 } from "zod";
284
+ var ProcessReportSchema = z2.object({
285
+ header: z2.object({ glibcVersionRuntime: z2.string().optional() })
286
+ });
287
+ function nativeBiome() {
288
+ const requireBiome = createRequire(import.meta.resolve("@biomejs/biome/bin/biome"));
289
+ const musl = process.platform === "linux" && ProcessReportSchema.parse(process.report.getReport()).header.glibcVersionRuntime === undefined;
290
+ const distribution = `@biomejs/cli-${process.platform}-${process.arch}${musl ? "-musl" : ""}`;
291
+ return requireBiome.resolve(`${distribution}/biome${process.platform === "win32" ? ".exe" : ""}`);
292
+ }
293
+ function defaultProjectFormatter() {
294
+ return { binary: nativeBiome(), timeoutMs: 15000 };
295
+ }
296
+ function formatProject(destination, formatter) {
297
+ if (!existsSync(join(destination, "biome.json")))
298
+ return;
299
+ execFileSync(formatter.binary, ["check", "--write", "--linter-enabled=false", "."], {
300
+ cwd: destination,
301
+ stdio: ["ignore", "pipe", "pipe"],
302
+ encoding: "utf8",
303
+ timeout: formatter.timeoutMs,
304
+ killSignal: "SIGKILL",
305
+ maxBuffer: 1024 * 1024
306
+ });
307
+ }
308
+
309
+ // src/scaffold.ts
277
310
  var TEXT_EXTENSIONS = new Set([
278
311
  ".cjs",
279
312
  ".css",
@@ -297,12 +330,12 @@ var TEMPLATE_RENAMES = new Map([
297
330
  ["_env.example.append", ".env.example"],
298
331
  ["_gitignore", ".gitignore"]
299
332
  ]);
300
- var RootManifestSchema = z2.looseObject({
301
- name: z2.string().min(1),
302
- catalog: z2.record(z2.string(), z2.string()).optional(),
303
- workspaces: z2.unknown().optional(),
304
- dependencies: z2.record(z2.string(), z2.string()).optional(),
305
- devDependencies: z2.record(z2.string(), z2.string()).optional()
333
+ var RootManifestSchema = z3.looseObject({
334
+ name: z3.string().min(1),
335
+ catalog: z3.record(z3.string(), z3.string()).optional(),
336
+ workspaces: z3.unknown().optional(),
337
+ dependencies: z3.record(z3.string(), z3.string()).optional(),
338
+ devDependencies: z3.record(z3.string(), z3.string()).optional()
306
339
  });
307
340
  var IGNORED_DIRECTORIES = new Set([
308
341
  ".next",
@@ -367,7 +400,7 @@ async function collectMaterialisedFiles(templateDirectory, directory, files) {
367
400
  const entries = await readdir(directory, { withFileTypes: true });
368
401
  entries.sort((left, right) => left.name.localeCompare(right.name));
369
402
  for (const entry of entries) {
370
- const sourcePath = join(directory, entry.name);
403
+ const sourcePath = join2(directory, entry.name);
371
404
  if (!shouldIncludeTemplatePath(templateDirectory, sourcePath))
372
405
  continue;
373
406
  if (entry.isDirectory()) {
@@ -379,7 +412,7 @@ async function collectMaterialisedFiles(templateDirectory, directory, files) {
379
412
  }
380
413
  const targetName = TEMPLATE_RENAMES.get(entry.name);
381
414
  const sourceRelativePath = relative(templateDirectory, sourcePath);
382
- const outputRelativePath = targetName ? join(dirname(sourceRelativePath), targetName) : sourceRelativePath;
415
+ const outputRelativePath = targetName ? join2(dirname(sourceRelativePath), targetName) : sourceRelativePath;
383
416
  const materialisedName = outputRelativePath.endsWith(".append") ? outputRelativePath.slice(0, -".append".length) : outputRelativePath;
384
417
  const fileExtension = extname(materialisedName);
385
418
  const content = TEXT_EXTENSIONS.has(fileExtension) || targetName ? await readFile(sourcePath, "utf8") : await readFile(sourcePath);
@@ -396,19 +429,20 @@ async function materialiseTemplateFiles(templateDirectory) {
396
429
  await collectMaterialisedFiles(templateDirectory, templateDirectory, files);
397
430
  return files;
398
431
  }
399
- async function writeMaterialisedFiles(destination, files) {
432
+ async function writeMaterialisedFiles(destination, files, slug) {
400
433
  for (const file of files) {
401
- const targetPath = join(destination, file.outputPath);
434
+ const targetPath = join2(destination, file.outputPath);
402
435
  await mkdir(dirname(targetPath), { recursive: true });
436
+ const content = typeof file.content === "string" ? file.content.replaceAll("@app/", `@${slug}/`) : file.content;
403
437
  if (file.append) {
404
- if (typeof file.content !== "string") {
438
+ if (typeof content !== "string") {
405
439
  throw new Error(`Append template entries must contain text: ${file.sourcePath}`);
406
440
  }
407
441
  const existing = await readFile(targetPath, "utf8");
408
442
  await writeFile(targetPath, `${existing.trimEnd()}
409
- ${file.content.trimStart()}`);
443
+ ${content.trimStart()}`);
410
444
  } else {
411
- await writeFile(targetPath, file.content);
445
+ await writeFile(targetPath, content);
412
446
  }
413
447
  }
414
448
  }
@@ -418,23 +452,23 @@ async function scaffoldProject(templateDirectory, destination, options = {}) {
418
452
  const destinationExisted = await assertDestinationAvailable(resolvedDestination);
419
453
  await mkdir(resolvedDestination, { recursive: true });
420
454
  try {
421
- await writeMaterialisedFiles(resolvedDestination, await materialiseTemplateFiles(templateDirectory));
455
+ await writeMaterialisedFiles(resolvedDestination, await materialiseTemplateFiles(templateDirectory), identity.slug);
422
456
  if (options.overlayDirectory) {
423
- await writeMaterialisedFiles(resolvedDestination, await materialiseTemplateFiles(options.overlayDirectory));
457
+ await writeMaterialisedFiles(resolvedDestination, await materialiseTemplateFiles(options.overlayDirectory), identity.slug);
424
458
  }
425
459
  if (options.lockfile === false) {
426
- await rm(join(resolvedDestination, "bun.lock"), { force: true });
460
+ await rm(join2(resolvedDestination, "bun.lock"), { force: true });
427
461
  }
428
- const declarationPath = join(resolvedDestination, "project.json");
462
+ const declarationPath = join2(resolvedDestination, "project.json");
429
463
  const declaration = withIdentity(JSON.parse(await readFile(declarationPath, "utf8")), identity);
430
464
  await writeFile(declarationPath, `${JSON.stringify(declaration, undefined, 2)}
431
465
  `);
432
466
  if (options.identityModule !== false) {
433
- const identityPath = join(resolvedDestination, APP_IDENTITY_PATH);
467
+ const identityPath = join2(resolvedDestination, APP_IDENTITY_PATH);
434
468
  await mkdir(dirname(identityPath), { recursive: true });
435
469
  await writeFile(identityPath, renderAppIdentityModule(declaration.identity));
436
470
  }
437
- const manifestPath = join(resolvedDestination, "package.json");
471
+ const manifestPath = join2(resolvedDestination, "package.json");
438
472
  const manifest = RootManifestSchema.parse(JSON.parse(await readFile(manifestPath, "utf8")));
439
473
  const catalog = options.stitchkitCatalogTarget ? { ...manifest.catalog ?? {}, stitchkit: options.stitchkitCatalogTarget } : manifest.catalog;
440
474
  const isWorkspace = manifest.workspaces !== undefined;
@@ -451,10 +485,10 @@ async function scaffoldProject(templateDirectory, destination, options = {}) {
451
485
  return dependencies;
452
486
  return {
453
487
  ...dependencies,
454
- ...dependencies.stitchkit?.startsWith("file:") && {
488
+ ...dependencies.stitchkit?.startsWith("link:") && {
455
489
  stitchkit: localReference("stitchkit")
456
490
  },
457
- ...dependencies["stitchkit-tui"]?.startsWith("file:") && {
491
+ ...dependencies["stitchkit-tui"]?.startsWith("link:") && {
458
492
  "stitchkit-tui": localReference("stitchkit-tui")
459
493
  }
460
494
  };
@@ -472,12 +506,13 @@ async function scaffoldProject(templateDirectory, destination, options = {}) {
472
506
  }
473
507
  }, undefined, 2)}
474
508
  `);
509
+ formatProject(resolvedDestination, options.formatter ?? defaultProjectFormatter());
475
510
  } catch (error) {
476
511
  if (!destinationExisted) {
477
512
  await rm(resolvedDestination, { recursive: true, force: true });
478
513
  } else {
479
514
  const entries = await readdir(resolvedDestination);
480
- await Promise.all(entries.map((entry) => rm(join(resolvedDestination, entry), { recursive: true, force: true })));
515
+ await Promise.all(entries.map((entry) => rm(join2(resolvedDestination, entry), { recursive: true, force: true })));
481
516
  }
482
517
  throw error;
483
518
  }
@@ -538,7 +573,7 @@ Created ${options.displayName ?? basename3(destination)}${mode}
538
573
  }
539
574
  }
540
575
  async function readStitchkitCatalogTarget(templateDirectory) {
541
- const manifest = JSON.parse(await readFile2(join2(templateDirectory, "package.json"), "utf8"));
576
+ const manifest = JSON.parse(await readFile2(join3(templateDirectory, "package.json"), "utf8"));
542
577
  if (typeof manifest !== "object" || manifest === null || !("catalog" in manifest) || typeof manifest.catalog !== "object" || manifest.catalog === null || !("stitchkit" in manifest.catalog) || typeof manifest.catalog.stitchkit !== "string") {
543
578
  throw new Error("Application template is missing catalog.stitchkit");
544
579
  }
@@ -549,8 +584,8 @@ if (import.meta.main) {
549
584
  }
550
585
  async function roleAddresses(destination) {
551
586
  try {
552
- const declaration = parseProjectDeclaration(JSON.parse(await readFile2(join2(destination, "project.json"), "utf8")));
553
- const environment = readEnvironmentExample(await readFile2(join2(destination, ".env.example"), "utf8"));
587
+ const declaration = parseProjectDeclaration(JSON.parse(await readFile2(join3(destination, "project.json"), "utf8")));
588
+ const environment = readEnvironmentExample(await readFile2(join3(destination, ".env.example"), "utf8"));
554
589
  const host = environment.BIND_HOST ?? "127.0.0.1";
555
590
  return declaration.roles.flatMap((role) => {
556
591
  const port = role.listener && environment[role.listener.portVariable];
@@ -2,6 +2,7 @@ import { appDeclaration } from '@app/config/declaration';
2
2
  import { dehydrate, HydrationBoundary } from '@tanstack/react-query';
3
3
  import type { Metadata } from 'next';
4
4
  import { getTranslations } from 'next-intl/server';
5
+ import { catalogueIsOpen } from '@/env';
5
6
  import { LocaleSchema } from '@/i18n/locales';
6
7
  import { publicRealtimeOrigin } from '@/lib/api/place';
7
8
  import { useRepository } from '@/lib/api/queries';
@@ -39,6 +40,7 @@ export default async function Page({ params }: { params: Promise<{ locale: strin
39
40
  applicationDescription={appDeclaration.identity.description[appLocale]}
40
41
  heroTitle={t('heroTitle')}
41
42
  catalogueLabel={t('ui')}
43
+ catalogueOpen={catalogueIsOpen()}
42
44
  locale={appLocale}
43
45
  realtimeOrigin={publicRealtimeOrigin()}
44
46
  />
@@ -16,6 +16,7 @@ interface StarterPageProps {
16
16
  applicationDescription: string;
17
17
  heroTitle: string;
18
18
  catalogueLabel: string;
19
+ catalogueOpen: boolean;
19
20
  realtimeOrigin?: string;
20
21
  locale: AppLocale;
21
22
  }
@@ -64,6 +65,7 @@ export async function StarterPage({
64
65
  applicationDescription,
65
66
  heroTitle,
66
67
  catalogueLabel,
68
+ catalogueOpen,
67
69
  realtimeOrigin,
68
70
  locale,
69
71
  }: StarterPageProps) {
@@ -90,14 +92,16 @@ export async function StarterPage({
90
92
  <div className='flex items-center gap-2'>
91
93
  <LanguageSwitcher />
92
94
  <ThemeToggle />
93
- <Link
94
- aria-label={catalogueLabel}
95
- className={cn(buttonVariants({ variant: 'outline', size: 'sm' }))}
96
- href='/ui'
97
- >
98
- <span className='hidden sm:inline'>{catalogueLabel}</span>
99
- <IconArrowUpRight />
100
- </Link>
95
+ {catalogueOpen ? (
96
+ <Link
97
+ aria-label={catalogueLabel}
98
+ className={cn(buttonVariants({ variant: 'outline', size: 'sm' }))}
99
+ href='/ui'
100
+ >
101
+ <span className='hidden sm:inline'>{catalogueLabel}</span>
102
+ <IconArrowUpRight />
103
+ </Link>
104
+ ) : null}
101
105
  </div>
102
106
  </header>
103
107
 
@@ -184,6 +184,15 @@
184
184
  "shape": "url",
185
185
  "required": false
186
186
  },
187
+ {
188
+ "name": "SERVICE_SURFACES",
189
+ "shape": "enum",
190
+ "required": false,
191
+ "members": [
192
+ "open",
193
+ "closed"
194
+ ]
195
+ },
187
196
  {
188
197
  "name": "TRUSTED_HOSTS",
189
198
  "shape": "string",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-stitchkit",
3
- "version": "0.6.17",
3
+ "version": "0.6.19",
4
4
  "description": "Create a production-shaped Stitchkit application",
5
5
  "license": "MIT",
6
6
  "author": "Max Listov <maxlistov@gmail.com>",
@@ -74,21 +74,22 @@
74
74
  "prepublishOnly": "bun run check && bun run test && bun run build"
75
75
  },
76
76
  "dependencies": {
77
- "zod": "^4.6.5"
77
+ "@biomejs/biome": "2.6.5",
78
+ "zod": "^4.6.7"
78
79
  },
79
80
  "devDependencies": {
80
- "@opentui/core": "^0.5.12",
81
- "@opentui/react": "^0.5.12",
81
+ "@opentui/core": "^0.8.2",
82
+ "@opentui/react": "^0.8.2",
82
83
  "@openrouter/ai-sdk-provider": "^3.1.0",
83
- "@types/bun": "^1.4.2",
84
+ "@types/bun": "^1.4.4",
84
85
  "@types/react": "^19.3.0",
85
- "ai": "^7.0.111",
86
- "react": "^19.3.0",
87
- "stitchkit": "0.111.3",
86
+ "ai": "^7.0.162",
87
+ "react": "^19.3.1",
88
+ "stitchkit": "0.119.0",
88
89
  "typescript": "^7.0.2"
89
90
  },
90
91
  "engines": {
91
92
  "bun": ">=1.2.0"
92
93
  },
93
- "packageManager": "bun@1.4.2"
94
+ "packageManager": "bun@1.4.4"
94
95
  }
@@ -45,6 +45,8 @@ database migrations you add and launches:
45
45
 
46
46
  - Web: <http://localhost:3210>
47
47
  - UI catalogue: <http://localhost:3210/en/ui>
48
+ - Admin panel on fixture, development only: <http://localhost:3210/en/admin>
49
+ ([how to take it off fixture](docs/ADMIN_MOCK.md))
48
50
  - API: <http://localhost:3211>
49
51
  - OpenAPI: <http://localhost:3211/openapi.json>
50
52
  - MCP: <http://localhost:3211/mcp>
@@ -84,6 +86,9 @@ server-delivered address, a client built on first use (hence the parentheses),
84
86
  an ordering requirement relative to `<Providers>`, and `CORS_ORIGIN` on the API
85
87
  role.
86
88
 
89
+ In production the catalogue and `/openapi.json` answer 404 unless the deployment
90
+ sets `SERVICE_SURFACES=open`; `bun run acceptance:local` proves both answers.
91
+
87
92
  The `/en/ui` catalogue is isolated under
88
93
  `packages/frontend/src/app/[locale]/ui` and can be removed as one directory;
89
94
  reusable primitives remain in `components/ui`. It renders the complete
@@ -131,6 +136,8 @@ runtime:smoke` / `bun run e2e` directly. `runtime:smoke` asks the web role to
131
136
  answer as two of the addresses `PUBLIC_WEB_HOSTS` claims, to prove one artifact
132
137
  serves many; a deployment claiming fewer than two addresses besides the one
133
138
  being dialled is told exactly what to add rather than failing on a refused host.
139
+ Both read the catalogue or `/openapi.json`, so that deployment needs
140
+ `SERVICE_SURFACES=open` while they run.
134
141
 
135
142
  ## Requirements
136
143
 
@@ -23,6 +23,11 @@ SMOKE_WEB_ORIGIN=http://127.0.0.1:3210
23
23
  PUBLIC_WEB_HOSTS=127.0.0.1:3210
24
24
  LOG_FORMAT=pretty
25
25
 
26
+ # `/en/ui` and `/openapi.json` answer 404 in production and stay open otherwise.
27
+ # `open` keeps them on a production deployment that wants them; leave it unset
28
+ # anywhere else.
29
+ # SERVICE_SURFACES=open
30
+
26
31
  # The web role reaches the API role internally, and forwards the browser's
27
32
  # same-origin `/api/…` calls to it (packages/frontend/src/app/api/[...path]).
28
33
  INTERNAL_API_URL=http://127.0.0.1:3211
@@ -1,5 +1,8 @@
1
1
  {
2
- "$schema": "https://biomejs.dev/schemas/2.5.14/schema.json",
2
+ "$schema": "https://biomejs.dev/schemas/2.6.5/schema.json",
3
+ "markdown": {
4
+ "formatter": { "enabled": false }
5
+ },
3
6
  "files": {
4
7
  "includes": [
5
8
  "**",