Editing and Publishing

Publishing and restore

Publish a branch to make it live, read publication history, and restore an earlier version

What publishing does

Publishing takes the work on a branch and makes it the live version of your docs site. The live version is called main. When we publish, Doxa squash merges the branch into main. The result is a new, unchangeable version of your site, and the production site serves that version.

After a publish, the branch you published from is handled based on its kind. Our hidden branch, the one the editor uses while it shows main, is always erased. A named branch can be erased, or reset to the new version with no working changes left on it.

Before you publish

Check these items first. A publish stops if one of them is not ready.

  • Review the preview. Build a preview of the branch and read the changed pages. See Branches and previews.

  • Fix invalid MDX. A changed page that fails the MDX check blocks the publish with an mdx_invalid error (HTTP 422). The error lists the affected pages under details.pages. Saving a page never blocks, so you can save a page with issues, but it must be fixed before you publish. For the components you can use in pages, see MDX components.

  • Confirm the branch is current. Publishing checks that the branch is based on the version you reviewed. If main changed in the meantime, refresh the branch and review it again.

Publish a branch

1

Open the branch you want to publish

Go to the branch in the dashboard and confirm the preview shows what you expect to go live.

2

Publish the branch

Start the publish from the branch. Doxa checks the concurrency values again under database locks. A publish that conflicts with a newer change is refused, so it cannot overwrite that change.

3

Confirm the live site

Open your site, or your custom domain, and check the pages you changed. Each publish adds one entry to your publication history.

Publishing needs approval by default:

When an agent asks to publish, a person must approve the request first. The publish scope lets an agent publish branches and restore publications, but the approval step still applies by default. See Agent approvals to review, approve, or cancel a request.

Read the publication history

Every move of main is recorded in the publication history. Each entry shows the new version, the previous version, the actor, the kind of publication, and a short summary. The history lists entries from newest to oldest.

Use it to answer questions such as "what changed last week?" or "which version was live before the last publish?"

KindWhat it records
importA publication created by an import.
generationA publication created by a Doxabot generation. See Generations.
starterA publication created from the starter pages.
editorA publication created from the dashboard editor.
promotionA publication that promoted a branch to main.
restoreA publication that made an earlier version live again.

Restore an earlier version

Restoring is how we undo a publish. Pick an older publication from the history and restore it. Doxa moves main to the production version of that publication.

Keep these points in mind:

  • Restore adds an entry. The publish you undid stays in the history. Restore records a new restore entry on top of it, so you can always see what happened.

  • Branches are not changed. Restoring does not change or erase any branch, so your work on branches is kept.

  • Branches are compared with the restored version. After a restore, each branch compares its base with the restored version. A branch based on the version you undid may show differences, so review it before you publish it again.

  • Restore needs approval by default. An agent cannot restore a publication until a person approves the request.

Restore is not a branch reset:

Restore changes main only. To discard working changes on a branch, erase or reset that branch instead.

Who can publish and restore

When an agent publishes or restores, it needs the publish scope, and the approval step still applies by default. People with access to a project can publish and restore from the dashboard, subject to their team role. For roles, see Teams and roles.

Agents work on named branches. Writes to main are rejected through the MCP server, so agents publish only through the approval flow. To choose which scopes to grant an agent, see Agent scopes.

What's next