Sanity · Arazzo Workflow
Sanity Replace Document Asset
Version 1.0.0
Upload a new image, find the target document, then point it at the new asset.
View Spec
View on GitHub
Headless CMSContent ManagementGROQReal-TimeStructured ContentDeveloper PlatformArazzoWorkflows
Provider
Workflows
replace-document-asset
Swap a document's image to a newly uploaded asset reference.
Uploads a replacement image, confirms the target document exists, and patches its image field to reference the new asset.
1
2
findDocument
Read the target document by id to confirm it exists before patching.
3
patchAsset
Patch the document's image field so its asset reference points at the newly uploaded asset.
Source API Descriptions
openapi
openapi
Arazzo Workflow Specification
Work with this as data
Every workflow here is available over the APIs.io API and to AI agents over MCP.