Drafts and publishing
Replace a version's pending content
Replaces the stored content of a version, typically one that is scheduled, so the new content goes live when the schedule fires. The schedule time stays the same. Send projectId and type in the body, not the query. type chooses the shape:
- type: "page": a full page snapshot (pageData with name, rootId, items, and pageAssignment). snapshot.pageData is the page itself, not a { page } wrapper. The write is fenced on snapshot.pageData.expectedUpdatedAt: if the version's page changed since then, the response is 409 STALE_PAGE and the stored snapshot stays the same.
- type: "theme": a full theme snapshot (theme, recentColors, previewHost, defaultLocale), fenced on expectedProjectUpdatedAt. If the project revision moved, the response is 409 STALE_PROJECT.
- type: "deferred-page": for a catch-all page version that has no live assignment yet. Send the page save payload as pageData (page and pageAssignment; page.id and page.expectedUpdatedAt are required), optional translations and staticTextChanges, the version's current scheduleRevision as expectedScheduleRevision, and expectedProjectUpdatedAt. The response is version_recaptured, and its versionId may name a new successor version; use that id from then on.
Refusals (409 CONFLICT). Draft versions cannot be changed; save a new draft through PUT /projects/{projectId}/page-drafts/{pageId} instead. Sending page for a deferred version, or deferred-page for a normal one, is also refused. An invalid snapshot is 400.
Required scope: content:publish
put/versions/{versionId}
Request
- Base URLhttps://studio.weaverse.io/api/v1/content
- AuthHTTP bearer
Request body
Response
Updated version
object required
Changes
No recorded changes to this operation across all 1 revision of this API.