@spacefast/common 0.2.1 → 0.4.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.
Files changed (226) hide show
  1. package/dist/agents/marketplace-prompts.d.ts +1 -0
  2. package/dist/agents/marketplace-prompts.js +6 -0
  3. package/dist/agents/registry/core.d.ts +4 -12
  4. package/dist/agents/registry/core.js +7 -28
  5. package/dist/config/domains.d.ts +10 -8
  6. package/dist/config/domains.js +4 -7
  7. package/dist/contracts/access-core.d.ts +135 -0
  8. package/dist/contracts/access-core.js +242 -0
  9. package/dist/contracts/access-profiles.d.ts +8 -8
  10. package/dist/contracts/access-profiles.js +8 -8
  11. package/dist/contracts/access.d.ts +14 -103
  12. package/dist/contracts/access.js +10 -210
  13. package/dist/contracts/activity.d.ts +54 -55
  14. package/dist/contracts/activity.js +38 -9
  15. package/dist/contracts/api-keys.d.ts +69 -26
  16. package/dist/contracts/api-keys.js +29 -2
  17. package/dist/contracts/application-journal.d.ts +197 -4
  18. package/dist/contracts/application-journal.js +97 -16
  19. package/dist/contracts/auth.d.ts +20 -0
  20. package/dist/contracts/auth.js +18 -0
  21. package/dist/contracts/beta.d.ts +13 -0
  22. package/dist/contracts/beta.js +28 -0
  23. package/dist/contracts/billing.d.ts +2 -2
  24. package/dist/contracts/bootstrap.d.ts +23 -6
  25. package/dist/contracts/builds.d.ts +24 -4
  26. package/dist/contracts/builds.js +16 -4
  27. package/dist/contracts/channels.d.ts +43 -0
  28. package/dist/contracts/channels.js +22 -6
  29. package/dist/contracts/comments.d.ts +49 -0
  30. package/dist/contracts/comments.js +61 -2
  31. package/dist/contracts/commerce.d.ts +19 -13
  32. package/dist/contracts/connector-access.d.ts +28 -0
  33. package/dist/contracts/connector-access.js +31 -0
  34. package/dist/contracts/connectors.d.ts +2382 -0
  35. package/dist/contracts/connectors.js +941 -0
  36. package/dist/contracts/content-contract-verification.d.ts +112 -58
  37. package/dist/contracts/content-contract-verification.js +42 -54
  38. package/dist/contracts/content-model-emit.d.ts +97 -0
  39. package/dist/contracts/content-model-emit.js +306 -0
  40. package/dist/contracts/content-model-sdk.d.ts +101 -0
  41. package/dist/contracts/content-model-sdk.js +232 -0
  42. package/dist/contracts/{content-program.d.ts → content-model.d.ts} +338 -82
  43. package/dist/contracts/{content-program.js → content-model.js} +291 -63
  44. package/dist/contracts/content-platform-fixture.d.ts +380 -110
  45. package/dist/contracts/content-platform-fixture.js +8 -8
  46. package/dist/contracts/content-sync.d.ts +197 -74
  47. package/dist/contracts/content-sync.js +98 -37
  48. package/dist/contracts/content.d.ts +30 -422
  49. package/dist/contracts/content.js +34 -294
  50. package/dist/contracts/dashboard-prefs.d.ts +10 -3
  51. package/dist/contracts/dashboard-prefs.js +6 -3
  52. package/dist/contracts/data-location.d.ts +9 -0
  53. package/dist/contracts/data-location.js +7 -0
  54. package/dist/contracts/deployment-comparison.d.ts +67 -0
  55. package/dist/contracts/deployment-comparison.js +68 -0
  56. package/dist/contracts/device-auth.d.ts +55 -11
  57. package/dist/contracts/domains.d.ts +40 -16
  58. package/dist/contracts/domains.js +23 -0
  59. package/dist/contracts/enums.d.ts +1 -10
  60. package/dist/contracts/enums.js +0 -15
  61. package/dist/contracts/error-code-meta.d.ts +388 -20
  62. package/dist/contracts/error-code-meta.js +201 -5
  63. package/dist/contracts/error-codes.d.ts +17 -4
  64. package/dist/contracts/error-codes.js +109 -10
  65. package/dist/contracts/events.d.ts +5 -0
  66. package/dist/contracts/events.js +12 -3
  67. package/dist/contracts/execution.d.ts +5 -1
  68. package/dist/contracts/execution.js +4 -0
  69. package/dist/contracts/feature-lifecycle.d.ts +53 -20
  70. package/dist/contracts/feature-lifecycle.js +65 -23
  71. package/dist/contracts/features.d.ts +57 -31
  72. package/dist/contracts/features.js +0 -1
  73. package/dist/contracts/feedback.d.ts +124 -0
  74. package/dist/contracts/feedback.js +64 -0
  75. package/dist/contracts/fixtures/content-model-sdk-v1.generated.d.ts +129 -0
  76. package/dist/contracts/fixtures/content-model-sdk-v1.generated.js +48 -0
  77. package/dist/contracts/fixtures/content-platform-v1.json +101 -49
  78. package/dist/contracts/frame-session.d.ts +60 -10
  79. package/dist/contracts/frame-session.js +52 -12
  80. package/dist/contracts/functions.d.ts +28 -2
  81. package/dist/contracts/functions.js +25 -2
  82. package/dist/contracts/grant-copy.d.ts +2 -0
  83. package/dist/contracts/grant-copy.js +2 -0
  84. package/dist/contracts/grants-core.d.ts +95 -0
  85. package/dist/contracts/grants-core.js +435 -0
  86. package/dist/contracts/grants.d.ts +13 -84
  87. package/dist/contracts/grants.js +21 -369
  88. package/dist/contracts/ids-core.d.ts +11 -0
  89. package/dist/contracts/ids-core.js +14 -0
  90. package/dist/contracts/ids.d.ts +7 -4
  91. package/dist/contracts/ids.js +12 -4
  92. package/dist/contracts/internal.d.ts +18 -0
  93. package/dist/contracts/internal.js +19 -0
  94. package/dist/contracts/mcp.d.ts +8 -18
  95. package/dist/contracts/mcp.js +2 -23
  96. package/dist/contracts/notifications.d.ts +4 -1
  97. package/dist/contracts/notifications.js +1 -0
  98. package/dist/contracts/oauth-resources.d.ts +55 -9
  99. package/dist/contracts/oauth-resources.js +64 -1
  100. package/dist/contracts/oauth-scope-actions.d.ts +27 -3
  101. package/dist/contracts/oauth-scope-actions.js +18 -8
  102. package/dist/contracts/operations.d.ts +1 -1
  103. package/dist/contracts/partner-account.d.ts +629 -0
  104. package/dist/contracts/partner-account.js +18 -0
  105. package/dist/contracts/principal-assertion.d.ts +74 -1
  106. package/dist/contracts/principal-assertion.js +67 -3
  107. package/dist/contracts/publish-archive.d.ts +22 -1
  108. package/dist/contracts/push-new.d.ts +3 -3
  109. package/dist/contracts/push-new.js +1 -1
  110. package/dist/contracts/quotas.js +2 -1
  111. package/dist/contracts/repository-connections.d.ts +10 -6
  112. package/dist/contracts/repository-connections.js +15 -0
  113. package/dist/contracts/resources.d.ts +6 -5
  114. package/dist/contracts/resources.js +7 -0
  115. package/dist/contracts/route-inventory.d.ts +74 -19
  116. package/dist/contracts/route-inventory.js +20 -6
  117. package/dist/contracts/runtime-api.d.ts +415 -4
  118. package/dist/contracts/runtime-api.js +60 -15
  119. package/dist/contracts/runtime-app.d.ts +6 -1
  120. package/dist/contracts/runtime-components.d.ts +646 -18
  121. package/dist/contracts/runtime-components.js +304 -188
  122. package/dist/contracts/runtime-services.d.ts +15 -0
  123. package/dist/contracts/runtime-services.js +25 -0
  124. package/dist/contracts/runtime-storage.d.ts +32 -0
  125. package/dist/contracts/runtime-storage.js +37 -0
  126. package/dist/contracts/source-workspaces.d.ts +511 -0
  127. package/dist/contracts/source-workspaces.js +276 -0
  128. package/dist/contracts/space-config-spacefast.d.ts +394 -0
  129. package/dist/contracts/space-config-spacefast.js +70 -0
  130. package/dist/contracts/space-config.d.ts +177 -90
  131. package/dist/contracts/space-config.js +77 -92
  132. package/dist/contracts/spaces.d.ts +132 -24
  133. package/dist/contracts/spaces.js +77 -13
  134. package/dist/contracts/superadmin-connectors.d.ts +371 -0
  135. package/dist/contracts/superadmin-connectors.js +61 -0
  136. package/dist/contracts/superadmin-emails.d.ts +1 -1
  137. package/dist/contracts/superadmin-emails.js +1 -1
  138. package/dist/contracts/superadmin-entities.d.ts +105 -0
  139. package/dist/contracts/superadmin-entities.js +64 -0
  140. package/dist/contracts/superadmin-runtime.d.ts +35 -116
  141. package/dist/contracts/superadmin-runtime.js +13 -69
  142. package/dist/contracts/superadmin-search.d.ts +12 -14
  143. package/dist/contracts/superadmin-search.js +2 -2
  144. package/dist/contracts/superadmin-spaces.d.ts +15 -72
  145. package/dist/contracts/superadmin-spaces.js +2 -7
  146. package/dist/contracts/superadmin-teams.d.ts +12 -0
  147. package/dist/contracts/superadmin-teams.js +7 -1
  148. package/dist/contracts/superadmin-tenants.d.ts +44 -16
  149. package/dist/contracts/superadmin.d.ts +2 -2
  150. package/dist/contracts/tags.d.ts +12 -12
  151. package/dist/contracts/teams.d.ts +29 -1
  152. package/dist/contracts/teams.js +24 -2
  153. package/dist/contracts/tenants.d.ts +98 -0
  154. package/dist/contracts/tenants.js +20 -0
  155. package/dist/contracts/transfers.d.ts +92 -0
  156. package/dist/contracts/transfers.js +37 -0
  157. package/dist/contracts/usage.d.ts +9 -1
  158. package/dist/contracts/usage.js +2 -0
  159. package/dist/contracts/visual-review.d.ts +448 -0
  160. package/dist/contracts/visual-review.js +156 -0
  161. package/dist/contracts/wordpress-php-toolkit.json +9 -0
  162. package/dist/contracts/work-mode.d.ts +24 -0
  163. package/dist/contracts/work-mode.js +17 -0
  164. package/dist/contracts/wp-cli.d.ts +66 -0
  165. package/dist/contracts/wp-cli.js +68 -0
  166. package/dist/contracts/zero-catalog.d.ts +29 -0
  167. package/dist/contracts/zero-catalog.js +55 -0
  168. package/dist/contracts/zero-platform-abilities.generated.d.ts +31 -0
  169. package/dist/contracts/zero-platform-abilities.generated.js +373 -0
  170. package/dist/contracts/zero-spacefast.d.ts +444 -0
  171. package/dist/contracts/zero-spacefast.js +149 -0
  172. package/dist/contracts/zero-types.d.ts +47 -0
  173. package/dist/contracts/zero-types.js +263 -0
  174. package/dist/contracts/zero.d.ts +781 -14
  175. package/dist/contracts/zero.js +204 -10
  176. package/dist/dashboard-paths/index.d.ts +2 -2
  177. package/dist/dashboard-paths/route-reservations.generated.d.ts +2 -2
  178. package/dist/dashboard-paths/route-reservations.generated.js +5 -0
  179. package/dist/docs/agent-prose.d.ts +1 -1
  180. package/dist/docs/agent-prose.js +15 -18
  181. package/dist/docs/agent-setup.d.ts +1 -1
  182. package/dist/docs/agent-setup.js +5 -13
  183. package/dist/docs/catalog.d.ts +64 -28
  184. package/dist/docs/catalog.js +155 -28
  185. package/dist/docs/error-docs.d.ts +365 -17
  186. package/dist/docs/error-docs.js +369 -21
  187. package/dist/docs/reference-urls.js +1 -1
  188. package/dist/docs/skills.d.ts +84 -84
  189. package/dist/docs/skills.js +66 -47
  190. package/dist/docs/start-prompts.d.ts +14 -0
  191. package/dist/docs/start-prompts.js +20 -0
  192. package/dist/utils/account-labels.d.ts +7 -0
  193. package/dist/utils/account-labels.js +15 -0
  194. package/dist/utils/auth.d.ts +1 -0
  195. package/dist/utils/auth.js +1 -0
  196. package/dist/utils/credential-policy.d.ts +22 -1
  197. package/dist/utils/credential-policy.js +55 -6
  198. package/dist/utils/local-space-state.d.ts +7 -0
  199. package/dist/utils/local-space-state.js +7 -0
  200. package/dist/utils/logger.d.ts +34 -0
  201. package/dist/utils/logger.js +144 -0
  202. package/dist/utils/page-routes.d.ts +9 -0
  203. package/dist/utils/page-routes.js +82 -0
  204. package/dist/utils/pages.d.ts +2 -0
  205. package/dist/utils/pages.js +7 -0
  206. package/dist/utils/publish-form-data.d.ts +2 -0
  207. package/dist/utils/publish-form-data.js +2 -0
  208. package/dist/utils/publish-policy-spacefast.d.ts +13 -0
  209. package/dist/utils/publish-policy-spacefast.js +117 -0
  210. package/dist/utils/publish-policy.d.ts +22 -16
  211. package/dist/utils/publish-policy.fixtures.json +15 -0
  212. package/dist/utils/publish-policy.js +62 -139
  213. package/dist/utils/query-client.js +9 -1
  214. package/dist/utils/runtime-upload.d.ts +4 -0
  215. package/dist/utils/runtime-upload.js +5 -0
  216. package/dist/utils/space-config.d.ts +2 -3
  217. package/dist/utils/space-config.js +1 -1
  218. package/dist/utils/uploaded-source.d.ts +4 -0
  219. package/dist/utils/uploaded-source.js +12 -0
  220. package/dist/visual-review.d.ts +4 -0
  221. package/dist/visual-review.js +208 -0
  222. package/dist/vocabulary.d.ts +38 -0
  223. package/dist/vocabulary.js +55 -0
  224. package/package.json +7 -2
  225. package/dist/agents/registry/deeplink-probes.d.ts +0 -23
  226. package/dist/agents/registry/deeplink-probes.js +0 -18
@@ -50,10 +50,10 @@ export declare const DOCS_CATALOG: readonly [{
50
50
  readonly slug: "spaces/rename";
51
51
  readonly title: "Rename a space";
52
52
  readonly kind: "guide";
53
- readonly tier: "full";
53
+ readonly tier: "essential";
54
54
  readonly summary: "Change a space slug and its managed view.fast address without breaking old links.";
55
- readonly keywords: readonly ["space", "rename", "slug", "view.fast", "redirect", "managed hostname"];
56
- readonly url: `${string}/operate/spaces`;
55
+ readonly keywords: readonly ["space", "rename", "slug", "view.fast", "redirect", "managed hostname", "rename a space", "change space name", "change space url"];
56
+ readonly url: `${string}/cli/spaces`;
57
57
  readonly body: "Run `sf spaces update --space <space> --slug <new-slug> --wait`, or PATCH `/v1/spaces/{spaceId}` with `{ \"slug\": \"<new-slug>\" }`. The managed view.fast hostname changes with the slug. Former managed addresses and branch aliases redirect directly to their current counterparts with a temporary, path- and query-preserving 307 for the life of the space unless an operator explicitly releases them. Custom domains stay attached, and immutable version URLs do not change.";
58
58
  }, {
59
59
  readonly slug: "versions-and-rollback";
@@ -203,11 +203,11 @@ export declare const DOCS_CATALOG: readonly [{
203
203
  readonly slug: "access-control";
204
204
  readonly title: "Access control";
205
205
  readonly kind: "guide";
206
- readonly tier: "full";
207
- readonly summary: "Create scoped Grants, invite People, and manage Links or credentials.";
208
- readonly keywords: readonly ["access", "share", "people", "links", "private", "team", "public"];
206
+ readonly tier: "essential";
207
+ readonly summary: "Make a space public, share private access, and understand permissions and scopes.";
208
+ readonly keywords: readonly ["access", "share", "people", "links", "private", "team", "public", "make space public", "share a space", "open to everyone", "permissions and scopes", "grant access", "who can access"];
209
209
  readonly url: `${string}/access`;
210
- readonly body: "Use `sf share grant`, `sf share people`, `sf share link`, `sf share password`, or `sf share token`. Inspect one route with `sf share check`; every audience uses the same path, capability, target, and constraint evaluator.";
210
+ readonly body: "New spaces are private. Make the live space public with `sf share grant --to public --role viewer --path '/**' --target live`. Use People or Links for private sharing. Permissions name allowed actions; scopes limit which resources a credential can reach.";
211
211
  }, {
212
212
  readonly slug: "redirects";
213
213
  readonly title: "Redirects";
@@ -252,7 +252,16 @@ export declare const DOCS_CATALOG: readonly [{
252
252
  readonly summary: "A capsule with a database: schema, queries, mutations, endpoints.";
253
253
  readonly keywords: readonly ["zero", "capsule", "database", "schema", "query", "mutation", "endpoint", "transaction", "sql", "sf dev"];
254
254
  readonly url: `${string}/zero-runtime`;
255
- readonly body: "Zero is for apps where the data is the point. Write one capsule — schema, queries, mutations, endpoints — start it locally with `sf dev`, and `sf publish` puts it live with its own database and dedicated runtime site on every plan.";
255
+ readonly body: "Zero is for apps where the data is the point. Write one capsule — schema, queries, mutations, endpoints — start it locally with `sf dev`, and `sf publish` puts it live with its own database and runtime site on every plan.";
256
+ }, {
257
+ readonly slug: "zero-connectors";
258
+ readonly title: "Zero connectors";
259
+ readonly kind: "guide";
260
+ readonly tier: "full";
261
+ readonly summary: "Declare connector roles, bind accounts to a Space, and connect visitor accounts.";
262
+ readonly keywords: readonly ["zero", "connectors", "roles", "team", "owner", "visitor", "serving", "bindings", "ConnectorGate", "Linear", "Workers", "env.CONNECTORS", "env.ZERO", "audit", "runs"];
263
+ readonly url: `${string}/zero-connectors`;
264
+ readonly body: "Declare roles with connector({ as: 'team' | 'owner' | 'visitor', connector: 'linear' }). Team roles require a bound team connection with a serving grant; owner roles require the binder's personal connection and a private Space. Visitor roles use each signed-in visitor's own account. Call ctx.connectors.<role>.<tool>(args) and render connection or approval states with ConnectorGate. Workers use env.CONNECTORS and, when a capsule is attached, env.ZERO.query(name, ...args) and env.ZERO.mutate(name, ...args). Inspect calls on the connector runs page by origin and Space.";
256
265
  }, {
257
266
  readonly slug: "runtimes/functions";
258
267
  readonly title: "Spacefast Functions";
@@ -379,6 +388,15 @@ export declare const DOCS_CATALOG: readonly [{
379
388
  readonly keywords: readonly ["init", "config", "scaffold", "sf.jsonc", "setup"];
380
389
  readonly url: `${string}/cli`;
381
390
  readonly body: "`sf init` detects your framework and writes a starter `sf.jsonc` so subsequent `sf publish` runs are zero-config.";
391
+ }, {
392
+ readonly slug: "feedback";
393
+ readonly title: "sf feedback";
394
+ readonly kind: "cli";
395
+ readonly tier: "essential";
396
+ readonly summary: "Send product, docs, or error feedback to Spacefast.";
397
+ readonly keywords: readonly ["feedback", "report", "bug", "docs", "error", "request id", "sf feedback"];
398
+ readonly url: `${string}/cli`;
399
+ readonly body: "Run `sf feedback --message \"Describe what happened\"`. For an API error, add `--category bug`, `--error-code <code>`, and `--request-id <requestId>` from the error output.";
382
400
  }, {
383
401
  readonly slug: "claim";
384
402
  readonly title: "sf spaces claim";
@@ -388,15 +406,24 @@ export declare const DOCS_CATALOG: readonly [{
388
406
  readonly keywords: readonly ["claim", "anonymous", "attach", "token", "adopt", "spaces"];
389
407
  readonly url: `${string}/cli`;
390
408
  readonly body: "After an agent publishes anonymously, run `sf spaces claim` with the space key to bind the space to your account.";
409
+ }, {
410
+ readonly slug: "cli/spaces/check";
411
+ readonly title: "sf spaces check";
412
+ readonly kind: "cli";
413
+ readonly tier: "essential";
414
+ readonly summary: "Check whether a Space name and its managed hostname are available.";
415
+ readonly keywords: readonly ["spaces", "check", "name availability", "slug availability", "hostname availability", "view.fast", "is this name free", "taken"];
416
+ readonly url: `${string}/cli/spaces`;
417
+ readonly body: "Run `sf spaces check <name> [--team <team>]` to check a name. The command reports the team-scoped Space slug and the global `view.fast` hostname separately. The result is advisory. A create or rename operation can still lose a race. Do not check availability with an HTTP request to the hostname.";
391
418
  }, {
392
419
  readonly slug: "cli/spaces";
393
420
  readonly title: "sf spaces";
394
421
  readonly kind: "cli";
395
- readonly tier: "full";
396
- readonly summary: "List, inspect, download, duplicate, transfer, and remove spaces.";
397
- readonly keywords: readonly ["spaces", "space", "ls", "get", "download", "duplicate", "rm", "transfer"];
398
- readonly url: `${string}/cli`;
399
- readonly body: "The `sf spaces` group manages spaces: `ls`, `get`, `claim`, `download`, `duplicate`, `transfer`, and `rm`. Use `sf spaces download --version <ref>` to retrieve one immutable version.";
422
+ readonly tier: "essential";
423
+ readonly summary: "Check, list, inspect, download, duplicate, transfer, and delete spaces.";
424
+ readonly keywords: readonly ["spaces", "space", "check", "availability", "ls", "get", "download", "duplicate", "rm", "remove", "delete", "delete a space", "remove a space", "transfer"];
425
+ readonly url: `${string}/cli/spaces`;
426
+ readonly body: "Use `sf spaces rm --space <space>` to delete a space; add `--yes` to skip confirmation. The `sf spaces` group also includes `check`, `ls`, `get`, `claim`, `download`, `duplicate`, and `transfer`.";
400
427
  }, {
401
428
  readonly slug: "cli/versions";
402
429
  readonly title: "sf versions";
@@ -473,11 +500,11 @@ export declare const DOCS_CATALOG: readonly [{
473
500
  readonly slug: "cli/api-keys";
474
501
  readonly title: "sf api-keys";
475
502
  readonly kind: "cli";
476
- readonly tier: "full";
477
- readonly summary: "Create and revoke API keys for the Spacefast API.";
478
- readonly keywords: readonly ["api-keys", "api key", "token", "create", "revoke", "list", "credential"];
479
- readonly url: `${string}/cli`;
480
- readonly body: "`sf api-keys create` mints a bearer key (shown once, masked in `--json`); `sf api-keys list` and `sf api-keys revoke` manage existing keys.";
503
+ readonly tier: "essential";
504
+ readonly summary: "Create, list, and revoke API keys with explicit permissions and scopes.";
505
+ readonly keywords: readonly ["api-keys", "api key", "api keys", "create api key", "revoke api key", "list api keys", "token", "credential", "permissions", "scopes", "permissions and scopes"];
506
+ readonly url: `${string}/cli/api-keys`;
507
+ readonly body: "Run `sf api-keys create` to mint a bearer key, `sf api-keys list` to inspect keys, and `sf api-keys revoke` to turn one off. Presets select a permission bundle; each key is scoped to its team. The secret is shown once and masked in `--json` output.";
481
508
  }, {
482
509
  readonly slug: "cli/analytics";
483
510
  readonly title: "sf analytics";
@@ -577,6 +604,15 @@ export declare const DOCS_CATALOG: readonly [{
577
604
  readonly keywords: readonly ["api", "teams", "team", "members", "invitations", "endpoint"];
578
605
  readonly url: `${string}/api`;
579
606
  readonly body: "Create teams, list members, and manage invitations programmatically. Webhooks and API keys are team-scoped.";
607
+ }, {
608
+ readonly slug: "api/connectors";
609
+ readonly title: "Connectors API";
610
+ readonly kind: "api";
611
+ readonly tier: "reference";
612
+ readonly summary: "Connect tool sources, manage connections and policy, and run tools over HTTP.";
613
+ readonly keywords: readonly ["api", "connectors", "connections", "tools", "policy", "runs", "mcp", "openapi", "graphql", "endpoint"];
614
+ readonly url: `${string}/api`;
615
+ readonly body: "Register OpenAPI, GraphQL, or remote MCP sources as team connectors; connect accounts whose credentials stay server-side; set an ordered tool policy; and run a single tool or a code program, with approvals when a rule asks for them.";
580
616
  }, {
581
617
  readonly slug: "api/docs";
582
618
  readonly title: "Docs API (GET /v1/docs)";
@@ -611,17 +647,17 @@ export declare const DOCS_CATALOG: readonly [{
611
647
  readonly tier: "reference";
612
648
  readonly summary: "The tenant-facing partner API for running Spacefast as infra.";
613
649
  readonly keywords: readonly ["api", "partner", "tenant", "infra", "openapi", "multi-tenant", "white label"];
614
- readonly url: `${string}/partners`;
650
+ readonly url: string;
615
651
  readonly body: `There is no partner route tree. Partners call the same \`/v1\` routes as everyone else: successes carry a \`{ data }\` envelope and failures are RFC 9457 problem documents (\`application/problem+json\` with a stable \`code\`), exactly as elsewhere in the API. A tenant-rooted credential's policy scope and response projection decide what it sees. "Partner" is a spec visibility tier: those operations, plus tenants and principals, are published as a second OpenAPI document at ${string}/openapi.partner.json, rendered at ${string}. Point \`openapi-typescript\` at that document for types. Configuration is not a set of endpoints: a tenant declares its integration in one designated space's published manifest (see \`partner/system-space\`).`;
616
652
  }, {
617
653
  readonly slug: "partner/onboarding";
618
654
  readonly title: "Partner onboarding";
619
655
  readonly kind: "api";
620
656
  readonly tier: "reference";
621
- readonly summary: "Bootstrap a tenant: one key, one space, one designation, one publish.";
657
+ readonly summary: "Connect your backend using separate live and test environments.";
622
658
  readonly keywords: readonly ["partner", "onboarding", "tenant", "bootstrap", "partner_admin", "api key", "setup"];
623
- readonly url: `${string}/partners#onboarding`;
624
- readonly body: "Tenant creation is superadmin-side and mints one bootstrap tenant-rooted API key with the `partner_admin` preset (`tenants:*`, `principals:read`, and space/domain/publish actions over the tenant). From there it is four steps you drive yourself: create a space with that key, `PATCH /v1/tenants/{tenantId}` with `systemSpaceId` to designate it, publish the manifest, then read `manifestStatus` on `GET /v1/tenants/{tenantId}` to watch each declared item converge. Mint further keys through the normal API-key routes every one is bounded to a subset of its grantor's policy.";
659
+ readonly url: `${string}/v1/docs/pages/partner/onboarding`;
660
+ readonly body: "Enable partner access for your Spacefast team, then open Partners in the dashboard. Your team manages a linked live and test tenant. Each environment has its own customers, configuration, and credentials. Team owners and admins create tenant server keys in the dashboard or through `POST /v1/tenants/{tenantId}/api-keys`. The default key manages that environment, including bounded key creation and revocation. For your first integration, call the shared API from your backend and keep the key on your server. Create a space with the selected environment's key, designate it with `PATCH /v1/tenants/{tenantId}` using `systemSpaceId`, then publish your system manifest. Read `manifestStatus` on `GET /v1/tenants/{tenantId}` to check activation. To replace a key, create a new key, deploy it to your backend, then revoke the old key with `DELETE /v1/tenants/{tenantId}/api-keys/{apiKeyId}`. Test hosting uses simulated infrastructure; use the live environment to publish publicly reachable sites. Billing stays in your system. Spacefast plans grant features and enforce quotas.";
625
661
  }, {
626
662
  readonly slug: "partner/system-space";
627
663
  readonly title: "The system space";
@@ -629,8 +665,8 @@ export declare const DOCS_CATALOG: readonly [{
629
665
  readonly tier: "reference";
630
666
  readonly summary: "Your integration is a published space, so config versions and rolls back.";
631
667
  readonly keywords: readonly ["partner", "system space", "manifest", "sf.jsonc", "systemSpaceId", "manifestStatus", "gitops", "reconciliation", "white label"];
632
- readonly url: `${string}/partners#system-space`;
633
- readonly body: "A tenant designates one ordinary space as its system space, and that space's live version *is* the integration definition: a top-level `system` section in `sf.jsonc` (presentation, hostname apex, API origin, token issuers, event subscriptions) plus `_pages/` and `theme.json` as the defaults layer. One config language, one validation pipeline, one publish flow — and `sf rollback` rolls back your configuration with it. Finalize, promote, and rollback all reconcile declared state against current state. Presentation, pages, theme, and subscriptions apply immediately; hostnames, API origins, and token issuers enter `pending` until their DNS, TLS, or key-possession check passes. Dropping an item from the manifest deactivates it. Per-item state lands in `manifestStatus` (`{ key, state, detail, since }` plus the source version id) on `GET /v1/tenants/{tenantId}`. There are no imperative config routes: the fix for a failed item is a new publish. Secrets are never declared — webhook secrets and API keys are minted by their own routes.";
668
+ readonly url: `${string}/v1/docs/pages/partner/system-space`;
669
+ readonly body: "A tenant designates one ordinary space as its system space, and that space's live version *is* the integration definition: a top-level `system` section in `sf.jsonc` (presentation, hostname apex, API origin, token issuers, event subscriptions) plus `_pages/` and `theme.json` as the defaults layer. One config language, one validation pipeline, one publish flow — and `sf rollback` rolls back your configuration with it. Finalize, promote, and rollback all reconcile declared state against current state. Presentation, pages, theme, and subscriptions apply immediately; hostnames, API origins, and token issuers enter `pending` until their DNS, TLS, or key-possession check passes. Removing an issuer, API origin, subscription, or plan declaration reconciles that desired state. For a custom API origin, run an HTTPS gateway that forwards to the shared API hostname and overrides `x-spacefast-tenant-id` with your live tenant ID. Preserve paths, query strings, and Authorization. `domainSetup.api` returns the upstream origin, proxy headers, ownership DNS records, and verification URL. The gateway must forward that URL without redirects; Spacefast checks public DNS ownership and a fresh nonce-bound response over HTTPS. Existing site hostnames remain pinned to their namespace; changing a hostname default does not rename published sites. Per-item state lands in `manifestStatus` (`{ key, state, detail, since }` plus the source version id) on `GET /v1/tenants/{tenantId}`. There are no imperative config routes: the fix for a failed item is a new publish. Secrets are never declared — webhook secrets and API keys are minted by their own routes.";
634
670
  }, {
635
671
  readonly slug: "partner/tokens";
636
672
  readonly title: "Partner tokens";
@@ -638,8 +674,8 @@ export declare const DOCS_CATALOG: readonly [{
638
674
  readonly tier: "reference";
639
675
  readonly summary: "Let your own auth system mint tokens Spacefast verifies directly.";
640
676
  readonly keywords: readonly ["partner", "token", "jwt", "issuer", "eddsa", "ed25519", "auth", "partner_token", "audience", "revocation"];
641
- readonly url: `${string}/partners#tokens`;
642
- readonly body: "Your customers never need a Spacefast credential: your auth system mints standard JWT access tokens and Spacefast verifies them. Declare the issuer in the system-space manifest with its pinned Ed25519 public keys there is no issuer CRUD. The first publish returns `state: pending` with a challenge nonce in `manifestStatus`; sign it with the declared key and republish with the `proof` field, and the issuer activates. Proof of key possession lives in your repo next to the declaration. The token profile is strict: `typ` of `at+jwt`, `alg` of `EdDSA` only, the per-issuer minted `aud` (never a shared value), all of `iss`/`sub`/`client_id`/`jti`/`iat`/`exp` required, `exp - iat` at most 30 minutes, 300s clock skew; embedded or fetched keys are rejected. A verified token becomes a `partner_token` credential bound to one external principal, carrying a fixed least-privilege policy: publish, read, versions, and variables over that principal's subtree never tenant or principal management. Revoke by removing the issuer or rotating its keys; worst-case acceptance of a revoked token is the shorter of a 30s cache TTL and the token's own expiry.";
677
+ readonly url: `${string}/v1/docs/pages/partner/tokens`;
678
+ readonly body: "Your auth system mints customer JWTs that Spacefast verifies. Declare one issuer and up to five Ed25519 public keys with unique `kid` values in your system-space manifest. The first publish returns a pending status item with `audience` and `challenge`. Sign that challenge with each declared private key, then republish the JWTs in `proofs`. Every newly added or replaced key needs proof of possession. Customer tokens use `typ: at+jwt`, `alg: EdDSA`, the returned `audience` as `aud`, and all of `iss`, `sub`, `client_id`, `jti`, `iat`, and `exp`. The lifetime is at most 30 minutes, with 300 seconds of clock skew. Embedded and fetched keys are rejected. Each token grants publishing, reads, versions, and variables only for its own external principal. Tokens remain usable until expiry; `jti` does not make them single-use. To rotate without interrupting customers, publish the old and new public keys together. Sign the returned challenge with every new key and republish `proofs`. Existing keys remain active while the new keys await proof. Once activation completes, switch your signer to the new key, then publish again without the old key. Removing a key takes effect immediately and requires no new proof. The audience stays unchanged during rotation. An empty `tokenIssuers` array or removal of the field revokes the issuer. Issuer revocation invalidates all its tokens; individual customer tokens cannot be revoked separately.";
643
679
  }, {
644
680
  readonly slug: "partner/principals";
645
681
  readonly title: "Principals and ownership";
@@ -647,7 +683,7 @@ export declare const DOCS_CATALOG: readonly [{
647
683
  readonly tier: "reference";
648
684
  readonly summary: "External principals are your customer directory; spaces have exactly one owner.";
649
685
  readonly keywords: readonly ["partner", "principals", "external", "tenant", "ownership", "iam", "policy", "scope", "variables"];
650
- readonly url: `${string}/partners#principals`;
686
+ readonly url: `${string}/v1/docs/pages/partner/principals`;
651
687
  readonly body: "Your customers are external principals inside your tenant. `GET /v1/principals` lists them within the caller's granted scope (a tenant-rooted key sees the whole tenant) and `GET /v1/principals/external/{principalId}` reads one. There is no create route: a principal is upserted implicitly in the same transaction as its first owned resource, and its identity is the normalized id — the display casing you first sent is preserved but never authoritative. Every space has exactly one owner: a team, an external principal, or an open claim token. IAM actions stay generic nouns (`tenants:read`, `tenants:write`, `principals:read`) rather than a `partner:*` namespace, evaluated per route like every other action, so a partner credential's reach is a policy fact and not a router branch. Per-principal environment variables live under `/v1/principals/{principalType}/{principalId}/variables`.";
652
688
  }, {
653
689
  readonly slug: "partner/events";
@@ -656,6 +692,6 @@ export declare const DOCS_CATALOG: readonly [{
656
692
  readonly tier: "reference";
657
693
  readonly summary: "Tenant-owned webhooks, declared in the manifest — including customer email.";
658
694
  readonly keywords: readonly ["partner", "events", "webhook", "subscriptions", "notifications", "email", "signature", "hmac"];
659
- readonly url: `${string}/partners#events`;
695
+ readonly url: `${string}/v1/docs/pages/partner/events`;
660
696
  readonly body: "Webhooks are the one event primitive, and their ownership generalizes from teams to tenants. Declare subscriptions in the system-space manifest (`url` plus an `events` selection) and reconciliation creates, updates, or disables the rows; delivery uses the same `Spacefast-Signature` HMAC and dual-secret rotation as team webhooks, so verify the signature before trusting a payload. Email white-labeling is not a separate endpoint: subscribe to `principal.notification.*` events (claim link issued, security notice, publish receipt) and send them yourself in your own voice. For a partner tenant these events replace Spacefast-sent email to your customers — no active subscription means no send, and Spacefast never falls back to sending as itself to someone else's customer.";
661
697
  }, ...DocEntry[]];
@@ -51,10 +51,20 @@ const HAND_WRITTEN_DOCS_CATALOG = [
51
51
  slug: "spaces/rename",
52
52
  title: "Rename a space",
53
53
  kind: "guide",
54
- tier: "full",
54
+ tier: "essential",
55
55
  summary: "Change a space slug and its managed view.fast address without breaking old links.",
56
- keywords: ["space", "rename", "slug", "view.fast", "redirect", "managed hostname"],
57
- url: `${DOCS_BASE_URL}/operate/spaces`,
56
+ keywords: [
57
+ "space",
58
+ "rename",
59
+ "slug",
60
+ "view.fast",
61
+ "redirect",
62
+ "managed hostname",
63
+ "rename a space",
64
+ "change space name",
65
+ "change space url",
66
+ ],
67
+ url: `${DOCS_BASE_URL}/cli/spaces`,
58
68
  body: 'Run `sf spaces update --space <space> --slug <new-slug> --wait`, or PATCH `/v1/spaces/{spaceId}` with `{ "slug": "<new-slug>" }`. The managed view.fast hostname changes with the slug. Former managed addresses and branch aliases redirect directly to their current counterparts with a temporary, path- and query-preserving 307 for the life of the space unless an operator explicitly releases them. Custom domains stay attached, and immutable version URLs do not change.',
59
69
  },
60
70
  {
@@ -228,11 +238,25 @@ const HAND_WRITTEN_DOCS_CATALOG = [
228
238
  slug: "access-control",
229
239
  title: "Access control",
230
240
  kind: "guide",
231
- tier: "full",
232
- summary: "Create scoped Grants, invite People, and manage Links or credentials.",
233
- keywords: ["access", "share", "people", "links", "private", "team", "public"],
241
+ tier: "essential",
242
+ summary: "Make a space public, share private access, and understand permissions and scopes.",
243
+ keywords: [
244
+ "access",
245
+ "share",
246
+ "people",
247
+ "links",
248
+ "private",
249
+ "team",
250
+ "public",
251
+ "make space public",
252
+ "share a space",
253
+ "open to everyone",
254
+ "permissions and scopes",
255
+ "grant access",
256
+ "who can access",
257
+ ],
234
258
  url: `${DOCS_BASE_URL}/access`,
235
- body: "Use `sf share grant`, `sf share people`, `sf share link`, `sf share password`, or `sf share token`. Inspect one route with `sf share check`; every audience uses the same path, capability, target, and constraint evaluator.",
259
+ body: "New spaces are private. Make the live space public with `sf share grant --to public --role viewer --path '/**' --target live`. Use People or Links for private sharing. Permissions name allowed actions; scopes limit which resources a credential can reach.",
236
260
  },
237
261
  {
238
262
  slug: "redirects",
@@ -293,7 +317,33 @@ const HAND_WRITTEN_DOCS_CATALOG = [
293
317
  "sf dev",
294
318
  ],
295
319
  url: `${DOCS_BASE_URL}/zero-runtime`,
296
- body: "Zero is for apps where the data is the point. Write one capsule — schema, queries, mutations, endpoints — start it locally with `sf dev`, and `sf publish` puts it live with its own database and dedicated runtime site on every plan.",
320
+ body: "Zero is for apps where the data is the point. Write one capsule — schema, queries, mutations, endpoints — start it locally with `sf dev`, and `sf publish` puts it live with its own database and runtime site on every plan.",
321
+ },
322
+ {
323
+ slug: "zero-connectors",
324
+ title: "Zero connectors",
325
+ kind: "guide",
326
+ tier: "full",
327
+ summary: "Declare connector roles, bind accounts to a Space, and connect visitor accounts.",
328
+ keywords: [
329
+ "zero",
330
+ "connectors",
331
+ "roles",
332
+ "team",
333
+ "owner",
334
+ "visitor",
335
+ "serving",
336
+ "bindings",
337
+ "ConnectorGate",
338
+ "Linear",
339
+ "Workers",
340
+ "env.CONNECTORS",
341
+ "env.ZERO",
342
+ "audit",
343
+ "runs",
344
+ ],
345
+ url: `${DOCS_BASE_URL}/zero-connectors`,
346
+ body: "Declare roles with connector({ as: 'team' | 'owner' | 'visitor', connector: 'linear' }). Team roles require a bound team connection with a serving grant; owner roles require the binder's personal connection and a private Space. Visitor roles use each signed-in visitor's own account. Call ctx.connectors.<role>.<tool>(args) and render connection or approval states with ConnectorGate. Workers use env.CONNECTORS and, when a capsule is attached, env.ZERO.query(name, ...args) and env.ZERO.mutate(name, ...args). Inspect calls on the connector runs page by origin and Space.",
297
347
  },
298
348
  {
299
349
  slug: "runtimes/functions",
@@ -457,6 +507,16 @@ const HAND_WRITTEN_DOCS_CATALOG = [
457
507
  url: `${DOCS_BASE_URL}/cli`,
458
508
  body: "`sf init` detects your framework and writes a starter `sf.jsonc` so subsequent `sf publish` runs are zero-config.",
459
509
  },
510
+ {
511
+ slug: "feedback",
512
+ title: "sf feedback",
513
+ kind: "cli",
514
+ tier: "essential",
515
+ summary: "Send product, docs, or error feedback to Spacefast.",
516
+ keywords: ["feedback", "report", "bug", "docs", "error", "request id", "sf feedback"],
517
+ url: `${DOCS_BASE_URL}/cli`,
518
+ body: 'Run `sf feedback --message "Describe what happened"`. For an API error, add `--category bug`, `--error-code <code>`, and `--request-id <requestId>` from the error output.',
519
+ },
460
520
  {
461
521
  slug: "claim",
462
522
  title: "sf spaces claim",
@@ -467,15 +527,49 @@ const HAND_WRITTEN_DOCS_CATALOG = [
467
527
  url: `${DOCS_BASE_URL}/cli`,
468
528
  body: "After an agent publishes anonymously, run `sf spaces claim` with the space key to bind the space to your account.",
469
529
  },
530
+ {
531
+ slug: "cli/spaces/check",
532
+ title: "sf spaces check",
533
+ kind: "cli",
534
+ tier: "essential",
535
+ summary: "Check whether a Space name and its managed hostname are available.",
536
+ keywords: [
537
+ "spaces",
538
+ "check",
539
+ "name availability",
540
+ "slug availability",
541
+ "hostname availability",
542
+ "view.fast",
543
+ "is this name free",
544
+ "taken",
545
+ ],
546
+ url: `${DOCS_BASE_URL}/cli/spaces`,
547
+ body: "Run `sf spaces check <name> [--team <team>]` to check a name. The command reports the team-scoped Space slug and the global `view.fast` hostname separately. The result is advisory. A create or rename operation can still lose a race. Do not check availability with an HTTP request to the hostname.",
548
+ },
470
549
  {
471
550
  slug: "cli/spaces",
472
551
  title: "sf spaces",
473
552
  kind: "cli",
474
- tier: "full",
475
- summary: "List, inspect, download, duplicate, transfer, and remove spaces.",
476
- keywords: ["spaces", "space", "ls", "get", "download", "duplicate", "rm", "transfer"],
477
- url: `${DOCS_BASE_URL}/cli`,
478
- body: "The `sf spaces` group manages spaces: `ls`, `get`, `claim`, `download`, `duplicate`, `transfer`, and `rm`. Use `sf spaces download --version <ref>` to retrieve one immutable version.",
553
+ tier: "essential",
554
+ summary: "Check, list, inspect, download, duplicate, transfer, and delete spaces.",
555
+ keywords: [
556
+ "spaces",
557
+ "space",
558
+ "check",
559
+ "availability",
560
+ "ls",
561
+ "get",
562
+ "download",
563
+ "duplicate",
564
+ "rm",
565
+ "remove",
566
+ "delete",
567
+ "delete a space",
568
+ "remove a space",
569
+ "transfer",
570
+ ],
571
+ url: `${DOCS_BASE_URL}/cli/spaces`,
572
+ body: "Use `sf spaces rm --space <space>` to delete a space; add `--yes` to skip confirmation. The `sf spaces` group also includes `check`, `ls`, `get`, `claim`, `download`, `duplicate`, and `transfer`.",
479
573
  },
480
574
  {
481
575
  slug: "cli/versions",
@@ -561,11 +655,23 @@ const HAND_WRITTEN_DOCS_CATALOG = [
561
655
  slug: "cli/api-keys",
562
656
  title: "sf api-keys",
563
657
  kind: "cli",
564
- tier: "full",
565
- summary: "Create and revoke API keys for the Spacefast API.",
566
- keywords: ["api-keys", "api key", "token", "create", "revoke", "list", "credential"],
567
- url: `${DOCS_BASE_URL}/cli`,
568
- body: "`sf api-keys create` mints a bearer key (shown once, masked in `--json`); `sf api-keys list` and `sf api-keys revoke` manage existing keys.",
658
+ tier: "essential",
659
+ summary: "Create, list, and revoke API keys with explicit permissions and scopes.",
660
+ keywords: [
661
+ "api-keys",
662
+ "api key",
663
+ "api keys",
664
+ "create api key",
665
+ "revoke api key",
666
+ "list api keys",
667
+ "token",
668
+ "credential",
669
+ "permissions",
670
+ "scopes",
671
+ "permissions and scopes",
672
+ ],
673
+ url: `${DOCS_BASE_URL}/cli/api-keys`,
674
+ body: "Run `sf api-keys create` to mint a bearer key, `sf api-keys list` to inspect keys, and `sf api-keys revoke` to turn one off. Presets select a permission bundle; each key is scoped to its team. The secret is shown once and masked in `--json` output.",
569
675
  },
570
676
  {
571
677
  slug: "cli/analytics",
@@ -678,6 +784,27 @@ const HAND_WRITTEN_DOCS_CATALOG = [
678
784
  url: `${DOCS_BASE_URL}/api`,
679
785
  body: "Create teams, list members, and manage invitations programmatically. Webhooks and API keys are team-scoped.",
680
786
  },
787
+ {
788
+ slug: "api/connectors",
789
+ title: "Connectors API",
790
+ kind: "api",
791
+ tier: "reference",
792
+ summary: "Connect tool sources, manage connections and policy, and run tools over HTTP.",
793
+ keywords: [
794
+ "api",
795
+ "connectors",
796
+ "connections",
797
+ "tools",
798
+ "policy",
799
+ "runs",
800
+ "mcp",
801
+ "openapi",
802
+ "graphql",
803
+ "endpoint",
804
+ ],
805
+ url: `${DOCS_BASE_URL}/api`,
806
+ body: "Register OpenAPI, GraphQL, or remote MCP sources as team connectors; connect accounts whose credentials stay server-side; set an ordered tool policy; and run a single tool or a code program, with approvals when a rule asks for them.",
807
+ },
681
808
  {
682
809
  slug: "api/docs",
683
810
  title: "Docs API (GET /v1/docs)",
@@ -727,7 +854,7 @@ const HAND_WRITTEN_DOCS_CATALOG = [
727
854
  tier: "reference",
728
855
  summary: "The tenant-facing partner API for running Spacefast as infra.",
729
856
  keywords: ["api", "partner", "tenant", "infra", "openapi", "multi-tenant", "white label"],
730
- url: `${DOCS_BASE_URL}/partners`,
857
+ url: PARTNER_API_REFERENCE_URL,
731
858
  body: `There is no partner route tree. Partners call the same \`/v1\` routes as everyone else: successes carry a \`{ data }\` envelope and failures are RFC 9457 problem documents (\`application/problem+json\` with a stable \`code\`), exactly as elsewhere in the API. A tenant-rooted credential's policy scope and response projection decide what it sees. "Partner" is a spec visibility tier: those operations, plus tenants and principals, are published as a second OpenAPI document at ${DEFAULT_API_URL}/openapi.partner.json, rendered at ${PARTNER_API_REFERENCE_URL}. Point \`openapi-typescript\` at that document for types. Configuration is not a set of endpoints: a tenant declares its integration in one designated space's published manifest (see \`partner/system-space\`).`,
732
859
  },
733
860
  {
@@ -735,10 +862,10 @@ const HAND_WRITTEN_DOCS_CATALOG = [
735
862
  title: "Partner onboarding",
736
863
  kind: "api",
737
864
  tier: "reference",
738
- summary: "Bootstrap a tenant: one key, one space, one designation, one publish.",
865
+ summary: "Connect your backend using separate live and test environments.",
739
866
  keywords: ["partner", "onboarding", "tenant", "bootstrap", "partner_admin", "api key", "setup"],
740
- url: `${DOCS_BASE_URL}/partners#onboarding`,
741
- body: "Tenant creation is superadmin-side and mints one bootstrap tenant-rooted API key with the `partner_admin` preset (`tenants:*`, `principals:read`, and space/domain/publish actions over the tenant). From there it is four steps you drive yourself: create a space with that key, `PATCH /v1/tenants/{tenantId}` with `systemSpaceId` to designate it, publish the manifest, then read `manifestStatus` on `GET /v1/tenants/{tenantId}` to watch each declared item converge. Mint further keys through the normal API-key routes every one is bounded to a subset of its grantor's policy.",
867
+ url: `${DEFAULT_API_URL}/v1/docs/pages/partner/onboarding`,
868
+ body: "Enable partner access for your Spacefast team, then open Partners in the dashboard. Your team manages a linked live and test tenant. Each environment has its own customers, configuration, and credentials. Team owners and admins create tenant server keys in the dashboard or through `POST /v1/tenants/{tenantId}/api-keys`. The default key manages that environment, including bounded key creation and revocation. For your first integration, call the shared API from your backend and keep the key on your server. Create a space with the selected environment's key, designate it with `PATCH /v1/tenants/{tenantId}` using `systemSpaceId`, then publish your system manifest. Read `manifestStatus` on `GET /v1/tenants/{tenantId}` to check activation. To replace a key, create a new key, deploy it to your backend, then revoke the old key with `DELETE /v1/tenants/{tenantId}/api-keys/{apiKeyId}`. Test hosting uses simulated infrastructure; use the live environment to publish publicly reachable sites. Billing stays in your system. Spacefast plans grant features and enforce quotas.",
742
869
  },
743
870
  {
744
871
  slug: "partner/system-space",
@@ -757,8 +884,8 @@ const HAND_WRITTEN_DOCS_CATALOG = [
757
884
  "reconciliation",
758
885
  "white label",
759
886
  ],
760
- url: `${DOCS_BASE_URL}/partners#system-space`,
761
- body: "A tenant designates one ordinary space as its system space, and that space's live version *is* the integration definition: a top-level `system` section in `sf.jsonc` (presentation, hostname apex, API origin, token issuers, event subscriptions) plus `_pages/` and `theme.json` as the defaults layer. One config language, one validation pipeline, one publish flow — and `sf rollback` rolls back your configuration with it. Finalize, promote, and rollback all reconcile declared state against current state. Presentation, pages, theme, and subscriptions apply immediately; hostnames, API origins, and token issuers enter `pending` until their DNS, TLS, or key-possession check passes. Dropping an item from the manifest deactivates it. Per-item state lands in `manifestStatus` (`{ key, state, detail, since }` plus the source version id) on `GET /v1/tenants/{tenantId}`. There are no imperative config routes: the fix for a failed item is a new publish. Secrets are never declared — webhook secrets and API keys are minted by their own routes.",
887
+ url: `${DEFAULT_API_URL}/v1/docs/pages/partner/system-space`,
888
+ body: "A tenant designates one ordinary space as its system space, and that space's live version *is* the integration definition: a top-level `system` section in `sf.jsonc` (presentation, hostname apex, API origin, token issuers, event subscriptions) plus `_pages/` and `theme.json` as the defaults layer. One config language, one validation pipeline, one publish flow — and `sf rollback` rolls back your configuration with it. Finalize, promote, and rollback all reconcile declared state against current state. Presentation, pages, theme, and subscriptions apply immediately; hostnames, API origins, and token issuers enter `pending` until their DNS, TLS, or key-possession check passes. Removing an issuer, API origin, subscription, or plan declaration reconciles that desired state. For a custom API origin, run an HTTPS gateway that forwards to the shared API hostname and overrides `x-spacefast-tenant-id` with your live tenant ID. Preserve paths, query strings, and Authorization. `domainSetup.api` returns the upstream origin, proxy headers, ownership DNS records, and verification URL. The gateway must forward that URL without redirects; Spacefast checks public DNS ownership and a fresh nonce-bound response over HTTPS. Existing site hostnames remain pinned to their namespace; changing a hostname default does not rename published sites. Per-item state lands in `manifestStatus` (`{ key, state, detail, since }` plus the source version id) on `GET /v1/tenants/{tenantId}`. There are no imperative config routes: the fix for a failed item is a new publish. Secrets are never declared — webhook secrets and API keys are minted by their own routes.",
762
889
  },
763
890
  {
764
891
  slug: "partner/tokens",
@@ -778,8 +905,8 @@ const HAND_WRITTEN_DOCS_CATALOG = [
778
905
  "audience",
779
906
  "revocation",
780
907
  ],
781
- url: `${DOCS_BASE_URL}/partners#tokens`,
782
- body: "Your customers never need a Spacefast credential: your auth system mints standard JWT access tokens and Spacefast verifies them. Declare the issuer in the system-space manifest with its pinned Ed25519 public keys there is no issuer CRUD. The first publish returns `state: pending` with a challenge nonce in `manifestStatus`; sign it with the declared key and republish with the `proof` field, and the issuer activates. Proof of key possession lives in your repo next to the declaration. The token profile is strict: `typ` of `at+jwt`, `alg` of `EdDSA` only, the per-issuer minted `aud` (never a shared value), all of `iss`/`sub`/`client_id`/`jti`/`iat`/`exp` required, `exp - iat` at most 30 minutes, 300s clock skew; embedded or fetched keys are rejected. A verified token becomes a `partner_token` credential bound to one external principal, carrying a fixed least-privilege policy: publish, read, versions, and variables over that principal's subtree never tenant or principal management. Revoke by removing the issuer or rotating its keys; worst-case acceptance of a revoked token is the shorter of a 30s cache TTL and the token's own expiry.",
908
+ url: `${DEFAULT_API_URL}/v1/docs/pages/partner/tokens`,
909
+ body: "Your auth system mints customer JWTs that Spacefast verifies. Declare one issuer and up to five Ed25519 public keys with unique `kid` values in your system-space manifest. The first publish returns a pending status item with `audience` and `challenge`. Sign that challenge with each declared private key, then republish the JWTs in `proofs`. Every newly added or replaced key needs proof of possession. Customer tokens use `typ: at+jwt`, `alg: EdDSA`, the returned `audience` as `aud`, and all of `iss`, `sub`, `client_id`, `jti`, `iat`, and `exp`. The lifetime is at most 30 minutes, with 300 seconds of clock skew. Embedded and fetched keys are rejected. Each token grants publishing, reads, versions, and variables only for its own external principal. Tokens remain usable until expiry; `jti` does not make them single-use. To rotate without interrupting customers, publish the old and new public keys together. Sign the returned challenge with every new key and republish `proofs`. Existing keys remain active while the new keys await proof. Once activation completes, switch your signer to the new key, then publish again without the old key. Removing a key takes effect immediately and requires no new proof. The audience stays unchanged during rotation. An empty `tokenIssuers` array or removal of the field revokes the issuer. Issuer revocation invalidates all its tokens; individual customer tokens cannot be revoked separately.",
783
910
  },
784
911
  {
785
912
  slug: "partner/principals",
@@ -798,7 +925,7 @@ const HAND_WRITTEN_DOCS_CATALOG = [
798
925
  "scope",
799
926
  "variables",
800
927
  ],
801
- url: `${DOCS_BASE_URL}/partners#principals`,
928
+ url: `${DEFAULT_API_URL}/v1/docs/pages/partner/principals`,
802
929
  body: "Your customers are external principals inside your tenant. `GET /v1/principals` lists them within the caller's granted scope (a tenant-rooted key sees the whole tenant) and `GET /v1/principals/external/{principalId}` reads one. There is no create route: a principal is upserted implicitly in the same transaction as its first owned resource, and its identity is the normalized id — the display casing you first sent is preserved but never authoritative. Every space has exactly one owner: a team, an external principal, or an open claim token. IAM actions stay generic nouns (`tenants:read`, `tenants:write`, `principals:read`) rather than a `partner:*` namespace, evaluated per route like every other action, so a partner credential's reach is a policy fact and not a router branch. Per-principal environment variables live under `/v1/principals/{principalType}/{principalId}/variables`.",
803
930
  },
804
931
  {
@@ -817,7 +944,7 @@ const HAND_WRITTEN_DOCS_CATALOG = [
817
944
  "signature",
818
945
  "hmac",
819
946
  ],
820
- url: `${DOCS_BASE_URL}/partners#events`,
947
+ url: `${DEFAULT_API_URL}/v1/docs/pages/partner/events`,
821
948
  body: "Webhooks are the one event primitive, and their ownership generalizes from teams to tenants. Declare subscriptions in the system-space manifest (`url` plus an `events` selection) and reconciliation creates, updates, or disables the rows; delivery uses the same `Spacefast-Signature` HMAC and dual-secret rotation as team webhooks, so verify the signature before trusting a payload. Email white-labeling is not a separate endpoint: subscribe to `principal.notification.*` events (claim link issued, security notice, publish receipt) and send them yourself in your own voice. For a partner tenant these events replace Spacefast-sent email to your customers — no active subscription means no send, and Spacefast never falls back to sending as itself to someone else's customer.",
822
949
  },
823
950
  ];