sanity-io avatar

Create Agent With Sanity Context

Helps you set up AI agents that can query and reason over Sanity CMS content through the Agent Context MCP server. Instead of just doing semantic search over embedded text, agents get your actual schema and learn GROQ, so they can filter by real fields, follow references, and understand content relationships. Walks through Studio plugin setup, MCP connection patterns, and how to write instructions that teach the production agent your domain. The implementation works with any LLM provider. Useful when you want a chatbot or assistant that needs to navigate structured content intelligently, not just find similar text. The distinction between base URLs and document URLs matters for configuration management.

skills.sh installs
512
GitHub stars
4
last updated
Jul 14, 2026

Install

$ npx -y skills add sanity-io/agent-context --skill create-agent-with-sanity-context --agent claude-code

Installs into .claude/skills of the current project.

Files

Build an Agent with Sanity Context

Give AI agents intelligent access to your Sanity content. Unlike embedding-only approaches, Sanity Context is schema-aware—agents can reason over your content structure, query with real field values, follow references, and combine structural filters with semantic search.

Sanity Context gives agents your schema and teaches them GROQ, but it can't know your domain. You close that gap through the Instructions field (dataset-specific query guidance) and optionally the system prompt (agent behavior and tone).

Three actors in this workflow:

  • You — the agent executing this skill, helping the user set things up
  • The user — the human you're working with, who knows their domain and data
  • The production agent — the agent being built, which will serve end users

What You'll Need

The agent code needs only three values:

Sponsors

Details

Repository
github.com/sanity-io/agent-context
Category
AI & Agent Building
First seen
Jun 3, 2026

More from sanity-io/agent-context

All 3
1aradotso avatarcodesight-ai-contextaradotso/trending-skillscodesight ai context504skills.sh installs
2sickn33 avatarprompt-engineering-patternssickn33/antigravity-awesome-skillsprompt engineering patterns442skills.sh installs
3jaganpro avatarsf-ai-agentforce-gridjaganpro/sf-skillssf ai agentforce grid435skills.sh installs
4vercel avatarai-gatewayvercel/vercel-pluginai gateway423skills.sh installs
5secondsky avatarmcp-managementsecondsky/claude-skillsManage MCP servers - discover, analyze, execute tools/prompts/resources. Use for MCP integrations, capability discovery, tool filtering, programmatic execution,393skills.sh installs
6sickn33 avatarvector-database-engineersickn33/antigravity-awesome-skillsvector database engineer392skills.sh installs