Posts API
Create Post
Section titled “Create Post”POST /posts{ "title": "My Post Title", "content": "# Hello\n\nMarkdown content here.", "slug": "my-post", "tags": ["tutorial", "ai"], "status": "draft", "meta": { "description": "Custom meta description", "og_image": "https://example.com/image.png" }}title(required) — Post titlecontent(required) — Markdown content (max 1MB)slug— URL slug (auto-generated from title if omitted)tags— Array of strings (max 10, each max 50 chars)status—"draft"(default) or"published"meta.description— Auto-generated from content if omittedmeta.og_image— Custom OG image URL
Response (201):
{ "id": "uuid", "slug": "my-post", "url": "https://myblog.postlark.ai/my-post", "status": "draft", "created_at": "2026-03-24T..."}List Posts
Section titled “List Posts”GET /posts?status=published&tag=tutorial&page=1&per_page=20&sort=created_at&order=descResponse:
{ "data": [...], "pagination": { "page": 1, "per_page": 20, "total": 42, "total_pages": 3 }}Get Post
Section titled “Get Post”GET /posts/:slugReturns the full post object including content_md (Markdown source) and content_html.
Update Post
Section titled “Update Post”PUT /posts/:slugPartial update — only include fields you want to change.
{ "title": "Updated Title", "content": "Updated markdown", "tags": ["new-tag"]}Delete Post
Section titled “Delete Post”DELETE /posts/:slugPermanent deletion. KV cache and CDN are purged automatically.
Publish
Section titled “Publish”POST /posts/:slug/publishChanges status from draft → published. Syncs to KV and makes the post accessible on the blog.
Schedule (Creator+)
Section titled “Schedule (Creator+)”POST /posts/:slug/schedule{ "scheduled_at": "2026-04-01T09:00:00Z"}Requires Creator plan or above. The post will be auto-published at the specified time.