MCPActive

Sanity Context

Hosted, read-only MCP server exposing Sanity content to AI agents via GROQ or Knowledge Base mode.

Open source page

Field note

What it does

Sanity Context is a hosted Model Context Protocol server giving AI agents structured, read-only access to your content, serving a live dataset in GROQ mode or a pre-built index in Knowledge Base mode.

Capabilities

Available capabilities

Tags

Tags

Ways to use it

Ways to use it

mcp

Not filed / https://www.sanity.io/docs/ai/sanity-context

sdk

javascript / @sanity/context

rest

Not filed / https://www.sanity.io/docs/ai/sanity-context#initial-context

mcp

Not filed / https://www.sanity.io/docs/ai

mcp

Not filed / https://www.sanity.io/docs/ai/sanity-context

npm

Not filed / @sanity/context

Product features

Product features

Context MCPs

Configurable endpoints defining accessible content and shaping agent behavior.

Core components

Filtering content

Follow the guided steps

GROQ filtering

groqFilter limits which documents an agent can read using GROQ filter expressions.

GROQ mode

Queries your live dataset at request time for structured, schema-aware content.

How it fits together

Initial context

Mode-aware orientation: compressed schema overview or Knowledge Base outline.

Initial context endpoint

A tool call and API endpoint giving an agent what it needs to know about your project.

Install the Sanity Context skill

Knowledge Base mode

Serves a pre-built index over datasets, websites, and uploaded files.

MCP endpoint

MCP endpoint segments

Prerequisites

Prompt your coding agent to run the setup skill

Sanity Context

Sanity Context document

Defines what an agent can see and how it behaves, with name, slug, instructions and groqFilter fields.

Setup skill

create-agent-with-sanity-context skill guides coding agents through Studio config and example agent setup.

Supported groqFilter operators