@aotter/mantle 0.1.4 → 0.2.0-alpha.1
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.
- package/README.md +39 -306
- package/dist/admin/consent.d.ts +17 -0
- package/dist/admin/consent.d.ts.map +1 -0
- package/dist/admin/consent.js +17 -0
- package/dist/admin/consent.js.map +1 -0
- package/dist/admin/createAdminSurface.d.ts +22 -0
- package/dist/admin/createAdminSurface.d.ts.map +1 -0
- package/dist/admin/createAdminSurface.js +589 -0
- package/dist/admin/createAdminSurface.js.map +1 -0
- package/dist/admin/developerConsole.d.ts +264 -0
- package/dist/admin/developerConsole.d.ts.map +1 -0
- package/dist/admin/developerConsole.js +136 -0
- package/dist/admin/developerConsole.js.map +1 -0
- package/dist/admin/identity.d.ts +62 -0
- package/dist/admin/identity.d.ts.map +1 -0
- package/dist/admin/identity.js +7 -0
- package/dist/admin/identity.js.map +1 -0
- package/dist/admin/index.d.ts +4 -0
- package/dist/admin/index.d.ts.map +1 -0
- package/dist/admin/index.js +4 -0
- package/dist/admin/index.js.map +1 -0
- package/dist/admin/procedureFlow.d.ts +25 -0
- package/dist/admin/procedureFlow.d.ts.map +1 -0
- package/dist/admin/procedureFlow.js +154 -0
- package/dist/admin/procedureFlow.js.map +1 -0
- package/dist/auth/ConsoleEmailSender.d.ts +15 -0
- package/dist/auth/ConsoleEmailSender.d.ts.map +1 -0
- package/dist/auth/ConsoleEmailSender.js +19 -0
- package/dist/auth/ConsoleEmailSender.js.map +1 -0
- package/dist/auth/appleClientSecret.d.ts +75 -0
- package/dist/auth/appleClientSecret.d.ts.map +1 -0
- package/dist/auth/appleClientSecret.js +116 -0
- package/dist/auth/appleClientSecret.js.map +1 -0
- package/dist/auth/buildAuth.d.ts +4565 -0
- package/dist/auth/buildAuth.d.ts.map +1 -0
- package/dist/auth/buildAuth.js +307 -0
- package/dist/auth/buildAuth.js.map +1 -0
- package/dist/auth/callerResolver.d.ts +48 -0
- package/dist/auth/callerResolver.d.ts.map +1 -0
- package/dist/auth/callerResolver.js +49 -0
- package/dist/auth/callerResolver.js.map +1 -0
- package/dist/auth/createAuthRoutes.d.ts +22 -0
- package/dist/auth/createAuthRoutes.d.ts.map +1 -0
- package/dist/auth/createAuthRoutes.js +128 -0
- package/dist/auth/createAuthRoutes.js.map +1 -0
- package/dist/auth/createMantleAuth.d.ts +3 -0
- package/dist/auth/createMantleAuth.d.ts.map +1 -0
- package/dist/auth/createMantleAuth.js +483 -0
- package/dist/auth/createMantleAuth.js.map +1 -0
- package/dist/auth/db.d.ts +17 -0
- package/dist/auth/db.d.ts.map +1 -0
- package/dist/auth/db.js +24 -0
- package/dist/auth/db.js.map +1 -0
- package/dist/auth/emailTemplates.d.ts +7 -0
- package/dist/auth/emailTemplates.d.ts.map +1 -0
- package/dist/auth/emailTemplates.js +27 -0
- package/dist/auth/emailTemplates.js.map +1 -0
- package/dist/auth/index.d.ts +9 -0
- package/dist/auth/index.d.ts.map +1 -0
- package/dist/auth/index.js +7 -0
- package/dist/auth/index.js.map +1 -0
- package/dist/auth/methods.d.ts +717 -0
- package/dist/auth/methods.d.ts.map +1 -0
- package/dist/auth/methods.js +321 -0
- package/dist/auth/methods.js.map +1 -0
- package/dist/auth/oauthTokens.d.ts +24 -0
- package/dist/auth/oauthTokens.d.ts.map +1 -0
- package/dist/auth/oauthTokens.js +146 -0
- package/dist/auth/oauthTokens.js.map +1 -0
- package/dist/auth/setupIncomplete.d.ts +16 -0
- package/dist/auth/setupIncomplete.d.ts.map +1 -0
- package/dist/auth/setupIncomplete.js +50 -0
- package/dist/auth/setupIncomplete.js.map +1 -0
- package/dist/auth/types.d.ts +440 -0
- package/dist/auth/types.d.ts.map +1 -0
- package/dist/auth/types.js +10 -0
- package/dist/auth/types.js.map +1 -0
- package/dist/bun/index.d.ts +65 -0
- package/dist/bun/index.d.ts.map +1 -0
- package/dist/bun/index.js +130 -0
- package/dist/bun/index.js.map +1 -0
- package/dist/cli/emitModule.d.ts +7 -0
- package/dist/cli/emitModule.d.ts.map +1 -0
- package/dist/cli/emitModule.js +127 -0
- package/dist/cli/emitModule.js.map +1 -0
- package/dist/cli/generate.d.ts +4 -16
- package/dist/cli/generate.d.ts.map +1 -1
- package/dist/cli/generate.js +332 -165
- package/dist/cli/generate.js.map +1 -1
- package/dist/cli/main.d.ts +1 -1
- package/dist/cli/main.d.ts.map +1 -1
- package/dist/cli/main.js +15 -71
- package/dist/cli/main.js.map +1 -1
- package/dist/cli/preset.d.ts +18 -0
- package/dist/cli/preset.d.ts.map +1 -0
- package/dist/cli/preset.js +352 -0
- package/dist/cli/preset.js.map +1 -0
- package/dist/cloudflare/index.d.ts +21 -0
- package/dist/cloudflare/index.d.ts.map +1 -0
- package/dist/cloudflare/index.js +14 -0
- package/dist/cloudflare/index.js.map +1 -0
- package/dist/cloudflare/r2Media.d.ts +43 -0
- package/dist/cloudflare/r2Media.d.ts.map +1 -0
- package/dist/cloudflare/r2Media.js +69 -0
- package/dist/cloudflare/r2Media.js.map +1 -0
- package/dist/core/caller.d.ts +35 -0
- package/dist/core/caller.d.ts.map +1 -0
- package/dist/core/caller.js +3 -0
- package/dist/core/caller.js.map +1 -0
- package/dist/core/createMantle.d.ts +22 -0
- package/dist/core/createMantle.d.ts.map +1 -0
- package/dist/core/createMantle.js +117 -0
- package/dist/core/createMantle.js.map +1 -0
- package/dist/core/dialect.d.ts +41 -0
- package/dist/core/dialect.d.ts.map +1 -0
- package/dist/core/dialect.js +7 -0
- package/dist/core/dialect.js.map +1 -0
- package/dist/core/driver.d.ts +17 -0
- package/dist/core/driver.d.ts.map +1 -0
- package/dist/core/driver.js +2 -0
- package/dist/core/driver.js.map +1 -0
- package/dist/core/email.d.ts +17 -0
- package/dist/core/email.d.ts.map +1 -0
- package/dist/core/email.js +2 -0
- package/dist/core/email.js.map +1 -0
- package/dist/core/index.d.ts +16 -0
- package/dist/core/index.d.ts.map +1 -0
- package/dist/core/index.js +16 -0
- package/dist/core/index.js.map +1 -0
- package/dist/core/invocation.d.ts +66 -0
- package/dist/core/invocation.d.ts.map +1 -0
- package/dist/core/invocation.js +3 -0
- package/dist/core/invocation.js.map +1 -0
- package/dist/core/runtime/auth.d.ts +9 -0
- package/dist/core/runtime/auth.d.ts.map +1 -0
- package/dist/core/runtime/auth.js +39 -0
- package/dist/core/runtime/auth.js.map +1 -0
- package/dist/core/runtime/createRuntime.d.ts +23 -0
- package/dist/core/runtime/createRuntime.d.ts.map +1 -0
- package/dist/core/runtime/createRuntime.js +214 -0
- package/dist/core/runtime/createRuntime.js.map +1 -0
- package/dist/core/runtime/verifyPlan.d.ts +34 -0
- package/dist/core/runtime/verifyPlan.d.ts.map +1 -0
- package/dist/core/runtime/verifyPlan.js +301 -0
- package/dist/core/runtime/verifyPlan.js.map +1 -0
- package/dist/core/service.d.ts +45 -0
- package/dist/core/service.d.ts.map +1 -0
- package/dist/core/service.js +2 -0
- package/dist/core/service.js.map +1 -0
- package/dist/core/site.d.ts +117 -0
- package/dist/core/site.d.ts.map +1 -0
- package/dist/core/site.js +2 -0
- package/dist/core/site.js.map +1 -0
- package/dist/core/siteConfig.d.ts +5 -0
- package/dist/core/siteConfig.d.ts.map +1 -0
- package/dist/core/siteConfig.js +24 -0
- package/dist/core/siteConfig.js.map +1 -0
- package/dist/core/sql/allowlist.d.ts +65 -0
- package/dist/core/sql/allowlist.d.ts.map +1 -0
- package/dist/core/sql/allowlist.js +705 -0
- package/dist/core/sql/allowlist.js.map +1 -0
- package/dist/core/sql/ast.d.ts +24 -0
- package/dist/core/sql/ast.d.ts.map +1 -0
- package/dist/core/sql/ast.js +32 -0
- package/dist/core/sql/ast.js.map +1 -0
- package/dist/core/sql/compile.d.ts +50 -0
- package/dist/core/sql/compile.d.ts.map +1 -0
- package/dist/core/sql/compile.js +48 -0
- package/dist/core/sql/compile.js.map +1 -0
- package/dist/core/sql/policy.d.ts +121 -0
- package/dist/core/sql/policy.d.ts.map +1 -0
- package/dist/core/sql/policy.js +379 -0
- package/dist/core/sql/policy.js.map +1 -0
- package/dist/core/sql/positions.d.ts +30 -0
- package/dist/core/sql/positions.d.ts.map +1 -0
- package/dist/core/sql/positions.js +22 -0
- package/dist/core/sql/positions.js.map +1 -0
- package/dist/core/sql/run.d.ts +76 -0
- package/dist/core/sql/run.d.ts.map +1 -0
- package/dist/core/sql/run.js +267 -0
- package/dist/core/sql/run.js.map +1 -0
- package/dist/core/store/createStore.d.ts +49 -0
- package/dist/core/store/createStore.d.ts.map +1 -0
- package/dist/core/store/createStore.js +227 -0
- package/dist/core/store/createStore.js.map +1 -0
- package/dist/core/store/cursor.d.ts +4 -0
- package/dist/core/store/cursor.d.ts.map +1 -0
- package/dist/core/store/cursor.js +22 -0
- package/dist/core/store/cursor.js.map +1 -0
- package/dist/core/store/json.d.ts +80 -0
- package/dist/core/store/json.d.ts.map +1 -0
- package/dist/core/store/json.js +342 -0
- package/dist/core/store/json.js.map +1 -0
- package/dist/core/store.d.ts +160 -0
- package/dist/core/store.d.ts.map +1 -0
- package/dist/core/store.js +2 -0
- package/dist/core/store.js.map +1 -0
- package/dist/core/wire.d.ts +20 -0
- package/dist/core/wire.d.ts.map +1 -0
- package/dist/core/wire.js +84 -0
- package/dist/core/wire.js.map +1 -0
- package/dist/core/withCaller.d.ts +16 -0
- package/dist/core/withCaller.d.ts.map +1 -0
- package/dist/core/withCaller.js +29 -0
- package/dist/core/withCaller.js.map +1 -0
- package/dist/d1/adapter.d.ts +12 -0
- package/dist/d1/adapter.d.ts.map +1 -0
- package/dist/d1/adapter.js +23 -0
- package/dist/d1/adapter.js.map +1 -0
- package/dist/d1/codec.d.ts +14 -0
- package/dist/d1/codec.d.ts.map +1 -0
- package/dist/d1/codec.js +136 -0
- package/dist/d1/codec.js.map +1 -0
- package/dist/d1/compile/index.d.ts +9 -0
- package/dist/d1/compile/index.d.ts.map +1 -0
- package/dist/d1/compile/index.js +9 -0
- package/dist/d1/compile/index.js.map +1 -0
- package/dist/d1/dialect.d.ts +4 -0
- package/dist/d1/dialect.d.ts.map +1 -0
- package/dist/d1/dialect.js +13 -0
- package/dist/d1/dialect.js.map +1 -0
- package/dist/d1/executor.d.ts +13 -0
- package/dist/d1/executor.d.ts.map +1 -0
- package/dist/d1/executor.js +91 -0
- package/dist/d1/executor.js.map +1 -0
- package/dist/d1/index.d.ts +6 -0
- package/dist/d1/index.d.ts.map +1 -0
- package/dist/d1/index.js +6 -0
- package/dist/d1/index.js.map +1 -0
- package/dist/d1/lower.d.ts +8 -0
- package/dist/d1/lower.d.ts.map +1 -0
- package/dist/d1/lower.js +167 -0
- package/dist/d1/lower.js.map +1 -0
- package/dist/d1/media.d.ts +5 -0
- package/dist/d1/media.d.ts.map +1 -0
- package/dist/d1/media.js +157 -0
- package/dist/d1/media.js.map +1 -0
- package/dist/d1/migrations.d.ts +12 -0
- package/dist/d1/migrations.d.ts.map +1 -0
- package/dist/d1/migrations.js +111 -0
- package/dist/d1/migrations.js.map +1 -0
- package/dist/d1/print.d.ts +28 -0
- package/dist/d1/print.d.ts.map +1 -0
- package/dist/d1/print.js +54 -0
- package/dist/d1/print.js.map +1 -0
- package/dist/d1/site.d.ts +17 -0
- package/dist/d1/site.d.ts.map +1 -0
- package/dist/d1/site.js +63 -0
- package/dist/d1/site.js.map +1 -0
- package/dist/d1/storage.d.ts +34 -0
- package/dist/d1/storage.d.ts.map +1 -0
- package/dist/d1/storage.js +288 -0
- package/dist/d1/storage.js.map +1 -0
- package/dist/d1/tz.d.ts +21 -0
- package/dist/d1/tz.d.ts.map +1 -0
- package/dist/d1/tz.js +54 -0
- package/dist/d1/tz.js.map +1 -0
- package/dist/d1/validator.d.ts +10 -0
- package/dist/d1/validator.d.ts.map +1 -0
- package/dist/d1/validator.js +33 -0
- package/dist/d1/validator.js.map +1 -0
- package/dist/mcp/apps.d.ts +43 -0
- package/dist/mcp/apps.d.ts.map +1 -0
- package/dist/mcp/apps.js +57 -0
- package/dist/mcp/apps.js.map +1 -0
- package/dist/mcp/catalog.d.ts +55 -0
- package/dist/mcp/catalog.d.ts.map +1 -0
- package/dist/mcp/catalog.js +81 -0
- package/dist/mcp/catalog.js.map +1 -0
- package/dist/mcp/createMcpSurface.d.ts +34 -0
- package/dist/mcp/createMcpSurface.d.ts.map +1 -0
- package/dist/mcp/createMcpSurface.js +150 -0
- package/dist/mcp/createMcpSurface.js.map +1 -0
- package/dist/mcp/index.d.ts +4 -0
- package/dist/mcp/index.d.ts.map +1 -0
- package/dist/mcp/index.js +4 -0
- package/dist/mcp/index.js.map +1 -0
- package/dist/postgres/adapter.d.ts +20 -0
- package/dist/postgres/adapter.d.ts.map +1 -0
- package/dist/postgres/adapter.js +44 -0
- package/dist/postgres/adapter.js.map +1 -0
- package/dist/postgres/codec.d.ts +13 -0
- package/dist/postgres/codec.d.ts.map +1 -0
- package/dist/postgres/codec.js +110 -0
- package/dist/postgres/codec.js.map +1 -0
- package/dist/postgres/compile/index.d.ts +9 -0
- package/dist/postgres/compile/index.d.ts.map +1 -0
- package/dist/postgres/compile/index.js +9 -0
- package/dist/postgres/compile/index.js.map +1 -0
- package/dist/postgres/driver.d.ts +92 -0
- package/dist/postgres/driver.d.ts.map +1 -0
- package/dist/postgres/driver.js +110 -0
- package/dist/postgres/driver.js.map +1 -0
- package/dist/postgres/executor.d.ts +20 -0
- package/dist/postgres/executor.d.ts.map +1 -0
- package/dist/postgres/executor.js +69 -0
- package/dist/postgres/executor.js.map +1 -0
- package/dist/postgres/index.d.ts +7 -0
- package/dist/postgres/index.d.ts.map +1 -0
- package/dist/postgres/index.js +7 -0
- package/dist/postgres/index.js.map +1 -0
- package/dist/postgres/lower.d.ts +6 -0
- package/dist/postgres/lower.d.ts.map +1 -0
- package/dist/postgres/lower.js +157 -0
- package/dist/postgres/lower.js.map +1 -0
- package/dist/postgres/print.d.ts +11 -0
- package/dist/postgres/print.d.ts.map +1 -0
- package/dist/postgres/print.js +121 -0
- package/dist/postgres/print.js.map +1 -0
- package/dist/postgres/storage.d.ts +19 -0
- package/dist/postgres/storage.d.ts.map +1 -0
- package/dist/postgres/storage.js +201 -0
- package/dist/postgres/storage.js.map +1 -0
- package/dist/postgres/textRows.d.ts +10 -0
- package/dist/postgres/textRows.d.ts.map +1 -0
- package/dist/postgres/textRows.js +44 -0
- package/dist/postgres/textRows.js.map +1 -0
- package/dist/postgres/validator.d.ts +12 -0
- package/dist/postgres/validator.d.ts.map +1 -0
- package/dist/postgres/validator.js +46 -0
- package/dist/postgres/validator.js.map +1 -0
- package/dist/spec/domain/index.d.ts +3 -0
- package/dist/spec/domain/index.d.ts.map +1 -0
- package/dist/spec/domain/index.js +3 -0
- package/dist/spec/domain/index.js.map +1 -0
- package/dist/spec/domain/model/ContentState.d.ts +8 -0
- package/dist/spec/domain/model/ContentState.d.ts.map +1 -0
- package/dist/spec/domain/model/ContentState.js +7 -0
- package/dist/spec/domain/model/ContentState.js.map +1 -0
- package/dist/spec/domain/model/Entry.d.ts +29 -0
- package/dist/spec/domain/model/Entry.d.ts.map +1 -0
- package/dist/spec/domain/model/Entry.js +16 -0
- package/dist/spec/domain/model/Entry.js.map +1 -0
- package/dist/spec/domain/model/Locale.d.ts +30 -0
- package/dist/spec/domain/model/Locale.d.ts.map +1 -0
- package/dist/spec/domain/model/Locale.js +33 -0
- package/dist/spec/domain/model/Locale.js.map +1 -0
- package/dist/spec/domain/model/ManifestGrammar.d.ts +452 -0
- package/dist/spec/domain/model/ManifestGrammar.d.ts.map +1 -0
- package/dist/spec/domain/model/ManifestGrammar.js +149 -0
- package/dist/spec/domain/model/ManifestGrammar.js.map +1 -0
- package/dist/spec/domain/model/MediaMimeAccept.d.ts +55 -0
- package/dist/spec/domain/model/MediaMimeAccept.d.ts.map +1 -0
- package/dist/spec/domain/model/MediaMimeAccept.js +90 -0
- package/dist/spec/domain/model/MediaMimeAccept.js.map +1 -0
- package/dist/spec/domain/model/RuntimePlan.d.ts +94 -0
- package/dist/spec/domain/model/RuntimePlan.d.ts.map +1 -0
- package/dist/spec/domain/model/RuntimePlan.js +4 -0
- package/dist/spec/domain/model/RuntimePlan.js.map +1 -0
- package/dist/spec/domain/model/SiteConfig.d.ts +173 -0
- package/dist/spec/domain/model/SiteConfig.d.ts.map +1 -0
- package/dist/spec/domain/model/SiteConfig.js +13 -0
- package/dist/spec/domain/model/SiteConfig.js.map +1 -0
- package/dist/spec/domain/model/SqlIr.d.ts +96 -0
- package/dist/spec/domain/model/SqlIr.d.ts.map +1 -0
- package/dist/spec/domain/model/SqlIr.js +95 -0
- package/dist/spec/domain/model/SqlIr.js.map +1 -0
- package/dist/spec/domain/model/index.d.ts +14 -0
- package/dist/spec/domain/model/index.d.ts.map +1 -0
- package/dist/spec/domain/model/index.js +14 -0
- package/dist/spec/domain/model/index.js.map +1 -0
- package/dist/spec/domain/service/CloudflareCron.d.ts +2 -0
- package/dist/spec/domain/service/CloudflareCron.d.ts.map +1 -0
- package/dist/spec/domain/service/CloudflareCron.js +63 -0
- package/dist/spec/domain/service/CloudflareCron.js.map +1 -0
- package/dist/spec/domain/service/CrossSchemaChecker.d.ts +34 -0
- package/dist/spec/domain/service/CrossSchemaChecker.d.ts.map +1 -0
- package/dist/spec/domain/service/CrossSchemaChecker.js +114 -0
- package/dist/spec/domain/service/CrossSchemaChecker.js.map +1 -0
- package/dist/spec/domain/service/EntryDataValidator.d.ts +56 -0
- package/dist/spec/domain/service/EntryDataValidator.d.ts.map +1 -0
- package/dist/spec/domain/service/EntryDataValidator.js +88 -0
- package/dist/spec/domain/service/EntryDataValidator.js.map +1 -0
- package/dist/spec/domain/service/JsonSchemaToZod.d.ts +29 -0
- package/dist/spec/domain/service/JsonSchemaToZod.d.ts.map +1 -0
- package/dist/spec/domain/service/JsonSchemaToZod.js +156 -0
- package/dist/spec/domain/service/JsonSchemaToZod.js.map +1 -0
- package/dist/spec/domain/service/LifecycleStateMachine.d.ts +75 -0
- package/dist/spec/domain/service/LifecycleStateMachine.d.ts.map +1 -0
- package/dist/spec/domain/service/LifecycleStateMachine.js +76 -0
- package/dist/spec/domain/service/LifecycleStateMachine.js.map +1 -0
- package/dist/spec/domain/service/LocaleCanonicalizer.d.ts +29 -0
- package/dist/spec/domain/service/LocaleCanonicalizer.d.ts.map +1 -0
- package/dist/spec/domain/service/LocaleCanonicalizer.js +96 -0
- package/dist/spec/domain/service/LocaleCanonicalizer.js.map +1 -0
- package/dist/spec/domain/service/ManifestFieldChecks.d.ts +60 -0
- package/dist/spec/domain/service/ManifestFieldChecks.d.ts.map +1 -0
- package/dist/spec/domain/service/ManifestFieldChecks.js +116 -0
- package/dist/spec/domain/service/ManifestFieldChecks.js.map +1 -0
- package/dist/spec/domain/service/ManifestGraphValidator.d.ts +15 -0
- package/dist/spec/domain/service/ManifestGraphValidator.d.ts.map +1 -0
- package/dist/spec/domain/service/ManifestGraphValidator.js +225 -0
- package/dist/spec/domain/service/ManifestGraphValidator.js.map +1 -0
- package/dist/spec/domain/service/ManifestLinker.d.ts +45 -0
- package/dist/spec/domain/service/ManifestLinker.d.ts.map +1 -0
- package/dist/spec/domain/service/ManifestLinker.js +92 -0
- package/dist/spec/domain/service/ManifestLinker.js.map +1 -0
- package/dist/spec/domain/service/ManifestLocaleTrimmer.d.ts +16 -0
- package/dist/spec/domain/service/ManifestLocaleTrimmer.d.ts.map +1 -0
- package/dist/spec/domain/service/ManifestLocaleTrimmer.js +76 -0
- package/dist/spec/domain/service/ManifestLocaleTrimmer.js.map +1 -0
- package/dist/spec/domain/service/ManifestParser.d.ts +49 -0
- package/dist/spec/domain/service/ManifestParser.d.ts.map +1 -0
- package/dist/spec/domain/service/ManifestParser.js +203 -0
- package/dist/spec/domain/service/ManifestParser.js.map +1 -0
- package/dist/spec/domain/service/ManifestPartition.d.ts +9 -0
- package/dist/spec/domain/service/ManifestPartition.d.ts.map +1 -0
- package/dist/spec/domain/service/ManifestPartition.js +19 -0
- package/dist/spec/domain/service/ManifestPartition.js.map +1 -0
- package/dist/spec/domain/service/ManifestPathDiagnoser.d.ts +33 -0
- package/dist/spec/domain/service/ManifestPathDiagnoser.d.ts.map +1 -0
- package/dist/spec/domain/service/ManifestPathDiagnoser.js +43 -0
- package/dist/spec/domain/service/ManifestPathDiagnoser.js.map +1 -0
- package/dist/spec/domain/service/ManifestSourceSpans.d.ts +10 -0
- package/dist/spec/domain/service/ManifestSourceSpans.d.ts.map +1 -0
- package/dist/spec/domain/service/ManifestSourceSpans.js +76 -0
- package/dist/spec/domain/service/ManifestSourceSpans.js.map +1 -0
- package/dist/spec/domain/service/McpToolNaming.d.ts +25 -0
- package/dist/spec/domain/service/McpToolNaming.d.ts.map +1 -0
- package/dist/spec/domain/service/McpToolNaming.js +50 -0
- package/dist/spec/domain/service/McpToolNaming.js.map +1 -0
- package/dist/spec/domain/service/PlanFingerprint.d.ts +4 -0
- package/dist/spec/domain/service/PlanFingerprint.d.ts.map +1 -0
- package/dist/spec/domain/service/PlanFingerprint.js +14 -0
- package/dist/spec/domain/service/PlanFingerprint.js.map +1 -0
- package/dist/spec/domain/service/ProcedureViewSpecChecks.d.ts +4 -0
- package/dist/spec/domain/service/ProcedureViewSpecChecks.d.ts.map +1 -0
- package/dist/spec/domain/service/ProcedureViewSpecChecks.js +211 -0
- package/dist/spec/domain/service/ProcedureViewSpecChecks.js.map +1 -0
- package/dist/spec/domain/service/SchemaAdminUiChecker.d.ts +42 -0
- package/dist/spec/domain/service/SchemaAdminUiChecker.d.ts.map +1 -0
- package/dist/spec/domain/service/SchemaAdminUiChecker.js +289 -0
- package/dist/spec/domain/service/SchemaAdminUiChecker.js.map +1 -0
- package/dist/spec/domain/service/SchemaIndexChecker.d.ts +33 -0
- package/dist/spec/domain/service/SchemaIndexChecker.d.ts.map +1 -0
- package/dist/spec/domain/service/SchemaIndexChecker.js +256 -0
- package/dist/spec/domain/service/SchemaIndexChecker.js.map +1 -0
- package/dist/spec/domain/service/SchemaSearchChecker.d.ts +11 -0
- package/dist/spec/domain/service/SchemaSearchChecker.d.ts.map +1 -0
- package/dist/spec/domain/service/SchemaSearchChecker.js +78 -0
- package/dist/spec/domain/service/SchemaSearchChecker.js.map +1 -0
- package/dist/spec/domain/service/SchemaSpecChecks.d.ts +31 -0
- package/dist/spec/domain/service/SchemaSpecChecks.d.ts.map +1 -0
- package/dist/spec/domain/service/SchemaSpecChecks.js +445 -0
- package/dist/spec/domain/service/SchemaSpecChecks.js.map +1 -0
- package/dist/spec/domain/service/SiteDefaultsValidator.d.ts +39 -0
- package/dist/spec/domain/service/SiteDefaultsValidator.d.ts.map +1 -0
- package/dist/spec/domain/service/SiteDefaultsValidator.js +194 -0
- package/dist/spec/domain/service/SiteDefaultsValidator.js.map +1 -0
- package/dist/spec/domain/service/SqlClassify.d.ts +19 -0
- package/dist/spec/domain/service/SqlClassify.d.ts.map +1 -0
- package/dist/spec/domain/service/SqlClassify.js +42 -0
- package/dist/spec/domain/service/SqlClassify.js.map +1 -0
- package/dist/spec/domain/service/SqlRefusal.d.ts +16 -0
- package/dist/spec/domain/service/SqlRefusal.d.ts.map +1 -0
- package/dist/spec/domain/service/SqlRefusal.js +20 -0
- package/dist/spec/domain/service/SqlRefusal.js.map +1 -0
- package/dist/spec/domain/service/SqlTypes.d.ts +40 -0
- package/dist/spec/domain/service/SqlTypes.d.ts.map +1 -0
- package/dist/spec/domain/service/SqlTypes.js +110 -0
- package/dist/spec/domain/service/SqlTypes.js.map +1 -0
- package/dist/spec/domain/service/StaffRoleHierarchy.d.ts +3 -0
- package/dist/spec/domain/service/StaffRoleHierarchy.d.ts.map +1 -0
- package/dist/spec/domain/service/StaffRoleHierarchy.js +19 -0
- package/dist/spec/domain/service/StaffRoleHierarchy.js.map +1 -0
- package/dist/spec/domain/service/TriggerGraphChecks.d.ts +16 -0
- package/dist/spec/domain/service/TriggerGraphChecks.d.ts.map +1 -0
- package/dist/spec/domain/service/TriggerGraphChecks.js +337 -0
- package/dist/spec/domain/service/TriggerGraphChecks.js.map +1 -0
- package/dist/spec/domain/service/TriggerSpecChecks.d.ts +4 -0
- package/dist/spec/domain/service/TriggerSpecChecks.d.ts.map +1 -0
- package/dist/spec/domain/service/TriggerSpecChecks.js +89 -0
- package/dist/spec/domain/service/TriggerSpecChecks.js.map +1 -0
- package/dist/spec/domain/service/ValidatedAdminUiProjection.d.ts +11 -0
- package/dist/spec/domain/service/ValidatedAdminUiProjection.d.ts.map +1 -0
- package/dist/spec/domain/service/ValidatedAdminUiProjection.js +26 -0
- package/dist/spec/domain/service/ValidatedAdminUiProjection.js.map +1 -0
- package/dist/spec/domain/service/ViewAdminUiChecker.d.ts +14 -0
- package/dist/spec/domain/service/ViewAdminUiChecker.d.ts.map +1 -0
- package/dist/spec/domain/service/ViewAdminUiChecker.js +53 -0
- package/dist/spec/domain/service/ViewAdminUiChecker.js.map +1 -0
- package/dist/spec/domain/service/index.d.ts +24 -0
- package/dist/spec/domain/service/index.d.ts.map +1 -0
- package/dist/spec/domain/service/index.js +24 -0
- package/dist/spec/domain/service/index.js.map +1 -0
- package/dist/spec/index.d.ts +10 -0
- package/dist/spec/index.d.ts.map +1 -0
- package/dist/spec/index.js +12 -0
- package/dist/spec/index.js.map +1 -0
- package/dist/spec/infrastructure/cli/parseArgsError.d.ts +16 -0
- package/dist/spec/infrastructure/cli/parseArgsError.d.ts.map +1 -0
- package/dist/spec/infrastructure/cli/parseArgsError.js +34 -0
- package/dist/spec/infrastructure/cli/parseArgsError.js.map +1 -0
- package/dist/spec/infrastructure/index.d.ts +2 -0
- package/dist/spec/infrastructure/index.d.ts.map +1 -0
- package/dist/spec/infrastructure/index.js +2 -0
- package/dist/spec/infrastructure/index.js.map +1 -0
- package/dist/spec/infrastructure/sql/PgQueryParser.d.ts +18 -0
- package/dist/spec/infrastructure/sql/PgQueryParser.d.ts.map +1 -0
- package/dist/spec/infrastructure/sql/PgQueryParser.js +17 -0
- package/dist/spec/infrastructure/sql/PgQueryParser.js.map +1 -0
- package/dist/spec/infrastructure/sql/compilePlan.d.ts +37 -0
- package/dist/spec/infrastructure/sql/compilePlan.d.ts.map +1 -0
- package/dist/spec/infrastructure/sql/compilePlan.js +282 -0
- package/dist/spec/infrastructure/sql/compilePlan.js.map +1 -0
- package/dist/spec/infrastructure/sql/compileSql.d.ts +35 -0
- package/dist/spec/infrastructure/sql/compileSql.d.ts.map +1 -0
- package/dist/spec/infrastructure/sql/compileSql.js +92 -0
- package/dist/spec/infrastructure/sql/compileSql.js.map +1 -0
- package/dist/spec/infrastructure/sql/frontEnd.d.ts +8 -0
- package/dist/spec/infrastructure/sql/frontEnd.d.ts.map +1 -0
- package/dist/spec/infrastructure/sql/frontEnd.js +100 -0
- package/dist/spec/infrastructure/sql/frontEnd.js.map +1 -0
- package/dist/spec/infrastructure/sql/index.d.ts +4 -0
- package/dist/spec/infrastructure/sql/index.d.ts.map +1 -0
- package/dist/spec/infrastructure/sql/index.js +4 -0
- package/dist/spec/infrastructure/sql/index.js.map +1 -0
- package/dist/spec/kernel/diagnostic.d.ts +137 -0
- package/dist/spec/kernel/diagnostic.d.ts.map +1 -0
- package/dist/spec/kernel/diagnostic.js +296 -0
- package/dist/spec/kernel/diagnostic.js.map +1 -0
- package/dist/spec/kernel/index.d.ts +8 -0
- package/dist/spec/kernel/index.d.ts.map +1 -0
- package/dist/spec/kernel/index.js +8 -0
- package/dist/spec/kernel/index.js.map +1 -0
- package/dist/spec/usecase/EmitTypes.d.ts +22 -0
- package/dist/spec/usecase/EmitTypes.d.ts.map +1 -0
- package/dist/spec/usecase/EmitTypes.js +182 -0
- package/dist/spec/usecase/EmitTypes.js.map +1 -0
- package/dist/spec/usecase/ValidateManifestsUseCase.d.ts +8 -0
- package/dist/spec/usecase/ValidateManifestsUseCase.d.ts.map +1 -0
- package/dist/spec/usecase/ValidateManifestsUseCase.js +101 -0
- package/dist/spec/usecase/ValidateManifestsUseCase.js.map +1 -0
- package/dist/spec/usecase/dto/ValidateManifestsRequest.d.ts +27 -0
- package/dist/spec/usecase/dto/ValidateManifestsRequest.d.ts.map +1 -0
- package/dist/spec/usecase/dto/ValidateManifestsRequest.js +2 -0
- package/dist/spec/usecase/dto/ValidateManifestsRequest.js.map +1 -0
- package/dist/spec/usecase/dto/ValidateManifestsResponse.d.ts +14 -0
- package/dist/spec/usecase/dto/ValidateManifestsResponse.d.ts.map +1 -0
- package/dist/spec/usecase/dto/ValidateManifestsResponse.js +2 -0
- package/dist/spec/usecase/dto/ValidateManifestsResponse.js.map +1 -0
- package/dist/spec/usecase/dto/index.d.ts +3 -0
- package/dist/spec/usecase/dto/index.d.ts.map +1 -0
- package/dist/spec/usecase/dto/index.js +3 -0
- package/dist/spec/usecase/dto/index.js.map +1 -0
- package/dist/spec/usecase/index.d.ts +10 -0
- package/dist/spec/usecase/index.d.ts.map +1 -0
- package/dist/spec/usecase/index.js +10 -0
- package/dist/spec/usecase/index.js.map +1 -0
- package/dist/testing/cases/before-hook.d.ts +4 -0
- package/dist/testing/cases/before-hook.d.ts.map +1 -0
- package/dist/testing/cases/before-hook.js +71 -0
- package/dist/testing/cases/before-hook.js.map +1 -0
- package/dist/testing/cases/corpus.d.ts +12 -0
- package/dist/testing/cases/corpus.d.ts.map +1 -0
- package/dist/testing/cases/corpus.js +91 -0
- package/dist/testing/cases/corpus.js.map +1 -0
- package/dist/testing/cases/policy.d.ts +74 -0
- package/dist/testing/cases/policy.d.ts.map +1 -0
- package/dist/testing/cases/policy.js +142 -0
- package/dist/testing/cases/policy.js.map +1 -0
- package/dist/testing/cases/printer.d.ts +4 -0
- package/dist/testing/cases/printer.d.ts.map +1 -0
- package/dist/testing/cases/printer.js +32 -0
- package/dist/testing/cases/printer.js.map +1 -0
- package/dist/testing/cases/report-view.d.ts +5 -0
- package/dist/testing/cases/report-view.d.ts.map +1 -0
- package/dist/testing/cases/report-view.js +33 -0
- package/dist/testing/cases/report-view.js.map +1 -0
- package/dist/testing/cases/requisition.d.ts +4 -0
- package/dist/testing/cases/requisition.d.ts.map +1 -0
- package/dist/testing/cases/requisition.js +38 -0
- package/dist/testing/cases/requisition.js.map +1 -0
- package/dist/testing/cases/search-places.d.ts +4 -0
- package/dist/testing/cases/search-places.d.ts.map +1 -0
- package/dist/testing/cases/search-places.js +60 -0
- package/dist/testing/cases/search-places.js.map +1 -0
- package/dist/testing/cases/stock.d.ts +4 -0
- package/dist/testing/cases/stock.d.ts.map +1 -0
- package/dist/testing/cases/stock.js +35 -0
- package/dist/testing/cases/stock.js.map +1 -0
- package/dist/testing/cases/store.d.ts +4 -0
- package/dist/testing/cases/store.d.ts.map +1 -0
- package/dist/testing/cases/store.js +100 -0
- package/dist/testing/cases/store.js.map +1 -0
- package/dist/testing/harness.d.ts +94 -0
- package/dist/testing/harness.d.ts.map +1 -0
- package/dist/testing/harness.js +168 -0
- package/dist/testing/harness.js.map +1 -0
- package/dist/testing/index.d.ts +37 -0
- package/dist/testing/index.d.ts.map +1 -0
- package/dist/testing/index.js +43 -0
- package/dist/testing/index.js.map +1 -0
- package/dist/testing/report.d.ts +15 -0
- package/dist/testing/report.d.ts.map +1 -0
- package/dist/testing/report.js +22 -0
- package/dist/testing/report.js.map +1 -0
- package/dist/web/createRestSurface.d.ts +7 -0
- package/dist/web/createRestSurface.d.ts.map +1 -0
- package/dist/web/createRestSurface.js +39 -0
- package/dist/web/createRestSurface.js.map +1 -0
- package/dist/web/index.d.ts +2 -0
- package/dist/web/index.d.ts.map +1 -0
- package/dist/web/index.js +2 -0
- package/dist/web/index.js.map +1 -0
- package/docs/adr/0008-structured-diagnostic-shape.md +2 -2
- package/docs/adr/0011-adapter-port-spec.md +2 -2
- package/docs/adr/0014-auth-better-auth-and-multi-tenant-mcp.md +21 -2
- package/docs/adr/0019-sealed-manifest-runtime-pipeline.md +5 -1
- package/docs/adr/0021-retire-starter-scaffolding.md +1 -1
- package/docs/adr/0022-caller-observed-version-occ.md +1 -1
- package/docs/adr/0024-manifest-native-schema-tables.md +2 -2
- package/docs/adr/0026-progressive-generate.md +36 -0
- package/docs/adr/0027-scheduled-procedure-triggers.md +31 -0
- package/docs/adr/0028-schema-ttl-expiry.md +33 -0
- package/docs/adr/0029-mcp-apps-interaction-contracts.md +324 -0
- package/docs/adr/0030-store.md +40 -0
- package/docs/adr/0031-host-cloud-core-contract.md +25 -0
- package/docs/adr/0032-store-centric-core-and-service-contract.md +361 -0
- package/docs/adr/0033-storage-converges-to-the-plan.md +92 -0
- package/docs/adr/0034-store-is-authored-as-sql.md +192 -0
- package/docs/adr/0035-sql-dialects.md +154 -0
- package/docs/adr/0036-host-and-dialect.md +65 -0
- package/docs/adr/0037-postgresql-is-the-reference-dialect.md +124 -0
- package/docs/adr/0038-bun-native-host.md +63 -0
- package/docs/adr/README.md +26 -8
- package/docs/adr/adr-lite-861-admin-webmcp.md +6 -0
- package/docs/adr/adr-lite-909-admin-ui-kit.md +1 -1
- package/docs/examples/README.md +16 -18
- package/docs/examples/commerce-inventory.md +481 -0
- package/docs/examples/commerce.md +254 -0
- package/docs/examples/guarded-api.md +238 -0
- package/docs/examples/intake-hooks.md +237 -0
- package/docs/examples/intake.md +127 -0
- package/docs/examples/legal-documents.md +218 -0
- package/docs/examples/procurement.md +215 -0
- package/docs/examples/publication.md +211 -0
- package/docs/examples/reference-service/.dev.vars.example +4 -0
- package/docs/examples/reference-service/.mantle/generated/mantle.ts +174 -0
- package/docs/examples/reference-service/.mantle/generated/plan.json +1936 -0
- package/docs/examples/reference-service/README.md +33 -0
- package/docs/examples/reference-service/manifests/catalog.yaml +103 -0
- package/docs/examples/reference-service/manifests/orders.yaml +120 -0
- package/docs/examples/reference-service/mantle.config.json +1 -0
- package/docs/examples/reference-service/package.json +27 -0
- package/docs/examples/reference-service/smoke.mjs +156 -0
- package/docs/examples/reference-service/src/handlers.ts +36 -0
- package/docs/examples/reference-service/src/index.ts +33 -0
- package/docs/examples/reference-service/src/service.ts +78 -0
- package/docs/examples/{host-minimal-worker → reference-service}/tsconfig.json +7 -2
- package/docs/examples/reference-service/wrangler.jsonc +26 -0
- package/docs/examples/reservation.md +142 -0
- package/docs/handbook/cloudflare/authentication.md +96 -299
- package/docs/handbook/cloudflare/chatgpt-sites.md +104 -15
- package/docs/handbook/cloudflare/deploy-and-operate.md +77 -71
- package/docs/handbook/cloudflare/media-r2.md +64 -187
- package/docs/handbook/cloudflare/service-entry.md +138 -0
- package/docs/handbook/concepts/authorization.md +104 -94
- package/docs/handbook/concepts/four-atoms.md +68 -144
- package/docs/handbook/concepts/lifecycle-and-locales.md +62 -114
- package/docs/handbook/concepts/mcp-and-agents.md +112 -117
- package/docs/handbook/concepts/procedures-and-triggers.md +126 -181
- package/docs/handbook/concepts/runtime-and-adapters.md +177 -156
- package/docs/handbook/concepts/views.md +97 -173
- package/docs/handbook/examples/hub.md +17 -6
- package/docs/handbook/guides/admin-ui.md +101 -96
- package/docs/handbook/guides/agent-setup.md +56 -71
- package/docs/handbook/guides/typed-queries.md +105 -111
- package/docs/handbook/navigation.json +8 -32
- package/docs/handbook/reference/authorization.md +52 -271
- package/docs/handbook/reference/diagnostics.md +69 -173
- package/docs/handbook/reference/features.md +48 -50
- package/docs/handbook/reference/manifest.md +56 -116
- package/docs/handbook/reference/procedure.md +92 -229
- package/docs/handbook/reference/schema.md +156 -215
- package/docs/handbook/reference/site-config.md +58 -211
- package/docs/handbook/reference/surface.md +69 -181
- package/docs/handbook/reference/trigger.md +73 -162
- package/docs/handbook/reference/view.md +140 -241
- package/docs/handbook/releases/index.md +58 -22
- package/docs/handbook/start/overview.md +59 -48
- package/docs/handbook/start/project-and-cli.md +127 -116
- package/docs/handbook/start/quickstart-worker.md +102 -151
- package/docs/skills/develop/SKILL.md +114 -232
- package/docs/skills/develop/mcp-app.md +79 -0
- package/docs/skills/integrate/SKILL.md +96 -0
- package/docs/skills/media-gc/SKILL.md +21 -10
- package/docs/skills/provision/SKILL.md +68 -162
- package/docs/skills/update/SKILL.md +33 -34
- package/docs/upgrade-0.1-to-0.2.md +211 -0
- package/package.json +87 -105
- package/dist/admin-ui.d.ts +0 -2
- package/dist/admin-ui.d.ts.map +0 -1
- package/dist/admin-ui.js +0 -2
- package/dist/admin-ui.js.map +0 -1
- package/dist/admin.d.ts +0 -2
- package/dist/admin.d.ts.map +0 -1
- package/dist/admin.js +0 -2
- package/dist/admin.js.map +0 -1
- package/dist/auth.d.ts +0 -2
- package/dist/auth.d.ts.map +0 -1
- package/dist/auth.js +0 -2
- package/dist/auth.js.map +0 -1
- package/dist/bun.d.ts +0 -2
- package/dist/bun.d.ts.map +0 -1
- package/dist/bun.js +0 -2
- package/dist/bun.js.map +0 -1
- package/dist/cli/harness.d.ts +0 -3
- package/dist/cli/harness.d.ts.map +0 -1
- package/dist/cli/harness.js +0 -214
- package/dist/cli/harness.js.map +0 -1
- package/dist/cli/skills.d.ts +0 -3
- package/dist/cli/skills.d.ts.map +0 -1
- package/dist/cli/skills.js +0 -128
- package/dist/cli/skills.js.map +0 -1
- package/dist/cloudflare.d.ts +0 -2
- package/dist/cloudflare.d.ts.map +0 -1
- package/dist/cloudflare.js +0 -2
- package/dist/cloudflare.js.map +0 -1
- package/dist/codegen/emitMantleModule.d.ts +0 -22
- package/dist/codegen/emitMantleModule.d.ts.map +0 -1
- package/dist/codegen/emitMantleModule.js +0 -291
- package/dist/codegen/emitMantleModule.js.map +0 -1
- package/dist/codegen.d.ts +0 -2
- package/dist/codegen.d.ts.map +0 -1
- package/dist/codegen.js +0 -2
- package/dist/codegen.js.map +0 -1
- package/dist/runtime-testing.d.ts +0 -2
- package/dist/runtime-testing.d.ts.map +0 -1
- package/dist/runtime-testing.js +0 -2
- package/dist/runtime-testing.js.map +0 -1
- package/dist/runtime.d.ts +0 -2
- package/dist/runtime.d.ts.map +0 -1
- package/dist/runtime.js +0 -2
- package/dist/runtime.js.map +0 -1
- package/dist/spec.d.ts +0 -2
- package/dist/spec.d.ts.map +0 -1
- package/dist/spec.js +0 -2
- package/dist/spec.js.map +0 -1
- package/dist/vercel-libsql.d.ts +0 -2
- package/dist/vercel-libsql.d.ts.map +0 -1
- package/dist/vercel-libsql.js +0 -2
- package/dist/vercel-libsql.js.map +0 -1
- package/dist/vercel.d.ts +0 -2
- package/dist/vercel.d.ts.map +0 -1
- package/dist/vercel.js +0 -2
- package/dist/vercel.js.map +0 -1
- package/dist/web.d.ts +0 -2
- package/dist/web.d.ts.map +0 -1
- package/dist/web.js +0 -2
- package/dist/web.js.map +0 -1
- package/docs/adapter-guide.md +0 -222
- package/docs/agent-prompts.md +0 -102
- package/docs/api-mcp-authorization.md +0 -5
- package/docs/assets/mantle-admin-developer.png +0 -0
- package/docs/assets/mantle-admin-operations.png +0 -0
- package/docs/assets/mantle-hero.jpg +0 -0
- package/docs/auth-hosting-model.md +0 -166
- package/docs/cloudflare-low-level-composition.md +0 -5
- package/docs/consumer-onboarding-audit.md +0 -65
- package/docs/deferred-lifecycle-queues.md +0 -5
- package/docs/design-atoms.md +0 -16
- package/docs/design-references/editorial-blog-2026-05-05.md +0 -218
- package/docs/direct-authoring.md +0 -5
- package/docs/examples/builtin-commerce.md +0 -269
- package/docs/examples/builtin-intake.md +0 -143
- package/docs/examples/builtin-legal-documents.md +0 -189
- package/docs/examples/builtin-procurement.md +0 -241
- package/docs/examples/builtin-publication.md +0 -241
- package/docs/examples/builtin-reservation.md +0 -149
- package/docs/examples/cf-primitives-commerce-inventory.md +0 -809
- package/docs/examples/cf-primitives-guarded-api.md +0 -429
- package/docs/examples/cf-primitives-intake-hooks.md +0 -319
- package/docs/examples/host-chatgpt-sites/.openai/hosting.json +0 -1
- package/docs/examples/host-chatgpt-sites/README.md +0 -70
- package/docs/examples/host-chatgpt-sites/drizzle/0000_sites_users.sql +0 -8
- package/docs/examples/host-chatgpt-sites/drizzle/0001_mantle.sql +0 -294
- package/docs/examples/host-chatgpt-sites/drizzle/0002_article_cover.sql +0 -5
- package/docs/examples/host-chatgpt-sites/drizzle/0003_store_instance_id.sql +0 -1
- package/docs/examples/host-chatgpt-sites/drizzle/meta/_journal.json +0 -1
- package/docs/examples/host-chatgpt-sites/manifests/site.yaml +0 -27
- package/docs/examples/host-chatgpt-sites/package.json +0 -1
- package/docs/examples/host-chatgpt-sites/public/site.css +0 -1
- package/docs/examples/host-chatgpt-sites/scripts/build.mjs +0 -13
- package/docs/examples/host-chatgpt-sites/scripts/check.mjs +0 -101
- package/docs/examples/host-chatgpt-sites/scripts/migration.mjs +0 -9
- package/docs/examples/host-chatgpt-sites/src/chatgpt-auth.ts +0 -63
- package/docs/examples/host-chatgpt-sites/src/index.ts +0 -46
- package/docs/examples/host-chatgpt-sites/src/mcp.ts +0 -49
- package/docs/examples/host-chatgpt-sites/src/media.ts +0 -109
- package/docs/examples/host-chatgpt-sites/src/r2-lab.ts +0 -38
- package/docs/examples/host-chatgpt-sites/src/storage-fingerprint.json +0 -1
- package/docs/examples/host-chatgpt-sites/src/web.ts +0 -35
- package/docs/examples/host-chatgpt-sites/tsconfig.json +0 -1
- package/docs/examples/host-chatgpt-sites/wrangler.jsonc +0 -10
- package/docs/examples/host-local-admin-otp/.dev.vars.example +0 -3
- package/docs/examples/host-local-admin-otp/README.md +0 -80
- package/docs/examples/host-local-admin-otp/ensure-dev-vars.mjs +0 -5
- package/docs/examples/host-local-admin-otp/manifests/site.yaml +0 -25
- package/docs/examples/host-local-admin-otp/package.json +0 -29
- package/docs/examples/host-local-admin-otp/public/.gitkeep +0 -1
- package/docs/examples/host-local-admin-otp/smoke.mjs +0 -141
- package/docs/examples/host-local-admin-otp/src/index.ts +0 -54
- package/docs/examples/host-local-admin-otp/tsconfig.json +0 -17
- package/docs/examples/host-local-admin-otp/wrangler.jsonc +0 -23
- package/docs/examples/host-minimal-worker/README.md +0 -41
- package/docs/examples/host-minimal-worker/manifests/site.yaml +0 -25
- package/docs/examples/host-minimal-worker/package.json +0 -26
- package/docs/examples/host-minimal-worker/smoke.mjs +0 -23
- package/docs/examples/host-minimal-worker/src/index.ts +0 -4
- package/docs/examples/host-minimal-worker/wrangler.jsonc +0 -22
- package/docs/handbook/chatgpt-sites/equipment-checkout.md +0 -231
- package/docs/handbook/chatgpt-sites/host-reference.md +0 -113
- package/docs/handbook/chatgpt-sites/index.md +0 -123
- package/docs/handbook/cloudflare/bindings.md +0 -298
- package/docs/handbook/cloudflare/conventional-worker.md +0 -162
- package/docs/handbook/cloudflare/deferred-hooks-queues.md +0 -170
- package/docs/handbook/cloudflare/low-level-composition.md +0 -169
- package/docs/handbook/cloudflare/public-web.md +0 -144
- package/docs/handbook/cloudflare/site-chrome.md +0 -75
- package/docs/handbook/examples/commerce-transaction.md +0 -11
- package/docs/handbook/examples/commerce.md +0 -11
- package/docs/handbook/examples/guarded-api.md +0 -10
- package/docs/handbook/examples/intake-form.md +0 -12
- package/docs/handbook/examples/intake-hooks.md +0 -11
- package/docs/handbook/examples/legal-documents.md +0 -10
- package/docs/handbook/examples/procurement-approvals.md +0 -10
- package/docs/handbook/examples/publication.md +0 -10
- package/docs/handbook/examples/reservation.md +0 -10
- package/docs/handbook/start/quickstart-admin.md +0 -50
- package/docs/labels.md +0 -71
- package/docs/media-uploads.md +0 -5
- package/docs/migration-0.1.2.md +0 -13
- package/docs/performance-harness.md +0 -228
- package/docs/release-process.md +0 -244
- package/docs/schema-indexes.md +0 -5
- package/docs/sealed-pipeline-ownership.md +0 -101
- package/docs/skills/plugin/SKILL.md +0 -132
- package/docs/skills/theme/SKILL.md +0 -77
- package/docs/spec-only-host-adoption.md +0 -157
- package/docs/transaction-patterns.md +0 -5
- package/skills/README.md +0 -125
- package/skills/develop/SKILL.md +0 -250
- package/skills/install/SKILL.md +0 -149
- package/skills/media-gc/SKILL.md +0 -85
- package/skills/plugin/SKILL.md +0 -132
- package/skills/provision/SKILL.md +0 -194
- package/skills/theme/SKILL.md +0 -77
- package/skills/update/SKILL.md +0 -51
package/docs/adapter-guide.md
DELETED
|
@@ -1,222 +0,0 @@
|
|
|
1
|
-
# Adapter implementation guide
|
|
2
|
-
|
|
3
|
-
This guide is the fresh-developer entry point for implementing a new mantle platform adapter.
|
|
4
|
-
|
|
5
|
-
Read this with [ADR-0019](adr/0019-sealed-manifest-runtime-pipeline.md). The source of truth for TypeScript shapes is `packages/mantle-runtime/src/domain/port/`.
|
|
6
|
-
|
|
7
|
-
Adapter packages live under `packages/adapters/<platform>/` using a plural `adapters` bucket. The npm package names stay unchanged, for example `@aotter/mantle-cloudflare`. Keep adapters in this monorepo until the runtime/spec API is stable enough that coordinated releases across separate repositories would not create version skew for consumers.
|
|
8
|
-
|
|
9
|
-
## Required storage boundary
|
|
10
|
-
|
|
11
|
-
A storage adapter prepares one `RuntimePlan` into semantic ports:
|
|
12
|
-
|
|
13
|
-
| Contract | Source | Cloudflare example |
|
|
14
|
-
|---|---|---|
|
|
15
|
-
| `MantleStorageAdapter` / `PreparedMantleStorage` | `packages/mantle-runtime/src/domain/port/MantleStorageAdapter.ts` | `SqliteMantleStorageAdapter` over `D1DatabaseDriver` |
|
|
16
|
-
| `EntryRepository & EntryReader` | Existing semantic content ports | `DatabaseEntryRepository` supplied by the SQLite adapter |
|
|
17
|
-
| `ViewQueryExecutor` | `packages/mantle-runtime/src/domain/port/ViewQueryExecutor.ts` | `SqliteViewQueryExecutor` |
|
|
18
|
-
|
|
19
|
-
`DatabaseDriver` is only the reusable SQLite/D1 implementation seam. A
|
|
20
|
-
PostgreSQL, MongoDB, or application-owned-table adapter implements the semantic
|
|
21
|
-
ports directly; it does not emulate D1 and needs no mapping DSL. Platform types
|
|
22
|
-
such as `D1Database`, Postgres pools, and Mongo clients remain in adapter code.
|
|
23
|
-
|
|
24
|
-
## Optional capabilities
|
|
25
|
-
|
|
26
|
-
Optional ports are enabled only when a feature needs them:
|
|
27
|
-
|
|
28
|
-
| Contract | Source | Required when |
|
|
29
|
-
|---|---|---|
|
|
30
|
-
| `MediaStorage` | `packages/mantle-runtime/src/domain/port/MediaStorage.ts` | The adapter exposes admin/MCP media upload flows. |
|
|
31
|
-
| `DeferredHookDispatcher` | `packages/mantle-runtime/src/domain/port/DeferredHookDispatcher.ts` | The adapter wants at-least-once queue delivery for `after_*` lifecycle hooks. |
|
|
32
|
-
|
|
33
|
-
Test seams such as `Clock` and `IdGenerator` are injectable through `createMantleRuntime`, but normal adapters do not need custom implementations.
|
|
34
|
-
|
|
35
|
-
Deferred delivery is an optional, versioned wire contract. Queue acceptance is
|
|
36
|
-
not atomic with the entry write; adapters must preserve the supplied event id,
|
|
37
|
-
validate untrusted messages before dereferencing them, surface handler failures
|
|
38
|
-
to their retry mechanism, and document poison-message/DLQ behavior. See
|
|
39
|
-
[Deferred lifecycle hooks on Cloudflare Queues](deferred-lifecycle-queues.md)
|
|
40
|
-
for the reference implementation and exact guarantees.
|
|
41
|
-
|
|
42
|
-
## Storage preparation
|
|
43
|
-
|
|
44
|
-
Compile before deployment preparation, then pass only the sealed plan:
|
|
45
|
-
|
|
46
|
-
```ts
|
|
47
|
-
import {
|
|
48
|
-
bootMantleRuntime,
|
|
49
|
-
SqliteMantleStorageAdapter,
|
|
50
|
-
} from "@aotter/mantle-runtime";
|
|
51
|
-
|
|
52
|
-
const storage = new SqliteMantleStorageAdapter(db, siteDefaults);
|
|
53
|
-
const runtime = await bootMantleRuntime({
|
|
54
|
-
plan,
|
|
55
|
-
storage,
|
|
56
|
-
handlers,
|
|
57
|
-
ports,
|
|
58
|
-
deployment: {
|
|
59
|
-
reservedHttpPathPrefixes: selectedCapabilities.flatMap(
|
|
60
|
-
(capability) => capability.reservedHttpPathPrefixes,
|
|
61
|
-
),
|
|
62
|
-
},
|
|
63
|
-
});
|
|
64
|
-
```
|
|
65
|
-
|
|
66
|
-
`bootMantleRuntime` performs one attempt and derives Procedure readiness from
|
|
67
|
-
the supplied handlers. The platform adapter remains responsible for lazy boot,
|
|
68
|
-
promise caching, retry policy, and teardown.
|
|
69
|
-
|
|
70
|
-
Hosts that need work between preparation and binding may keep the same stages
|
|
71
|
-
public and explicit:
|
|
72
|
-
|
|
73
|
-
```ts
|
|
74
|
-
const prepared = await prepareDeployment(plan, storage, {
|
|
75
|
-
handlerNames: Object.keys(handlers ?? {}),
|
|
76
|
-
});
|
|
77
|
-
const runtime = createMantleRuntime({ prepared, handlers, ports });
|
|
78
|
-
```
|
|
79
|
-
|
|
80
|
-
The prepared revision carries its exact plan, but exposes both `plan` and
|
|
81
|
-
`storage`; it seals the pairing invariant rather than hiding low-level host
|
|
82
|
-
capabilities. Omit `handlerNames` only for a read-only embedding that never
|
|
83
|
-
dispatches Procedures.
|
|
84
|
-
|
|
85
|
-
The official SQLite adapter runs canonical migrations, materializes one native
|
|
86
|
-
table per Schema, prepares indexes and Views, and skips mutation for an
|
|
87
|
-
unchanged storage revision. A
|
|
88
|
-
custom adapter owns its own preparation and returns application-owned semantic
|
|
89
|
-
ports. Unsupported native View dialects fail before the adapter mutates state.
|
|
90
|
-
|
|
91
|
-
### Bun embedding
|
|
92
|
-
|
|
93
|
-
> **Experimental.** The Bun and Vercel adapters may change in a minor
|
|
94
|
-
> release. They cover public Views and HTTP Triggers; the host owns
|
|
95
|
-
> authentication and CSRF, and Auth, Admin and MCP are Cloudflare-only today.
|
|
96
|
-
> Cloudflare is the supported host.
|
|
97
|
-
|
|
98
|
-
`@aotter/mantle-bun` is the minimal SQLite reference: pass an application-owned
|
|
99
|
-
`bun:sqlite` `Database` and a compiled `RuntimePlan` to `createBunMantle()`.
|
|
100
|
-
Its `handle()` returns `null` for sibling routes and a Web-standard `Response`
|
|
101
|
-
for manifest-declared public Views and HTTP Triggers. The host owns
|
|
102
|
-
`Bun.serve`, database shutdown, authentication, and CSRF policy; the adapter
|
|
103
|
-
prepares the semantic revision once and retries only after failed preparation.
|
|
104
|
-
|
|
105
|
-
### Vercel Functions embedding
|
|
106
|
-
|
|
107
|
-
`@aotter/mantle-vercel` accepts a compiled plan plus any application-owned
|
|
108
|
-
`MantleStorageAdapter` and reuses the same public View/HTTP Trigger transport as
|
|
109
|
-
Bun. It maps deferred work to Vercel Functions `waitUntil` and otherwise leaves
|
|
110
|
-
the Web Handler, auth/CSRF, and route composition to the application. The
|
|
111
|
-
optional `/libsql` subpath adapts a caller-owned remote Turso/libSQL client to
|
|
112
|
-
the canonical SQLite chain; the default entry has no database-vendor policy.
|
|
113
|
-
Vercel's read-only filesystem and writable `/tmp` are never durable state.
|
|
114
|
-
|
|
115
|
-
### Browser IndexedDB embedding
|
|
116
|
-
|
|
117
|
-
`@aotter/mantle-indexeddb` implements the same required semantic storage ports
|
|
118
|
-
over one application-owned IndexedDB database. It keeps browser globals out of
|
|
119
|
-
Runtime Core, supports declarative Views with a documented O(n) collection
|
|
120
|
-
scan, and exposes `deleteDatabase()` only on the concrete adapter. The host owns
|
|
121
|
-
database naming, `navigator.storage` persistence requests, active-runtime
|
|
122
|
-
selection, UI invalidation, and any remote synchronization.
|
|
123
|
-
|
|
124
|
-
## HTTP and MCP surfaces
|
|
125
|
-
|
|
126
|
-
The runtime is a library, not an HTTP server. A new adapter must mount equivalent framework routes:
|
|
127
|
-
|
|
128
|
-
| Surface | Adapter responsibility | Cloudflare reference |
|
|
129
|
-
|---|---|---|
|
|
130
|
-
| Runtime HTTP endpoints | Route HTTP Triggers and public View REST endpoints into runtime use cases. | `packages/adapters/cloudflare/src/mount/mountRuntimeEndpoints.ts` |
|
|
131
|
-
| Optional Admin | Supply session/request context and assets to `mantle-admin`; mount only when selected. | `packages/adapters/cloudflare/src/mount/mountAdmin.ts` |
|
|
132
|
-
| Auth endpoints | Own sign-in/session/OAuth metadata through the adapter's Better Auth implementation selected by Admin/OAuth surfaces. | `packages/adapters/cloudflare/src/auth/createAuth.ts` |
|
|
133
|
-
| MCP endpoints | Mount `/mcp/staff` and `/mcp` behind one canonical protected resource. The adapter verifies Better Auth JWTs, normalizes the caller, re-reads the staff D1 role, then dispatches JSON-RPC. | `packages/adapters/cloudflare/src/mount/mountMcp.ts`, `auth/createAuth.ts` |
|
|
134
|
-
|
|
135
|
-
Auth is not a runtime port. Per [ADR-0014](adr/0014-auth-better-auth-and-multi-tenant-mcp.md), the adapter owns Better Auth wiring and passes authenticated user/staff context into runtime dispatchers. Procedure handlers receive that data through `HandlerContext` in `packages/mantle-runtime/src/domain/model/HandlerContext.ts`.
|
|
136
|
-
|
|
137
|
-
The adapter must also normalize verified credential metadata into
|
|
138
|
-
`HandlerContext.auth` (`credential`, opaque `credentialId`, optional
|
|
139
|
-
`clientId`, scopes). Platform-native session/OAuth verification stays in the
|
|
140
|
-
adapter. A narrow adapter extension seam may let consumer code verify its own
|
|
141
|
-
API-key or personal-token formats, but credential storage/issuance must not
|
|
142
|
-
become a runtime port. The Cloudflare reference is
|
|
143
|
-
`mount/resolveCaller.ts`; consumer usage is documented in
|
|
144
|
-
[API and MCP authorization](examples/cf-primitives-guarded-api.md).
|
|
145
|
-
|
|
146
|
-
Minimum HTTP behavior for a full adapter:
|
|
147
|
-
|
|
148
|
-
- Route manifest HTTP Triggers to `runtime.invokeProcedure`.
|
|
149
|
-
- Route `GET /api/views/<name>` to `runtime.executeView`.
|
|
150
|
-
- Mount admin content APIs with session/role checks before calling runtime content use cases.
|
|
151
|
-
- Serve selected Admin SPA assets through `AdminAssetServer`, with an SPA catchall for client-side routes.
|
|
152
|
-
- Mount public render routes and markdown mirrors when the application exposes public pages.
|
|
153
|
-
- Translate runtime diagnostics and validation failures into stable HTTP JSON responses instead of throwing raw errors.
|
|
154
|
-
- Evaluate target auth and dynamic guards through the runtime use cases; do
|
|
155
|
-
not duplicate guard logic in HTTP handlers.
|
|
156
|
-
|
|
157
|
-
For the Cloudflare adapter, public rendering requires three matching consumer
|
|
158
|
-
inputs: `mountPublicRoutes(...)` route declarations, a `TemplateRegistry`
|
|
159
|
-
passed through `MantleCloudflareConfig.templates`, and a `publicPathResolver`
|
|
160
|
-
passed through `MantleCloudflareConfig.publicPathResolver`. Omitting public routes is valid for a headless
|
|
161
|
-
consumer; mounting every Schema automatically is not, because some collections
|
|
162
|
-
are private even when they contain a slug.
|
|
163
|
-
|
|
164
|
-
`TemplateRegistry` and `createPublicPathResolver` come from
|
|
165
|
-
`@aotter/mantle-web`. Other adapters can call `createMantleWeb(runtime)` and map
|
|
166
|
-
its document operations into their own routing and cache conventions.
|
|
167
|
-
|
|
168
|
-
### HTTP cache contract
|
|
169
|
-
|
|
170
|
-
Keep responses private by default. For Cloudflare, apply the final policy after
|
|
171
|
-
all routes and preserve only explicit anonymous public opt-in. Follow the
|
|
172
|
-
[public cache contract](handbook/cloudflare/public-web.md#cache-contract) and the
|
|
173
|
-
[performance harness](performance-harness.md#cache-contract) for verification.
|
|
174
|
-
|
|
175
|
-
Minimum auth/MCP behavior:
|
|
176
|
-
|
|
177
|
-
- Provide Better Auth-compatible sign-in/session routes for the platform.
|
|
178
|
-
- Validate `/mcp/staff` requests with the staff D1 admin role (`owner`/`editor`/`contributor`).
|
|
179
|
-
- Validate `/mcp` requests with any authenticated session (D1 role check is surface-driven, not OAuth-scope-driven — claude.ai rejects colon-shaped scopes).
|
|
180
|
-
- Advertise a single non-colon scope (default `["mcp"]`) in `scopes_supported`. Per-surface enforcement happens server-side in the apiHandler.
|
|
181
|
-
- Build `McpAuthContext` from the validated session and pass it to `McpJsonRpcDispatcher`.
|
|
182
|
-
- Build Procedure/View `HandlerContext` with `user`, live `staff`, normalized
|
|
183
|
-
`auth`, adapter `env`, and optional `waitUntil`.
|
|
184
|
-
- Re-read mutable staff role for each protected REST/MCP invocation. Token or
|
|
185
|
-
consent-time role snapshots are not an authorization boundary.
|
|
186
|
-
- Keep `tools/list` filtering as UX only; route every `tools/call` through the
|
|
187
|
-
same auth evaluator and guard runner used by REST.
|
|
188
|
-
|
|
189
|
-
## Static assets
|
|
190
|
-
|
|
191
|
-
`AdminAssetServer` belongs to optional `@aotter/mantle-admin`. Headless Core
|
|
192
|
-
storage preparation and binding do not accept or require a static asset port.
|
|
193
|
-
|
|
194
|
-
## Implementation checklist
|
|
195
|
-
|
|
196
|
-
- [ ] Run `runStorageConformance` from `@aotter/mantle-runtime/testing/storage`
|
|
197
|
-
against a disposable prepared-storage factory. See the
|
|
198
|
-
[Runtime conformance guide](../packages/mantle-runtime/README.md#storage-adapter-conformance)
|
|
199
|
-
for coverage, cleanup, locale setup, and remaining adapter-specific tests.
|
|
200
|
-
- [ ] Implement `MantleStorageAdapter` returning existing semantic ports, or reuse `SqliteMantleStorageAdapter` with an already-owned handle.
|
|
201
|
-
- [ ] Call `bootMantleRuntime()` once per semantic revision, or explicitly prepare before binding.
|
|
202
|
-
- [ ] Mount HTTP Trigger and View REST surfaces.
|
|
203
|
-
- [ ] Mount admin/public render routes and admin SPA assets.
|
|
204
|
-
- [ ] Provide adapter-owned Better Auth wiring and session helpers.
|
|
205
|
-
- [ ] Normalize session/OAuth and any consumer credential seam into
|
|
206
|
-
`HandlerContext.auth`; never put raw credentials in runtime context.
|
|
207
|
-
- [ ] Mount `/mcp/staff` and `/mcp` behind one resource-bound token verifier. Enforce the live staff role inside the apiHandler.
|
|
208
|
-
- [ ] Preserve the HTTP cache contract: private by default; explicit anonymous 200 `GET`/`HEAD` public opt-in only.
|
|
209
|
-
- [ ] Prove one guarded target has identical REST/MCP outcomes, including
|
|
210
|
-
mutable revocation on the next call.
|
|
211
|
-
- [ ] Add optional `MediaStorage` or `DeferredHookDispatcher` only when the adapter supports those features.
|
|
212
|
-
- [ ] For deferred hooks, document at-least-once delivery, idempotency,
|
|
213
|
-
message limits, retries/DLQ, and the non-transactional write-to-enqueue gap.
|
|
214
|
-
- [ ] Verify the runtime package still has no platform-specific imports.
|
|
215
|
-
|
|
216
|
-
## Current non-goals
|
|
217
|
-
|
|
218
|
-
- Do not add `SessionRepository`, `OAuthVerifier`, `UserRepository`, or `StaffRepository` runtime ports. Those were pre-ADR-0014 concepts and are not part of the current adapter contract.
|
|
219
|
-
- Do not add API-key, personal-token, transaction, billing, or entitlement
|
|
220
|
-
repositories to Core. They are consumer state behind the adapter resolver
|
|
221
|
-
and guard Procedure.
|
|
222
|
-
- Do not generalize `DatabaseDriver` for PostgreSQL/MongoDB or add a mapping DSL. Implement semantic ports; SQLite/D1 alone reuse the canonical SQL chain.
|
package/docs/agent-prompts.md
DELETED
|
@@ -1,102 +0,0 @@
|
|
|
1
|
-
# Task-specific agent prompts
|
|
2
|
-
|
|
3
|
-
Cold start from GitHub or a marketplace host is the install skill:
|
|
4
|
-
|
|
5
|
-
```sh
|
|
6
|
-
npx skills add aotter/mantle
|
|
7
|
-
```
|
|
8
|
-
|
|
9
|
-
Copy one block into a coding agent after that skill is present. Paths below
|
|
10
|
-
are relative to the Mantle docs root: `node_modules/@aotter/mantle/docs/`
|
|
11
|
-
after `@aotter/mantle` is installed. A standalone `skills add` installation
|
|
12
|
-
contains only the selected skill, not these docs.
|
|
13
|
-
`npx --no-install mantle --help` is the layered CLI overview; it mirrors the
|
|
14
|
-
authoring docs. A live `/mcp` catalog mirrors the Manifest → RuntimePlan, not
|
|
15
|
-
the CLI. Resolve only missing requirements first; do not assume a host. There is no `mantle create`. Empty `generate` fails until
|
|
16
|
-
manifests exist. Admin is opt-in.
|
|
17
|
-
|
|
18
|
-
### Interview then build
|
|
19
|
-
|
|
20
|
-
```text
|
|
21
|
-
Interview me about the service: host, who uses it, whether humans need a
|
|
22
|
-
Dev UI, and whether we only embed Spec/Runtime. If the install skill is
|
|
23
|
-
missing, run npx skills add aotter/mantle. Read the
|
|
24
|
-
installer-reported skill, choose and install an exact SDK version, then read
|
|
25
|
-
its embedded skills/install/SKILL.md,
|
|
26
|
-
run npx --no-install mantle --help, and
|
|
27
|
-
read handbook/start/overview.md.
|
|
28
|
-
Use examples/README.md as the examples index; copy builtin-* Manifests only
|
|
29
|
-
(not cf-primitives-*). Implement locally first. Take only the surfaces we
|
|
30
|
-
chose. For Spec-only use, skip Runtime and code generation. For a Worker
|
|
31
|
-
without Admin, follow examples/host-minimal-worker/. For a Worker with
|
|
32
|
-
Dev UI, follow examples/host-local-admin-otp/README.md. ChatGPT Sites only
|
|
33
|
-
if I name that host. No mantle create. Pin all @aotter/mantle* packages
|
|
34
|
-
to one exact version.
|
|
35
|
-
```
|
|
36
|
-
|
|
37
|
-
### Embed Runtime with typed APIs
|
|
38
|
-
|
|
39
|
-
```text
|
|
40
|
-
Read handbook/start/project-and-cli.md and npx --no-install mantle --help.
|
|
41
|
-
Pin @aotter/mantle at the exact version we agree, author manifests for
|
|
42
|
-
this existing host, then run mantle generate. Embed
|
|
43
|
-
the typed binding from .mantle/generated/mantle.ts into the current
|
|
44
|
-
system. Do not add Admin, mantle-admin-ui, a visitor frontend, or a
|
|
45
|
-
Cloudflare adapter unless I ask. Do not invent a default Schema.
|
|
46
|
-
```
|
|
47
|
-
|
|
48
|
-
### Minimal API service locally
|
|
49
|
-
|
|
50
|
-
```text
|
|
51
|
-
Read handbook/start/quickstart-worker.md and examples/host-minimal-worker/.
|
|
52
|
-
Author a Cloudflare Worker from that official example or from scratch:
|
|
53
|
-
one Schema, one public View (copy the contract, not the tree wholesale).
|
|
54
|
-
Pin every @aotter/mantle* package to the same exact version. Run
|
|
55
|
-
pnpm install && pnpm generate && pnpm dev (or wrangler dev --local).
|
|
56
|
-
Probe GET /api/views/<name> with curl. GET / may 404. Do not install
|
|
57
|
-
Admin or wrangler ASSETS unless I ask.
|
|
58
|
-
```
|
|
59
|
-
|
|
60
|
-
### Full local Dev UI (opt-in)
|
|
61
|
-
|
|
62
|
-
```text
|
|
63
|
-
I want the optional Admin / Dev UI. Read examples/host-local-admin-otp/README.md
|
|
64
|
-
(the procedural SSOT) and the thin pointer at handbook/start/quickstart-admin.md.
|
|
65
|
-
Interview me for a bootstrap owner email, then follow that example locally.
|
|
66
|
-
Prefer 127.0.0.1 over localhost. After pnpm check / smoke, restore .dev.vars
|
|
67
|
-
from .dev.vars.example before pnpm dev.
|
|
68
|
-
```
|
|
69
|
-
|
|
70
|
-
### Later layer: MCP or public web (opt-in)
|
|
71
|
-
|
|
72
|
-
```text
|
|
73
|
-
Do not add Admin unless it is already in this project. Read
|
|
74
|
-
handbook/concepts/mcp-and-agents.md and/or
|
|
75
|
-
handbook/cloudflare/public-web.md. Add only the surface I name: MCP
|
|
76
|
-
Triggers at /mcp or /mcp/staff, or optional @aotter/mantle-web
|
|
77
|
-
composition. Keep Core adapter-neutral. Probe the new route; do not
|
|
78
|
-
claim Auth or Admin works from a public 200.
|
|
79
|
-
```
|
|
80
|
-
|
|
81
|
-
### Mantle on ChatGPT Sites, including media
|
|
82
|
-
|
|
83
|
-
Use only when the user names ChatGPT Sites as the host.
|
|
84
|
-
|
|
85
|
-
```text
|
|
86
|
-
Build with ChatGPT Sites; use Mantle for content management and publishing.
|
|
87
|
-
Read handbook/chatgpt-sites/index.md and examples/host-chatgpt-sites/README.md.
|
|
88
|
-
Use that runnable host as a reference and install its pinned
|
|
89
|
-
dependencies from the registry. Derive Schema, View,
|
|
90
|
-
Procedure and Trigger from my requirements and check the Admin editor/picker and public
|
|
91
|
-
projections against them. Request both Sites D1 and R2 when my workflow
|
|
92
|
-
includes uploads. Bind the R2 media port, declare media.purposes, and keep
|
|
93
|
-
the same-origin PUT and committed-only public GET checks. Pin every
|
|
94
|
-
@aotter/mantle* dependency to one exact version. Run the local smoke,
|
|
95
|
-
show a draft-to-publish walkthrough, then save and deploy through Sites when
|
|
96
|
-
requested. Verify the deployed owner/member role, R2 upload, published page, and anonymous draft 404. Treat public read-only
|
|
97
|
-
MCP, Admin WebMCP, and staff OAuth MCP as separate acceptance gates; never
|
|
98
|
-
claim staff MCP from a working browser session or connector URL alone.
|
|
99
|
-
```
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
[Back to the Core README](../README.md#for-engineers-and-agents).
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -1,166 +0,0 @@
|
|
|
1
|
-
# Auth Hosting Model
|
|
2
|
-
|
|
3
|
-
Mantle treats authentication as a runtime capability, not a paywall on
|
|
4
|
-
basic login. The split is:
|
|
5
|
-
|
|
6
|
-
- **Mantle SDK** gives every generated site the primitives needed to
|
|
7
|
-
run its own auth.
|
|
8
|
-
- **Mantle's conventional Cloudflare adapter** runs the generated site's
|
|
9
|
-
selected self-hosted or Mantle Platform hosted client configuration.
|
|
10
|
-
- **The application owner/host** declares the explicit auth mode and provider
|
|
11
|
-
configuration.
|
|
12
|
-
- **Mantle Platform** can sell hosted identity, provider setup, email,
|
|
13
|
-
and billing convenience for site owners who do not want to operate
|
|
14
|
-
those pieces.
|
|
15
|
-
|
|
16
|
-
This document is the source of truth for the product and SDK boundary.
|
|
17
|
-
Do not duplicate this model in starter handoff copy or landing prose;
|
|
18
|
-
link here and keep downstream docs short.
|
|
19
|
-
|
|
20
|
-
## Free Self-Hosted Auth
|
|
21
|
-
|
|
22
|
-
A free Mantle site can run every login method the SDK exposes through
|
|
23
|
-
`createAuth()`:
|
|
24
|
-
|
|
25
|
-
- social OAuth providers supported by Better Auth;
|
|
26
|
-
- provider-specific options through Better Auth's native `socialProviders` types;
|
|
27
|
-
- email OTP;
|
|
28
|
-
- magic link;
|
|
29
|
-
- passkey or another Better Auth method through the raw `plugins` path when the
|
|
30
|
-
application owns its callback and UI;
|
|
31
|
-
- first-party same-domain or same-parent-domain SSO when the site owner
|
|
32
|
-
controls every participating subdomain.
|
|
33
|
-
|
|
34
|
-
The site owner supplies their own provider client ids/secrets,
|
|
35
|
-
transactional email sender, DNS, cookie policy, and operational
|
|
36
|
-
maintenance. Mantle must not block self-hosted login behind a paid
|
|
37
|
-
feature flag.
|
|
38
|
-
|
|
39
|
-
## Hosted Platform Auth
|
|
40
|
-
|
|
41
|
-
Paid hosted auth is a convenience and operations product. The value is
|
|
42
|
-
that Mantle Platform can:
|
|
43
|
-
|
|
44
|
-
- hold OAuth provider configuration;
|
|
45
|
-
- hold email provider credentials;
|
|
46
|
-
- send OTP and magic-link email;
|
|
47
|
-
- manage deliverability and provider rotation;
|
|
48
|
-
- register generated sites as clients;
|
|
49
|
-
- check billing/license entitlements before hosted capabilities are
|
|
50
|
-
enabled;
|
|
51
|
-
- expose a stable hosted identity broker for generated sites.
|
|
52
|
-
|
|
53
|
-
The generated site still owns local grants, member records, content,
|
|
54
|
-
orders, forms, and legal copy. Platform returns identity. The site maps
|
|
55
|
-
that identity into `ctx.user`, `ctx.staff`, and its own grant model.
|
|
56
|
-
|
|
57
|
-
## Same Parent Domain SSO
|
|
58
|
-
|
|
59
|
-
When the apps share a parent domain that the same party controls, SSO
|
|
60
|
-
can use browser cookies:
|
|
61
|
-
|
|
62
|
-
```ts
|
|
63
|
-
createAuth({
|
|
64
|
-
// ...
|
|
65
|
-
trustedOrigins: ["https://mantle.tools", "https://www.mantle.tools"],
|
|
66
|
-
cookiePrefix: "mantle-platform",
|
|
67
|
-
crossSubDomainCookies: {
|
|
68
|
-
enabled: true,
|
|
69
|
-
domain: "mantle.tools",
|
|
70
|
-
},
|
|
71
|
-
});
|
|
72
|
-
```
|
|
73
|
-
|
|
74
|
-
Use this only for a trusted first-party app family, for example
|
|
75
|
-
`platform.mantle.tools` and `mantle.tools`.
|
|
76
|
-
|
|
77
|
-
`cookiePrefix` is required whenever more than one Better Auth app can
|
|
78
|
-
write cookies under the same parent domain. Without it, Platform and
|
|
79
|
-
Landing can overwrite each other's default Better Auth cookie names.
|
|
80
|
-
|
|
81
|
-
`trustedOrigins` is a Better Auth auth-flow trust list. It is not a
|
|
82
|
-
general API CORS policy and must not be documented as one.
|
|
83
|
-
|
|
84
|
-
## Customer Domain SSO
|
|
85
|
-
|
|
86
|
-
Shared cookies do not work across different registrable domains:
|
|
87
|
-
|
|
88
|
-
```text
|
|
89
|
-
platform.mantle.tools -> customer.com
|
|
90
|
-
```
|
|
91
|
-
|
|
92
|
-
Browsers will not send a `mantle.tools` cookie to `customer.com`. For a
|
|
93
|
-
customer-owned domain, hosted auth must use OAuth/OIDC:
|
|
94
|
-
|
|
95
|
-
```text
|
|
96
|
-
customer.com/login
|
|
97
|
-
-> platform.mantle.tools/api/auth/oauth2/authorize
|
|
98
|
-
-> user signs in with Platform-supported methods
|
|
99
|
-
-> customer.com/api/auth/callback/mantle
|
|
100
|
-
-> customer.com verifies the authorization response
|
|
101
|
-
-> customer.com creates its own local session
|
|
102
|
-
```
|
|
103
|
-
|
|
104
|
-
That local session is the customer's site session. Platform remains the
|
|
105
|
-
identity broker and entitlement authority; it does not become the
|
|
106
|
-
customer site's member database or authorization system.
|
|
107
|
-
|
|
108
|
-
## Landing Provisioning Split
|
|
109
|
-
|
|
110
|
-
Landing should branch before GitHub or Cloudflare side effects:
|
|
111
|
-
|
|
112
|
-
- **Continue free**: commit a self-hosted auth-ready site with docs,
|
|
113
|
-
env placeholders, and the user's own provider setup path.
|
|
114
|
-
- **Use hosted auth**: check Platform entitlement, register the site as
|
|
115
|
-
a Platform auth client, and commit the generated site's Platform auth
|
|
116
|
-
client config.
|
|
117
|
-
|
|
118
|
-
Landing can probe Platform staff/session state, but provisioning's
|
|
119
|
-
GitHub OAuth token is still Landing-owned unless a separate token
|
|
120
|
-
handoff design is introduced.
|
|
121
|
-
|
|
122
|
-
The conventional hosted-auth client wiring belongs in Core's Cloudflare
|
|
123
|
-
adapter. Applications declare its environment bindings; a provisioning host supplies an
|
|
124
|
-
allocated client. A site can still replace Auth construction through
|
|
125
|
-
`createMantleWorker({ auth })` when it needs a different curated identity
|
|
126
|
-
design. Core continues to own the normalized manifest/runtime credential
|
|
127
|
-
vocabulary (`ctx.user`, `ctx.staff`, `ctx.auth`) and guard orchestration.
|
|
128
|
-
|
|
129
|
-
## API and MCP Authorization
|
|
130
|
-
|
|
131
|
-
Login hosting and business API authorization are related but separate. Core
|
|
132
|
-
provides a normalized verified-credential context (`ctx.auth`), closed scope
|
|
133
|
-
predicates, one Cloudflare consumer credential resolver seam, and a
|
|
134
|
-
Procedure-backed guard that REST and MCP both execute. A generated site owns
|
|
135
|
-
API keys, personal tokens, grants, transactions, subscriptions, and the guard
|
|
136
|
-
handler that checks current business state.
|
|
137
|
-
|
|
138
|
-
Mantle Platform may be the identity or OAuth token authority for a hosted
|
|
139
|
-
flow. That does not make token claims the generated site's live membership or
|
|
140
|
-
entitlement authority. The target site's guard reads its authoritative state
|
|
141
|
-
on every call. See [API and MCP authorization](examples/cf-primitives-guarded-api.md) for
|
|
142
|
-
the exact public API and four consumer examples.
|
|
143
|
-
|
|
144
|
-
## SDK Surface Rule
|
|
145
|
-
|
|
146
|
-
Mantle owns only integration fields with a real Mantle use case. Method
|
|
147
|
-
configuration uses Better Auth's official provider/plugin option types; do not
|
|
148
|
-
copy those unions or add a generic `Partial<BetterAuthOptions>` deep merge.
|
|
149
|
-
|
|
150
|
-
The current first-party SSO use case justifies these optional fields on
|
|
151
|
-
`CreateAuthConfig`:
|
|
152
|
-
|
|
153
|
-
- `trustedOrigins`
|
|
154
|
-
- `crossSubDomainCookies`
|
|
155
|
-
- `cookiePrefix`
|
|
156
|
-
|
|
157
|
-
The cross-site API use case additionally justifies these fields and facades:
|
|
158
|
-
|
|
159
|
-
- native generic OAuth `authorizationUrlParams`, `tokenUrlParams`, and
|
|
160
|
-
`refreshTokenParams` for RFC 8707 `resource`
|
|
161
|
-
- OAuth provider `resources` and the curated `mcpResource`
|
|
162
|
-
- `Auth.getProviderAccessToken(request, providerId)`
|
|
163
|
-
- `Auth.verifyOAuthAccessToken(tokenOrRequest, { audience, scopes })`
|
|
164
|
-
|
|
165
|
-
Generic OAuth providers use Better Auth 1.7's official `GenericOAuthConfig`,
|
|
166
|
-
standard social sign-in and `/api/auth/callback/:id` path.
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
# Cloudflare low-level composition
|
|
2
|
-
|
|
3
|
-
This guide moved into the handbook: [`docs/handbook/cloudflare/low-level-composition.md`](handbook/cloudflare/low-level-composition.md).
|
|
4
|
-
|
|
5
|
-
The handbook ships inside the `@aotter/mantle` package under `node_modules/@aotter/mantle/docs/handbook/` and describes the installed release.
|
|
@@ -1,65 +0,0 @@
|
|
|
1
|
-
# Consumer onboarding audit for 0.1.3
|
|
2
|
-
|
|
3
|
-
Scope: source skill install → pinned npm package → CLI → generated skills and
|
|
4
|
-
handbook → application manifest and Admin customization. This is maintainer
|
|
5
|
-
evidence, not a release announcement. Baseline: develop `b90cebbd`, package
|
|
6
|
-
version `0.1.3-alpha.5`; the package version alone does not identify unreleased
|
|
7
|
-
commits on develop. Tracking: [#1042](https://github.com/aotter/mantle/issues/1042).
|
|
8
|
-
|
|
9
|
-
## Clean source install
|
|
10
|
-
|
|
11
|
-
Executed in an empty temporary directory:
|
|
12
|
-
|
|
13
|
-
```sh
|
|
14
|
-
npx --yes skills add aotter/mantle --skill install --agent codex --yes
|
|
15
|
-
```
|
|
16
|
-
|
|
17
|
-
Observed output: repository cloned, **7 skills found**, **1 selected**, copied
|
|
18
|
-
to `./.agents/skills/install`. `skills-lock.json` records source `aotter/mantle`,
|
|
19
|
-
source type `github`, and source path `skills/install/SKILL.md`. The installed
|
|
20
|
-
file's hash in that lock was
|
|
21
|
-
`8a6fd26aea97ae8bdf3e05fef22196c247b3f95aa049204a6ac51259d87e4e29`.
|
|
22
|
-
No SDK, handbook or application is installed by that command. The explicit
|
|
23
|
-
Codex and noninteractive flags make the audited destination reproducible;
|
|
24
|
-
other selected agents/global scope can use another destination.
|
|
25
|
-
|
|
26
|
-
This source install follows the repository's default ref. It does not test the
|
|
27
|
-
unreleased edits in this PR or establish an npm version. The packed-consumer
|
|
28
|
-
check below tests this branch's shipped instructions separately.
|
|
29
|
-
|
|
30
|
-
## White-box path and fixes
|
|
31
|
-
|
|
32
|
-
| Stage / owner | Finding before this change | Correction |
|
|
33
|
-
|---|---|---|
|
|
34
|
-
| README → external skills installer | Prompt told the agent to read `skills/install/SKILL.md` and `docs/agent-prompts.md`, neither installed there. | Read the installer-reported destination, then the installed SDK's embedded docs. |
|
|
35
|
-
| `skills/install/SKILL.md` | Bootstrap Git instructions did not explicitly hand off to the installed package's own install skill; `docs/...` root was implicit. Host interview was repeated. | Explicit package-root resolution and version authority; ask only for missing requirements. |
|
|
36
|
-
| Install → CLI | It was possible to try the local CLI before installing Core; `generate` in an empty directory fails rather than creating a project. | Spell out package installation before CLI and manifest authoring before generation. |
|
|
37
|
-
| Quickstart versions | Floating `latest` dependency examples contradicted exact-pin advice. | Resolve the requested channel once and save exact Mantle versions before the first build. |
|
|
38
|
-
| `mantle skills` | Correctly projected four project skills, but success output did not tell the agent what to read next. | Print the projected develop skill and installed handbook entry. Document overwrite, drift and opt-in behavior. |
|
|
39
|
-
| `sync-package-docs.mjs` → npm `files` | Docs and all seven skills already shipped; presence checks did not protect the new entry paths or exercise projection from the tarball. | Assert handbook/skill files and byte-identical `.agents`/`.claude` projection in the existing packed-consumer check. |
|
|
40
|
-
| View concepts → grammar/runtime | Concepts denied internal Views and recommended SQL for every new View; reference `surface` table omitted `internal`. SQL admission text was stale. | Match implemented surfaces, typed declarative reads, SQLite admission sandbox and native-dialect limits. |
|
|
41
|
-
| Manifest reference | View's allowed spec keys omitted `cache`; Schema list-column prose omitted native columns. | Reconcile with parser and Admin UI checker. |
|
|
42
|
-
| Plugin/update skills | Assumed conventional source paths, missed regeneration after plugin manifest edits, and treated every View as publicly callable. | Use actual project paths, regenerate the plan, verify the declared surface and distinguish stable index from target prerelease docs. |
|
|
43
|
-
| Feature discovery | No task-to-manifest capability map or usable human entry; reference was buried after host-specific sections. | Add overview, capability table and task guides; move reference before host guides without breaking existing URLs. |
|
|
44
|
-
| Typed query discovery | APIs existed but lacked a complete internal-View calling example or clear reader authorization distinction. | Explain generated params/results, runtime `result` versus REST `data`, SQL `unknown`, indexed reader limits and plan-based emission. |
|
|
45
|
-
| Admin requests → theme/develop skills | Theme skill targeted visitor source; no routing from an Admin request to manifest-controlled presentation. | Route to Admin guide, with Schema/View/Procedure rendering table and supported customization ceiling. |
|
|
46
|
-
| Auth operations | Store-bound session cache behavior existed in code/ADR but was missing from the handbook. | Explain store identity, preparation order and KV propagation limits. |
|
|
47
|
-
|
|
48
|
-
## Verification and regression coverage
|
|
49
|
-
|
|
50
|
-
- `packages/mantle-spec/test/handbook-contract.test.ts`: complete handbook YAML
|
|
51
|
-
examples parse and validate; navigation covers pages; relative links resolve.
|
|
52
|
-
- `packages/mantle/test/cli/generate.test.ts`: extracts the new internal-View
|
|
53
|
-
YAML and TypeScript directly from the handbook, generates bindings and runs
|
|
54
|
-
strict TypeScript checking on the real example.
|
|
55
|
-
- CLI surface/projection tests assert the concrete next-read destinations;
|
|
56
|
-
existing drift checks verify `--check` is read-only.
|
|
57
|
-
- `scripts/check-optional-packages.mjs`: packs and installs the actual Core
|
|
58
|
-
tarball, checks embedded entry pages/skills, runs `skills` and `skills --check`,
|
|
59
|
-
and compares each project projection byte-for-byte with the installed package.
|
|
60
|
-
- Repository gate: `pnpm check`. Exact execution results and any environment
|
|
61
|
-
limitations are recorded in the PR, rather than frozen as a future guarantee.
|
|
62
|
-
|
|
63
|
-
No npm publish, tag, deployment or grammar change is part of this audit. Source
|
|
64
|
-
skill consumers receive the corrections only once they reach the installed Git
|
|
65
|
-
ref; npm consumers receive them only in a package built from the corrected tree.
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
# Deferred lifecycle hooks on Cloudflare Queues
|
|
2
|
-
|
|
3
|
-
This guide moved into the handbook: [`docs/handbook/cloudflare/deferred-hooks-queues.md`](handbook/cloudflare/deferred-hooks-queues.md).
|
|
4
|
-
|
|
5
|
-
The handbook ships inside the `@aotter/mantle` package under `node_modules/@aotter/mantle/docs/handbook/` and describes the installed release.
|
package/docs/design-atoms.md
DELETED
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
# Manifest reference has moved
|
|
2
|
-
|
|
3
|
-
The version-matched [handbook](handbook/reference/manifest.md) is the single
|
|
4
|
-
grammar reference. This compatibility URL contains no duplicate grammar.
|
|
5
|
-
|
|
6
|
-
- [Four atoms](handbook/concepts/four-atoms.md)
|
|
7
|
-
- [Schema](handbook/reference/schema.md)
|
|
8
|
-
- [View](handbook/reference/view.md)
|
|
9
|
-
- [Procedure and builtin handlers](handbook/reference/procedure.md)
|
|
10
|
-
- [Trigger](handbook/reference/trigger.md)
|
|
11
|
-
- [Authorization](handbook/reference/authorization.md)
|
|
12
|
-
- [Diagnostics](handbook/reference/diagnostics.md)
|
|
13
|
-
|
|
14
|
-
Builder consumers must load these pages from the same installed SDK as their
|
|
15
|
-
runtime. The old Markdown section headings are retired; see
|
|
16
|
-
[#837](https://github.com/aotter/mantle/issues/837).
|