Sanity · Arazzo Workflow
Sanity Compare Draft and Published
Version 1.0.0
Read a document's draft and published perspectives to inspect its history.
View Spec
View on GitHub
Headless CMSContent ManagementGROQReal-TimeStructured ContentDeveloper PlatformArazzoWorkflows
Provider
Workflows
compare-draft-and-published
Fetch published and draft perspectives of one document for comparison.
Queries a document by id under the published perspective, then under the drafts perspective, so the caller can compare the two states. Used as a stand-in for revision history, which this API description does not expose directly.
1
getPublished
queryDocuments
Fetch the document under the published perspective to capture its live state.
2
getDraft
queryDocuments
Fetch the document under the drafts perspective to capture any pending unpublished edits for comparison against the published state.