posts

Create a new post

Create a new post in your publication. The publication is identified by the API key provided in the Authorization header.

Requirements:

  • markdown field is required and will be converted to TipTap JSON format
  • title field is required

Behavior:

  • The post will be created as published by default. Set status to "draft" to create a draft instead
  • If sendNewsletter is true, an email will be sent to all subscribers when the post publishes
  • Set scheduledAt (Unix timestamp in milliseconds) to schedule first-publish for a future time. Must be in the future and at most 30 days out. Scheduling cannot be combined with status: "draft". When scheduled, the response status is "scheduled" and the post publishes (plus sends newsletter, if requested) at the scheduled time.
post/v1/posts

Request body

markdownstring required

Post content in Markdown format

titlestring required

Title of the post

subtitlestring

Optional subtitle or brief summary

imageUrlstring uri

Optional URL to the post's cover image

status'published' | 'draft'

Status of the post. Default: published

slugstring

Optional URL-friendly identifier for the post. If not provided, will be generated from title

postPreviewstring

Optional preview text for the post. If not provided, will be generated from content

scheduledAtinteger

Optional Unix timestamp (milliseconds) to schedule first-publish of the post at a future time. Must be in the future. Cannot be combined with status: 'draft'. When set, the post is created and queued to publish (and send newsletter, if requested) at the specified time.

Response

Post created successfully

idstring required

The ID of the created post

status'published' | 'draft' | 'scheduled' required

Final status of the post: 'published' if published immediately, 'draft' if created as a draft, 'scheduled' if queued to publish at scheduledAt

Changes