Sanity agent skills for Claude Code, Cursor and RevampKey

5 ready-made playbooks that teach an AI agent how to do real Sanity work: which tools to call, what to check first, and when to stop and ask you.

Download RevampKey, freeI have it: connect Sanity

Get RevampKey to connect Sanity

RevampKey is a free desktop app for Mac, Windows and Linux. Install it, sign in, and Sanity is one click away with its skills already attached.

Download RevampKey

Not now? Use the skills in your current tool

for s in essentials content-draft-import content-model-audit dataset-health-check draft-cleanup-review; do
  curl -fsSL --create-dirs -o .claude/skills/sanity-$s/SKILL.md https://revampkey.com/marketplace/sanity/skills/$s/SKILL.md
done
Other tools

Connect Sanity once and all 5 skills install themselves and stay up to date. Mac, Windows and Linux.

All 5 Sanity skills

Each skill is one job. You ask in plain words and the agent loads the skill that matches, then follows its steps.

Start hereAsks before writing18 Sanity tools

Use the Sanity connector safely

Sets the project, dataset and auth mode before any work, picks read, draft or publish tools in order of risk, and asks for explicit approval before every change to content, schema or configuration.

Use it when

  • You have just connected Sanity and want to know what the agent can safely do.
  • An agent is about to query or edit a dataset and you need it to confirm which project and dataset.
  • A Sanity request failed with a permission or CORS error and you need to know why.

Tools it uses

  • list_organizations
  • list_projects
  • list_datasets
  • get_schema
  • list_workspace_schemas
  • get_document
  • query_documents
  • create_documents_from_json
  • create_documents_from_markdown
  • patch_document_from_json
  • patch_document_from_markdown
  • publish_documents
  • discard_drafts
  • deploy_schema
  • create_version
  • list_embeddings_indices
  • list_sanity_rules
  • add_cors_origin
Example

Connect to my Sanity project and tell me which dataset I'm working in before you change anything.

I'm connected as you via OAuth to the project Acme Website, dataset production. I'll read the schema and count the draft documents first. Nothing will be published or changed until you approve each step.

Use in RevampKey

Get RevampKey to connect Sanity

RevampKey is a free desktop app for Mac, Windows and Linux. Install it, sign in, and Sanity is one click away with its skills already attached.

Download RevampKey

Not now? Use the skills in your current tool

for s in essentials content-draft-import content-model-audit dataset-health-check draft-cleanup-review; do
  curl -fsSL --create-dirs -o .claude/skills/sanity-$s/SKILL.md https://revampkey.com/marketplace/sanity/skills/$s/SKILL.md
done
Other tools
Read the full skill →
Asks before writing12 Sanity tools

Import content into Sanity as drafts

Turns a markdown or JSON source into Sanity draft documents, mapping fields and checking for collisions first. It writes drafts only and asks before any bulk write or publish.

Use it when

  • You have a folder of markdown articles to load into a Sanity dataset
  • You need to migrate a JSON export from another CMS into your schema
  • You want to bulk-create content without publishing it straight away

Tools it uses

  • list_projects
  • list_datasets
  • list_organizations
  • get_schema
  • list_workspace_schemas
  • query_documents
  • get_document
  • create_documents_from_json
  • create_documents_from_markdown
  • publish_documents
  • patch_document_from_json
  • patch_document_from_markdown
Example

Import the 48 markdown posts in ./blog-export into the production dataset as drafts, and show me how the fields map first.

I checked the target first: project 'marketing', dataset 'production', document type 'post'. The mapping pairs front matter title, date and tags with the matching fields, and the body with the portable text field. I created 3 pilot drafts and checked them against the source. Once you approve the full run, I will create the remaining 45 as drafts. Nothing will be published.

Use in RevampKey

Get RevampKey to connect Sanity

RevampKey is a free desktop app for Mac, Windows and Linux. Install it, sign in, and Sanity is one click away with its skills already attached.

Download RevampKey

Not now? Use the skills in your current tool

for s in essentials content-draft-import content-model-audit dataset-health-check draft-cleanup-review; do
  curl -fsSL --create-dirs -o .claude/skills/sanity-$s/SKILL.md https://revampkey.com/marketplace/sanity/skills/$s/SKILL.md
done
Other tools
Read the full skill →
Asks before writing16 Sanity tools

Audit a Sanity content model

Reads your deployed and workspace schemas to find unused types, orphaned fields and risky schema changes, and reports them. It never deploys a change, and it asks before switching projects or workspaces.

Use it when

  • Before a schema refactor, to see what would break
  • When the studio has grown and nobody knows which types are still used
  • When a field rename might leave existing documents inconsistent

Tools it uses

  • list_organizations
  • list_projects
  • get_schema
  • list_workspace_schemas
  • get_project_studios
  • migration_guide
  • query_documents
  • deploy_schema
  • create_dataset
  • create_project
  • add_cors_origin
  • create_version
  • publish_documents
  • discard_drafts
  • patch_document_from_json
  • patch_document_from_markdown
Example

Audit the content model in our production dataset and tell me which document types look unused.

I checked the deployed schema and the workspace schema for the production dataset. Found 6 document types, 2 of which have no references from other types: legacyBanner and promoCard. I counted 0 documents of legacyBanner and 3 of promoCard, so promoCard may still be queried directly by the frontend. I haven't deployed anything. Want me to check the codebase for promoCard before we decide?

Use in RevampKey

Get RevampKey to connect Sanity

RevampKey is a free desktop app for Mac, Windows and Linux. Install it, sign in, and Sanity is one click away with its skills already attached.

Download RevampKey

Not now? Use the skills in your current tool

for s in essentials content-draft-import content-model-audit dataset-health-check draft-cleanup-review; do
  curl -fsSL --create-dirs -o .claude/skills/sanity-$s/SKILL.md https://revampkey.com/marketplace/sanity/skills/$s/SKILL.md
done
Other tools
Read the full skill →
Asks before writing11 Sanity tools

Check the health of your Sanity setup with AI

Surveys your Sanity projects, datasets, studios, CORS origins and embeddings indices and reports what is misconfigured or unused. It only reads, and asks before changing anything.

Use it when

  • Before a launch, to confirm every studio and front end can reach the API
  • When you inherit an account and want to know what exists
  • When you suspect old datasets or embeddings indices are costing money

Tools it uses

  • list_organizations
  • list_projects
  • list_datasets
  • get_project_studios
  • list_workspace_schemas
  • get_schema
  • list_embeddings_indices
  • get_sanity_rules
  • list_sanity_rules
  • add_cors_origin
  • deploy_schema
Example

Run a health check on my Sanity projects and tell me what needs attention.

I checked your organisation's 3 projects and 7 datasets. The main issue is that the storefront studio's origin is not in the CORS list for the production project, which would block browser requests. Two datasets, staging-old and test-copy, appear unused, and one embeddings index points at an empty dataset. I have not changed anything. Want me to add the missing origin, and should I list the two datasets for review?

Use in RevampKey

Get RevampKey to connect Sanity

RevampKey is a free desktop app for Mac, Windows and Linux. Install it, sign in, and Sanity is one click away with its skills already attached.

Download RevampKey

Not now? Use the skills in your current tool

for s in essentials content-draft-import content-model-audit dataset-health-check draft-cleanup-review; do
  curl -fsSL --create-dirs -o .claude/skills/sanity-$s/SKILL.md https://revampkey.com/marketplace/sanity/skills/$s/SKILL.md
done
Other tools
Read the full skill →
Asks before writing8 Sanity tools

Review and clean up stale Sanity drafts

Finds stale or abandoned drafts and versions in a Sanity dataset, sorts them into keep, discard and publish-candidate groups, and asks before discarding or publishing anything.

Use it when

  • Your Sanity dataset has hundreds of old drafts and you want to know which are safe to remove
  • You want to find duplicate drafts left behind by repeated saves
  • You need a reviewed list before anyone discards or publishes work

Tools it uses

  • list_datasets
  • query_documents
  • get_schema
  • get_sanity_rules
  • discard_drafts
  • publish_documents
  • create_version
  • deploy_schema
Example

Find stale drafts in our production dataset and tell me which ones we can safely discard.

I checked 412 drafts in the production dataset. 96 are publish candidates because a published copy exists with the same content, 201 are active or ambiguous and I'd leave them, and 115 are discard candidates: no edits in over a year, nearly empty, and no published counterpart. I haven't discarded anything. Tell me which group to act on and I'll list the exact IDs for your yes.

Use in RevampKey

Get RevampKey to connect Sanity

RevampKey is a free desktop app for Mac, Windows and Linux. Install it, sign in, and Sanity is one click away with its skills already attached.

Download RevampKey

Not now? Use the skills in your current tool

for s in essentials content-draft-import content-model-audit dataset-health-check draft-cleanup-review; do
  curl -fsSL --create-dirs -o .claude/skills/sanity-$s/SKILL.md https://revampkey.com/marketplace/sanity/skills/$s/SKILL.md
done
Other tools
Read the full skill →

Get all 5 without copying a file

RevampKey adds the skills when you connect Sanity, updates them for you and removes them when you disconnect.

Download RevampKey

How Sanity skills work

  1. Connect Sanity

    The Sanity MCP server gives the agent its tools.

  2. Ask in plain words

    “Import the 48 markdown posts in ./blog-export into the production dataset as drafts, and show me how the fields map first.” Each SKILL.md says when it applies, so only the one that fits is loaded.

  3. Approve any change

    The agent calls the tools in order, checks its work, and shows you any change before it makes it.

How to install Sanity skills

In RevampKey the skills install themselves when you connect Sanity. In other tools each skill is one folder with a SKILL.md file, and you also need the Sanity MCP server connected there.

About 1 minute · nothing to copy

  1. Download RevampKey for Mac, Windows or Linux and sign in.

  2. Open Connectors and connect Sanity. All 5 skills come with it and stay up to date; they go away when you remove the connector.

  3. Ask in plain language, for example “Import the 48 markdown posts in ./blog-export into the production dataset as drafts, and show me how the fields map first.”

  4. Download RevampKeyConnect Sanity · 1 click

    Get RevampKey to connect Sanity

    RevampKey is a free desktop app for Mac, Windows and Linux. Install it, sign in, and Sanity is one click away with its skills already attached.

    Download RevampKey

    Not now? Use the skills in your current tool

    for s in essentials content-draft-import content-model-audit dataset-health-check draft-cleanup-review; do
      curl -fsSL --create-dirs -o .claude/skills/sanity-$s/SKILL.md https://revampkey.com/marketplace/sanity/skills/$s/SKILL.md
    done
    Other tools

RevampKey or copy the files?

In RevampKey

  • One click when you connect Sanity
  • Updated for you when a skill improves
  • Removed when you disconnect
  • The MCP server is set up for you
  • 800+ other connectors, same way
Download free

Copy into your project

  • One command per project
  • Run it again to get updates
  • You connect the Sanity MCP server yourself
  • Works in Claude Code, Cursor, Codex and VS Code
See the command

Sanity skills FAQ

What is a Sanity agent skill?

A SKILL.md file: a short playbook an AI agent loads when your request matches it. Each Sanity skill describes one job, which Sanity tools to use in which order, what to check first and when to stop and ask you.

Do the Sanity skills change anything on their own?

The others tell the agent to show you the change and wait for a yes before it creates, edits or deletes anything in Sanity.

Which tools can use these skills?

Any agent that reads the open Agent Skills format: Claude Code, Cursor, Codex, VS Code with Copilot and RevampKey. In RevampKey they are attached when you connect Sanity; elsewhere you copy the folders into your project or skills directory.

Do I need the Sanity MCP server too?

Yes. The skills tell the agent how to do the work; the Sanity MCP server gives it the tools to do it. The Sanity MCP setup guide covers every client.

Sanity MCP server setup · This page as Markdown

Put Sanity’s best workflows in your agent

Download RevampKey, connect Sanity and ask your first question in about a minute.

Download RevampKeyConnect Sanity · 1 click

Get RevampKey to connect Sanity

RevampKey is a free desktop app for Mac, Windows and Linux. Install it, sign in, and Sanity is one click away with its skills already attached.

Download RevampKey

Not now? Use the skills in your current tool

for s in essentials content-draft-import content-model-audit dataset-health-check draft-cleanup-review; do
  curl -fsSL --create-dirs -o .claude/skills/sanity-$s/SKILL.md https://revampkey.com/marketplace/sanity/skills/$s/SKILL.md
done
Other tools