From d21990a10548478b68a3550e2ab219144430c9fd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?batuhan=20i=C3=A7=C3=B6z?= Date: Fri, 30 Oct 2026 03:24:19 +0000 Subject: [PATCH 1/3] Show how WordPress triggers rebuilds The WordPress data sources page said a content change needs Build now or a push. The Spacefast plugin's headless mode triggers the production build itself, debounced, so document that path, what it reacts to, and what its authorization covers. Co-Authored-By: Claude Opus 5.5 --- content/(publish)/wordpress-data-sources.mdx | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/content/(publish)/wordpress-data-sources.mdx b/content/(publish)/wordpress-data-sources.mdx index e4e7a511..99948c24 100644 --- a/content/(publish)/wordpress-data-sources.mdx +++ b/content/(publish)/wordpress-data-sources.mdx @@ -122,4 +122,21 @@ With no argument it reads `WORDPRESS_URL`, falling back to the default entry in The URL has to serve the standard WordPress REST API at `/wp-json/` with pretty permalinks on. The content the build reads is whatever that API returns to an anonymous caller, so anything private stays private. -A source is only read while a build runs. When published content changes, a new build is what picks it up. Open **Builds** and use **Build now** for an immediate refresh, or push to the production branch. +## Rebuild when content changes + +A source is only read while a build runs. When published content changes, a new build is what picks it up. Let WordPress start it. + + + + Download [`spacefast-wordpress.zip`](https://github.com/spacefast/wordpress/releases/latest/download/spacefast-wordpress.zip) and install it in WordPress. It needs WordPress 6.5 and PHP 8.1 or newer. + + + Open **Settings → Spacefast** and expand **Use WordPress as a CMS for a repository site**. Sign in to Spacefast, authorize one team, and pick the Space whose repository reads this site. + + + +That's the loop. The plugin writes this site into the Space's data sources as the default, so the step above is optional when you connect it this way. + +Any change to published content the REST API serves schedules a production build of the connected repository: publishing it, updating it, moving it out of published, or deleting it. So do media, taxonomy term, menu, and user changes. Saving a draft, or a revision WordPress keeps on its own, doesn't. Each change restarts a 60-second quiet window, so a batch of edits becomes one build. **Build now**, in WordPress or on the Space's **Builds** page, skips the wait. + +The plugin asks for `teams:read`, `spaces:read`, `spaces:write`, and `builds:trigger`. Write access keeps the Space's title, search visibility, and WordPress source in sync with the site; turn each off under **WordPress sync**. A build it triggers always runs the Space's saved production branch, build settings, and live target. It can't pick its own. From 26cb36dea6b0793ef52205279535fa2755c9aaf5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?batuhan=20i=C3=A7=C3=B6z?= Date: Fri, 30 Oct 2026 15:20:18 +0000 Subject: [PATCH 2/3] Warn that picking a Space syncs it right away, and cover cron and scopes Name the skipped step, add plugin activation, list offline_access, and say WP-Cron needs traffic or a server cron. --- content/(publish)/wordpress-data-sources.mdx | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/content/(publish)/wordpress-data-sources.mdx b/content/(publish)/wordpress-data-sources.mdx index 99948c24..0d6e080c 100644 --- a/content/(publish)/wordpress-data-sources.mdx +++ b/content/(publish)/wordpress-data-sources.mdx @@ -128,15 +128,17 @@ A source is only read while a build runs. When published content changes, a new - Download [`spacefast-wordpress.zip`](https://github.com/spacefast/wordpress/releases/latest/download/spacefast-wordpress.zip) and install it in WordPress. It needs WordPress 6.5 and PHP 8.1 or newer. + Download [`spacefast-wordpress.zip`](https://github.com/spacefast/wordpress/releases/latest/download/spacefast-wordpress.zip), install it in WordPress, and activate it. It needs WordPress 6.5 and PHP 8.1 or newer. Open **Settings → Spacefast** and expand **Use WordPress as a CMS for a repository site**. Sign in to Spacefast, authorize one team, and pick the Space whose repository reads this site. -That's the loop. The plugin writes this site into the Space's data sources as the default, so the step above is optional when you connect it this way. +Picking a Space acts right away. The plugin copies the site's title, description, and search visibility onto the Space, sets this site as the Space's default WordPress source, and starts a production build. The **WordPress sync** switches that turn each of those off appear only after the first sync, so pick an existing Space only if you want it to match this site. Connecting this way also means you can skip [Add a source](#add-a-source). Any change to published content the REST API serves schedules a production build of the connected repository: publishing it, updating it, moving it out of published, or deleting it. So do media, taxonomy term, menu, and user changes. Saving a draft, or a revision WordPress keeps on its own, doesn't. Each change restarts a 60-second quiet window, so a batch of edits becomes one build. **Build now**, in WordPress or on the Space's **Builds** page, skips the wait. -The plugin asks for `teams:read`, `spaces:read`, `spaces:write`, and `builds:trigger`. Write access keeps the Space's title, search visibility, and WordPress source in sync with the site; turn each off under **WordPress sync**. A build it triggers always runs the Space's saved production branch, build settings, and live target. It can't pick its own. +The plugin sends builds from WP-Cron, which only runs when the site gets a request. On a quiet headless site, a change can wait for the next visit. If `DISABLE_WP_CRON` is set, have the server request `wp-cron.php` on a schedule. **Tools → Site Health** flags a disabled or stuck delivery. + +The plugin asks for `teams:read`, `spaces:read`, `spaces:write`, `builds:trigger`, and `offline_access`, which keeps it signed in with a refresh token. A build it triggers always runs the Space's saved production branch, build settings, and live target. It can't pick its own. From c1786018994e8a7d1a2253986b7727fc9d06d41c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?batuhan=20i=C3=A7=C3=B6z?= Date: Fri, 30 Oct 2026 15:28:11 +0000 Subject: [PATCH 3/3] Say the plugin replaces a source already named wordpress --- content/(publish)/wordpress-data-sources.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/content/(publish)/wordpress-data-sources.mdx b/content/(publish)/wordpress-data-sources.mdx index 0d6e080c..22e05a89 100644 --- a/content/(publish)/wordpress-data-sources.mdx +++ b/content/(publish)/wordpress-data-sources.mdx @@ -135,7 +135,7 @@ A source is only read while a build runs. When published content changes, a new -Picking a Space acts right away. The plugin copies the site's title, description, and search visibility onto the Space, sets this site as the Space's default WordPress source, and starts a production build. The **WordPress sync** switches that turn each of those off appear only after the first sync, so pick an existing Space only if you want it to match this site. Connecting this way also means you can skip [Add a source](#add-a-source). +Picking a Space acts right away. The plugin copies the site's title, description, and search visibility onto the Space, saves this site as the default source under the name `wordpress`, replacing any source already called that, and starts a production build. The **WordPress sync** switches that turn each of those off appear only after the first sync, so pick an existing Space only if you want it to match this site. Connecting this way also means you can skip [Add a source](#add-a-source). Any change to published content the REST API serves schedules a production build of the connected repository: publishing it, updating it, moving it out of published, or deleting it. So do media, taxonomy term, menu, and user changes. Saving a draft, or a revision WordPress keeps on its own, doesn't. Each change restarts a 60-second quiet window, so a batch of edits becomes one build. **Build now**, in WordPress or on the Space's **Builds** page, skips the wait.