Context and KBs now power the Ask AI agent, plus new guides and improvements across the platform
Published: October 30, 2026
This month we added new guides for dataset environments, upgrading older @sanity/client versions, and diagnosing API request spikes. The docs site also adds an improved “Ask agent” feature, powered by Sanity Context and Knowledge Bases.
New and updated docs
Datasets, environments, and limits
- New guide: Development, staging, and production environments explains how drafts, releases, preview, separate datasets, Cloud Clone, and export and import fit together across environments.
- How to use Hot Swapping for datasets now lists what doesn't work through a dataset alias, and scopes hot swapping to recovery and breaking migrations.
- Drafts and versions (previously Drafts) now covers both draft and version documents.
- Backups clarifies which plans include backups, that you turn them on per dataset, and how to confirm they're running.
- Technical limits adds the limit of 200 active releases per dataset, and clarifies that document limits are plan quotas counted across datasets.
Studio
- New guide: Archive documents without deleting them compares unpublishing, an archived field, deleting and restoring, and unpublishing in a release.
- New guide: Reorganize your structure without breaking links shows how to rename and move Structure Builder items without breaking saved URLs.
- New guide: Re-enable browser autocomplete on Studio fields covers per-field and studio-wide overrides.
- Validation shows how to restrict publishing by user role with
context.currentUser. - Handle intents in the Structure Tool explains how to route documents of the same type to different lists based on a field value.
Client libraries and APIs
- New guide: Upgrade @sanity/client from an older major version covers the breaking changes in each major version from v3 to v8.
- Advanced client patterns with @sanity/client adds error handling and routing requests through a proxy. Working with assets in @sanity/client adds upload progress tracking.
- New guide: Diagnose an API request spike helps you find the cause of unexpected API usage with your request logs.
- Add live content to your application covers private datasets, and the new Relay live draft updates through your server guide shows how to get draft-aware live updates without a token in the browser.
- Command Line Interface (CLI) now lists the CLI's requirements, including the hosts to allowlist on restricted networks.
Media Library and assets
- New guide: Update an asset to a new version with the API.
- New guide: Use Media Library with AI agents covers the Media Library tools in the Sanity MCP server, including uploading files from your computer.
- Working with video shows how to get static MP4 renditions of Media Library videos.
- Assets and Keeping your data safe clarify that dataset assets are always public on the asset CDN, even in private datasets.
Functions, Blueprints, and App SDK
- New guide: Manage stacks covers listing, inspecting, and removing Blueprints stacks. The stack limit is now correctly listed as 10 per scope.
- Add environment variables to functions documents the 4KB size limit, and Functions cheat sheet shows how to keep functions from running during an import or sync.
- Create a PubSub function explains that PubSub functions only run when another function invokes them.
- App SDK deployment shows how to turn on auto-updates for App SDK apps, and warns against putting secrets in
SANITY_APP_environment variables. - App SDK and TypeGen is rewritten for the
typegen.resourcesworkflow, with a new Migrate from experimental TypeGen in the App SDK guide.
Sanity Context and Content Agent
- Context MCP tools adds the
knowledge_base_searchtool. The Context MCP no longer reads atoolsURL parameter, so Context MCP reference and Inline initial context into your system prompt now cover filtering tools on the client side. - Content Agent for Linear is now in the Content Agent navigation, and the Slack and Linear guides explain when the agent can publish.
- Get started with Sanity Content Agent adds the registration step for self-hosted studios.
Organizations, billing, and access
- New: Spending alerts explains how to get notified as your organization's overage spending grows.
- New: Export activity to Google Cloud Storage and the Activity Feed Export data reference.
- Set up single sign-on with SAML explains that role mapping is additive, applies at first login, and doesn't remove users who leave your identity provider.
- Document mutation patterns and Build a custom role with the Access API explain that purging history requires the
editHistorypermission, which no predefined role grants.
Astro
The Astro docs now recommend the Sanity-maintained @portabletext/astro package (a fork of the community package), and Configuring @sanity/astro documents the clients option added in @sanity/astro 3.6.0.
Platform updates
Ask agent, powered by Sanity Context
The docs site's AI assistant is now powered by Sanity Context and Knowledge Bases, the same tools we document for building your own agents.
- Open it from the “Ask agent” button.
- Use Ask about this page on any article to ask a question with that page as context.
- Type a question into search and send it to the Ask agent.
Smaller improvements
- Code blocks have a Copy link button, so you can link straight to an example.
- Deep links to a code block or heading that is otherwise not rendered (hidden inside a tab, collapsed inside a snippet, etc) will automatically show and render on load.
- We now check the docs for broken internal and external links on a schedule, and block redirects that would break existing pages.