Sites and CMS

Publish to Sanity from Wavefront

Write approved articles as documents in a Sanity dataset, as drafts or published documents.

API token (Editor) Articles

What it does

Wavefront writes each approved article as a document of one type in your Sanity dataset. Drafts follow Sanity Studio's convention, so they show in Studio as drafts and never go live without a publish.

You choose which field each Wavefront field goes to, with suggestions from your existing documents. Every write changes only the mapped fields.

Before you start

  • A Sanity project and dataset with a document type for articles
  • Permission to create an API token with Editor permissions

How to connect Sanity

  1. In sanity.io/manage, open the project, then API → Tokens → Add API token with Editor permissions.
  2. In Wavefront, open Settings → Publishing and choose Add destination. Pick Sanity.
  3. Enter the project ID, the dataset (usually production) and the token.
  4. Choose Load fields, pick the document type, and type or pick the field for title, slug and body, plus any optional fields.
  5. Optionally set the body format, a live URL pattern, your Studio address, and how authors and categories are found.
  6. Choose Test connection. Wavefront reads the dataset and checks a write without saving it.

What Wavefront sends

  • Title, slug, excerpt, SEO title and description, date and canonical URL
  • The body as Portable Text, or Markdown or HTML on a text field
  • Header and body images as Sanity image assets
  • Authors and categories as references, or as text

Good to know

  • Scheduling (Sanity's Content Releases) and JSON-LD aren't supported.
  • Images are uploaded only when a document is published, at most 15 per article.
  • Withdraw unpublishes the document and keeps it as a draft.

Publish your next post with your team's sign-off

Start a 7-day trial with 300 credits and every feature. No card needed. Then $99 a month.