Logo
Sign in
Product Logo
Agent ActionsSanity

APIs for AI-powered generation, transformation, and translation of structured content directly within Sanity’s Content Lake.

Vendor

Vendor

Sanity

Company Website

Company Website

Product details

Sanity Agent Actions are a set of schema-aware APIs that enable programmatic generation, transformation, translation, and patching of structured content using large language models. These actions are deeply integrated into the Sanity Content Lake, allowing users to automate content operations such as creating new documents, modifying existing content, translating between languages, generating images, and running LLM prompts—all while ensuring outputs conform to the defined schema. Agent Actions can be triggered from any environment where code runs, including CI/CD pipelines, webhooks, Sanity Functions, and custom components, supporting scalable and programmable content workflows without the need for manual intervention or third-party AI integrations.

Key Features

Schema-aware AI Content Generation Automate the creation of new content that fits your Sanity schema.

  • Generate new documents or fields using LLMs.
  • Ensure all outputs are validated against your schema.
  • Use structured prompts and live content values for contextual results.

Content Transformation Modify existing content programmatically while preserving structure.

  • Rework structure, style, or tone of documents.
  • Apply bulk updates or single-field changes.
  • Standardize or adapt imported data at scale.

Automated Translation Translate documents or fields between languages, respecting schema and intent.

  • Translate entire documents or specific fields.
  • Use style guides to control tone and terminology.
  • Preserve protected phrases and legal language.

Image Generation Create images based on document fields or prompts.

  • Integrate image generation into content workflows.
  • Configure schema to support AI-assisted images.

Prompt and Patch APIs Run LLM prompts for suggestions or ideas without mutating documents; patch documents while enforcing schema compliance.

  • Use agent.action.prompt for LLM requests.
  • Use agent.action.patch for schema-aware document updates.

Flexible Integration Trigger actions from any code environment.

  • Integrate with APIs, scripts, CI/CD, webhooks, or Sanity Studio.
  • Run synchronously or in the background.

Benefits

Accelerate Content Operations Automate repetitive or large-scale content tasks.

  • Reduce manual editing and translation work.
  • Speed up content creation and localization processes.

Ensure Consistency and Compliance Maintain structured, schema-valid content across your datasets.

  • Prevent schema violations and data inconsistencies.
  • Standardize content style and terminology.

Programmable and Scalable Adapt to complex or evolving workflows.

  • Scale automation from single fields to entire datasets.
  • Integrate with existing DevOps and editorial pipelines.