Skip to content

Commit 4ab144a

Browse files
committed
Merge remote-tracking branch 'origin/main' into domain-registration-docs
2 parents eeeaef1 + dab9c69 commit 4ab144a

123 files changed

Lines changed: 9828 additions & 3658 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎.vale.ini‎

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,3 +30,18 @@ Spacefast.Hype = NO
3030
Spacefast.Wordiness = NO
3131
Spacefast.Condescension = NO
3232
Spacefast.ApiKey = NO
33+
Spacefast.Hosting = NO
34+
35+
; Generated error pages are a verified snapshot synced from the monorepo, and
36+
; the OpenAPI prose extraction reads generated/openapi. Both stay exempt from
37+
; the "hosting" rule until the snapshot is refreshed with the monorepo fixes;
38+
; then remove these carve-outs.
39+
[content/(reference)/errors/**]
40+
BasedOnStyles = Vale, Spacefast
41+
Vale.Spelling = NO
42+
Spacefast.Hosting = NO
43+
44+
[*openapi-prose.md]
45+
BasedOnStyles = Vale, Spacefast
46+
Vale.Spelling = NO
47+
Spacefast.Hosting = NO

‎AGENTS.md‎

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -89,8 +89,11 @@ alerts is the bar.
8989
rules, which mirror the vocabulary registry in the product monorepo
9090
(`packages/common/src/vocabulary.ts`): "API key" never "access token". The
9191
infra brand is "WP Cloud" (never dotted or hyphenated). Prefer "infra";
92-
name WP Cloud only when the external reference is necessary — never the
93-
euphemism "the hosting provider". Marketing may use the family line "the
92+
name WP Cloud only when the external reference is necessary. Never use the
93+
word "hosting" in prose: say publish, serve, live, infrastructure, or
94+
runtime (`Hosting.yml`). Generated error pages, OpenAPI prose, and the
95+
shipped changelog are exempt until the generated snapshot is refreshed.
96+
Marketing may use the family line "the
9497
same infra as Automattic, WP Cloud, Pressable, and WordPress.com".
9598
- Unknown technical words go in `styles/Spacefast/spelling-exceptions.txt`
9699
(sorted, case matters for proper nouns). Identifiers in prose — commands,

‎STYLE_GUIDE.md‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -211,9 +211,9 @@ that is.
211211
(`ProductName.yml`).
212212
- **WP Cloud** — exact casing, never "wp cloud," "wp.cloud," or hyphenated
213213
(`WpCloudBrand.yml`). Prefer "infra" generally; name WP Cloud only when
214-
the external reference is genuinely necessary. Never say "the hosting
215-
provider" for Spacefast's own infra (`HostingProvider.yml`) — generic
216-
references to *other* hosting providers are fine.
214+
the external reference is genuinely necessary. Never use the word
215+
"hosting" for Spacefast or its features (`Hosting.yml`). Say publish,
216+
serve, live, infrastructure, or runtime.
217217
- **"API key," never "access token"** (`ApiKey.yml`) — "OAuth access
218218
token" is the one exempted phrase, since that's the protocol's own term.
219219

‎blume.config.ts‎

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import { pagefind } from "blume/search";
88
import { loadPricing, pricingVariables } from "./scripts/pricing.mjs";
99

1010
import { redirects } from "./redirects.ts";
11-
import { pricingTableMarkdown } from "./scripts/pricing-next.mjs";
11+
import { planVariables, pricingTableMarkdown } from "./scripts/pricing-next.mjs";
1212

1313
const deploymentBase = "/docs";
1414
// Agent guidance for llms.txt, kept as Markdown so Vale lints it with the pages.
@@ -62,8 +62,14 @@ const icons = {
6262

6363
export default defineConfig({
6464
title: "Spacefast Docs",
65-
variables: pricingVariables(await loadPricing({ fixture: new URL("./content/_pricing/document.json", import.meta.url) })),
66-
description: "Publish and host the sites your agents build.",
65+
variables: {
66+
...pricingVariables(await loadPricing({ fixture: new URL("./content/_pricing/document.json", import.meta.url) })),
67+
// Plan values from scripts/pricing-next.mjs, the source Pricing & Limits renders.
68+
...planVariables(),
69+
},
70+
description: "Publish what your agents build.",
71+
// Two links (components/Logo.astro): the mark goes to the Website home at the
72+
// origin root, outside the /docs base; "Docs" goes to the Docs home.
6773
logo: { href: "/", image: { light: "/spacefast-wordmark.svg", alt: "Spacefast" }, text: "Docs" },
6874
// The 2026-10 brand: neutral greys, one green, dark first like the Website.
6975
// The green is a ground with ink on it, never type on white, so light mode
@@ -168,12 +174,12 @@ export default defineConfig({
168174
},
169175
agents: {
170176
llmsTxt: { details: llmsDetails },
171-
// The WP Cloud footer, written out as Markdown for .md pages, llms-full.txt
177+
// The upstream reference footer, written out as Markdown for .md pages, llms-full.txt
172178
// and MCP: without this the component ships as raw JSX.
173179
markdownComponents: {
174-
PricingTable: ({ props }) => pricingTableMarkdown(String(props.table)),
180+
PricingTable: ({ props }) => pricingTableMarkdown(String(props.table), props.row ? String(props.row) : undefined),
175181
WpCloudDocs: ({ props }) =>
176-
`Spacefast is built on Automattic's [WP Cloud](https://wp.cloud/). Using the [Partner API](${deploymentBase}/platforms/partner-api)? See [${String(props.title)}](${String(props.href)}) on WP Cloud Docs.`,
182+
`Using the [Partner API](${deploymentBase}/platforms/partner-api)? See [${String(props.title)}](${String(props.href)}) in the upstream infrastructure reference.`,
177183
},
178184
// The Website publishes Spacefast's agent skill at the site root; a second,
179185
// generated Docs skill would compete with it.

‎components.ts‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,13 @@
11
import { defineComponents } from "blume";
22

33
import Breadcrumbs from "./components/Breadcrumbs.astro";
4+
import Logo from "./components/Logo.astro";
45
import Pagination from "./components/Pagination.astro";
56
import Sidebar from "./components/Sidebar.astro";
67
import PricingTable from "./components/PricingTable.astro";
78
import WpCloudDocs from "./components/WpCloudDocs.astro";
89

910
export default defineComponents({
10-
layout: { Breadcrumbs, Pagination, Sidebar },
11+
layout: { Breadcrumbs, Logo, Pagination, Sidebar },
1112
mdx: { PricingTable, WpCloudDocs },
1213
});

‎components/Logo.astro‎

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
---
2+
// The brand lockup: the Spacefast mark links to the Website home, "Docs" links
3+
// to the Docs home. Docs are always served inside the Website artifact at
4+
// /docs, so the configured root-relative `logo.href` ("/") is emitted as is,
5+
// without the deployment base, and reaches the Website home on whatever origin
6+
// serves the page. The Website is not part of the Docs' client router, so the
7+
// mark's link does a plain page load instead of a router fetch first.
8+
import { withBase } from "blume/components/islands/base-path.ts";
9+
import type { BlumeLogo } from "blume/core/data.ts";
10+
11+
interface Props {
12+
site: { title: string };
13+
logo?: BlumeLogo | null;
14+
locale?: string;
15+
}
16+
17+
const { site, logo } = Astro.props;
18+
const label = logo?.text ?? site.title;
19+
const link = "inline-flex items-center transition-opacity hover:opacity-80";
20+
// The config inlines the wordmark so it follows the theme. Fail the build
21+
// rather than ship a header whose mark silently disappeared.
22+
if (!logo?.svg) throw new Error("components/Logo.astro needs blume.config.ts `logo` to resolve to an inline SVG.");
23+
---
24+
25+
<div class="flex min-w-0 items-center gap-2" data-sf-brand>
26+
<a
27+
aria-label={`${logo.alt || "Spacefast"} home`}
28+
class:list={[link, "shrink-0 text-foreground"]}
29+
data-astro-reload
30+
href={logo.href}
31+
>
32+
<span aria-hidden="true" class="inline-flex h-5 items-center [&>svg]:h-5 [&>svg]:w-auto" set:html={logo.svg} />
33+
</a>
34+
{
35+
label && (
36+
<a class:list={[link, "min-w-0 font-semibold text-base text-foreground"]} href={withBase("/")}>
37+
<span class="truncate">{label}</span>
38+
</a>
39+
)
40+
}
41+
</div>

‎components/PricingTable.astro‎

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,14 +10,16 @@ import { pricingTable } from "../scripts/pricing-next.mjs";
1010
1111
interface Props {
1212
table: "plans" | "team" | "space" | "features" | "examples" | "payments";
13+
/** Show only these rows, joined with " | ", so another page can quote plan limits from the same data. */
14+
row?: string;
1315
}
1416
15-
const { table } = Astro.props;
16-
const { columns, groups, highlight } = pricingTable(table);
17+
const { table, row: rowLabel } = Astro.props;
18+
const { columns, groups, highlight } = pricingTable(table, rowLabel);
1719
const span = columns.length + 1;
1820
---
1921

20-
<div class="sf-pricing not-prose" data-pricing-table={table} tabindex="0" role="region" aria-label={`${table} pricing table, scroll sideways for every plan`}>
22+
<div class="sf-pricing not-prose" data-pricing-table={table} tabindex="0" role="region" aria-label={`${rowLabel ? rowLabel.replaceAll(" | ", ", ") : `${table} pricing table`}, scroll sideways for every plan`}>
2123
<table style={`--sf-cols: ${columns.length}`}>
2224
<thead>
2325
<tr>

‎components/WpCloudDocs.astro‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,6 @@ const { title, href } = Astro.props;
1111

1212
<aside class="not-prose mt-10 border-border border-t pt-4 text-muted-foreground text-sm leading-6 [&_a]:underline [&_a]:decoration-current/50 hover:[&_a]:text-foreground" data-wp-cloud-docs>
1313
<p>
14-
Spacefast is built on Automattic's <a href="https://wp.cloud/">WP Cloud</a>. Using the <a href={contentHref("/platforms/partner-api")}>Partner API</a>? See <a href={href}>{title}</a> on WP Cloud Docs.
14+
Using the <a href={contentHref("/platforms/partner-api")}>Partner API</a>? See <a href={href}>{title}</a> in the upstream infrastructure reference.
1515
</p>
1616
</aside>

‎content/(account)/api-keys.mdx‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -82,12 +82,12 @@ Keys created through the API can also be scoped to a single Space instead of the
8282

8383
Some actions are reserved for a signed-in person, at every permission level. No API key, agent grant, or OAuth token can do them:
8484

85-
- Invite a member, cancel or resend an invitation
85+
- Cancel or resend an invitation
8686
- Change a member's role
8787
- Remove a member
8888
- Accept a team invitation
8989

90-
A credential that tries gets a `403` with `authorization_level_not_allowed`. Do those in the dashboard. Once you accept an invitation there, the device credentials you already approved pick the new team up on their own. More detail in [what agents are allowed to do](/agents/permissions).
90+
A credential that tries gets a `403` with `authorization_level_not_allowed`. Do those in the dashboard. Creating an invitation is the exception: a credential with the `teams:members.write` scope, such as Agent access, can invite people with [`createTeamInvitation`](/api/reference/teams/createteaminvitation). Once you accept an invitation in the dashboard, the device credentials you already approved pick the new team up on their own. More detail in [what agents are allowed to do](/agents/permissions).
9191

9292
## Rotate a key
9393

‎content/(account)/auto-enroll.mdx‎

Lines changed: 76 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,76 @@
1+
---
2+
title: Allowed email domains
3+
description: Let people with a verified company email address find and join your team without an invitation
4+
---
5+
6+
An allowed email domain offers your team to anyone whose verified email address is at that domain. Spacefast never adds anyone automatically. A person becomes a member only when they press **Join**.
7+
8+
Only owners and admins can add or remove domains. An OAuth token needs the `teams:members.write` scope, including to list them.
9+
10+
## Add a domain
11+
12+
1. Open the team and go to **Members**.
13+
2. Press **Join Link**. The **Let Teammates Join** dialog opens.
14+
3. Type the domain, for example `example.com`, in **Company email domain**.
15+
4. Press **Add Domain**.
16+
17+
Over HTTP, send [`createTeamAutoEnrollEntry`](/api/reference/teams/createteamautoenrollentry):
18+
19+
```bash
20+
curl "https://api.spacefast.com/v1/teams/$TEAM_ID/auto-enroll" \
21+
-H "Authorization: Bearer $SPACEFAST_API_KEY" \
22+
-H "Content-Type: application/json" \
23+
-d '{"value":"example.com"}'
24+
```
25+
26+
The `201` response holds the entry: `id`, `teamId`, `kind` (always `domain`), `value`, and `createdAt`. Adding a domain the team already has returns the existing entry. [`listTeamAutoEnrollEntries`](/api/reference/teams/listteamautoenrollentries) returns all entries, newest first.
27+
28+
Adding a domain needs a credential that acts for a person. A team API key or OAuth app acts for the person who created it. A key with no person behind it gets `forbidden`.
29+
30+
## Which domains Spacefast accepts
31+
32+
A domain is accepted when all of these are true:
33+
34+
- **A current member already uses it.** At least one member of this team must have a verified email address at exactly that domain. A subdomain does not count.
35+
- **It is a domain, not an address.** A value with `@` is refused. Invite that person by email instead.
36+
- **It is a registrable domain.** IP addresses, single labels such as `localhost`, and public suffixes such as `co.uk` are refused.
37+
- **It is not a shared mailbox provider.** These are refused: `gmail.com`, `googlemail.com`, `outlook.com`, `hotmail.com`, `live.com`, `yahoo.com`, `proton.me`, `protonmail.com`, `icloud.com`, `me.com`, `aol.com`, `mail.com`, `gmx.com`, and `wordpress.com`.
38+
39+
Spacefast stores the canonical form: lowercase ASCII, with international names converted to their `xn--` form. `Bücher.de` becomes `xn--bcher-kva.de`. Matching uses the same form, so either spelling works for people who join.
40+
41+
## What a person sees
42+
43+
A signed-in person with a verified address at the domain sees your team under **Open invites** on the **Teams** page. The row reads **You have an @example.com email**. Their team's Spaces page also shows a **Teams you can join** notice with **View Teams**.
44+
45+
Every verified address on the account counts, including secondary addresses. The account does not need to use that address to sign in.
46+
47+
Pressing **Join** makes them a member with the `member` role. Owners and admins can change the role later on **Members**. Joining needs a signed-in browser session. An API key or an agent cannot join for a person. The API operation is [`joinTeam`](/api/reference/teams/jointeam).
48+
49+
## Seats and billing
50+
51+
A person who joins through a domain takes a seat like any other member. Members on Pro: {{plan-team-members-pro}}.
52+
53+
Personal and Go allow one member, the owner. On those plans, **Join** fails with `team_member_quota_exceeded`, so nobody can join until the team moves to Pro. See [Pricing & Limits](/pricing).
54+
55+
## Remove a domain
56+
57+
In **Join Link**, press **Remove** next to the domain. Confirm with **Remove Domain**.
58+
59+
Over HTTP, send [`deleteTeamAutoEnrollEntry`](/api/reference/teams/deleteteamautoenrollentry) with the entry `id`. It answers `204`.
60+
61+
- **Existing members stay.** Removing a domain changes no membership and no role.
62+
- **New people need an invitation.** The team stops appearing under their **Open invites**.
63+
64+
To take access away from someone who joined through a domain, remove them on **Members**. See [Teams and members](/teams#change-a-role-or-remove-someone).
65+
66+
A member you remove cannot rejoin through the domain. To bring them back, send an invitation. A member who leaves on their own can rejoin through the domain.
67+
68+
## Errors
69+
70+
| Code | Status | Meaning |
71+
| --- | --- | --- |
72+
| `invalid_domain_name` | 422 | The value is not a registrable domain. IP addresses and public suffixes land here |
73+
| `validation_error` | 422 | `details.reason` says why. `email_not_supported`: the value is an email address. `domain_not_allowed`: the domain is a shared mailbox provider. `domain_not_represented`: no member has a verified address there |
74+
| `not_found` | 404 | The entry does not exist or belongs to another team |
75+
| `forbidden` | 403 | Your role cannot manage members, or the credential has no person behind it |
76+
| `team_member_quota_exceeded` | 409 | A person pressed **Join** while the team was at its member limit |

0 commit comments

Comments
 (0)