All integrationsWebsites & Blogs
Sanity
Query, create, update and publish content in Sanity, the headless CMS.
- actions
- 9
- trigger
- 1
Triggers
Start a workflow when something happens in Sanity.
- New documentRuns for each new document in Sanity. Ones already there when the workflow is turned on don't start it. It can watch up to 4,000. How often it checks follows your workspace plan.
Actions
Steps a workflow can run in Sanity.
- Run a GROQ queryRead content with a GROQ query, Sanity's query language, such as *[_type == "post"]{title, slug}. The answer is in result.
- Get documents by IDGet one or more documents by their IDs, always reading the latest write. To read a draft, use its ID with drafts. in front. IDs that don't exist, or that the token can't read, are listed in omitted.
- List recent documents of a typeList the newest documents of one type, most recently created first.
- Create a documentCreate a new document. It fails if a document with the same ID already exists. Give an ID that starts with drafts. to create an unpublished draft.
- Create or replace a documentCreate a document with this ID, or replace the whole document if it already exists. Fields left out of a replaced document are removed.
- Update fields of a documentSet or remove fields of an existing document, leaving its other fields as they are. Fields are set first, then removed.
- Delete a documentDelete a document and its draft. It succeeds even if there was nothing to delete.
- Publish a draftPublish a document's draft, replacing the published version and removing the draft, as Publish does in Sanity Studio.
- List datasetsList the project's datasets.
No actions match that.
Automate Sanity with Lodol.
Connect Sanity, then hand Lodol the job in Slack, Claude or ChatGPT.
We’re letting people in a few at a time.