Sanity MCP Server
OfficialServer Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
| MCP_USER_ROLE | No | Determines tool access level (developer or editor) | |
| SANITY_DATASET | Yes | The dataset to use | |
| SANITY_API_HOST | No | API host (defaults to https://api.sanity.io) | https://api.sanity.io |
| SANITY_API_TOKEN | Yes | Your Sanity API token | |
| SANITY_PROJECT_ID | Yes | Your Sanity project ID |
Instructions
Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.
This server publishes no instructions, or was last inspected before Glama recorded them.
Capabilities
Server capabilities have not been inspected yet.
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| get_initial_contextA | IMPORTANT: This tool must be called before using any other tools. It will get initial context and usage instructions for this MCP server. |
| get_sanity_configA | Get current Sanity configuration (projectId, dataset, API settings) |
| get_groq_specificationA | Get the GROQ language specification summary |
| create_documentB | Create a new document in Sanity with AI-generated content based on instructions |
| update_documentB | Update an existing document or version with AI-generated content based on instructions |
| patch_documentA | Apply direct patch operations to modify specific parts of a document without using AI generation |
| query_documentsC | Query documents from Sanity using GROQ query language |
| document_actionB | Perform document actions like publishing, unpublishing, or deleting documents |
| create_versionA | Create a version of an existing document for a specific release, with optional AI-generated modifications |
| discard_versionC | Discard a draft or delete a specific version document from a release |
| mark_for_unpublishA | Mark a document to be unpublished when a specific release is published |
| get_schemaA | Get the full schema of the current Sanity environment |
| list_schema_idsB | Get a list of all available schema IDs |
| list_releasesB | List content releases in Sanity, optionally filtered by state (active, scheduled, etc) |
| create_releaseB | Create a new content release in Sanity with an automatically generated ID |
| edit_releaseC | Update metadata for an existing content release |
| schedule_releaseA | Schedule a content release to be published at a specific time |
| release_actionC | Perform basic actions on existing content releases (publish, archive, unschedule, delete) |
| list_embeddings_indicesB | List all available embeddings indices for a dataset |
| semantic_searchB | Perform a semantic search on an embeddings index |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
No prompts | |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
No resources | |
TDQS
Scored across 20 tools
Most tools have distinct purposes (e.g., create_document vs update_document, list_releases vs release_action). Slight overlap arises with document_action and mark_for_unpublish both involving unpublishing, but descriptions clarify the release-specific context.
The majority follow a verb_noun pattern (create_document, list_releases, query_documents). Minor deviations include get_initial_context (more imperative than descriptive) and action-based names (document_action, release_action) that break the pattern.
20 tools is slightly above the typical 3-15 range but still reasonable for a full-featured CMS server. Each tool covers a distinct operation, and no obvious bloat is present.
Core document and release lifecycles are covered (create, query, update, delete, schedule, publish). A notable gap is the absence of a direct get_document by ID tool, though query_documents can substitute with GROQ. Auxiliary features like semantic search and schema retrieval add value.