Create post OAuth Scope: posts:write

<Note title="Currently in beta" icon="b"> This feature is currently in beta, the API is subject to change, and available only to Enterprise users.<br/><br/>To inquire about Enterprise pricing, please visit our <a href="https://www.beehiiv.com/enterprise">Enterprise page</a>. </Note> Create a post for a specific publication.

Authentication

AuthorizationBearer

Bearer authentication of the form Bearer <token>, where token is your auth token.

Path parameters

publicationIdstringRequiredformat: "^(pub_[0-9a-fA-F\-]+)$"
The prefixed ID of the publication object

Request

This endpoint expects an object.
titlestringRequired
The title of the post.
body_contentstringOptional
The content of the post as raw HTML. Either this field OR the blocks field must be provided.
blockslist of objectsOptional

The structured content blocks that make up the post. Either this field OR the body_content field must be provided.

subtitlestringOptional
The subtitle of the post.
post_template_idstringOptionalformat: "^(post_template_[0-9a-fA-F\-]+)$"
The ID of the template to use for the post. If not provided, the default template will be used.
statusenumOptionalDefaults to confirmed

The status of the post. If not provided, the default (confirmed) value will be used and the post will either publish immediately (if no scheduled_at is provided) or at the scheduled_at time.

Allowed values:
scheduled_atdatetimeOptional

The time in which the post will be published. If not provided, the post will be published immediately unless status is set to draft. A draft post cannot be scheduled.

email_capture_type_overrideenumOptional
The email capture type to use for this post. If not provided, the default value will be used.
Allowed values:
override_scheduled_atdatetimeOptional

If you wish to display a date other than the scheduled_at date in the email, you can provide a date here. This will not affect the actual publish date of the post.

social_shareenumOptional
The social share type to use for this post. If not provided, the default value will be used.
Allowed values:
thumbnail_image_urlstringOptional
The URL of the thumbnail image to use for the post. If not provided, the default value will be used.
recipientsobjectOptional
The recipients to use for this post. If not provided, the default value will be used.
email_settingsobjectOptional
The email settings to use for this post. If not provided, the default value will be used.
web_settingsobjectOptional
The web settings to use for this post. If not provided, the default value will be used.
seo_settingsobjectOptional
The metadata to use for this post. If not provided, the default value will be used.
content_tagslist of stringsOptional
The content tags to use for this post. If not provided, the default value will be used.
headersmap from strings to stringsOptional
The headers to use for this post. If not provided, the default value will be used.
custom_fieldsmap from strings to stringsOptional
The custom fields to use for this post. If not provided, the default value will be used.

Response

Created
dataobject

Errors