Sanity is a headless content management system that treats content as structured data, making it accessible through APIs for any frontend or application. The Sanity MCP integration with Weldable lets your AI agents create, update, and query content documents using natural language. Sanity's official MCP server is generally available and hosted on Sanity's own infrastructure, following Anthropic's MCP specification. Manage your content operations without switching between editing interfaces and your communication tools.
Sanity's real-time content lake stores all your documents as structured JSON, queryable through GROQ, the platform's own query language. Your agent can work with full schema awareness, meaning it knows which fields exist, what types they expect, and how documents relate to each other.
Use cases
Draft and publish content updates
Ask your AI agent to create a new blog post draft in Sanity with a title, body, and metadata fields populated. The agent can also update existing documents, change publication status, or modify specific fields. Writers and marketers can queue up content changes through chat instead of logging into the studio.
Query content for reporting
Your agent can pull content inventory reports from Sanity, such as how many articles were published this month, which pages are still in draft, or what content is missing required fields. It formats the results into a Google Sheet or posts a summary to Slack. This makes content audits fast and repeatable without building custom queries by hand.
Sync content across channels
When you publish a new piece in Sanity, your agent can take the content and post a summary to Slack, send a notification via Gmail, or push key details into Google Sheets for tracking. This keeps your team informed and your distribution workflow moving without manual effort.
Release management and scheduled publishing
Sanity's release system lets you group document changes and publish them together. Your agent can create a release, add specific document versions to it, and schedule the release for a target date. It posts the release contents to Slack for team review before publication.
Content migration from other platforms
Moving content into Sanity from another CMS usually involves custom scripts. Your agent can read source content from Google Docs or Sheets, map it to your Sanity schema, resolve references between documents, and create everything in the correct order so that referenced documents exist before the documents that link to them.
How it works
Connect your Sanity project to Weldable through the integrations page by providing your project ID and an API token from manage.sanity.io. Your AI agent can then work with your content using requests like "create a new article draft titled Q1 Product Update" or "list all published blog posts from March." Weldable handles the GROQ query generation and authentication automatically.
Tips
Reference your schema types. When asking the agent to create or update documents, mention the document type (e.g., "post," "page," "author") so it targets the correct schema in your Sanity project.
Use for bulk operations. Sanity's API supports batch updates, and your agent can apply changes across multiple documents at once. Ask it to update a field across all drafts or tag a set of documents with a new category.
Pair with Slack for editorial workflows. Have your agent notify a Slack channel whenever content moves from draft to published in Sanity. This keeps editors, reviewers, and stakeholders aligned without extra meetings.
Portable Text is Sanity's rich text format. Rich text fields store content as Portable Text, a JSON-based structure that separates content from presentation. Your agent produces the correct block format for paragraphs, headings, and links when creating content through the API.
Datasets isolate your content environments. Each Sanity project can have multiple datasets for production, staging, and development. Make sure your agent targets the correct dataset, and test bulk operations against a development dataset before running them in production.
Works well with
Connect your agent to Sanity
Connect your Sanity account and start automating with AI agents in minutes. Free to use, no credit card required.